star-horse-lowcode 2.7.65 → 2.7.66

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 (220) hide show
  1. package/README.md +1 -0
  2. package/dist/assets/index.css +1 -1
  3. package/dist/index.es.js +491 -253
  4. package/package.json +1 -1
  5. package/.env.development +0 -3
  6. package/.env.production +0 -3
  7. package/.eslintrc-auto-import.json +0 -77
  8. package/.gitignore +0 -27
  9. package/.idea/.gitignore +0 -5
  10. package/.idea/MarsCodeWorkspaceAppSettings.xml +0 -6
  11. package/.idea/inspectionProfiles/Project_Default.xml +0 -7
  12. package/.idea/modules.xml +0 -8
  13. package/.idea/testcode.iml +0 -12
  14. package/.idea/vcs.xml +0 -6
  15. package/.idea/watcherTasks.xml +0 -4
  16. package/.idea/workspace.xml +0 -207
  17. package/.npmignore +0 -21
  18. package/.prettierignore +0 -26
  19. package/auto-imports.d.ts +0 -137
  20. package/components.d.ts +0 -189
  21. package/eslint.config.js +0 -37
  22. package/index.html +0 -14
  23. package/package-lock.json +0 -8276
  24. package/prettier.config.js +0 -20
  25. package/public/logo.svg +0 -660
  26. package/src/App.vue +0 -11
  27. package/src/api/date_utils.ts +0 -219
  28. package/src/api/finger_utils.ts +0 -71
  29. package/src/api/form_utils.ts +0 -281
  30. package/src/api/jquery.min.js +0 -2
  31. package/src/api/pcas-code.json +0 -1
  32. package/src/api/settings.ts +0 -81
  33. package/src/api/star_horse_apis.ts +0 -196
  34. package/src/api/star_horse_utils.ts +0 -797
  35. package/src/api/system.ts +0 -351
  36. package/src/api/user_func.ts +0 -147
  37. package/src/api/valid_utils.ts +0 -165
  38. package/src/assets/css/index.scss +0 -908
  39. package/src/assets/icons.css +0 -574
  40. package/src/assets/star-horse-icons.woff +0 -0
  41. package/src/components/comp/ShDynamicForm.vue +0 -160
  42. package/src/components/comp/ShForm.vue +0 -30
  43. package/src/components/comp/ShTableListColumn.vue +0 -61
  44. package/src/components/comp/StarHorseDataSelector.vue +0 -139
  45. package/src/components/comp/StarHorseDataView.vue +0 -110
  46. package/src/components/comp/StarHorseDataViewItems.vue +0 -61
  47. package/src/components/comp/StarHorseDataViewTable.vue +0 -102
  48. package/src/components/comp/StarHorseDialog.vue +0 -383
  49. package/src/components/comp/StarHorseDraggable.vue +0 -401
  50. package/src/components/comp/StarHorseForm.vue +0 -458
  51. package/src/components/comp/StarHorseFormItem.vue +0 -82
  52. package/src/components/comp/StarHorseFormList.vue +0 -516
  53. package/src/components/comp/StarHorseFormTable.vue +0 -56
  54. package/src/components/comp/StarHorseIcon.vue +0 -76
  55. package/src/components/comp/StarHorseItem.vue +0 -302
  56. package/src/components/comp/StarHorseJsonEditor.vue +0 -115
  57. package/src/components/comp/StarHorsePopover.vue +0 -66
  58. package/src/components/comp/StarHorseSearchComp.vue +0 -253
  59. package/src/components/comp/StarHorseStaticTable.vue +0 -395
  60. package/src/components/comp/StarHorseTableColumn.vue +0 -249
  61. package/src/components/comp/StarHorseTableComp.vue +0 -1193
  62. package/src/components/comp/StarHorseTableViewColumn.vue +0 -61
  63. package/src/components/comp/StarHorseTree.vue +0 -494
  64. package/src/components/comp/index.ts +0 -22
  65. package/src/components/comp/items/UTableColumn.vue +0 -65
  66. package/src/components/comp/items/boxItem.vue +0 -98
  67. package/src/components/comp/items/callitem.ts +0 -9
  68. package/src/components/comp/items/cardItem.vue +0 -152
  69. package/src/components/comp/items/collapseItem.vue +0 -134
  70. package/src/components/comp/items/dytableItem.vue +0 -135
  71. package/src/components/comp/items/otherItem.vue +0 -65
  72. package/src/components/comp/items/tabItem.vue +0 -155
  73. package/src/components/comp/items/tabPanelItem.vue +0 -110
  74. package/src/components/comp/items/tableColumn.vue +0 -129
  75. package/src/components/comp/items/tableItem.vue +0 -97
  76. package/src/components/comp/items/tablebtn.vue +0 -158
  77. package/src/components/comp/items/viewBoxItem.vue +0 -55
  78. package/src/components/comp/items/viewCardItem.vue +0 -47
  79. package/src/components/comp/items/viewCollapseItem.vue +0 -71
  80. package/src/components/comp/items/viewDytableItem.vue +0 -77
  81. package/src/components/comp/items/viewOtherItem.vue +0 -55
  82. package/src/components/comp/items/viewTabItem.vue +0 -77
  83. package/src/components/comp/items/viewTabPanelItem.vue +0 -54
  84. package/src/components/comp/items/viewTableItem.vue +0 -74
  85. package/src/components/comp/selfcomp.ts +0 -9
  86. package/src/components/comp/utils/DataPicker.vue +0 -302
  87. package/src/components/comp/utils/DataTag.vue +0 -51
  88. package/src/components/cron/Crontab-Day.vue +0 -230
  89. package/src/components/cron/Crontab-Hour.vue +0 -165
  90. package/src/components/cron/Crontab-Min.vue +0 -166
  91. package/src/components/cron/Crontab-Month.vue +0 -166
  92. package/src/components/cron/Crontab-Result.vue +0 -615
  93. package/src/components/cron/Crontab-Second.vue +0 -185
  94. package/src/components/cron/Crontab-Week.vue +0 -208
  95. package/src/components/cron/Crontab-Year.vue +0 -183
  96. package/src/components/cron/Crontab.vue +0 -474
  97. package/src/components/enums/ModuleEnums.ts +0 -10
  98. package/src/components/enums/ServiceEnums.ts +0 -18
  99. package/src/components/formcomp/container/box-container.vue +0 -162
  100. package/src/components/formcomp/container/callitem.ts +0 -9
  101. package/src/components/formcomp/container/card-container.vue +0 -170
  102. package/src/components/formcomp/container/collapse-container.vue +0 -133
  103. package/src/components/formcomp/container/dytable-col.vue +0 -448
  104. package/src/components/formcomp/container/dytable-container.vue +0 -57
  105. package/src/components/formcomp/container/dytableUtils.ts +0 -358
  106. package/src/components/formcomp/container/group-box-container.vue +0 -331
  107. package/src/components/formcomp/container/index.ts +0 -6
  108. package/src/components/formcomp/container/tab-container.vue +0 -153
  109. package/src/components/formcomp/container/table-container.vue +0 -249
  110. package/src/components/formcomp/items/allitem.ts +0 -9
  111. package/src/components/formcomp/items/area-item.vue +0 -116
  112. package/src/components/formcomp/items/audio-item.vue +0 -163
  113. package/src/components/formcomp/items/autocomplete-item.vue +0 -118
  114. package/src/components/formcomp/items/barcode-item.vue +0 -87
  115. package/src/components/formcomp/items/base-json-item.vue +0 -207
  116. package/src/components/formcomp/items/button-item.vue +0 -228
  117. package/src/components/formcomp/items/cascade-item.vue +0 -113
  118. package/src/components/formcomp/items/checkbox-item.vue +0 -97
  119. package/src/components/formcomp/items/color-item.vue +0 -70
  120. package/src/components/formcomp/items/cron-item.vue +0 -115
  121. package/src/components/formcomp/items/datetime-item.vue +0 -99
  122. package/src/components/formcomp/items/depart-item.vue +0 -51
  123. package/src/components/formcomp/items/dialog-input-item.vue +0 -207
  124. package/src/components/formcomp/items/divider-item.vue +0 -66
  125. package/src/components/formcomp/items/html-item.vue +0 -65
  126. package/src/components/formcomp/items/htmleditor-item.vue +0 -104
  127. package/src/components/formcomp/items/icon-item.vue +0 -195
  128. package/src/components/formcomp/items/image-item.vue +0 -247
  129. package/src/components/formcomp/items/index.ts +0 -44
  130. package/src/components/formcomp/items/input-item.vue +0 -150
  131. package/src/components/formcomp/items/json-array-item.vue +0 -67
  132. package/src/components/formcomp/items/json-item.vue +0 -66
  133. package/src/components/formcomp/items/markdown-item.vue +0 -77
  134. package/src/components/formcomp/items/number-item.vue +0 -94
  135. package/src/components/formcomp/items/number-range-item.vue +0 -278
  136. package/src/components/formcomp/items/page-select-item.vue +0 -407
  137. package/src/components/formcomp/items/password-item.vue +0 -71
  138. package/src/components/formcomp/items/qrcode-item.vue +0 -84
  139. package/src/components/formcomp/items/radio-item.vue +0 -112
  140. package/src/components/formcomp/items/rate-item.vue +0 -68
  141. package/src/components/formcomp/items/select-item.vue +0 -133
  142. package/src/components/formcomp/items/signature-item.vue +0 -216
  143. package/src/components/formcomp/items/slider-item.vue +0 -68
  144. package/src/components/formcomp/items/starhorse-form-item.vue +0 -334
  145. package/src/components/formcomp/items/switch-item.vue +0 -77
  146. package/src/components/formcomp/items/tag-item.vue +0 -77
  147. package/src/components/formcomp/items/text-item.vue +0 -75
  148. package/src/components/formcomp/items/textarea-item.vue +0 -85
  149. package/src/components/formcomp/items/time-item.vue +0 -77
  150. package/src/components/formcomp/items/time-picker-item.vue +0 -74
  151. package/src/components/formcomp/items/transfer-item.vue +0 -93
  152. package/src/components/formcomp/items/tselect-item.vue +0 -121
  153. package/src/components/formcomp/items/unknown-item.vue +0 -51
  154. package/src/components/formcomp/items/upload-item.vue +0 -189
  155. package/src/components/formcomp/items/user-item.vue +0 -177
  156. package/src/components/formcomp/items/usercomp-item.vue +0 -85
  157. package/src/components/formcomp/items/view-markdown-item.vue +0 -77
  158. package/src/components/formcomp/utils/EditDataDialog.vue +0 -67
  159. package/src/components/formcomp/utils/FieldList.vue +0 -125
  160. package/src/components/formcomp/utils/ItemRelationEventUtils.ts +0 -284
  161. package/src/components/help.vue +0 -31
  162. package/src/components/menu/MenuItem.vue +0 -95
  163. package/src/components/menu/SubMenu.vue +0 -68
  164. package/src/components/menu/SubSystemMenu.vue +0 -142
  165. package/src/components/register.ts +0 -24
  166. package/src/components/system/ContentMenu.vue +0 -260
  167. package/src/components/system/StarHorseButtonList.vue +0 -344
  168. package/src/components/system/StarHorseMenu.vue +0 -97
  169. package/src/components/system/StarHorseSvg.vue +0 -62
  170. package/src/components/system/SystemComp.ts +0 -9
  171. package/src/components/system/index.ts +0 -4
  172. package/src/components/types/ApiUrls.ts +0 -168
  173. package/src/components/types/BtnAction.ts +0 -51
  174. package/src/components/types/BtnAuth.ts +0 -43
  175. package/src/components/types/CompInfo.ts +0 -81
  176. package/src/components/types/DialogProps.ts +0 -55
  177. package/src/components/types/DyCompField.ts +0 -23
  178. package/src/components/types/DynamicNode.ts +0 -42
  179. package/src/components/types/MenusInfo.ts +0 -45
  180. package/src/components/types/PageFieldInfo.ts +0 -530
  181. package/src/components/types/PageProps.ts +0 -25
  182. package/src/components/types/Params.ts +0 -93
  183. package/src/components/types/RuleType.ts +0 -10
  184. package/src/components/types/SearchProps.ts +0 -42
  185. package/src/components/types/ShortKey.ts +0 -30
  186. package/src/components/types/StarHorseType.ts +0 -18
  187. package/src/components/types/index.ts +0 -15
  188. package/src/config/element.ts +0 -15
  189. package/src/config/styles.ts +0 -4
  190. package/src/index.ts +0 -98
  191. package/src/install.ts +0 -33
  192. package/src/lang/en_US.ts +0 -81
  193. package/src/lang/index.ts +0 -35
  194. package/src/lang/zh_CN.ts +0 -84
  195. package/src/main.ts +0 -57
  196. package/src/plugins/AblesPlugin.ts +0 -618
  197. package/src/plugins/registerCompPlugin.ts +0 -15
  198. package/src/sample/test.vue +0 -9
  199. package/src/store/ButtonPermission.ts +0 -101
  200. package/src/store/ConsumerView.ts +0 -52
  201. package/src/store/ContinusConfig.ts +0 -78
  202. package/src/store/CopyerOperation.ts +0 -74
  203. package/src/store/DesignForm.ts +0 -481
  204. package/src/store/DesignPage.ts +0 -59
  205. package/src/store/DynamicForm.ts +0 -241
  206. package/src/store/GlobalConfig.ts +0 -90
  207. package/src/store/SelfOperation.ts +0 -95
  208. package/src/store/UserInfo.ts +0 -88
  209. package/src/store/index.ts +0 -6
  210. package/src/theme/localStorge.ts +0 -16
  211. package/src/theme/theme.ts +0 -27
  212. package/src/utils/FieldOperationUtils.ts +0 -91
  213. package/src/utils/auth.ts +0 -83
  214. package/src/utils/message.ts +0 -69
  215. package/src/utils/preview.ts +0 -125
  216. package/tsconfig.json +0 -39
  217. package/tsconfig.node.json +0 -10
  218. package/vite-env.d.ts +0 -16
  219. package/vite.config.ts +0 -162
  220. package/yarn.lock +0 -4627
