ui-process-h5 2.0.7-beta → 2.1.0-beta

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (91) hide show
  1. package/README.md +11 -204
  2. package/build/configure/README.md +211 -0
  3. package/build/configure/package.json +32 -0
  4. package/debug.js +9 -0
  5. package/index.html +12 -0
  6. package/package.json +56 -25
  7. package/src/App.vue +233 -0
  8. package/src/assets/font-icon/iconfont.scss +57 -0
  9. package/src/assets/font-icon/iconfont.ttf +0 -0
  10. package/src/assets/img/add-file.png +0 -0
  11. package/src/assets/img/arrow-right.png +0 -0
  12. package/src/assets/img/arrow.png +0 -0
  13. package/src/assets/img/check.png +0 -0
  14. package/src/assets/img/del.png +0 -0
  15. package/src/assets/img/doc.png +0 -0
  16. package/src/assets/img/file.png +0 -0
  17. package/src/assets/img/image.png +0 -0
  18. package/src/assets/img/pdf.png +0 -0
  19. package/src/assets/img/process.png +0 -0
  20. package/src/assets/img/xls.png +0 -0
  21. package/src/assets/img/zip.png +0 -0
  22. package/src/assets/js/auth.js +65 -0
  23. package/src/assets/js/errorCode.js +6 -0
  24. package/src/assets/js/message.js +352 -0
  25. package/src/assets/js/request.js +99 -0
  26. package/src/assets/js/toast.js +239 -0
  27. package/src/assets/js/top.js +229 -0
  28. package/src/assets/js/utils.js +83 -0
  29. package/src/assets/js/vuePopper.js +123 -0
  30. package/src/assets/query.png +0 -0
  31. package/src/assets/status/check.png +0 -0
  32. package/src/assets/status/del.png +0 -0
  33. package/src/assets/status/error.png +0 -0
  34. package/src/assets/status/loading.png +0 -0
  35. package/src/assets/status/success.png +0 -0
  36. package/src/main.js +17 -0
  37. package/src/packages/attchUpload/index.js +375 -0
  38. package/src/packages/attchUpload/index.scss +143 -0
  39. package/src/packages/attchUpload/index.vue +173 -0
  40. package/src/packages/downSelect/index.js +119 -0
  41. package/src/packages/downSelect/index.scss +88 -0
  42. package/src/packages/downSelect/index.vue +62 -0
  43. package/src/packages/index.js +6 -0
  44. package/src/packages/popup/index.js +125 -0
  45. package/src/packages/popup/index.scss +178 -0
  46. package/src/packages/popup/index.vue +80 -0
  47. package/src/packages/preview/index.js +40 -0
  48. package/src/packages/preview/index.vue +15 -0
  49. package/src/packages/previewImage/index.js +286 -0
  50. package/src/packages/previewImage/index.scss +76 -0
  51. package/src/packages/previewImage/index.vue +53 -0
  52. package/src/packages/process/index.js +1016 -0
  53. package/src/packages/process/index.scss +188 -0
  54. package/src/packages/process/index.vue +291 -0
  55. package/src/packages/process/operation/backNode.vue +396 -0
  56. package/src/packages/process/operation/cancel.vue +425 -0
  57. package/src/packages/process/operation/ccTask.vue +256 -0
  58. package/src/packages/process/operation/complete.vue +1384 -0
  59. package/src/packages/process/operation/counterSign.vue +498 -0
  60. package/src/packages/process/operation/delegateTask.vue +493 -0
  61. package/src/packages/process/operation/index.js +8 -0
  62. package/src/packages/process/operation/index.scss +212 -0
  63. package/src/packages/process/operation/msgList.vue +174 -0
  64. package/src/packages/process/operation/treeNode.vue +901 -0
  65. package/src/packages/process/operation/treePerson.vue +304 -0
  66. package/src/packages/submitPopup/index.js +708 -0
  67. package/src/packages/submitPopup/index.scss +190 -0
  68. package/src/packages/submitPopup/index.vue +125 -0
  69. package/src/packages/tab/index.js +236 -0
  70. package/src/packages/tab/index.scss +177 -0
  71. package/src/packages/tab/index.vue +155 -0
  72. package/src/packages/tip/index.js +80 -0
  73. package/src/packages/tip/index.scss +121 -0
  74. package/src/packages/tip/index.vue +57 -0
  75. package/src/packages/viewAttchList/index.js +138 -0
  76. package/src/packages/viewAttchList/index.scss +76 -0
  77. package/src/packages/viewAttchList/index.vue +121 -0
  78. package/src/style.css +80 -0
  79. package/vite.config.ts +118 -0
  80. package/v2/style.css +0 -1
  81. package/v2/ui-process-h5.js +0 -9945
  82. package/v2/ui-process-h5.umd.cjs +0 -18
  83. package/v2.7/style.css +0 -1
  84. package/v2.7/ui-process-h5.js +0 -9322
  85. package/v2.7/ui-process-h5.umd.cjs +0 -18
  86. package/v3/style.css +0 -1
  87. package/v3/ui-process-h5.js +0 -6842
  88. package/v3/ui-process-h5.umd.cjs +0 -6
  89. /package/{scripts → build/scripts}/postinstall.mjs +0 -0
  90. /package/{scripts → build/scripts}/switch-cli.mjs +0 -0
  91. /package/{scripts → build/scripts}/utils.mjs +0 -0
