yahee-components 0.0.10 → 0.0.12

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 (46) hide show
  1. package/es/api/server.js +26 -10
  2. package/es/country-platform-shop-condition/country-platform-shop-condition.vue.js +218 -0
  3. package/es/country-platform-shop-condition/country-platform-shop-condition.vue2.js +4 -0
  4. package/es/country-platform-shop-condition/index.js +7 -0
  5. package/es/country-platform-shop-condition/style/index.css +48 -0
  6. package/es/drop-down-condition/drop-down-condition.vue.js +215 -0
  7. package/es/drop-down-condition/drop-down-condition.vue2.js +4 -0
  8. package/es/drop-down-condition/index.js +7 -0
  9. package/es/drop-down-condition/style/index.css +45 -0
  10. package/es/index.js +23 -15
  11. package/es/installs.js +18 -10
  12. package/es/left-condition/index.js +7 -0
  13. package/es/left-condition/left-condition-sub.vue.js +95 -0
  14. package/es/left-condition/left-condition-sub.vue2.js +4 -0
  15. package/es/left-condition/left-condition.vue.js +214 -0
  16. package/es/left-condition/left-condition.vue2.js +4 -0
  17. package/es/left-condition/style/index.css +11 -0
  18. package/es/left-condition-enum/index.js +7 -0
  19. package/es/left-condition-enum/left-condition-enum.vue.js +76 -0
  20. package/es/left-condition-enum/left-condition-enum.vue2.js +4 -0
  21. package/es/left-condition-enum/style/index.css +0 -0
  22. package/es/static/CommonObject.js +4 -0
  23. package/es/style.css +81 -196
  24. package/es/utils/style.js +28 -0
  25. package/es/utils/translate.js +39 -22
  26. package/lib/country-platform-shop-condition/style/index.css +48 -0
  27. package/lib/drop-down-condition/style/index.css +45 -0
  28. package/lib/left-condition/style/index.css +11 -0
  29. package/lib/left-condition-enum/style/index.css +0 -0
  30. package/lib/style.css +81 -196
  31. package/package.json +1 -1
  32. package/types/src/components.d.ts +4 -0
  33. package/types/src/country-platform-shop-condition/country-platform-shop-condition.d.ts +17 -0
  34. package/types/src/country-platform-shop-condition/country-platform-shop-condition.vue.d.ts +14 -0
  35. package/types/src/country-platform-shop-condition/index.d.ts +16 -0
  36. package/types/src/drop-down-condition/drop-down-condition.d.ts +6 -0
  37. package/types/src/drop-down-condition/drop-down-condition.vue.d.ts +38 -0
  38. package/types/src/drop-down-condition/index.d.ts +40 -0
  39. package/types/src/installs.d.ts +259 -2
  40. package/types/src/left-condition/index.d.ts +69 -0
  41. package/types/src/left-condition/left-condition-sub.vue.d.ts +47 -0
  42. package/types/src/left-condition/left-condition.d.ts +5 -0
  43. package/types/src/left-condition/left-condition.vue.d.ts +68 -0
  44. package/types/src/left-condition-enum/index.d.ts +153 -0
  45. package/types/src/left-condition-enum/left-condition-enum.d.ts +5 -0
  46. package/types/src/left-condition-enum/left-condition-enum.vue.d.ts +151 -0
package/es/style.css CHANGED
@@ -81,225 +81,110 @@
81
81
  padding: 5px 11px;
82
82
  }
83
83
 