@@ -1,474 +0,0 @@
1
- <script setup lang="ts">
2
- import { nextTick, onMounted, ref, watch } from "vue";
3
- import CrontabSecond from "@/components/cron/Crontab-Second.vue";
4
- import CrontabMin from "@/components/cron/Crontab-Min.vue";
5
- import CrontabHour from "@/components/cron/Crontab-Hour.vue";
6
- import CrontabDay from "@/components/cron/Crontab-Day.vue";
7
- import Crontabmonth from "@/components/cron/Crontab-Month.vue";
8
- import CrontabWeek from "@/components/cron/Crontab-Week.vue";
9
- import CrontabYear from "@/components/cron/Crontab-Year.vue";
10
- import { useVModel } from "@vueuse/core";
11
- import { copyText } from "@/api/system";
12
-
13
- defineOptions({
14
- name: "Crontab",
15
- });
16
-
17
- export interface Crontab {
18
- expression?: string;
19
- modelValue: string;
20
- hideComponent?: any;
21
- }
22
-
23
- const props = withDefaults(defineProps<Crontab>(), {});
24
- const emits = defineEmits(["update:modelValue"]);
25
- let dataValue = useVModel(props, "modelValue", emits);
26
- let tabTitles = ref<Array<string>>([
27
- "秒",
28
- "分钟",
29
- "小时",
30
- "日",
31
- "月",
32
- "周",
33
- "年",
34
- ]);
35
- let tabActive = ref<string>("0");
36
- const cronsecond = ref();
37
- const cronmin = ref();
38
- const cronhour = ref();
39
- const cronday = ref();
40
- const cronmonth = ref();
41
- const cronweek = ref();
42
- const cronyear = ref();
43
- const prototypeCron = ["0 0 0 0 0 *", "* * * * * ? *", "* * * * * ?"];
44
- let contabValueObj = ref<any>({
45
- second: "*",
46
- min: "*",
47
- hour: "*",
48
- day: "*",
49
- month: "*",
50
- week: "?",
51
- year: "",
52
- });
53
- let contabValueString = ref<string>("");
54
- const contabValueStringFun = () => {
55
- let obj = contabValueObj.value;
56
- let val =
57
- obj.second +
58
- " " +
59
- obj.min +
60
- " " +
61
- obj.hour +
62
- " " +
63
- obj.day +
64
- " " +
65
- obj.month +
66
- " " +
67
- obj.week +
68
- (obj.year == "" ? "" : " " + obj.year);
69
- contabValueString.value = val;
70
- if (!prototypeCron.includes(val)) {
71
- emits("update:modelValue", val);
72
- }
73
- };
74
- const shouldHide = (key: any) => {
75
- return !(props.hideComponent && props.hideComponent.includes(key));
76
- };
77
- const resolveExp = () => {
78
- //反解析 表达式
79
- if (dataValue.value) {
80
- let arr = dataValue.value.split(" ");
81
- // debugger;
82
- if (arr.length >= 6) {
83
- //6 位以上是合法表达式
84
- let obj: any = {
85
- second: arr[0],
86
- min: arr[1],
87
- hour: arr[2],
88
- day: arr[3],
89
- month: arr[4],
90
- week: arr[5],
91
- year: arr[6] ? arr[6] : "",
92
- };
93
-
94
- contabValueObj.value = obj;
95
- for (let i in obj) {
96
- if (obj[i]) {
97
- changeRadio(i, obj[i]);
98
- }
99
- }
100
- }
101
- } else {
102
- //没有传入的表达式 则还原
103
- clearCron();
104
- }
105
- };
106
-
107
- // 由子组件触发,更改表达式组成的字段值
108
- const updateContabValue = (name: string, value: any, from: any) => {
109
- contabValueObj.value[name] = value;
110
- if (from && from !== name) {
111
- changeRadio(name, value);
112
- }
113
- };
114
- const getRefObj = (name: string) => {
115
- if (name == "cronsecond") {
116
- return cronsecond;
117
- } else if (name == "cronmin") {
118
- return cronmin;
119
- } else if (name == "cronhour") {
120
- return cronhour;
121
- } else if (name == "cronday") {
122
- return cronday;
123
- } else if (name == "cronmonth") {
124
- return cronmonth;
125
- } else if (name == "cronweek") {
126
- return cronweek;
127
- } else {
128
- return cronyear;
129
- }
130
- };
131
-
132
- const parseCheckList = (refObj: any, value: string) => {
133
- let numStrs = value?.split(",");
134
- if (numStrs?.length > 0) {
135
- let arr = [];
136
- for (let i = 0; i < numStrs.length; i++) {
137
- arr.push(parseInt(numStrs[i]));
138
- }
139
- refObj.value.checkboxList = arr;
140
- } else {
141
- refObj.value.checkboxList = [];
142
- }
143
- };
144
- //赋值到组件
145
- const changeRadio = async (name: string, value: string) => {
146
- let arr = ["second", "min", "hour", "month"],
147
- refName = "cron" + name,
148
- insValue;
149
- let refObj = getRefObj(refName);
150
- await nextTick();
151
- if (arr.includes(name)) {
152
- if (value === "*") {
153
- insValue = 1;
154
- } else if (value.indexOf("-") > -1) {
155
- let indexArr: Array<any> = value.split("-");
156
- isNaN(indexArr[0])
157
- ? (refObj.value.cycle01 = 0)
158
- : (refObj.value.cycle01 = indexArr[0]);
159
- refObj.value.cycle02 = indexArr[1];
160
- insValue = 2;
161
- } else if (value.indexOf("/") > -1) {
162
- let indexArr: Array<any> = value.split("/");
163
- isNaN(indexArr[0])
164
- ? (refObj.value.average01 = 0)
165
- : (refObj.value.average01 = indexArr[0]);
166
- refObj.value.average02 = indexArr[1];
167
- insValue = 3;
168
- } else {
169
- if (name == "month" && value == "0") {
170
- insValue = 1;
171
- } else {
172
- insValue = 4;
173
- parseCheckList(refObj, value);
174
- }
175
- }
176
- } else if (name == "day") {
177
- if (value === "*") {
178
- insValue = 1;
179
- } else if (value == "?") {
180
- insValue = 2;
181
- } else if (value.indexOf("-") > -1) {
182
- let indexArr: Array<any> = value.split("-");
183
- isNaN(indexArr[0])
184
- ? (refObj.value.cycle01 = 0)
185
- : (refObj.value.cycle01 = parseInt(indexArr[0]));
186
- refObj.value.cycle02 = parseInt(indexArr[1]);
187
- insValue = 3;
188
- } else if (value.indexOf("/") > -1) {
189
- let indexArr: Array<any> = value.split("/");
190
- isNaN(indexArr[0])
191
- ? (refObj.value.average01 = 0)
192
- : (refObj.value.average01 = parseInt(indexArr[0]));
193
- refObj.value.average02 = parseInt(indexArr[1]);
194
- insValue = 4;
195
- } else if (value.indexOf("W") > -1) {
196
- let indexArr: Array<any> = value.split("W");
197
- isNaN(indexArr[0])
198
- ? (refObj.value.workday = 0)
199
- : (refObj.value.workday = parseInt(indexArr[0]));
200
- insValue = 5;
201
- } else if (value === "L") {
202
- insValue = 6;
203
- } else {
204
- insValue = 7;
205
- parseCheckList(refObj, value);
206
- }
207
- } else if (name == "week") {
208
- if (value === "*") {
209
- insValue = 1;
210
- } else if (value == "?") {
211
- insValue = 2;
212
- } else if (value.indexOf("-") > -1) {
213
- let indexArr: Array<any> = value.split("-");
214
- isNaN(indexArr[0])
215
- ? (refObj.value.cycle01 = 0)
216
- : (refObj.value.cycle01 = parseInt(indexArr[0]));
217
- refObj.value.cycle02 = parseInt(indexArr[1]);
218
- insValue = 3;
219
- } else if (value.indexOf("#") > -1) {
220
- let indexArr: Array<any> = value.split("#");
221
- isNaN(indexArr[0])
222
- ? (refObj.value.average01 = 1)
223
- : (refObj.value.average01 = parseInt(indexArr[0]));
224
- refObj.value.average02 = parseInt(indexArr[1]);
225
- insValue = 4;
226
- } else if (value.indexOf("L") > -1) {
227
- let indexArr: Array<any> = value.split("L");
228
- isNaN(indexArr[0])
229
- ? (refObj.value.weekday = 1)
230
- : (refObj.value.weekday = parseInt(indexArr[0]));
231
- insValue = 5;
232
- } else {
233
- insValue = 7;
234
- parseCheckList(refObj, value);
235
- }
236
- } else if (name == "year") {
237
- if (value == "") {
238
- insValue = 1;
239
- } else if (value == "*") {
240
- insValue = 2;
241
- } else if (value.indexOf("-") > -1) {
242
- insValue = 3;
243
- } else if (value.indexOf("/") > -1) {
244
- insValue = 4;
245
- } else {
246
- insValue = 5;
247
- parseCheckList(refObj, value);
248
- }
249
- }
250
- refObj.value.radioValue = insValue;
251
- };
252
- // 表单选项的子组件校验数字格式(通过-props传递)
253
- const checkNumber = (value: number, minLimit: number, maxLimit: number) => {
254
- //检查必须为整数
255
- value = Math.floor(value);
256
- if (value < minLimit) {
257
- value = minLimit;
258
- } else if (value > maxLimit) {
259
- value = maxLimit;
260
- }
261
- return value;
262
- };
263
-
264
- const clearCron = () => {
265
- // 还原选择项
266
- contabValueObj.value = {
267
- second: "*",
268
- min: "*",
269
- hour: "*",
270
- day: "*",
271
- month: "*",
272
- week: "?",
273
- year: "",
274
- };
275
- for (let j in contabValueObj.value) {
276
- changeRadio(j, contabValueObj.value[j]);
277
- }
278
- };
279
- onMounted(() => {
280
- resolveExp();
281
- });
282
- watch(
283
- () => contabValueObj.value,
284
- () => {
285
- contabValueStringFun();
286
- },
287
- { immediate: false, deep: true },
288
- );
289
- defineExpose({
290
- clearCron,
291
- resolveExp,
292
- });
293
- </script>
294
- <template>
295
- <div class="flex flex-col h-full">
296
- <div class="flex-grow-1 flex-1 overflow-auto min-h-0">
297
- <el-tabs type="border-card" v-model="tabActive">
298
- <el-tab-pane label="秒" name="0" v-if="shouldHide('second')">
299
- <CrontabSecond
300
- @update="updateContabValue"
301
- :cron="contabValueObj"
302
- :check="checkNumber"
303
- ref="cronsecond"
304
- />
305
- </el-tab-pane>
306
- <el-tab-pane label="分钟" name="1" v-if="shouldHide('min')">
307
- <CrontabMin
308
- @update="updateContabValue"
309
- :check="checkNumber"
310
- :cron="contabValueObj"
311
- ref="cronmin"
312
- />
313
- </el-tab-pane>
314
- <el-tab-pane label="小时" name="2" v-if="shouldHide('hour')">
315
- <CrontabHour
316
- @update="updateContabValue"
317
- :check="checkNumber"
318
- :cron="contabValueObj"
319
- ref="cronhour"
320
- />
321
- </el-tab-pane>
322
- <el-tab-pane label="日" name="3" v-if="shouldHide('day')">
323
- <CrontabDay
324
- @update="updateContabValue"
325
- :check="checkNumber"
326
- :cron="contabValueObj"
327
- ref="cronday"
328
- />
329
- </el-tab-pane>
330
- <el-tab-pane label="月" name="4" v-if="shouldHide('month')">
331
- <Crontabmonth
332
- @update="updateContabValue"
333
- :check="checkNumber"
334
- :cron="contabValueObj"
335
- ref="cronmonth"
336
- />
337
- </el-tab-pane>
338
- <el-tab-pane label="周" name="5" v-if="shouldHide('week')">
339
- <CrontabWeek
340
- @update="updateContabValue"
341
- :check="checkNumber"
342
- :cron="contabValueObj"
343
- ref="cronweek"
344
- />
345
- </el-tab-pane>
346
- <el-tab-pane label="年" name="6" v-if="shouldHide('year')">
347
- <CrontabYear
348
- @update="updateContabValue"
349
- :check="checkNumber"
350
- :cron="contabValueObj"
351
- ref="cronyear"
352
- />
353
- </el-tab-pane>
354
- </el-tabs>
355
- </div>
356
- <div class="popup-main">
357
- <div class="popup-result">
358
- <p class="title">时间表达式</p>
359
- <table>
360
- <thead>
361
- <tr>
362
- <th v-for="item of tabTitles" width="40" :key="item">
363
- {{ item }}
364
- </th>
365
- <th>crontab完整表达式</th>
366
- </tr>
367
- </thead>
368
- <tbody>
369
- <tr>
370
- <td>
371
- <el-tag>{{ contabValueObj.second }}</el-tag>
372
- </td>
373
- <td>
374
- <el-tag>{{ contabValueObj.min }}</el-tag>
375
- </td>
376
- <td>
377
- <el-tag>{{ contabValueObj.hour }}</el-tag>
378
- </td>
379
- <td>
380
- <el-tag>{{ contabValueObj.day }}</el-tag>
381
- </td>
382
- <td>
383
- <el-tag>{{ contabValueObj.month }}</el-tag>
384
- </td>
385
- <td>
386
- <el-tag>{{ contabValueObj.week }}</el-tag>
387
- </td>
388
- <td>
389
- <el-tag>{{ contabValueObj.year }}</el-tag>
390
- </td>
391
- <td>
392
- <el-tag
393
- style="cursor: pointer"
394
- @click="copyText(contabValueString)"
395
- >{{ contabValueString }}</el-tag
396
- >
397
- </td>
398
- </tr>
399
- </tbody>
400
- </table>
401
- </div>
402
- <CrontabResult :ex="contabValueString" />
403
- </div>
404
- </div>
405
- </template>
406
- <style lang="scss" scoped>
407
- :deep {
408
- .el-tabs__content {
409
- padding: 5px !important;
410
- height: 100%;
411
- }
412
-
413
- .el-tab-pane {
414
- height: 100%; /* 显式设置tab面板高度为100% */
415
- display: flex; /* 配合flex布局撑满空间 */
416
- flex-direction: column;
417
- }
418
- }
419
-
420
- :deep(.el-form-item__content) {
421
- display: flex;
422
- align-items: center;
423
- justify-content: space-between;
424
- flex-direction: row;
425
- }
426
-
427
- .popup-main {
428
- background: #fff;
429
- width: 100%;
430
- font-size: 12px;
431
- overflow: hidden;
432
- display: flex;
433
- flex-direction: column;
434
-
435
- .popup-result {
436
- box-sizing: border-box;
437
- margin: 5px auto;
438
- line-height: 24px;
439
- width: 100%;
440
- border: 1px solid #ccc;
441
- font-size: 14px;
442
-
443
- .title {
444
- display: flex;
445
- width: 100%;
446
- justify-content: center;
447
- align-items: center;
448
- flex-direction: row;
449
- overflow: hidden;
450
- line-height: 34px;
451
- background: #f2f2f2;
452
- }
453
-
454
- table {
455
- text-align: center;
456
- width: 100%;
457
- margin: 0 auto;
458
- border-spacing: 5px; /* 新增:控制单元格间距(上下左右) */
459
- border-collapse: separate; /* 必须设置,否则border-spacing无效 */
460
-
461
- span {
462
- display: block;
463
- width: 100%;
464
- line-height: 30px;
465
- height: 30px;
466
- font-size: 12px;
467
- white-space: nowrap;
468
- overflow: hidden;
469
- border: 1px solid #e8e8e8;
470
- }
471
- }
472
- }
473
- }
474
- </style>
@@ -1,10 +0,0 @@
1
- export enum ModuleEnums {
2
- /**
3
- * 动态表单
4
- */
5
- DYNAMIC_FORM = "dynamic-form",
6
- /**
7
- * 动态页面
8
- */
9
- DYNAMIC_PAGE = "dynamic-page",
10
- }
@@ -1,18 +0,0 @@
1
- export enum ServiceEnums {
2
- /**
3
- * 系统服务
4
- */
5
- SYSTEM_SERVICE = "system-config",
6
- /**
7
- * 数据库服务
8
- */
9
- DBUSER_SERVICE = "dbuser-manage",
10
- /**
11
- * 公共接口前缀
12
- */
13
- GLOBAL_PREFIX = `${SYSTEM_SERVICE}/global/`,
14
- /**
15
- * 系统服务接口前缀
16
- */
17
- SYSTEM_PREFIX = `${SYSTEM_SERVICE}/system/`,
18
- }
@@ -1,162 +0,0 @@
1
- <script setup lang="ts" name="box-container">
2
- import { computed, PropType } from "vue";
3
- import { warning } from "@/utils/message";
4
- import { useDesignFormStore } from "@/store/DesignForm";
5
- import piniaInstance from "@/store/index";
6
- import { itemCheck } from "@/api/system";
7
-
8
- const props = defineProps({
9
- parentField: { type: String },
10
- isDesign: { type: Boolean, default: false },
11
- showFormItem: { type: Boolean, default: false },
12
- disabled: { type: Object as PropType<Boolean | String> },
13
- formInfo: { type: Object as PropType<any> },
14
- field: { type: Object as PropType<any> },
15
- });
16
- let designForm = useDesignFormStore(piniaInstance);
17
- let draggingItem = computed(() => designForm.draggingItem);
18
- const formData = defineModel("formData");
19
- let isEdit = computed(() => props.isDesign);
20
- const isDragging = computed(() => designForm.isDragging);
21
- let boxCompList = computed(() => props.field);
22
- let excludeContainerType: Array<string> = [
23
- "box",
24
- "tab",
25
- "table",
26
- "dytable",
27
- "collapse",
28
- "card",
29
- ];
30
-
31
- const checkItem = (items: any) => {
32
- if (!items["items"]) {
33
- items["items"] = [];
34
- }
35
- };
36
- const onDragAdd = (evt: Event | any, dataList: any) => {
37
- let newIndex = evt.newIndex;
38
- if (excludeContainerType.includes(draggingItem.value.itemType)) {
39
- warning("栅格容器不允许嵌套其他容器");
40
- let elements = props.field.preps.elements;
41
- for (let inde in elements) {
42
- let element = elements[inde];
43
- for (let sind in element?.columns) {
44
- let column = element.columns[sind];
45
- for (let i in column?.items) {
46
- let item = column.items[i];
47
- if (draggingItem.value.id == item.id) {
48
- column.items.splice(i, 1);
49
- }
50
- }
51
- }
52
- }
53
- return false;
54
- }
55
- if (newIndex != null && newIndex != "undefined") {
56
- let dataInfo = dataList[newIndex];
57
- designForm.selectItem(dataInfo, dataInfo.itemType, "");
58
- }
59
- };
60
- </script>
61
- <template>
62
- <group-box-container
63
- class="star-horse-form-container"
64
- :showFormItem="showFormItem"
65
- :isDesign="isDesign"
66
- :disabled="disabled"
67
- :parentField="parentField"
68
- :form-item="boxCompList"
69
- >
70
- <el-row
71
- v-for="element in boxCompList.preps.elements"
72
- :gutter="boxCompList.preps?.gutter || 10"
73
- :justify="boxCompList.preps?.justify || 'start'"
74
- :align="boxCompList.preps?.align || 'top'"
75
- :tag="boxCompList.preps?.tag || 'div'"
76
- >
77
- <el-col
78
- class="edit_col"
79
- :class="{ 'dragging-area': isDragging }"
80
- :item-key="index"
81
- :span="sdata.colspan || 24"
82
- v-for="(sdata, index) in element.columns"
83
- v-if="isEdit"
84
- >
85
- <draggable
86
- @add="(evt: Event) => onDragAdd(evt, sdata.items)"
87
- @dragover="checkItem(sdata)"
88
- class="smain-design"
89
- tag="div"
90
- group="starHorseGroup"
91
- ghostClass="ghost"
92
- animation="200"
93
- :list="sdata.items"
94
- >
95
- <template #item="{ element: data }">
96
- <div class="comp-item">
97
- <component
98
- :key="data.id"
99
- :field="data"
100
- :formInfo="formInfo"
101
- :showFormItem="showFormItem"
102
- :isDesign="isDesign"
103
- :disabled="disabled"
104
- :is="itemCheck(data)"
105
- :parentField="boxCompList"
106
- v-model:formData="formData"
107
- />
108
- </div>
109
- </template>
110
- </draggable>
111
- </el-col>
112
- <el-col
113
- :item-key="index"
114
- :span="sdata.colspan || 24"
115
- :class="{ 'dragging-area': isDragging }"
116
- style="border: none"
117
- v-else
118
- v-for="(sdata, index) in element.columns"
119
- >
120
- <template v-for="data in sdata.items">
121
- <component
122
- :field="data"
123
- :isDesign="isDesign"
124
- :disabled="disabled"
125
- :showFormItem="showFormItem"
126
- :is="itemCheck(data)"
127
- v-model:formData="formData"
128
- :formInfo="formInfo"
129
- />
130
- </template>
131
- </el-col>
132
- </el-row>
133
- </group-box-container>
134
- </template>
135
- <style lang="scss" scoped>
136
- .smain-design {
137
- width: 100%;
138
- background: var(--star-horse-background);
139
- border-radius: 3px;
140
- min-height: 50px;
141
- display: flex;
142
- flex-direction: column;
143
- vertical-align: middle;
144
- justify-content: center;
145
- align-items: center;
146
-
147
- .ghost {
148
- content: "";
149
- font-size: 0;
150
- height: 3px;
151
- box-sizing: border-box;
152
- outline-width: 0;
153
- padding: 0;
154
- overflow: hidden;
155
- }
156
- }
157
-
158
- .edit_col {
159
- border: 1px dashed var(--star-horse-border—color);
160
- min-height: 50px;
161
- }
162
- </style>
@@ -1,9 +0,0 @@
1
- import { App, defineAsyncComponent } from "vue";
2
-
3
- const containers = import.meta.glob("@/components/formcomp/container/*.vue");
4
- export default function install(app: App<Element>) {
5
- for (const [key, value] of Object.entries(containers)) {
6
- const name = key.slice(key.lastIndexOf("/") + 1, key.lastIndexOf("."));
7
- app.component(name, defineAsyncComponent(value as any));
8
- }
9
- }