@@ -0,0 +1,177 @@
1
+ .tops-tab {
2
+ height: 100%;
3
+ }
4
+ .tops-tab-header {
5
+ display: flex;
6
+ width: 100%;
7
+ height: 45px;
8
+ font-size: 14px;
9
+ color: #333;
10
+ padding: 10px 17px;
11
+ font-weight: 500;
12
+ box-sizing: border-box;
13
+ overflow-x: auto;
14
+ white-space: nowrap;
15
+ flex-wrap: nowrap;
16
+ flex-shrink: 0;
17
+ -ms-overflow-style: none;
18
+ position: relative;
19
+ background-color: #fff;
20
+ }
21
+
22
+ .tops-tab-header::after {
23
+ content: "";
24
+ position: absolute;
25
+ width: 100%;
26
+ height: 1px;
27
+ background-color: #f2f2f2;
28
+ left: 0;
29
+ bottom: 0;
30
+ }
31
+
32
+ .tops-tab-header::-webkit-scrollbar {
33
+ display: none;
34
+ }
35
+
36
+ .tops-tab-header-items {
37
+ white-space: nowrap;
38
+ padding-right: 10px;
39
+ box-sizing: border-box;
40
+ display: inline-block;
41
+ height: 100%;
42
+ text-align: center;
43
+ margin-right: 32px;
44
+ font-weight: 400;
45
+ font-size: 15px;
46
+ text-align: left;
47
+ color: #333;
48
+ display: flex;
49
+ align-items: center;
50
+ }
51
+
52
+ .tops-tab-header-items:nth-last-child(2) {
53
+ padding-right: 0;
54
+ margin-right: 0;
55
+ }
56
+
57
+ .tops-tab-header .active {
58
+ position: relative;
59
+ color: #1389ff;
60
+ font-family: "PingFang SC Bold";
61
+ font-weight: 700;
62
+ font-size: 15px;
63
+ text-align: left;
64
+ }
65
+
66
+ .tops-tab-header .bottom-line {
67
+ width: 30px;
68
+ height: 3px;
69
+ border-radius: 1.5px;
70
+ background-color: #1389ff;
71
+ position: absolute;
72
+ bottom: 1px;
73
+ left: 0;
74
+ }
75
+ .tops-tab-body {
76
+ height: calc(100% - 45px);
77
+ overflow-y: auto;
78
+ }
79
+
80
+ .seal-list__item {
81
+ padding: 6px 10px;
82
+ margin: 10px;
83
+ margin-bottom: 0px;
84
+ padding-bottom: 0px;
85
+ background-color: #ffffff;
86
+ border-radius: 10px;
87
+ box-sizing: border-box;
88
+ }
89
+
90
+ .seal-list__item:last-child {
91
+ margin-bottom: 15px;
92
+ }
93
+
94
+ .seal-list__item .seal-list__item--header {
95
+ margin-bottom: 6px;
96
+ display: flex;
97
+ align-items: center;
98
+ }
99
+
100
+ .seal-list__item .seal-list__item--header span:first-of-type {
101
+ font-size: 15px;
102
+ margin-right: 6px;
103
+ font-weight: bold;
104
+ }
105
+
106
+ .seal-list__item .seal-list__item--option {
107
+ display: flex;
108
+ justify-content: space-between;
109
+ align-items: center;
110
+ font-size: 14px;
111
+ padding: 10px 0;
112
+ color: #333;
113
+ }
114
+
115
+ .seal-list__item .seal-list__item--option span:last-child {
116
+ max-width: 144px;
117
+ /* overflow: hidden;
118
+ white-space: nowrap;
119
+ text-overflow: ellipsis; */
120
+ color: #888;
121
+ }
122
+
123
+ .seal-list__item .seal-list__item--attch {
124
+ font-size: 14px;
125
+ padding: 10px 0;
126
+ color: #333;
127
+ text-align: right;
128
+ color: #1389ff;
129
+ }
130
+
131
+ .seal-list__item .seal-list__item--actions {
132
+ margin-top: 12px;
133
+ position: relative;
134
+ display: flex;
135
+ justify-content: space-around;
136
+ align-items: center;
137
+ }
138
+
139
+ .seal-list__item .seal-list__item--actions ::before {
140
+ content: "";
141
+ top: 0;
142
+ width: 100%;
143
+ transform: scaleY(0.5);
144
+ transform-origin: top;
145
+ border-top: 1px #e8e8e8 solid;
146
+ position: absolute;
147
+ }
148
+
149
+ .seal-list__item .seal-list__item--actions .van-button {
150
+ width: 50%;
151
+ }
152
+
153
+ .seal-list__item .seal-list__item--actions .van-button ::after {
154
+ content: "";
155
+ height: 60%;
156
+ border-left: 1px #e8e8e8 solid;
157
+ position: absolute;
158
+ left: 100%;
159
+ top: 50%;
160
+ transform: translate(-50%, -50%) scaleX(0.5);
161
+ transform-origin: left;
162
+ }
163
+
164
+ .seal-list__item .seal-list__item--actions .van-button:last-child ::after {
165
+ content: none;
166
+ }
167
+
168
+ .textnone {
169
+ text-align: center;
170
+ padding-top: 30px;
171
+ color: #999;
172
+ font-size: 14px;
173
+ }
174
+
175
+ .tops-tab-body-taskcommentlist{
176
+ overflow-y: auto;
177
+ }
@@ -0,0 +1,155 @@
1
+ <template>
2
+ <div class="tops-tab">
3
+ <div class="tops-tab-header">
4
+ <template v-for="(item, i) of isTapList">
5
+ <div
6
+ class="tops-tab-header-items"
7
+ :class="[item.key === active ? 'active' : '']"
8
+ @click="handleActive(item.key, i)"
9
+ >
10
+ {{ item.label }}
11
+ </div>
12
+ </template>
13
+ <div class="bottom-line" v-if="isTapList.length"></div>
14
+ </div>
15
+ <div class="tops-tab-body">
16
+ <div
17
+ v-for="item in isTapList"
18
+ :key="item.key"
19
+ v-show="active === item.key"
20
+ style="height: 100%;"
21
+ :class="[item.key === 'c' && 'tops-tab-body-taskcommentlist']"
22
+ >
23
+ <!-- :taskNode="getTaskNode()" -->
24
+ <slot
25
+ v-if="item.key === 'a' && item.type === 'default'"
26
+ name="default"
27
+ ></slot>
28
+ <div style="height:100%;"
29
+ v-if="item.key === 'b' && item.type === 'default'"
30
+ :name="item.slot"
31
+ >
32
+ <div
33
+ style="padding: 10px 20px; color: #1389ff;"
34
+ v-if="trackUrl"
35
+ @click="() => (visibleTack = true)"
36
+ >
37
+ 查看流程节点信息
38
+ </div>
39
+ <iframe
40
+ v-if="trackUrl"
41
+ :src="trackUrl"
42
+ style="
43
+ width: 100%;
44
+ height: calc(100% - 41px);
45
+ border: none;
46
+ "
47
+ scrolling="no"
48
+ frameborder="0"
49
+ ></iframe>
50
+ <div v-else class="textnone">
51
+ 暂无流程图
52
+ </div>
53
+ </div>
54
+ <div style="height:100%;"
55
+ v-if="item.key === 'c' && item.type === 'default'"
56
+ >
57
+ <template v-if="taskCommentList.length > 0">
58
+ <div
59
+ v-for="(item, index) in taskCommentList"
60
+ :key="item.id"
61
+ class="seal-list__item"
62
+ >
63
+ <div>
64
+ <div class="seal-list__item--option">
65
+ <span>节点名称</span>
66
+ <span>{{ item.activityName }}</span>
67
+ </div>
68
+ <div class="seal-list__item--option">
69
+ <span>审批人</span>
70
+ <span>{{ item.createUserName }}</span>
71
+ </div>
72
+ <div class="seal-list__item--option">
73
+ <span>审批操作</span>
74
+ <span>{{ item.actionName }}</span>
75
+ </div>
76
+ <div class="seal-list__item--option">
77
+ <span>审批意见</span>
78
+ <span v-html="item.msg"></span>
79
+ </div>
80
+ <div class="seal-list__item--option">
81
+ <span>审批时间</span>
82
+ <span>{{ item.createDate }}</span>
83
+ </div>
84
+ <div
85
+ v-if="
86
+ item.metaAnnexList &&
87
+ item.metaAnnexList.length
88
+ "
89
+ class="seal-list__item--attch"
90
+ @click="viewList(item.metaAnnexList)"
91
+ >
92
+ <span>查看附件</span>
93
+ </div>
94
+ </div>
95
+ </div>
96
+ </template>
97
+ <div v-else class="textnone">暂无数据</div>
98
+ </div>
99
+ <slot v-if="item.type == 'slot'" :name="item.slot"></slot>
100
+ </div>
101
+ </div>
102
+ <TopPopup
103
+ v-bind:visible="visible"
104
+ v-on:update:visible="(val) => (visible = val)"
105
+ ref="TopPopup"
106
+ titleText="附件列表"
107
+ isDrawer
108
+ :isIndex="5"
109
+ >
110
+ <ViewAttchList :inList="inList"></ViewAttchList>
111
+ </TopPopup>
112
+ <TopPopup
113
+ v-bind:visible="visibleTack"
114
+ v-on:update:visible="(val) => (visibleTack = val)"
115
+ ref="TopPopups"
116
+ titleText="流程信息"
117
+ isDrawer
118
+ width="60vw"
119
+ >
120
+ <template v-if="trackListss && trackListss.length">
121
+ <div
122
+ v-for="(item, index) in trackListss"
123
+ :key="item.id"
124
+ class="seal-list__item"
125
+ >
126
+ <div>
127
+ <div class="seal-list__item--option">
128
+ <span>序号</span>
129
+ <span style="max-width: 100px;">{{ item.no }}</span>
130
+ </div>
131
+ <div class="seal-list__item--option">
132
+ <span>节点名称</span>
133
+ <span style="max-width: 100px;"
134
+ >{{ item.name
135
+ }}{{
136
+ item.type !== "普通" ? `[${item.type}]` : ""
137
+ }}</span
138
+ >
139
+ </div>
140
+ <div class="seal-list__item--option">
141
+ <span>审批人</span>
142
+ <span style="max-width: 100px;">{{
143
+ item.assigneeNames
144
+ }}</span>
145
+ </div>
146
+ </div>
147
+ </div>
148
+ </template>
149
+ </TopPopup>
150
+ </div>
151
+ </template>
152
+ <script src="./index.js"></script>
153
+ <style lang="scss" scoped>
154
+ @import "./index.scss";
155
+ </style>
@@ -0,0 +1,80 @@
1
+ import { defineComponent } from "vue-demi";
2
+ import error from "@/assets/status/error.png";
3
+ import loading from "@/assets/status/loading.png";
4
+ import success from "@/assets/status/success.png";
5
+
6
+ export default defineComponent({
7
+ name: "TopTips",
8
+ props: {
9
+ text: { default: "", type: String }, // tips文本展示
10
+ type: { default: "default", type: String }, // tips 类型 (success, error, loading)
11
+ statusTips: { default: false, type: Boolean }, // 开启状态展示
12
+ domNode: { default: "", type: String },
13
+ visible: { default: false, type: Boolean },
14
+ },
15
+ data() {
16
+ return {
17
+ show: false,
18
+ status: "",
19
+ timeOut: null,
20
+ };
21
+ },
22
+ computed: {
23
+ error() {
24
+ return error;
25
+ },
26
+ loading() {
27
+ return loading;
28
+ },
29
+ success() {
30
+ return success;
31
+ },
32
+ },
33
+ watch: {
34
+ type: {
35
+ handler(val, preVal) {
36
+ if (val == "loading") {
37
+ clearInterval(this.timeOut);
38
+ return;
39
+ } else {
40
+ this.timeOut = setTimeout(() => {
41
+ this.show = false;
42
+ }, 1500);
43
+ }
44
+ },
45
+ immediate: true,
46
+ deep: true,
47
+ },
48
+ },
49
+ mounted() {
50
+ this.$nextTick(() => {
51
+ const body = document.getElementsByClassName("process-warp")[0]
52
+ ? document.getElementsByClassName("process-warp")[0]
53
+ : document
54
+ .getElementsByClassName("sumbmitPopup-index-sumbit")[0]
55
+ .getElementsByClassName("top-popup")[0];
56
+ if (body.append) {
57
+ body.append(this.$el);
58
+ } else {
59
+ body.appendChild(this.$el);
60
+ }
61
+ });
62
+ },
63
+ methods: {
64
+ handleOpen() {
65
+ if (!this.show) {
66
+ this.show = true;
67
+ if (this.type == "loading") {
68
+ clearInterval(this.timeOut);
69
+ } else {
70
+ this.timeOut = setTimeout(() => {
71
+ this.show = false;
72
+ }, 1500);
73
+ }
74
+ }
75
+ },
76
+ handleClose() {
77
+ this.show = false;
78
+ },
79
+ },
80
+ });
@@ -0,0 +1,121 @@
1
+ .top-tipss {
2
+ position: absolute;
3
+ z-index: 2999;
4
+ top: 50%;
5
+ left: 50%;
6
+ -webkit-transform: translate(-50%, -50%);
7
+ transform: translate(-50%, -50%);
8
+ text-align: center;
9
+ max-width: 80%;
10
+ transition: all 0.3s ease;
11
+ visibility: hidden;
12
+ opacity: 0;
13
+ }
14
+
15
+ .top-tipss-animal {
16
+ animation: shows 1.5s ease;
17
+ }
18
+
19
+ .top-tipss-mask {
20
+ position: fixed;
21
+ width: 100vw;
22
+ height: 100vh;
23
+ background-color: #000;
24
+ opacity: 0.7;
25
+ top: 0;
26
+ left: 0;
27
+ z-index: 1999;
28
+ transition: all 0.3s ease;
29
+ }
30
+
31
+ .top-tipss-text {
32
+ display: inline-block;
33
+ vertical-align: middle;
34
+ color: #fff;
35
+ padding: 10px 20px;
36
+ border-radius: 5px;
37
+ font-size: 13px;
38
+ text-align: center;
39
+ max-width: 100%;
40
+ word-break: break-all;
41
+ white-space: normal;
42
+ background-color: rgba(17, 17, 17, 0.7);
43
+ }
44
+ .top-tipss-status {
45
+ width: 120px;
46
+ height: 120px;
47
+ border-radius: 12px;
48
+ background-color: rgba(17, 17, 17, 0.7);
49
+ display: flex;
50
+ }
51
+
52
+ .top-tipss-loadinig,
53
+ .top-tipss-success,
54
+ .top-tipss-error {
55
+ width: 100%;
56
+ height: 100%;
57
+ display: flex;
58
+ align-items: center;
59
+ justify-content: center;
60
+ flex-direction: column;
61
+ }
62
+
63
+ .top-tipss-loadinig img,
64
+ .top-tipss-success img,
65
+ .top-tipss-error img {
66
+ width: 40px;
67
+ height: 40px;
68
+ }
69
+
70
+ .top-tipss-loadinig img {
71
+ -webkit-animation: rotation 0.8s linear infinite;
72
+ animation: rotation 0.8s linear infinite;
73
+ }
74
+
75
+ .top-tipss-status-text {
76
+ color: #fff;
77
+ font-size: 12px;
78
+ padding: 10px 5px 0;
79
+ }
80
+
81
+ @-webkit-keyframes rotation {
82
+ 0% {
83
+ transform: rotate(0deg);
84
+ }
85
+ 100% {
86
+ transform: rotate(360deg);
87
+ }
88
+ }
89
+
90
+ .fade-enter,
91
+ .fade-leave-to {
92
+ visibility: hidden;
93
+ opacity: 0;
94
+ }
95
+ .fade-enter-active,
96
+ .fade-leave-active {
97
+ transition: opacity 2s;
98
+ }
99
+
100
+ @keyframes shows {
101
+ 0% {
102
+ visibility: hidden;
103
+ opacity: 0;
104
+ }
105
+ 25% {
106
+ visibility: hidden;
107
+ opacity: 0.5;
108
+ }
109
+ 50% {
110
+ visibility: visible;
111
+ opacity: 1;
112
+ }
113
+ 75% {
114
+ visibility: hidden;
115
+ opacity: 0.5;
116
+ }
117
+ 100% {
118
+ visibility: hidden;
119
+ opacity: 0.5;
120
+ }
121
+ }
@@ -0,0 +1,57 @@
1
+ <template>
2
+ <div v-if="show">
3
+ <div
4
+ v-if="!statusTips"
5
+ class="top-tipss"
6
+ :style="
7
+ show
8
+ ? 'visibility: visible; opacity: 1;'
9
+ : 'visibility: hidden; opacity: 0;'
10
+ "
11
+ >
12
+ <div v-if="text" class="top-tipss-text">{{ text }}</div>
13
+ </div>
14
+ <div
15
+ v-else
16
+ class="top-tipss"
17
+ :style="
18
+ show
19
+ ? 'visibility: visible; opacity: 1;'
20
+ : 'visibility: hidden; opacity: 0;'
21
+ "
22
+ >
23
+ <div class="top-tipss-status">
24
+ <div class="top-tipss-loadinig" v-if="type == 'loading'">
25
+ <img :src="loading" />
26
+ <div v-if="text" class="top-tipss-status-text">
27
+ {{ text }}
28
+ </div>
29
+ </div>
30
+ <div class="top-tipss-success" v-if="type == 'success'">
31
+ <img :src="success" />
32
+ <div v-if="text" class="top-tipss-status-text">
33
+ {{ text }}
34
+ </div>
35
+ </div>
36
+ <div class="top-tipss-error" v-if="type == 'error'">
37
+ <img :src="error" />
38
+ <div v-if="text" class="top-tipss-status-text">
39
+ {{ text }}
40
+ </div>
41
+ </div>
42
+ </div>
43
+ </div>
44
+ <div
45
+ class="top-tipss-mask"
46
+ :style="
47
+ show && statusTips
48
+ ? 'visibility: visible; opacity: .7;'
49
+ : 'visibility: hidden; opacity: 0;'
50
+ "
51
+ ></div>
52
+ </div>
53
+ </template>
54
+ <script src="./index.js"></script>
55
+ <style lang="scss" scoped>
56
+ @import "./index.scss";
57
+ </style>