84
- .yahee-operation-log {
85
- min-width: 350px;
86
- }
87
- .yahee-operation-log .infinite-list-wrapper {
88
- overflow: hidden;
89
- padding: 10px 4px;
90
- }
91
- .yahee-operation-log .infinite-list-wrapper .list-item-left {
92
- display: flex;
93
- justify-content: flex-start;
94
- gap: 10px;
95
- margin-bottom: 18px;
96
- }
97
- .yahee-operation-log .infinite-list-wrapper .list-item-left .date {
98
- margin-top: 6px;
99
- margin-left: 8px;
100
- }
101
- .yahee-operation-log .infinite-list-wrapper .list-item-left .name {
102
- flex: none;
103
- height: -moz-fit-content;
104
- height: fit-content;
105
- padding: 5px 8px;
106
- text-align: center;
107
- border-radius: 2px;
108
- background: #E8FFE8;
109
- }
110
- .yahee-operation-log .infinite-list-wrapper .list-item-left .content {
111
- border: 1px solid #ccc;
112
- border-radius: 4px;
113
- padding: 10px;
114
- margin-left: -8px;
115
- background: #F7FFF7;
116
- }
117
- .yahee-operation-log .infinite-list-wrapper .list-item-right {
118
- display: flex;
119
- justify-content: flex-end;
120
- gap: 10px;
121
- margin-bottom: 18px;
122
- }
123
- .yahee-operation-log .infinite-list-wrapper .list-item-right .date {
124
- margin-top: 6px;
125
- margin-right: 8px;
126
- }
127
- .yahee-operation-log .infinite-list-wrapper .list-item-right .name {
128
- flex: none;
129
- height: -moz-fit-content;
130
- height: fit-content;
131
- padding: 5px 8px;
132
- text-align: center;
133
- border-radius: 2px;
134
- background: #f1f1f1;
84
+ :deep(.custom-button + .custom-button) {
85
+ margin-left: 5px;
86
+ margin-bottom: 5px;
87
+ position: relative;
88
+ top: 2px;
135
89
  }
136
- .yahee-operation-log .infinite-list-wrapper .list-item-right .content {
137
- text-align: right;
138
- padding: 10px;
139
- margin-right: -8px;
140
- border: 1px solid #f1f1f1;
141
- border-radius: 4px;
142
- background: #FAFAFA;
90
+
91
+ :deep(.custom-button) {
92
+ padding: 1px 4px;
93
+ height: 22px;
143
94
  }
144
- .yahee-operation-log .bg-link {
145
- color: #3366cc;
146
- cursor: pointer;
95
+
96
+ .yahee-drop-down-condition {
97
+ /* 滚动槽 */
98
+ /* 滚动条滑块 */
147
99
  }
148
- .yahee-operation-log .imgBox {
100
+ .yahee-drop-down-condition .checkbox-group {
149
101
  display: flex;
150
- flex-wrap: wrap;
102
+ flex-direction: column;
151
103
  }
152
- .yahee-operation-log .timeBox {
153
- margin: 0 5px;
104
+ .yahee-drop-down-condition .checkbox {
105
+ margin-top: 5px;
154
106
  }
155
- .yahee-operation-log .input-with-select {
156
- width: 150px;
107
+ .yahee-drop-down-condition .custom-total-button {
108
+ margin-right: 0;
109
+ padding: 1px 4px;
110
+ height: 22px;
157
111
  }
158
- .yahee-operation-log .lt-created-time {
159
- display: block;
112
+ .yahee-drop-down-condition .custom-button {
113
+ margin-right: 0;
114
+ padding: 1px 4px;
115
+ min-height: 22px;
116
+ height: 22px;
117
+ margin-left: 5px;
160
118
  }
161
- .yahee-operation-log .rt-created-time {
162
- display: inline-block;
119
+ .yahee-drop-down-condition .custom-button.inner-el-button {
120
+ margin-top: 5px;
163
121
  }
164
- .yahee-operation-log .content-div {
165
- width: 100%;
166
- height: 121px;
167
- border: 1px solid #ccc;
168
- padding: 10px;
122
+ .yahee-drop-down-condition .scrollable-container {
123
+ max-height: 700px;
124
+ overflow-y: auto;
125
+ display: flex;
126
+ flex-direction: column;
169
127
  }
170
- .yahee-operation-log .titleRemarks {
171
- font-size: 14px;
172
- font-weight: bold;
173
- padding-left: 5px;
174
- border-bottom: 1px solid #eee;
175
- height: 30px;
176
- line-height: 30px;
128
+ .yahee-drop-down-condition .scrollable-container::-webkit-scrollbar {
129
+ width: 5px;
177
130
  }
178
- .yahee-operation-log .remarkContent {
179
- position: relative;
180
- margin-bottom: 20px;
181
- border: 1px solid #eee;
131
+ .yahee-drop-down-condition .scrollable-container::-webkit-scrollbar-track {
132
+ -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
133
+ border-radius: 10px;
182
134
  }
183
- .yahee-operation-log .remarkContent .buttonQuill {
184
- position: absolute;
185
- bottom: -35px;
186
- right: 10px;
187
- display: flex;
135
+ .yahee-drop-down-condition .scrollable-container::-webkit-scrollbar-thumb {
136
+ border-radius: 10px;
137
+ background: rgba(0, 0, 0, 0.1);
138
+ -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
188
139
  }
189
- .yahee-operation-log .remarkContent .buttonQuill button {
190
- margin-right: 10px;
140
+
141
+ .yahee-country-platform-shop-condition .popover-table {
142
+ width: auto;
143
+ border: 1px solid transparent;
144
+ border-collapse: separate;
191
145
  }
192
- .yahee-operation-log .content-main {
193
- width: 100%;
146
+ .yahee-country-platform-shop-condition .popover-table tr,
147
+ .yahee-country-platform-shop-condition .popover-table td {
148
+ text-align: left;
149
+ cursor: pointer;
150
+ min-height: 22px;
194
151
  }
195
- .yahee-operation-log .span-backG {
196
- position: relative;
197
- display: flex;
198
- min-height: 70px;
152
+ .yahee-country-platform-shop-condition .checkbox-group {
153
+ margin: 5px;
199
154
  width: 100%;
200
- margin-top: 10px;
201
- }
202
- .yahee-operation-log .bubble-tail {
203
- position: absolute;
204
- right: 85px;
205
- top: 5px;
206
- width: 0;
207
- height: 0;
208
- border-width: 6px;
209
- border-style: solid;
210
- border-color: transparent;
211
- border-left-width: 9px;
212
- border-left-color: currentColor;
213
- color: #eee;
214
- }
215
- .yahee-operation-log .leftbubble-tail {
216
- position: absolute;
217
- left: 84px;
218
- top: 5px;
219
- width: 0;
220
- height: 0;
221
- border-width: 7px;
222
- border-style: solid;
223
- border-color: transparent;
224
- margin-bottom: -39px;
225
- border-right-width: 10px;
226
- border-right-color: currentColor;
227
- color: #eee;
228
- }
229
- .yahee-operation-log .r-text {
230
- float: right;
231
- margin-right: 100px;
232
- max-width: 420px;
233
- min-height: 52px;
234
- }
235
- .yahee-operation-log .r-text-main {
236
- background: #FAFAFA;
237
- border: 1px solid #ccc;
238
- border-radius: 2px;
239
- padding: 4px;
240
- word-break: break-all;
241
- text-align: right;
242
155
  }
243
- .yahee-operation-log .l-text {
244
- margin-left: 100px;
245
- max-width: 420px;
246
- min-height: 52px;
247
- }
248
- .yahee-operation-log .l-text-main {
249
- background: #F7FFF7;
250
- border: 1px solid #ccc;
251
- border-radius: 2px;
252
- padding: 4px;
253
- display: inline-block;
254
- min-width: 123px;
255
- word-break: break-all;
156
+ .yahee-country-platform-shop-condition .popover-table th {
157
+ text-align: left;
158
+ cursor: pointer;
159
+ min-height: 22px;
160
+ border: 1px solid transparent;
256
161
  }
257
- .yahee-operation-log .r-name {
258
- border: 1px solid #ccc;
259
- position: absolute;
260
- right: 10px;
261
- width: 65px;
262
- line-height: 17px;
263
- padding: 3px 0 5px;
264
- text-align: center;
265
- border: 1px solid #ccc;
266
- border-radius: 2px;
267
- background: #f1f1f1;
268
- word-break: break-all;
162
+ .yahee-country-platform-shop-condition .popover-table td span {
163
+ display: block;
164
+ margin-bottom: 4px;
165
+ border: 1px solid transparent;
269
166
  }
270
- .yahee-operation-log .l-name {
271
- border: 1px solid #ccc;
272
- position: absolute;
273
- left: 10px;
274
- width: 65px;
275
- line-height: 17px;
276
- padding: 3px 0 5px;
277
- text-align: center;
278
- border: 1px solid #ccc;
279
- border-radius: 2px;
280
- background: #E8FFE8;
281
- float: right;
282
- word-break: break-all;
167
+ .yahee-country-platform-shop-condition .hover-trigger {
168
+ cursor: pointer;
169
+ color: blue;
283
170
  }
284
- .yahee-operation-log .text-m {
285
- word-break: break-all;
286
- white-space: pre-line;
171
+ .yahee-country-platform-shop-condition .custom-total-button {
172
+ margin-right: 0;
173
+ padding: 1px 4px;
174
+ height: 22px;
287
175
  }
288
- .yahee-operation-log .loading {
289
- display: flex;
290
- justify-content: center;
291
- align-items: center;
292
- margin-bottom: 36px;
176
+ .yahee-country-platform-shop-condition .custom-button {
177
+ width: 100%;
178
+ min-height: 22px;
179
+ min-width: 50px;
180
+ height: 22px;
181
+ margin: 3px;
293
182
  }
294
- .yahee-operation-log .no-more {
295
- display: flex;
296
- justify-content: center;
297
- align-items: center;
298
- margin-bottom: 36px;
183
+ .yahee-country-platform-shop-condition .custom-button.inner-el-button {
184
+ margin-top: 5px;
299
185
  }
300
- .yahee-operation-log .el-form--inline .el-form-item {
301
- margin-right: 10px !important;
302
- margin-bottom: 6px !important;
186
+ .yahee-country-platform-shop-condition ::v-deep(.el-checkbox-button__inner) {
187
+ width: 100%;
303
188
  }
304
189
 
305
190
  :root {
@@ -0,0 +1,28 @@
1
+ function e(o) {
2
+ return o ? { backgroundColor: "#3366CC", color: "#fff", borderColor: "#3366CC" } : {};
3
+ }
4
+ function c(o) {
5
+ let r = "";
6
+ switch (o) {
7
+ case "急":
8
+ r = "#740F00";
9
+ break;
10
+ case "高":
11
+ r = "#AF6C12";
12
+ break;
13
+ case "中":
14
+ r = "#999";
15
+ break;
16
+ case "低":
17
+ r = "#999";
18
+ break;
19
+ }
20
+ return { backgroundColor: r, color: "#fff", borderColor: r };
21
+ }
22
+ const t = {
23
+ getBackgroundColor: e,
24
+ getPriorityColor: c
25
+ };
26
+ export {
27
+ t as stylesUtils
28
+ };
@@ -1,40 +1,57 @@
1
- import { sessionStorageProxy as c } from "./storage.js";
2
- import p from "../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js";
3
- import f from "../node_modules/.pnpm/axios@1.7.7/node_modules/axios/lib/axios.js";
4
- import "../api/server.js";
5
- const L = (e) => {
6
- var l;
7
- const t = c.get("employee") || {}, o = m(e);
1
+ import { sessionStorageProxy as u, storage as s } from "./storage.js";
2
+ import m from "../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/lodash.js";
3
+ import h from "../node_modules/.pnpm/axios@1.7.7/node_modules/axios/lib/axios.js";
4
+ import { i18nType as c } from "../static/CommonObject.js";
5
+ import { Get as y } from "../api/server.js";
6
+ const T = (e) => {
7
+ var i;
8
+ const t = u.get("employee") || {}, o = d(e);
8
9
  if (o === 0) return e;
9
- const r = c.get(`translate${t.Language}`) || {};
10
- if (p.isEmpty(r) || t.Language === "zh-CN" || !/[\u4e00-\u9fa5]/.test(e)) return e;
11
- const i = r[o];
12
- if (i)
13
- return i;
10
+ const n = u.get(`translate${t.Language}`) || {};
11
+ if (m.isEmpty(n) || t.Language === "zh-CN" || !/[\u4e00-\u9fa5]/.test(e)) return e;
12
+ const l = n[o];
13
+ if (l)
14
+ return l;
14
15
  {
15
- const n = ((l = localStorage.getItem("localStorageListId")) == null ? void 0 : l.split(",")) || [];
16
- if (n.includes(o.toString()))
16
+ const r = ((i = localStorage.getItem("localStorageListId")) == null ? void 0 : i.split(",")) || [];
17
+ if (r.includes(o.toString()))
17
18
  return e;
18
- n.push(o.toString()), localStorage.setItem("localStorageListId", n.join(","));
19
- const g = {
19
+ r.push(o.toString()), localStorage.setItem("localStorageListId", r.join(","));
20
+ const p = {
20
21
  projectId: "place-order",
21
22
  id: o,
22
23
  cn: e
23
- }, s = "https://erptools.yaheecloud.com/api/translation/addTranslate";
24
- return console.log(s, "url"), f.post(s, g, { withCredentials: !0 }).then((u) => {
25
- u.data.code;
24
+ }, g = "https://erptools.yaheecloud.com/api/translation/addTranslate";
25
+ return console.log(g, "url"), h.post(g, p, { withCredentials: !0 }).then((f) => {
26
+ f.data.code;
26
27
  }), e;
27
28
  }
28
29
  };
29
- function m(e) {
30
+ function d(e) {
30
31
  let t = 0;
31
32
  if (!e || e.length === 0) return t;
32
- for (let o = 0, r = e.length; o < r; o++) {
33
+ for (let o = 0, n = e.length; o < n; o++) {
33
34
  const a = e.charCodeAt(o);
34
35
  t = (t << 5) - t + a, t |= 0;
35
36
  }
36
37
  return t;
37
38
  }
39
+ function $(e, t = "") {
40
+ const o = s.get("totalEmployees");
41
+ if (!e || m.isEmpty(o)) return t;
42
+ const n = u.get("employee");
43
+ if (n.Language === c.CN) return t;
44
+ const a = o[e];
45
+ return a ? n.Language === c.CN ? a.name || t : a.enName || "" : (E(e).then((l) => {
46
+ const i = s.get("totalEmployees") || {}, r = l.data[0];
47
+ return r ? (i[e] = r, s.setWithExpireTime("totalEmployees", i, 3600 * 1e3), n.Language === c.CN ? r.name || "" : r.enName || "") : t;
48
+ }), t);
49
+ }
50
+ function E(e) {
51
+ const t = "/employee/all";
52
+ return y(e ? `${t}?idsStr=${e}` : t);
53
+ }
38
54
  export {
39
- L as M2
55
+ T as M2,
56
+ $ as translateEmployeeName
40
57
  };
@@ -0,0 +1,48 @@
1
+ .yahee-country-platform-shop-condition .popover-table {
2
+ width: auto;
3
+ border: 1px solid transparent;
4
+ border-collapse: separate;
5
+ }
6
+ .yahee-country-platform-shop-condition .popover-table tr,
7
+ .yahee-country-platform-shop-condition .popover-table td {
8
+ text-align: left;
9
+ cursor: pointer;
10
+ min-height: 22px;
11
+ }
12
+ .yahee-country-platform-shop-condition .checkbox-group {
13
+ margin: 5px;
14
+ width: 100%;
15
+ }
16
+ .yahee-country-platform-shop-condition .popover-table th {
17
+ text-align: left;
18
+ cursor: pointer;
19
+ min-height: 22px;
20
+ border: 1px solid transparent;
21
+ }
22
+ .yahee-country-platform-shop-condition .popover-table td span {
23
+ display: block;
24
+ margin-bottom: 4px;
25
+ border: 1px solid transparent;
26
+ }
27
+ .yahee-country-platform-shop-condition .hover-trigger {
28
+ cursor: pointer;
29
+ color: blue;
30
+ }
31
+ .yahee-country-platform-shop-condition .custom-total-button {
32
+ margin-right: 0;
33
+ padding: 1px 4px;
34
+ height: 22px;
35
+ }
36
+ .yahee-country-platform-shop-condition .custom-button {
37
+ width: 100%;
38
+ min-height: 22px;
39
+ min-width: 50px;
40
+ height: 22px;
41
+ margin: 3px;
42
+ }
43
+ .yahee-country-platform-shop-condition .custom-button.inner-el-button {
44
+ margin-top: 5px;
45
+ }
46
+ .yahee-country-platform-shop-condition ::v-deep(.el-checkbox-button__inner) {
47
+ width: 100%;
48
+ }
@@ -0,0 +1,45 @@
1
+ @charset "UTF-8";
2
+ .yahee-drop-down-condition {
3
+ /* 滚动槽 */
4
+ /* 滚动条滑块 */
5
+ }
6
+ .yahee-drop-down-condition .checkbox-group {
7
+ display: flex;
8
+ flex-direction: column;
9
+ }
10
+ .yahee-drop-down-condition .checkbox {
11
+ margin-top: 5px;
12
+ }
13
+ .yahee-drop-down-condition .custom-total-button {
14
+ margin-right: 0;
15
+ padding: 1px 4px;
16
+ height: 22px;
17
+ }
18
+ .yahee-drop-down-condition .custom-button {
19
+ margin-right: 0;
20
+ padding: 1px 4px;
21
+ min-height: 22px;
22
+ height: 22px;
23
+ margin-left: 5px;
24
+ }
25
+ .yahee-drop-down-condition .custom-button.inner-el-button {
26
+ margin-top: 5px;
27
+ }
28
+ .yahee-drop-down-condition .scrollable-container {
29
+ max-height: 700px;
30
+ overflow-y: auto;
31
+ display: flex;
32
+ flex-direction: column;
33
+ }
34
+ .yahee-drop-down-condition .scrollable-container::-webkit-scrollbar {
35
+ width: 5px;
36
+ }
37
+ .yahee-drop-down-condition .scrollable-container::-webkit-scrollbar-track {
38
+ -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
39
+ border-radius: 10px;
40
+ }
41
+ .yahee-drop-down-condition .scrollable-container::-webkit-scrollbar-thumb {
42
+ border-radius: 10px;
43
+ background: rgba(0, 0, 0, 0.1);
44
+ -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
45
+ }
@@ -0,0 +1,11 @@
1
+ :deep(.custom-button + .custom-button) {
2
+ margin-left: 5px;
3
+ margin-bottom: 5px;
4
+ position: relative;
5
+ top: 2px;
6
+ }
7
+
8
+ :deep(.custom-button) {
9
+ padding: 1px 4px;
10
+ height: 22px;
11
+ }
File without changes