@qynpm/ui 1.0.45 → 1.0.47
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.
- package/CHANGELOG.md +8 -0
- package/README.md +7 -2
- package/dist/index.cjs +10 -3
- package/dist/index.mjs +258 -92
- package/dist/qy-action-bar/index.cjs +3 -1
- package/dist/qy-action-bar/index.mjs +7 -2
- package/dist/qy-button/index.cjs +1 -1
- package/dist/qy-button/index.mjs +1 -1
- package/dist/qy-cascader/index.cjs +1 -1
- package/dist/qy-cascader/index.mjs +1 -1
- package/dist/qy-checkbox/index.cjs +1 -1
- package/dist/qy-checkbox/index.mjs +1 -1
- package/dist/qy-checkbox-group/index.cjs +1 -1
- package/dist/qy-checkbox-group/index.mjs +1 -1
- package/dist/qy-collapse/index.cjs +1 -1
- package/dist/qy-collapse/index.mjs +1 -1
- package/dist/qy-color-picker/index.cjs +1 -1
- package/dist/qy-color-picker/index.mjs +1 -1
- package/dist/qy-date-picker/index.cjs +1 -1
- package/dist/qy-date-picker/index.mjs +1 -1
- package/dist/qy-dialog/index.cjs +3 -2
- package/dist/qy-dialog/index.mjs +7 -5
- package/dist/qy-drawer/index.cjs +1 -1
- package/dist/qy-drawer/index.mjs +1 -1
- package/dist/qy-file-picker/index.cjs +1 -1
- package/dist/qy-file-picker/index.mjs +1 -1
- package/dist/qy-form-section/index.cjs +3 -1
- package/dist/qy-form-section/index.mjs +7 -2
- package/dist/qy-fullscreen/index.cjs +1 -1
- package/dist/qy-fullscreen/index.mjs +1 -1
- package/dist/qy-icon/index.cjs +1 -1
- package/dist/qy-icon/index.mjs +2 -2
- package/dist/qy-icon-picker/index.cjs +1 -1
- package/dist/qy-icon-picker/index.mjs +1 -1
- package/dist/qy-iframe/index.cjs +1 -1
- package/dist/qy-iframe/index.mjs +1 -1
- package/dist/qy-image/index.cjs +1 -1
- package/dist/qy-image/index.mjs +1 -1
- package/dist/qy-image-preview/index.mjs +2 -2
- package/dist/qy-image-upload/index.cjs +3 -1
- package/dist/qy-image-upload/index.mjs +7 -2
- package/dist/qy-input/index.cjs +1 -1
- package/dist/qy-input/index.mjs +1 -1
- package/dist/qy-input-number/index.cjs +1 -1
- package/dist/qy-input-number/index.mjs +1 -1
- package/dist/qy-input-tag/index.cjs +1 -1
- package/dist/qy-input-tag/index.mjs +151 -5
- package/dist/qy-legacy-selection-dialog/index.cjs +8 -1
- package/dist/qy-legacy-selection-dialog/index.mjs +12 -2
- package/dist/qy-menu-actions/index.cjs +1 -1
- package/dist/qy-menu-actions/index.mjs +1 -1
- package/dist/qy-pagination/index.cjs +1 -1
- package/dist/qy-pagination/index.mjs +1 -1
- package/dist/qy-popconfirm/index.cjs +1 -1
- package/dist/qy-popconfirm/index.mjs +1 -1
- package/dist/qy-popover/index.cjs +1 -1
- package/dist/qy-popover/index.mjs +1 -1
- package/dist/qy-radio/index.cjs +1 -1
- package/dist/qy-radio/index.mjs +1 -1
- package/dist/qy-radio-group/index.cjs +1 -1
- package/dist/qy-radio-group/index.mjs +1 -1
- package/dist/qy-record-quote-search/index.cjs +4 -1
- package/dist/qy-record-quote-search/index.mjs +8 -2
- package/dist/qy-remark-image/index.cjs +3 -1
- package/dist/qy-remark-image/index.mjs +11 -2
- package/dist/qy-remote-select/index.cjs +3 -1
- package/dist/qy-remote-select/index.mjs +7 -2
- package/dist/qy-result/index.cjs +1 -1
- package/dist/qy-result/index.mjs +1 -1
- package/dist/qy-scrollbar/index.cjs +1 -1
- package/dist/qy-scrollbar/index.mjs +1 -1
- package/dist/qy-search-input/index.cjs +3 -1
- package/dist/qy-search-input/index.mjs +7 -2
- package/dist/qy-select/index.cjs +1 -1
- package/dist/qy-select/index.mjs +1 -1
- package/dist/qy-selection-dialog/index.cjs +7 -1
- package/dist/qy-selection-dialog/index.mjs +11 -2
- package/dist/qy-switch/index.cjs +1 -1
- package/dist/qy-switch/index.mjs +1 -1
- package/dist/qy-table-column-settings/index.cjs +1 -1
- package/dist/qy-table-column-settings/index.mjs +1 -1
- package/dist/qy-tabs/index.cjs +1 -1
- package/dist/qy-tabs/index.mjs +1 -1
- package/dist/qy-tag/index.cjs +1 -1
- package/dist/qy-tag/index.mjs +1 -1
- package/dist/qy-tooltip/index.cjs +1 -1
- package/dist/qy-tooltip/index.mjs +1 -1
- package/dist/qy-tree/index.cjs +1 -1
- package/dist/qy-tree/index.mjs +1 -1
- package/dist/qy-tree-select/index.cjs +1 -1
- package/dist/qy-tree-select/index.mjs +1 -1
- package/dist/qy-upload/index.cjs +1 -1
- package/dist/qy-upload/index.mjs +1 -1
- package/dist/shared/{index-DEoy2IfN.mjs → index-B0CTzdRW.mjs} +1 -1
- package/dist/shared/index-BJZjXeoT.cjs +1 -0
- package/dist/shared/index-BN4A-O6P.mjs +727 -0
- package/dist/shared/index-BR7tIt2k.mjs +211 -0
- package/dist/shared/index-BaRw7pWi.mjs +156 -0
- package/dist/shared/index-BqzKToOL.cjs +1 -0
- package/dist/shared/index-BxGP8OkE.cjs +1 -0
- package/dist/shared/{index-DM0zanTb.mjs → index-Bzr2RHi5.mjs} +1 -1
- package/dist/shared/index-C50jpQ11.mjs +295 -0
- package/dist/shared/{index-CsfcDlq4.cjs → index-CIXJwYI-.cjs} +1 -1
- package/dist/shared/index-CKkanVur.cjs +1 -0
- package/dist/shared/index-CLvL8LAM.cjs +1 -0
- package/dist/shared/index-CN2mgT5V.cjs +1 -0
- package/dist/shared/{index-uMEKxoXj.mjs → index-CW4s627w.mjs} +1 -1
- package/dist/shared/{index-8Iwma3ls.mjs → index-CXOCZlps.mjs} +2 -2
- package/dist/shared/{index-CUlhX6fW.cjs → index-CXnL-0Kp.cjs} +1 -1
- package/dist/shared/index-CbSGTE1S.mjs +578 -0
- package/dist/shared/index-Cqr-L0yd.mjs +285 -0
- package/dist/shared/{index-CjImIyvI.mjs → index-Cu6yAwdj.mjs} +1 -1
- package/dist/shared/index-D5HS8M1P.cjs +1 -0
- package/dist/shared/index-D6QwZtYV.mjs +56 -0
- package/dist/shared/index-DAU1WtID.mjs +361 -0
- package/dist/shared/index-DCsun70c.cjs +1 -0
- package/dist/shared/{index-D359jZg_.cjs → index-DEzFHeJL.cjs} +1 -1
- package/dist/shared/{index-2D5AFexl.mjs → index-DNMRIYkm.mjs} +1 -1
- package/dist/shared/index-DiN5vXXD.cjs +1 -0
- package/dist/shared/{index-Mj7JZt7y.cjs → index-Duq5XZ5w.cjs} +1 -1
- package/dist/shared/{index-DOpfxPDq.cjs → index-FZ5gl2au.cjs} +1 -1
- package/dist/shared/index-ykI9hKtc.mjs +88 -0
- package/dist/shared/{index.vue_vue_type_script_setup_true_lang-qXBKqHCs.mjs → index.vue_vue_type_script_setup_true_lang-4CNzVpgF.mjs} +2 -2
- package/dist/shared/{index.vue_vue_type_script_setup_true_lang-BNKC9382.cjs → index.vue_vue_type_script_setup_true_lang-D3MxDFk1.cjs} +1 -1
- package/dist/shared/{index.vue_vue_type_script_setup_true_lang-Bypkl4Ty.mjs → index.vue_vue_type_script_setup_true_lang-DECgTYqI.mjs} +1 -1
- package/dist/shared/{index.vue_vue_type_script_setup_true_lang-CYaK3oDY.cjs → index.vue_vue_type_script_setup_true_lang-DW2JKXjA.cjs} +1 -1
- package/dist/shared/index.vue_vue_type_script_setup_true_lang-DeFEEJk8.cjs +1 -0
- package/dist/shared/index.vue_vue_type_script_setup_true_lang-GUuWAB0o.mjs +238 -0
- package/dist/shared/{index.vue_vue_type_script_setup_true_lang-Byp7e--Y.mjs → index.vue_vue_type_script_setup_true_lang-mWNAIcqc.mjs} +1 -1
- package/dist/shared/{index.vue_vue_type_style_index_0_lang-D2iiEHqM.mjs → index.vue_vue_type_style_index_0_lang-BLRxKB-e.mjs} +1 -1
- package/dist/shared/{index.vue_vue_type_style_index_0_lang-z2Unl0WQ.mjs → index.vue_vue_type_style_index_0_lang-Ba6d5zw4.mjs} +1 -1
- package/dist/shared/{index.vue_vue_type_style_index_0_lang-OHPkiKBo.cjs → index.vue_vue_type_style_index_0_lang-C4yXFBV_.cjs} +1 -1
- package/dist/shared/{index.vue_vue_type_style_index_0_lang-DbQkbvgb.mjs → index.vue_vue_type_style_index_0_lang-CuTyK1Ey.mjs} +3 -3
- package/dist/shared/{index.vue_vue_type_style_index_0_lang-BI4abIsm.mjs → index.vue_vue_type_style_index_0_lang-CvVl_Y56.mjs} +21 -21
- package/dist/shared/js.cookie-BA-dL3zT.mjs +74 -0
- package/dist/shared/js.cookie-BmJmHEx1.cjs +1 -0
- package/dist/shared/{overlay-stack-CFFRngnU.mjs → overlay-stack-eI-yzYU6.mjs} +2 -2
- package/dist/shared/{utils-CUXINmHY.mjs → utils-DpZkMLkb.mjs} +1 -1
- package/index.d.ts +0 -3
- package/package.json +2 -1
- package/qy-remark-image/index.d.ts +4 -0
- package/dist/shared/index-BvXyRAhX.cjs +0 -1
- package/dist/shared/index-CPW3gKgP.mjs +0 -2429
- package/dist/shared/index-CUwUz-Le.cjs +0 -1
- package/dist/shared/index-DPqFEuPp.mjs +0 -798
- package/dist/shared/index.vue_vue_type_script_setup_true_lang-CPm8gzId.cjs +0 -1
- package/dist/shared/index.vue_vue_type_script_setup_true_lang-DkMm40Ac.mjs +0 -151
- /package/dist/shared/{index-DiEag4sK.cjs → index-5UAiwqdT.cjs} +0 -0
- /package/dist/shared/{index-BhpomD_C.cjs → index-AvNvmJe5.cjs} +0 -0
- /package/dist/shared/{index-_e-HwHF0.mjs → index-B1J7PQMl.mjs} +0 -0
- /package/dist/shared/{index-C5hzCMaD.mjs → index-B7j9BtSm.mjs} +0 -0
- /package/dist/shared/{index-BcDt1tKY.mjs → index-BAOV5iYx.mjs} +0 -0
- /package/dist/shared/{index-B3GsIwhf.mjs → index-BKdw4jD_.mjs} +0 -0
- /package/dist/shared/{index-B25yA5j-.mjs → index-BVaIvVMi.mjs} +0 -0
- /package/dist/shared/{index-HNFq7v-A.cjs → index-Bdlzmh8A.cjs} +0 -0
- /package/dist/shared/{index-MEzLM_rM.cjs → index-BgAP_K2E.cjs} +0 -0
- /package/dist/shared/{index-BfA7ZJnJ.cjs → index-Blgz8PJc.cjs} +0 -0
- /package/dist/shared/{index-Bq9quq2D.cjs → index-BsNtvE6i.cjs} +0 -0
- /package/dist/shared/{index-9G8dxxVx.mjs → index-BuVrLl5B.mjs} +0 -0
- /package/dist/shared/{index-Bfmf0msc.mjs → index-Bv1DrJ32.mjs} +0 -0
- /package/dist/shared/{index-DaUdmOjn.cjs → index-C6G9eVku.cjs} +0 -0
- /package/dist/shared/{index-DWBkjY5O.cjs → index-CB0v25oB.cjs} +0 -0
- /package/dist/shared/{index-B3YHS3Aa.mjs → index-CGH2ROZV.mjs} +0 -0
- /package/dist/shared/{index-BfXhDFFn.cjs → index-CxTyKMEH.cjs} +0 -0
- /package/dist/shared/{index-MyPNS-OR.cjs → index-DY2IXvwl.cjs} +0 -0
- /package/dist/shared/{index-XSV-GmR2.mjs → index-DdGlwebp.mjs} +0 -0
- /package/dist/shared/{index-ByQyMTPg.mjs → index-DvXzDAmi.mjs} +0 -0
- /package/dist/shared/{index-EIFVul2W.cjs → index-O6K0DO_k.cjs} +0 -0
- /package/dist/shared/{index-B3XwO-Lc.mjs → index-QN7-6GpS.mjs} +0 -0
- /package/dist/shared/{index-CVWru9T3.cjs → index-_Bagw0Pj.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_script_setup_true_lang-BnIolx5s.cjs → index.vue_vue_type_script_setup_true_lang-2ZOn9XPM.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_script_setup_true_lang-wG7OTsWa.mjs → index.vue_vue_type_script_setup_true_lang-DM0MGPZh.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-CVdFZeHK.mjs → index.vue_vue_type_style_index_0_lang-90f2jQr7.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-Dt19xolk.cjs → index.vue_vue_type_style_index_0_lang-B4fDeQox.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-hbNK_h45.cjs → index.vue_vue_type_style_index_0_lang-BNL5vyrU.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-gs0YJI91.mjs → index.vue_vue_type_style_index_0_lang-BvBAR8A1.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-BZZ8vhEf.cjs → index.vue_vue_type_style_index_0_lang-BzJsAWKD.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-C1n-zAZh.mjs → index.vue_vue_type_style_index_0_lang-C7L66EnO.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-CYIUfOy9.cjs → index.vue_vue_type_style_index_0_lang-CFp5MK6j.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-Tzo8o6M8.mjs → index.vue_vue_type_style_index_0_lang-CN3dJjUV.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-CPxbKjvY.mjs → index.vue_vue_type_style_index_0_lang-CNdV3Mnk.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-W44zpeKW.cjs → index.vue_vue_type_style_index_0_lang-CVAm3ApY.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-B1FgJZbw.mjs → index.vue_vue_type_style_index_0_lang-CgScSrRJ.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-DFAaBzkW.cjs → index.vue_vue_type_style_index_0_lang-Clt7QDAK.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-WGzoSatU.cjs → index.vue_vue_type_style_index_0_lang-CvlRVqcl.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-BNBJu1Mq.cjs → index.vue_vue_type_style_index_0_lang-D-p1u8y8.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-DzvboHR2.mjs → index.vue_vue_type_style_index_0_lang-D9T_xdbu.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-E92uiH6Q.cjs → index.vue_vue_type_style_index_0_lang-DGV7FQlw.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-KHk9wRYT.mjs → index.vue_vue_type_style_index_0_lang-DGt78p3G.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-shJS7iXC.mjs → index.vue_vue_type_style_index_0_lang-DZOPXZov.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-BXTkWo5P.cjs → index.vue_vue_type_style_index_0_lang-J7wvS2CR.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-Bpe6LkvL.mjs → index.vue_vue_type_style_index_0_lang-KXiTSh4t.mjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-DVXf-yUs.cjs → index.vue_vue_type_style_index_0_lang-YEjVWWsy.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-D9DraThL.cjs → index.vue_vue_type_style_index_0_lang-nS-EDK4t.cjs} +0 -0
- /package/dist/shared/{index.vue_vue_type_style_index_0_lang-BnPRHCwR.cjs → index.vue_vue_type_style_index_0_lang-yci929so.cjs} +0 -0
|
@@ -1,2429 +0,0 @@
|
|
|
1
|
-
import { _ as Ie } from "./index.vue_vue_type_style_index_0_lang-D2iiEHqM.mjs";
|
|
2
|
-
import { U as We, a as Aa } from "./index-DPqFEuPp.mjs";
|
|
3
|
-
import { I as qa } from "./index-CjImIyvI.mjs";
|
|
4
|
-
import { _ as Pa } from "./index.vue_vue_type_script_setup_true_lang-qXBKqHCs.mjs";
|
|
5
|
-
import { useAttrs as Se, ref as x, computed as P, openBlock as Q, createBlock as Y, mergeProps as me, unref as v, defineComponent as ve, watch as ee, onMounted as Ta, nextTick as De, onBeforeUnmount as Be, createElementBlock as R, normalizeStyle as Ge, normalizeClass as ge, createElementVNode as te, withCtx as b, Fragment as Pe, renderList as Oe, createCommentVNode as I, createVNode as O, createTextVNode as ce, createSlots as xe, renderSlot as q, normalizeProps as He, guardReactiveProps as Je, withKeys as _e, toDisplayString as ye, useSlots as Ia, getCurrentInstance as Ra, reactive as Re, withModifiers as ze, withDirectives as Ze, vShow as Fa } from "vue";
|
|
6
|
-
import { useFormDisabled as Ke, ElMessage as $e, ElSelect as Xe, ElOption as Ye, ElInput as Te, ElPopover as Da, ElButton as fe, ElUpload as Oa, ElAutocomplete as xa, ElForm as et, ElFormItem as he, ElTable as _a, ElTableColumn as za, ElPagination as Ka, ElTreeSelect as Ma } from "element-plus";
|
|
7
|
-
import { _ as we } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
|
|
8
|
-
import { B as Ea } from "./index-B3XwO-Lc.mjs";
|
|
9
|
-
import { D as La } from "./index-B1gnVI8Y.mjs";
|
|
10
|
-
import { _ as Ua } from "./index-B3GsIwhf.mjs";
|
|
11
|
-
import { _ as Na } from "./index.vue_vue_type_script_setup_true_lang-DkMm40Ac.mjs";
|
|
12
|
-
import { _ as ja } from "./index.vue_vue_type_style_index_0_lang-B1FgJZbw.mjs";
|
|
13
|
-
import { _ as Wa } from "./index.vue_vue_type_script_setup_true_lang-BtMkNw_I.mjs";
|
|
14
|
-
import { _ as Ga } from "./index.vue_vue_type_style_index_0_lang-shJS7iXC.mjs";
|
|
15
|
-
import { C as Ha } from "./index-_e-HwHF0.mjs";
|
|
16
|
-
import { _ as Ja } from "./index.vue_vue_type_script_setup_true_lang-Byp7e--Y.mjs";
|
|
17
|
-
import { R as Za } from "./index-9G8dxxVx.mjs";
|
|
18
|
-
import { _ as Xa } from "./index.vue_vue_type_script_setup_true_lang-DMHhx9lY.mjs";
|
|
19
|
-
import { M as Ya } from "./index-DEoy2IfN.mjs";
|
|
20
|
-
import { T as eo } from "./index-DM0zanTb.mjs";
|
|
21
|
-
import { _ as to } from "./index.vue_vue_type_script_setup_true_lang-Bypkl4Ty.mjs";
|
|
22
|
-
import { S as Me } from "./index-C5hzCMaD.mjs";
|
|
23
|
-
import { T as tt } from "./index-BcDt1tKY.mjs";
|
|
24
|
-
import { ElLoadingDirective as ao } from "element-plus/es";
|
|
25
|
-
import { T as Fe } from "./index-B3YHS3Aa.mjs";
|
|
26
|
-
import { F as oo } from "./index-uMEKxoXj.mjs";
|
|
27
|
-
import { S as no } from "./index-Bfmf0msc.mjs";
|
|
28
|
-
import { _ as lo } from "./index.vue_vue_type_script_lang-DIKHRo0o.mjs";
|
|
29
|
-
import { _ as ro } from "./index.vue_vue_type_style_index_0_lang-CPxbKjvY.mjs";
|
|
30
|
-
import { _ as io } from "./index.vue_vue_type_style_index_0_lang-Bpe6LkvL.mjs";
|
|
31
|
-
import { _ as so } from "./index.vue_vue_type_style_index_0_lang-z2Unl0WQ.mjs";
|
|
32
|
-
import { _ as uo } from "./index.vue_vue_type_style_index_0_lang-BI4abIsm.mjs";
|
|
33
|
-
import { _ as co } from "./index.vue_vue_type_script_setup_true_lang-BJe7Uo6S.mjs";
|
|
34
|
-
import { _ as fo } from "./index.vue_vue_type_script_setup_true_lang-Dd_nKJvH.mjs";
|
|
35
|
-
import { _ as yo } from "./index.vue_vue_type_style_index_0_lang-gs0YJI91.mjs";
|
|
36
|
-
import { _ as mo } from "./index.vue_vue_type_script_lang-Dfq7D3mJ.mjs";
|
|
37
|
-
import { _ as po } from "./index.vue_vue_type_script_lang-CZK0hDYa.mjs";
|
|
38
|
-
import { _ as go } from "./index.vue_vue_type_script_lang-69zSOotQ.mjs";
|
|
39
|
-
import { F as ho } from "./index-8Iwma3ls.mjs";
|
|
40
|
-
import { Q as at } from "./index-2D5AFexl.mjs";
|
|
41
|
-
import { _ as vo } from "./index.vue_vue_type_style_index_0_lang-DbQkbvgb.mjs";
|
|
42
|
-
import { _ as bo } from "./index.vue_vue_type_style_index_0_lang-DzvboHR2.mjs";
|
|
43
|
-
import { _ as Qo } from "./index.vue_vue_type_script_lang-Bk0kLg5l.mjs";
|
|
44
|
-
import { _ as So } from "./index.vue_vue_type_script_lang-BaIOvoQn.mjs";
|
|
45
|
-
import { _ as wo } from "./index.vue_vue_type_script_lang-DRvk4-_O.mjs";
|
|
46
|
-
import { _ as ko } from "./index.vue_vue_type_script_lang-ChS-3_vl.mjs";
|
|
47
|
-
import { _ as $o } from "./index.vue_vue_type_script_lang-CWnNQBPN.mjs";
|
|
48
|
-
import { _ as Co } from "./index.vue_vue_type_script_lang-D7b9ABei.mjs";
|
|
49
|
-
import { _ as Vo } from "./index.vue_vue_type_script_lang-chBiq2cG.mjs";
|
|
50
|
-
import { _ as Bo } from "./index.vue_vue_type_style_index_0_lang-C1n-zAZh.mjs";
|
|
51
|
-
import { _ as Ao } from "./index.vue_vue_type_script_setup_true_lang-Bdz9oDDW.mjs";
|
|
52
|
-
import { _ as qo } from "./index.vue_vue_type_script_setup_true_lang-BXnZt9UT.mjs";
|
|
53
|
-
import { I as Po } from "./index-B25yA5j-.mjs";
|
|
54
|
-
import { _ as To } from "./index.vue_vue_type_script_setup_true_lang-B4JrNUDc.mjs";
|
|
55
|
-
import { _ as Io } from "./index.vue_vue_type_script_lang-D7nzeBUR.mjs";
|
|
56
|
-
import { _ as Ro } from "./index.vue_vue_type_script_lang-C9X0V5AK.mjs";
|
|
57
|
-
import { _ as Fo } from "./index.vue_vue_type_script_lang-C4JHCuXz.mjs";
|
|
58
|
-
import { _ as Do } from "./index.vue_vue_type_style_index_0_lang-Tzo8o6M8.mjs";
|
|
59
|
-
import { _ as Oo } from "./index.vue_vue_type_script_setup_true_lang-COAUEujY.mjs";
|
|
60
|
-
import { _ as xo } from "./index.vue_vue_type_style_index_0_lang-CVdFZeHK.mjs";
|
|
61
|
-
import { _ as _o } from "./index.vue_vue_type_script_lang-BGAdXWIL.mjs";
|
|
62
|
-
import { _ as zo } from "./index.vue_vue_type_script_lang-BnmY1ndj.mjs";
|
|
63
|
-
import { _ as Ko } from "./index.vue_vue_type_script_lang-DOOT2grg.mjs";
|
|
64
|
-
import { _ as Mo } from "./index.vue_vue_type_style_index_0_lang-KHk9wRYT.mjs";
|
|
65
|
-
import { P as Eo } from "./index-XSV-GmR2.mjs";
|
|
66
|
-
import { w as f } from "./install-CxBnxbuN.mjs";
|
|
67
|
-
import { v as Lo, Q as ot } from "./index-B1zDCCqy.mjs";
|
|
68
|
-
import { _ as Uo } from "./index.vue_vue_type_script_setup_true_lang-wG7OTsWa.mjs";
|
|
69
|
-
import { o as No } from "./utils-CUXINmHY.mjs";
|
|
70
|
-
import { openQyLoading as jo } from "@qynpm/hooks";
|
|
71
|
-
const Wo = /* @__PURE__ */ Object.assign({
|
|
72
|
-
name: "QyImageUpload",
|
|
73
|
-
inheritAttrs: !1
|
|
74
|
-
}, {
|
|
75
|
-
__name: "index",
|
|
76
|
-
props: {
|
|
77
|
-
/** 单图/单文件 URL;multiple=true 时为 URL 数组。 */
|
|
78
|
-
modelValue: { type: [String, Array], default: "" },
|
|
79
|
-
/** 上传接口路径。 */
|
|
80
|
-
api: { type: String, default: "/permission-api/common/uploads" },
|
|
81
|
-
/** FormData 中文件字段名。 */
|
|
82
|
-
name: { type: String, default: "files" },
|
|
83
|
-
/** 是否禁用。 */
|
|
84
|
-
disabled: { type: Boolean, default: void 0 },
|
|
85
|
-
/** 是否多选;开启后 v-model 输出 string[]。 */
|
|
86
|
-
multiple: { type: Boolean, default: !1 },
|
|
87
|
-
/** 上传模式。voucher 用于承接旧 CopyImgUpload 的凭证图片场景。 */
|
|
88
|
-
mode: { type: String, default: "default" },
|
|
89
|
-
/** 是否启用凭证图片模式。 */
|
|
90
|
-
voucher: { type: Boolean, default: !1 },
|
|
91
|
-
/** 允许的文件类型后缀。 */
|
|
92
|
-
fileType: { type: Array, default: () => [] },
|
|
93
|
-
/** 单个文件大小限制(MB)。 */
|
|
94
|
-
fileSize: { type: Number, default: 10 },
|
|
95
|
-
/** 是否显示格式/大小提示。 */
|
|
96
|
-
isShowTip: { type: Boolean, default: !1 },
|
|
97
|
-
/** 文件数量限制;不传时单图为 1,多图为 9。 */
|
|
98
|
-
limit: { type: Number, default: void 0 },
|
|
99
|
-
/** token 读取 key。 */
|
|
100
|
-
tokenKey: { type: String, default: "Admin-Token" },
|
|
101
|
-
/** 是否为视频上传。 */
|
|
102
|
-
supportVideo: { type: Boolean, default: !1 },
|
|
103
|
-
/** 上传卡片尺寸。 */
|
|
104
|
-
size: { type: String, default: "128px" },
|
|
105
|
-
/** 禁用拖拽。 */
|
|
106
|
-
disableDrag: { type: Boolean, default: !1 },
|
|
107
|
-
/** 是否显示纯粘贴入口。 */
|
|
108
|
-
showPasteInput: { type: Boolean, default: !0 },
|
|
109
|
-
/** 粘贴入口提示文案。 */
|
|
110
|
-
pastePlaceholder: { type: String, default: "粘贴图片上传" },
|
|
111
|
-
/** 成功回调。 */
|
|
112
|
-
callBack: { type: Function, default: null },
|
|
113
|
-
/** 上传时附加的额外 FormData 字段。 */
|
|
114
|
-
extraData: { type: Object, default: () => ({}) },
|
|
115
|
-
/** 自定义上传请求,用于接入宿主项目 request / 鉴权 / baseURL。 */
|
|
116
|
-
uploadRequest: { type: Function, default: null }
|
|
117
|
-
},
|
|
118
|
-
emits: [
|
|
119
|
-
"update:modelValue",
|
|
120
|
-
"change",
|
|
121
|
-
"success",
|
|
122
|
-
"error",
|
|
123
|
-
"remove",
|
|
124
|
-
"updateImg"
|
|
125
|
-
],
|
|
126
|
-
setup(e, { expose: F, emit: N }) {
|
|
127
|
-
const t = e, i = N, oe = Se(), S = x(null), m = ["jpg", "jpeg", "png", "gif", "bmp", "webp"], s = P(
|
|
128
|
-
() => t.voucher || t.mode === "voucher"
|
|
129
|
-
), $ = P(() => Array.isArray(t.modelValue) ? t.modelValue.filter(Boolean) : t.modelValue ? String(t.modelValue).split(",").filter(Boolean) : []), w = P(() => t.supportVideo ? 1 : s.value ? t.limit ?? 30 : t.limit ?? (t.multiple ? 9 : 1)), _ = P(() => {
|
|
130
|
-
var y;
|
|
131
|
-
return (y = t.fileType) != null && y.length ? t.fileType : s.value && !t.supportVideo ? m : [];
|
|
132
|
-
});
|
|
133
|
-
function V(y) {
|
|
134
|
-
return Array.isArray(y) ? y.filter(Boolean) : [];
|
|
135
|
-
}
|
|
136
|
-
function k(y) {
|
|
137
|
-
const C = V(y);
|
|
138
|
-
return t.multiple ? C : C[0] || "";
|
|
139
|
-
}
|
|
140
|
-
function T(y) {
|
|
141
|
-
i("update:modelValue", k(y));
|
|
142
|
-
}
|
|
143
|
-
function j(y) {
|
|
144
|
-
i("change", k(y == null ? void 0 : y.files));
|
|
145
|
-
}
|
|
146
|
-
function M(y) {
|
|
147
|
-
var c, a;
|
|
148
|
-
if (typeof y == "string") return y;
|
|
149
|
-
const C = y || {}, o = C.url ?? C.urls ?? ((c = C.data) == null ? void 0 : c.url) ?? ((a = C.data) == null ? void 0 : a.urls) ?? "";
|
|
150
|
-
return Array.isArray(o) ? o[0] || "" : o || "";
|
|
151
|
-
}
|
|
152
|
-
function G(y) {
|
|
153
|
-
const C = M(y);
|
|
154
|
-
C && i("updateImg", C), i("success", le(), y);
|
|
155
|
-
}
|
|
156
|
-
function E(y) {
|
|
157
|
-
i("error", y);
|
|
158
|
-
}
|
|
159
|
-
function U(y, C) {
|
|
160
|
-
i("remove", y, C);
|
|
161
|
-
}
|
|
162
|
-
function H() {
|
|
163
|
-
var y, C;
|
|
164
|
-
(C = (y = S.value) == null ? void 0 : y.openFileDialog) == null || C.call(y);
|
|
165
|
-
}
|
|
166
|
-
function B() {
|
|
167
|
-
var y, C;
|
|
168
|
-
(C = (y = S.value) == null ? void 0 : y.clearFiles) == null || C.call(y);
|
|
169
|
-
}
|
|
170
|
-
function z() {
|
|
171
|
-
var y, C;
|
|
172
|
-
return ((C = (y = S.value) == null ? void 0 : y.getPathList) == null ? void 0 : C.call(y)) || [];
|
|
173
|
-
}
|
|
174
|
-
const J = P(() => z()), W = P(() => z());
|
|
175
|
-
function Z() {
|
|
176
|
-
return z();
|
|
177
|
-
}
|
|
178
|
-
function le() {
|
|
179
|
-
const y = z();
|
|
180
|
-
return t.multiple ? y : y[0] || "";
|
|
181
|
-
}
|
|
182
|
-
return F({
|
|
183
|
-
openFileDialog: H,
|
|
184
|
-
clearFiles: B,
|
|
185
|
-
getPathList: z,
|
|
186
|
-
getFullPathList: Z,
|
|
187
|
-
fullPathList: J,
|
|
188
|
-
pathList: W,
|
|
189
|
-
getValue: le
|
|
190
|
-
}), (y, C) => (Q(), Y(We, me({
|
|
191
|
-
ref_key: "uploadRef",
|
|
192
|
-
ref: S
|
|
193
|
-
}, v(oe), {
|
|
194
|
-
"model-value": $.value,
|
|
195
|
-
"value-format": "array",
|
|
196
|
-
api: e.api,
|
|
197
|
-
name: e.name,
|
|
198
|
-
multiple: e.multiple,
|
|
199
|
-
disabled: e.disabled,
|
|
200
|
-
"file-type": _.value,
|
|
201
|
-
"file-size": e.fileSize,
|
|
202
|
-
limit: w.value,
|
|
203
|
-
"is-show-tip": e.isShowTip,
|
|
204
|
-
"token-key": e.tokenKey,
|
|
205
|
-
"support-video": e.supportVideo,
|
|
206
|
-
size: e.size,
|
|
207
|
-
"disable-drag": e.disableDrag,
|
|
208
|
-
"call-back": e.callBack,
|
|
209
|
-
"extra-data": e.extraData,
|
|
210
|
-
"upload-request": e.uploadRequest,
|
|
211
|
-
"show-text": !1,
|
|
212
|
-
"show-paste-input": e.showPasteInput,
|
|
213
|
-
"paste-placeholder": e.pastePlaceholder,
|
|
214
|
-
"onUpdate:modelValue": T,
|
|
215
|
-
onChange: j,
|
|
216
|
-
onSuccess: G,
|
|
217
|
-
onError: E,
|
|
218
|
-
onRemove: U
|
|
219
|
-
}), null, 16, ["model-value", "api", "name", "multiple", "disabled", "file-type", "file-size", "limit", "is-show-tip", "token-key", "support-video", "size", "disable-drag", "call-back", "extra-data", "upload-request", "show-paste-input", "paste-placeholder"]));
|
|
220
|
-
}
|
|
221
|
-
});
|
|
222
|
-
function Ne(e) {
|
|
223
|
-
const F = e == null ? void 0 : e.match(/(\[url\:(.*?)\])(.*)/);
|
|
224
|
-
return F ? {
|
|
225
|
-
imageUrl: F[2],
|
|
226
|
-
text: F[3]
|
|
227
|
-
} : {
|
|
228
|
-
imageUrl: "",
|
|
229
|
-
text: e || ""
|
|
230
|
-
};
|
|
231
|
-
}
|
|
232
|
-
function Go(e) {
|
|
233
|
-
const F = String(e || "").match(/(\[url\:.*?\])([\s\S]*)/);
|
|
234
|
-
return F ? F[2] : e;
|
|
235
|
-
}
|
|
236
|
-
function je(e, F) {
|
|
237
|
-
return F ? `[url:${F}]${e}` : e;
|
|
238
|
-
}
|
|
239
|
-
const Ho = { class: "qy-remark-image__field" }, Jo = {
|
|
240
|
-
key: 1,
|
|
241
|
-
class: "qy-remark-image__divider"
|
|
242
|
-
}, Zo = { class: "qy-remark-image__upload-anchor" }, Xo = {
|
|
243
|
-
key: 0,
|
|
244
|
-
class: "icon-[line-md--loading-twotone-loop]",
|
|
245
|
-
role: "img",
|
|
246
|
-
"aria-hidden": "true"
|
|
247
|
-
}, Yo = {
|
|
248
|
-
key: 1,
|
|
249
|
-
class: "icon-[ion--cloud-upload-outline]",
|
|
250
|
-
role: "img",
|
|
251
|
-
"aria-hidden": "true"
|
|
252
|
-
}, en = {
|
|
253
|
-
key: 2,
|
|
254
|
-
class: "icon-[ph--images-thin]",
|
|
255
|
-
role: "img",
|
|
256
|
-
"aria-hidden": "true"
|
|
257
|
-
}, tn = { class: "qy-remark-image__popover" }, an = ["src"], on = { class: "qy-remark-image__popover-footer" }, nn = /* @__PURE__ */ ve({
|
|
258
|
-
__name: "index",
|
|
259
|
-
props: {
|
|
260
|
-
defaultValue: { default: "" },
|
|
261
|
-
defaultImage: { default: "" },
|
|
262
|
-
rows: { default: 6 },
|
|
263
|
-
width: { default: "" },
|
|
264
|
-
autosize: { type: [Boolean, Object], default: !1 },
|
|
265
|
-
disabled: { type: Boolean, default: void 0 },
|
|
266
|
-
placeholder: { default: "粘贴图片上传" },
|
|
267
|
-
type: { default: "textarea" },
|
|
268
|
-
layout: { default: "default" },
|
|
269
|
-
selectValue: { type: [String, Number, Boolean], default: "" },
|
|
270
|
-
selectOptions: { default: () => [] },
|
|
271
|
-
selectDisabled: { type: Boolean, default: !1 },
|
|
272
|
-
api: { default: "/permission-api/common/uploads" },
|
|
273
|
-
tokenKey: { default: "Admin-Token" },
|
|
274
|
-
uploadName: { default: "files" },
|
|
275
|
-
uploadRequest: {}
|
|
276
|
-
},
|
|
277
|
-
emits: ["change", "update:selectValue", "select-change"],
|
|
278
|
-
setup(e, { expose: F, emit: N }) {
|
|
279
|
-
const t = e, i = N, oe = Se(), S = Ke(), m = x(null), s = x(""), $ = x(""), w = x(!1);
|
|
280
|
-
let _ = 0, V;
|
|
281
|
-
function k() {
|
|
282
|
-
_++, V == null || V.abort(), V = void 0, w.value = !1;
|
|
283
|
-
}
|
|
284
|
-
const T = P(
|
|
285
|
-
() => t.layout === "select-prefix"
|
|
286
|
-
), j = P(() => ({
|
|
287
|
-
"qy-remark-image--select-prefix": T.value
|
|
288
|
-
})), M = P(
|
|
289
|
-
() => T.value || t.type === "text" ? "text" : "textarea"
|
|
290
|
-
), G = P(() => {
|
|
291
|
-
if (t.width)
|
|
292
|
-
return {
|
|
293
|
-
width: typeof t.width == "number" ? `${t.width}px` : t.width
|
|
294
|
-
};
|
|
295
|
-
});
|
|
296
|
-
ee(
|
|
297
|
-
() => t.defaultValue,
|
|
298
|
-
(o) => {
|
|
299
|
-
const c = Ne(o || ""), a = c.imageUrl || t.defaultImage || "";
|
|
300
|
-
(c.text !== s.value || a !== $.value) && k(), s.value = c.text, $.value = a;
|
|
301
|
-
},
|
|
302
|
-
{ immediate: !0 }
|
|
303
|
-
), ee(
|
|
304
|
-
() => t.defaultImage,
|
|
305
|
-
(o) => {
|
|
306
|
-
o !== void 0 && !Ne(t.defaultValue || "").imageUrl && ((o || "") !== $.value && k(), $.value = o || "");
|
|
307
|
-
},
|
|
308
|
-
{ immediate: !0 }
|
|
309
|
-
), Ta(() => {
|
|
310
|
-
De(U);
|
|
311
|
-
}), Be(() => {
|
|
312
|
-
k();
|
|
313
|
-
const o = E();
|
|
314
|
-
o && o.removeEventListener("paste", W);
|
|
315
|
-
});
|
|
316
|
-
function E() {
|
|
317
|
-
var o, c;
|
|
318
|
-
return ((o = m.value) == null ? void 0 : o.textarea) || ((c = m.value) == null ? void 0 : c.input) || null;
|
|
319
|
-
}
|
|
320
|
-
function U() {
|
|
321
|
-
const o = E();
|
|
322
|
-
o && (o.removeEventListener("paste", W), o.addEventListener("paste", W));
|
|
323
|
-
}
|
|
324
|
-
function H(o) {
|
|
325
|
-
S.value || (s.value = Go(o || ""));
|
|
326
|
-
}
|
|
327
|
-
function B(o) {
|
|
328
|
-
S.value || t.selectDisabled || (i("update:selectValue", o), i("select-change", o));
|
|
329
|
-
}
|
|
330
|
-
function z() {
|
|
331
|
-
S.value || (k(), $.value = "", C());
|
|
332
|
-
}
|
|
333
|
-
function J() {
|
|
334
|
-
k(), s.value = "", $.value = "", C();
|
|
335
|
-
}
|
|
336
|
-
async function W(o) {
|
|
337
|
-
var u;
|
|
338
|
-
if (S.value || w.value) return;
|
|
339
|
-
const a = Array.from(((u = o.clipboardData) == null ? void 0 : u.files) || []).find((p) => p.type.startsWith("image/"));
|
|
340
|
-
a && (o.preventDefault(), await Z({
|
|
341
|
-
file: a,
|
|
342
|
-
onError: () => {
|
|
343
|
-
},
|
|
344
|
-
onProgress: () => {
|
|
345
|
-
},
|
|
346
|
-
onSuccess: () => {
|
|
347
|
-
}
|
|
348
|
-
}));
|
|
349
|
-
}
|
|
350
|
-
async function Z(o) {
|
|
351
|
-
var a, u;
|
|
352
|
-
if (S.value || w.value) return !1;
|
|
353
|
-
if (o.file.size > 51200 * 1e3)
|
|
354
|
-
return $e.error("图片过大"), !1;
|
|
355
|
-
w.value = !0;
|
|
356
|
-
const c = ++_;
|
|
357
|
-
V = t.uploadRequest ? void 0 : new AbortController();
|
|
358
|
-
try {
|
|
359
|
-
const p = await le(o, V == null ? void 0 : V.signal);
|
|
360
|
-
return c !== _ ? !1 : ($.value = y(p), C(), $e.success("上传图片成功"), (a = o.onSuccess) == null || a.call(o, p), !0);
|
|
361
|
-
} catch (p) {
|
|
362
|
-
return c !== _ || ((u = o.onError) == null || u.call(o, p), $e.error("上传失败")), !1;
|
|
363
|
-
} finally {
|
|
364
|
-
c === _ && (w.value = !1, V = void 0);
|
|
365
|
-
}
|
|
366
|
-
}
|
|
367
|
-
async function le(o, c) {
|
|
368
|
-
const a = new FormData();
|
|
369
|
-
if (a.append(t.uploadName, o.file), t.uploadRequest)
|
|
370
|
-
return t.uploadRequest({
|
|
371
|
-
file: o.file,
|
|
372
|
-
formData: a,
|
|
373
|
-
options: o,
|
|
374
|
-
api: t.api,
|
|
375
|
-
tokenKey: t.tokenKey
|
|
376
|
-
});
|
|
377
|
-
const u = Aa.get(t.tokenKey);
|
|
378
|
-
return (await fetch(t.api, {
|
|
379
|
-
method: "POST",
|
|
380
|
-
signal: c,
|
|
381
|
-
body: a,
|
|
382
|
-
credentials: "include",
|
|
383
|
-
headers: u ? { Authorization: `Bearer ${u}` } : void 0
|
|
384
|
-
})).json();
|
|
385
|
-
}
|
|
386
|
-
function y(o) {
|
|
387
|
-
var u, p;
|
|
388
|
-
if (typeof o == "string") return o;
|
|
389
|
-
const c = o, a = (c == null ? void 0 : c.urls) ?? ((u = c == null ? void 0 : c.data) == null ? void 0 : u.urls) ?? ((p = c == null ? void 0 : c.data) == null ? void 0 : p.url) ?? (c == null ? void 0 : c.url) ?? "";
|
|
390
|
-
return Array.isArray(a) ? a[0] || "" : a || "";
|
|
391
|
-
}
|
|
392
|
-
function C() {
|
|
393
|
-
i(
|
|
394
|
-
"change",
|
|
395
|
-
je(s.value || "", $.value || ""),
|
|
396
|
-
$.value || ""
|
|
397
|
-
);
|
|
398
|
-
}
|
|
399
|
-
return F({
|
|
400
|
-
deleteImage: z,
|
|
401
|
-
// 兼容旧 remarkImage,在表单 reset/clearFrom 时清空文字和图片。
|
|
402
|
-
clearContent: J,
|
|
403
|
-
// 给表单保存或外部调试读取当前拆分值。
|
|
404
|
-
getValue: () => ({
|
|
405
|
-
text: s.value || "",
|
|
406
|
-
imageUrl: $.value || "",
|
|
407
|
-
value: je(s.value || "", $.value || "")
|
|
408
|
-
})
|
|
409
|
-
}), (o, c) => (Q(), R("div", {
|
|
410
|
-
class: ge(["qy-remark-image", j.value]),
|
|
411
|
-
style: Ge(G.value)
|
|
412
|
-
}, [
|
|
413
|
-
te("div", Ho, [
|
|
414
|
-
T.value ? (Q(), Y(v(Xe), {
|
|
415
|
-
key: 0,
|
|
416
|
-
class: "qy-remark-image__prefix-select",
|
|
417
|
-
"model-value": e.selectValue,
|
|
418
|
-
options: e.selectOptions,
|
|
419
|
-
disabled: v(S) || e.selectDisabled,
|
|
420
|
-
size: "small",
|
|
421
|
-
"onUpdate:modelValue": B
|
|
422
|
-
}, {
|
|
423
|
-
default: b(() => [
|
|
424
|
-
(Q(!0), R(Pe, null, Oe(e.selectOptions, (a) => (Q(), Y(v(Ye), {
|
|
425
|
-
key: String(a.value),
|
|
426
|
-
label: a.label,
|
|
427
|
-
value: a.value,
|
|
428
|
-
disabled: a.disabled
|
|
429
|
-
}, null, 8, ["label", "value", "disabled"]))), 128))
|
|
430
|
-
]),
|
|
431
|
-
_: 1
|
|
432
|
-
}, 8, ["model-value", "options", "disabled"])) : I("", !0),
|
|
433
|
-
T.value ? (Q(), R("span", Jo)) : I("", !0),
|
|
434
|
-
O(v(Te), me({
|
|
435
|
-
ref_key: "inputRef",
|
|
436
|
-
ref: m,
|
|
437
|
-
"model-value": s.value,
|
|
438
|
-
type: M.value,
|
|
439
|
-
rows: e.rows,
|
|
440
|
-
autosize: e.autosize,
|
|
441
|
-
disabled: v(S),
|
|
442
|
-
placeholder: e.placeholder
|
|
443
|
-
}, v(oe), {
|
|
444
|
-
"onUpdate:modelValue": H,
|
|
445
|
-
onBlur: C
|
|
446
|
-
}), null, 16, ["model-value", "type", "rows", "autosize", "disabled", "placeholder"]),
|
|
447
|
-
O(v(Da), {
|
|
448
|
-
placement: "top-start",
|
|
449
|
-
width: 400,
|
|
450
|
-
trigger: "hover",
|
|
451
|
-
disabled: !$.value
|
|
452
|
-
}, {
|
|
453
|
-
reference: b(() => [
|
|
454
|
-
te("div", Zo, [
|
|
455
|
-
O(v(Oa), {
|
|
456
|
-
disabled: w.value || v(S),
|
|
457
|
-
class: "qy-remark-image__upload",
|
|
458
|
-
"show-file-list": !1,
|
|
459
|
-
"http-request": Z
|
|
460
|
-
}, {
|
|
461
|
-
default: b(() => [
|
|
462
|
-
w.value ? (Q(), R("span", Xo)) : $.value ? (Q(), R("span", en)) : (Q(), R("span", Yo))
|
|
463
|
-
]),
|
|
464
|
-
_: 1
|
|
465
|
-
}, 8, ["disabled"])
|
|
466
|
-
])
|
|
467
|
-
]),
|
|
468
|
-
default: b(() => [
|
|
469
|
-
te("div", tn, [
|
|
470
|
-
te("img", {
|
|
471
|
-
src: $.value,
|
|
472
|
-
class: "qy-remark-image__preview-img"
|
|
473
|
-
}, null, 8, an),
|
|
474
|
-
te("div", on, [
|
|
475
|
-
c[1] || (c[1] = te("span", { class: "qy-remark-image__popover-tip" }, "再次点击按钮可更换图片", -1)),
|
|
476
|
-
O(v(fe), {
|
|
477
|
-
link: "",
|
|
478
|
-
size: "small",
|
|
479
|
-
type: "danger",
|
|
480
|
-
disabled: v(S),
|
|
481
|
-
onClick: z
|
|
482
|
-
}, {
|
|
483
|
-
default: b(() => [...c[0] || (c[0] = [
|
|
484
|
-
ce(" 删除图片 ", -1)
|
|
485
|
-
])]),
|
|
486
|
-
_: 1
|
|
487
|
-
}, 8, ["disabled"])
|
|
488
|
-
])
|
|
489
|
-
])
|
|
490
|
-
]),
|
|
491
|
-
_: 1
|
|
492
|
-
}, 8, ["disabled"])
|
|
493
|
-
])
|
|
494
|
-
], 6));
|
|
495
|
-
}
|
|
496
|
-
}), ln = /* @__PURE__ */ we(nn, [["__scopeId", "data-v-50037758"]]), rn = /* @__PURE__ */ ve({
|
|
497
|
-
name: "QyRemoteSelect",
|
|
498
|
-
inheritAttrs: !1,
|
|
499
|
-
__name: "index",
|
|
500
|
-
props: {
|
|
501
|
-
modelValue: { type: [String, Number, Boolean, Array, null], default: void 0 },
|
|
502
|
-
fetchMethod: {},
|
|
503
|
-
defaultOptions: { default: () => [] },
|
|
504
|
-
labelKey: { default: "label" },
|
|
505
|
-
valueKey: { default: "value" },
|
|
506
|
-
disabledKey: { default: "disabled" },
|
|
507
|
-
placeholder: { default: "请选择" },
|
|
508
|
-
disabled: { type: Boolean, default: void 0 },
|
|
509
|
-
clearable: { type: Boolean, default: !0 },
|
|
510
|
-
multiple: { type: Boolean, default: !1 },
|
|
511
|
-
multipleLimit: { default: 0 },
|
|
512
|
-
validateEvent: { type: Boolean, default: !0 },
|
|
513
|
-
collapseTags: { type: Boolean, default: !1 },
|
|
514
|
-
collapseTagsTooltip: { type: Boolean, default: !1 },
|
|
515
|
-
autoSelectSingle: { type: Boolean, default: !1 },
|
|
516
|
-
size: { default: void 0 },
|
|
517
|
-
teleported: { type: Boolean, default: !0 },
|
|
518
|
-
appendTo: { default: "body" },
|
|
519
|
-
fitInputWidth: { type: Boolean, default: !0 },
|
|
520
|
-
popperClass: { default: "" },
|
|
521
|
-
debounce: { default: 300 },
|
|
522
|
-
minLength: { default: 1 },
|
|
523
|
-
remoteOnFocus: { type: Boolean, default: !1 },
|
|
524
|
-
remoteShowSuffix: { type: Boolean, default: !0 },
|
|
525
|
-
loading: { type: Boolean, default: !1 },
|
|
526
|
-
reserveSelectedOption: { type: Boolean, default: !0 },
|
|
527
|
-
allowCreate: { type: Boolean, default: !1 },
|
|
528
|
-
commitOnBlur: { type: Boolean, default: !1 }
|
|
529
|
-
},
|
|
530
|
-
emits: ["update:modelValue", "change", "clear", "visible-change", "focus", "blur", "options-change", "loading-change", "error"],
|
|
531
|
-
setup(e, { expose: F, emit: N }) {
|
|
532
|
-
const t = e, i = N, oe = Se(), S = Ke(), m = x(null), s = x([]), $ = x(/* @__PURE__ */ new Map()), w = x(!1), _ = x(""), V = x("");
|
|
533
|
-
let k = 0, T = null;
|
|
534
|
-
const j = P(() => t.loading || w.value), M = x(!1), G = P(() => _.value !== ""), E = P(() => {
|
|
535
|
-
if (G.value) return s.value;
|
|
536
|
-
const d = /* @__PURE__ */ new Map(), K = (se) => {
|
|
537
|
-
d.set(U(se), se);
|
|
538
|
-
};
|
|
539
|
-
return t.defaultOptions.forEach(K), t.reserveSelectedOption && $.value.forEach((se) => K(se)), s.value.forEach(K), Array.from(d.values());
|
|
540
|
-
});
|
|
541
|
-
ee(
|
|
542
|
-
() => t.defaultOptions,
|
|
543
|
-
(d) => {
|
|
544
|
-
d.forEach(B);
|
|
545
|
-
},
|
|
546
|
-
{ immediate: !0 }
|
|
547
|
-
), ee(
|
|
548
|
-
() => t.modelValue,
|
|
549
|
-
() => {
|
|
550
|
-
E.value.forEach(B);
|
|
551
|
-
},
|
|
552
|
-
{ immediate: !0 }
|
|
553
|
-
);
|
|
554
|
-
function U(d) {
|
|
555
|
-
return (d == null ? void 0 : d[t.valueKey]) ?? (d == null ? void 0 : d.value) ?? (d == null ? void 0 : d.label);
|
|
556
|
-
}
|
|
557
|
-
function H(d) {
|
|
558
|
-
return Array.isArray(t.modelValue) ? t.modelValue.includes(d) : t.modelValue === d;
|
|
559
|
-
}
|
|
560
|
-
function B(d) {
|
|
561
|
-
if (!t.reserveSelectedOption) return;
|
|
562
|
-
const K = U(d);
|
|
563
|
-
H(K) && $.value.set(K, d);
|
|
564
|
-
}
|
|
565
|
-
function z(d) {
|
|
566
|
-
return S.value ? !1 : d ? d.length >= t.minLength : t.remoteOnFocus;
|
|
567
|
-
}
|
|
568
|
-
function J(d) {
|
|
569
|
-
w.value !== d && (w.value = d, i("loading-change", d));
|
|
570
|
-
}
|
|
571
|
-
async function W(d) {
|
|
572
|
-
const K = X(d), se = ++k;
|
|
573
|
-
if (pe(K), !z(K)) {
|
|
574
|
-
s.value = [], J(!1), i("options-change", E.value);
|
|
575
|
-
return;
|
|
576
|
-
}
|
|
577
|
-
J(!0);
|
|
578
|
-
try {
|
|
579
|
-
const de = await t.fetchMethod(K);
|
|
580
|
-
if (se !== k) return;
|
|
581
|
-
s.value = Array.isArray(de) ? de : [], s.value.forEach(B), i("options-change", E.value);
|
|
582
|
-
} catch (de) {
|
|
583
|
-
if (se !== k) return;
|
|
584
|
-
s.value = [], i("error", de), i("options-change", E.value);
|
|
585
|
-
} finally {
|
|
586
|
-
se === k && J(!1);
|
|
587
|
-
}
|
|
588
|
-
}
|
|
589
|
-
function Z() {
|
|
590
|
-
M.value || (M.value = !0, W(""));
|
|
591
|
-
}
|
|
592
|
-
function le(d) {
|
|
593
|
-
const K = X(d);
|
|
594
|
-
V.value = K, k += 1, pe(K), T && (clearTimeout(T), T = null), T = setTimeout(() => {
|
|
595
|
-
W(K);
|
|
596
|
-
}, t.debounce);
|
|
597
|
-
}
|
|
598
|
-
function y() {
|
|
599
|
-
M.value = !0, W("");
|
|
600
|
-
}
|
|
601
|
-
function C() {
|
|
602
|
-
W(_.value);
|
|
603
|
-
}
|
|
604
|
-
function o(d) {
|
|
605
|
-
V.value = "", i("update:modelValue", d);
|
|
606
|
-
}
|
|
607
|
-
function c(d) {
|
|
608
|
-
V.value = "", E.value.forEach(B), i("change", d);
|
|
609
|
-
}
|
|
610
|
-
function a() {
|
|
611
|
-
u(), i("clear");
|
|
612
|
-
}
|
|
613
|
-
function u() {
|
|
614
|
-
k += 1, T && clearTimeout(T), T = null, V.value = "", _.value = "", s.value = [], J(!1), i("options-change", E.value);
|
|
615
|
-
}
|
|
616
|
-
function p(d) {
|
|
617
|
-
d && t.remoteOnFocus && !_.value && Z(), i("visible-change", d);
|
|
618
|
-
}
|
|
619
|
-
function D(d) {
|
|
620
|
-
t.remoteOnFocus && !_.value && Z(), i("focus", d);
|
|
621
|
-
}
|
|
622
|
-
function re(d) {
|
|
623
|
-
ie(), i("blur", d);
|
|
624
|
-
}
|
|
625
|
-
function ie() {
|
|
626
|
-
if (!t.allowCreate || !t.commitOnBlur || S.value) return;
|
|
627
|
-
const d = V.value;
|
|
628
|
-
d.trim() && (V.value = "", i("update:modelValue", d), i("change", d));
|
|
629
|
-
}
|
|
630
|
-
function X(d) {
|
|
631
|
-
return String(d ?? "");
|
|
632
|
-
}
|
|
633
|
-
function pe(d) {
|
|
634
|
-
_.value = d, s.value = [], i("options-change", E.value);
|
|
635
|
-
}
|
|
636
|
-
function be() {
|
|
637
|
-
var d, K;
|
|
638
|
-
(K = (d = m.value) == null ? void 0 : d.focus) == null || K.call(d);
|
|
639
|
-
}
|
|
640
|
-
function Ce() {
|
|
641
|
-
var d, K;
|
|
642
|
-
(K = (d = m.value) == null ? void 0 : d.blur) == null || K.call(d);
|
|
643
|
-
}
|
|
644
|
-
function Ve() {
|
|
645
|
-
u(), i("update:modelValue", t.multiple ? [] : ""), i("clear");
|
|
646
|
-
}
|
|
647
|
-
return Be(() => {
|
|
648
|
-
k += 1, T && clearTimeout(T);
|
|
649
|
-
}), F({
|
|
650
|
-
// 暴露远程选择常用控制方法,供弹窗打开后聚焦或请求失败后重试。
|
|
651
|
-
focus: be,
|
|
652
|
-
blur: Ce,
|
|
653
|
-
clear: Ve,
|
|
654
|
-
retryFetch: C,
|
|
655
|
-
fetchDefaultOptions: y
|
|
656
|
-
}), (d, K) => (Q(), Y(Me, me({
|
|
657
|
-
ref_key: "selectRef",
|
|
658
|
-
ref: m
|
|
659
|
-
}, v(oe), {
|
|
660
|
-
"model-value": e.modelValue,
|
|
661
|
-
options: E.value,
|
|
662
|
-
"label-key": e.labelKey,
|
|
663
|
-
"value-key": e.valueKey,
|
|
664
|
-
"disabled-key": e.disabledKey,
|
|
665
|
-
placeholder: e.placeholder,
|
|
666
|
-
disabled: v(S),
|
|
667
|
-
clearable: e.clearable,
|
|
668
|
-
filterable: !0,
|
|
669
|
-
multiple: e.multiple,
|
|
670
|
-
"multiple-limit": e.multipleLimit,
|
|
671
|
-
"validate-event": e.validateEvent,
|
|
672
|
-
"collapse-tags": e.collapseTags,
|
|
673
|
-
"collapse-tags-tooltip": e.collapseTagsTooltip,
|
|
674
|
-
"auto-select-single": e.autoSelectSingle,
|
|
675
|
-
size: e.size,
|
|
676
|
-
teleported: e.teleported,
|
|
677
|
-
"append-to": e.appendTo,
|
|
678
|
-
"fit-input-width": e.fitInputWidth,
|
|
679
|
-
"popper-class": e.popperClass,
|
|
680
|
-
remote: "",
|
|
681
|
-
debounce: 0,
|
|
682
|
-
"remote-show-suffix": e.remoteShowSuffix,
|
|
683
|
-
"remote-method": le,
|
|
684
|
-
loading: j.value,
|
|
685
|
-
"onUpdate:modelValue": o,
|
|
686
|
-
onChange: c,
|
|
687
|
-
onClear: a,
|
|
688
|
-
onVisibleChange: p,
|
|
689
|
-
onFocus: D,
|
|
690
|
-
onBlur: re
|
|
691
|
-
}), xe({
|
|
692
|
-
default: b(() => [
|
|
693
|
-
d.$slots.default ? q(d.$slots, "default", {}, void 0, void 0, 0) : I("", !0)
|
|
694
|
-
]),
|
|
695
|
-
_: 2
|
|
696
|
-
}, [
|
|
697
|
-
d.$slots.prefix ? {
|
|
698
|
-
name: "prefix",
|
|
699
|
-
fn: b(() => [
|
|
700
|
-
q(d.$slots, "prefix")
|
|
701
|
-
]),
|
|
702
|
-
key: "0"
|
|
703
|
-
} : void 0,
|
|
704
|
-
d.$slots.empty ? {
|
|
705
|
-
name: "empty",
|
|
706
|
-
fn: b(() => [
|
|
707
|
-
q(d.$slots, "empty")
|
|
708
|
-
]),
|
|
709
|
-
key: "1"
|
|
710
|
-
} : void 0,
|
|
711
|
-
d.$slots.loading ? {
|
|
712
|
-
name: "loading",
|
|
713
|
-
fn: b(() => [
|
|
714
|
-
q(d.$slots, "loading")
|
|
715
|
-
]),
|
|
716
|
-
key: "2"
|
|
717
|
-
} : void 0,
|
|
718
|
-
d.$slots.tag ? {
|
|
719
|
-
name: "tag",
|
|
720
|
-
fn: b((se) => [
|
|
721
|
-
q(d.$slots, "tag", He(Je(se)))
|
|
722
|
-
]),
|
|
723
|
-
key: "3"
|
|
724
|
-
} : void 0
|
|
725
|
-
]), 1040, ["model-value", "options", "label-key", "value-key", "disabled-key", "placeholder", "disabled", "clearable", "multiple", "multiple-limit", "validate-event", "collapse-tags", "collapse-tags-tooltip", "auto-select-single", "size", "teleported", "append-to", "fit-input-width", "popper-class", "remote-show-suffix", "loading"]));
|
|
726
|
-
}
|
|
727
|
-
}), sn = { class: "qy-search-input__item" }, un = ["innerHTML"], cn = {
|
|
728
|
-
key: 0,
|
|
729
|
-
class: "qy-search-input__item-description"
|
|
730
|
-
}, dn = /* @__PURE__ */ ve({
|
|
731
|
-
name: "QySearchInput",
|
|
732
|
-
inheritAttrs: !1,
|
|
733
|
-
__name: "index",
|
|
734
|
-
props: {
|
|
735
|
-
modelValue: { default: "" },
|
|
736
|
-
loading: { type: Boolean, default: !1 },
|
|
737
|
-
disabled: { type: Boolean, default: void 0 },
|
|
738
|
-
placeholder: { default: "请输入搜索内容" },
|
|
739
|
-
removeSpace: { type: Boolean, default: !1 },
|
|
740
|
-
trimMode: { default: "none" },
|
|
741
|
-
clearable: { type: Boolean, default: !0 },
|
|
742
|
-
showButton: { type: Boolean, default: !0 },
|
|
743
|
-
buttonText: { default: "搜索" },
|
|
744
|
-
buttonProps: { default: () => ({}) },
|
|
745
|
-
suggestions: { default: () => [] },
|
|
746
|
-
fetchSuggestions: { type: [Function, null], default: null },
|
|
747
|
-
fetchSuggestionsMethod: { type: [Function, null], default: null },
|
|
748
|
-
debounce: { default: 300 },
|
|
749
|
-
minLength: { default: 1 },
|
|
750
|
-
triggerOnFocus: { type: Boolean, default: !1 },
|
|
751
|
-
searchOnEnter: { type: Boolean, default: !0 },
|
|
752
|
-
searchOnSelect: { type: Boolean, default: !1 },
|
|
753
|
-
highlightKeyword: { type: Boolean, default: !0 },
|
|
754
|
-
teleported: { type: Boolean, default: !0 },
|
|
755
|
-
appendTo: { default: "body" },
|
|
756
|
-
popperClass: { default: "" },
|
|
757
|
-
fitInputWidth: { type: Boolean, default: !0 }
|
|
758
|
-
},
|
|
759
|
-
emits: ["update:modelValue", "search", "clear", "input", "change", "focus", "blur", "enter", "select", "visible-change", "suggestions-change", "error"],
|
|
760
|
-
setup(e, { expose: F, emit: N }) {
|
|
761
|
-
const t = e, i = N, oe = Se(), S = Ke(), m = x(null), s = x(M(t.modelValue)), $ = P(() => M(t.modelValue)), w = P(
|
|
762
|
-
() => ["qy-search-input__popper", t.popperClass].filter(Boolean).join(" ")
|
|
763
|
-
), _ = P(() => M(t.modelValue)), V = x("");
|
|
764
|
-
let k = 0, T = !1;
|
|
765
|
-
function j() {
|
|
766
|
-
k++, m.value && (m.value.loading = !1, m.value.suggestions = []);
|
|
767
|
-
}
|
|
768
|
-
ee(
|
|
769
|
-
() => t.modelValue,
|
|
770
|
-
(l) => {
|
|
771
|
-
s.value = M(l), s.value !== V.value && j();
|
|
772
|
-
}
|
|
773
|
-
);
|
|
774
|
-
function M(l) {
|
|
775
|
-
return l == null ? "" : String(l);
|
|
776
|
-
}
|
|
777
|
-
function G(l) {
|
|
778
|
-
return t.removeSpace ? l.replace(/\s+/g, "") : l;
|
|
779
|
-
}
|
|
780
|
-
function E(l, g) {
|
|
781
|
-
return t.trimMode !== g ? l : l.trim();
|
|
782
|
-
}
|
|
783
|
-
function U(l) {
|
|
784
|
-
return G(M(l));
|
|
785
|
-
}
|
|
786
|
-
function H(l) {
|
|
787
|
-
s.value = l, i("update:modelValue", l);
|
|
788
|
-
}
|
|
789
|
-
function B(l, g = "") {
|
|
790
|
-
return {
|
|
791
|
-
...l,
|
|
792
|
-
label: l.label || l.value,
|
|
793
|
-
value: l.value || l.label,
|
|
794
|
-
description: l.description || g
|
|
795
|
-
};
|
|
796
|
-
}
|
|
797
|
-
function z(l = []) {
|
|
798
|
-
return l.flatMap((g) => {
|
|
799
|
-
if (Array.isArray(g.items)) {
|
|
800
|
-
const L = g;
|
|
801
|
-
return L.items.map((ae) => B(ae, L.groupLabel));
|
|
802
|
-
}
|
|
803
|
-
return B(g);
|
|
804
|
-
});
|
|
805
|
-
}
|
|
806
|
-
function J(l) {
|
|
807
|
-
const g = l.toLowerCase();
|
|
808
|
-
return (L) => [L.label, L.value, L.description].filter(Boolean).some((ae) => String(ae).toLowerCase().includes(g));
|
|
809
|
-
}
|
|
810
|
-
function W(l) {
|
|
811
|
-
return l ? l.length >= t.minLength : t.triggerOnFocus;
|
|
812
|
-
}
|
|
813
|
-
function Z(l) {
|
|
814
|
-
i("suggestions-change", l), i("visible-change", l.length > 0);
|
|
815
|
-
}
|
|
816
|
-
async function le(l) {
|
|
817
|
-
if (!W(l))
|
|
818
|
-
return [];
|
|
819
|
-
if (t.fetchSuggestionsMethod)
|
|
820
|
-
return await new Promise((Ae) => {
|
|
821
|
-
var Qe;
|
|
822
|
-
(Qe = t.fetchSuggestionsMethod) == null || Qe.call(t, l, (ne) => {
|
|
823
|
-
Ae(z(ne));
|
|
824
|
-
});
|
|
825
|
-
});
|
|
826
|
-
if (t.fetchSuggestions) {
|
|
827
|
-
const ae = await t.fetchSuggestions(l);
|
|
828
|
-
return z(Array.isArray(ae) ? ae : []);
|
|
829
|
-
}
|
|
830
|
-
const g = z(t.suggestions);
|
|
831
|
-
return l ? g.filter(J(l)) : g;
|
|
832
|
-
}
|
|
833
|
-
async function y(l, g) {
|
|
834
|
-
if (T || S.value || l !== s.value) {
|
|
835
|
-
g([]);
|
|
836
|
-
return;
|
|
837
|
-
}
|
|
838
|
-
const L = ++k;
|
|
839
|
-
V.value = l;
|
|
840
|
-
try {
|
|
841
|
-
const ae = await le(l);
|
|
842
|
-
if (T || L !== k) return;
|
|
843
|
-
Z(ae), g(ae);
|
|
844
|
-
} catch (ae) {
|
|
845
|
-
if (T || L !== k) return;
|
|
846
|
-
i("error", ae), Z([]), g([]);
|
|
847
|
-
}
|
|
848
|
-
}
|
|
849
|
-
function C() {
|
|
850
|
-
var l, g;
|
|
851
|
-
S.value || !V.value || (g = (l = m.value) == null ? void 0 : l.getData) == null || g.call(l, V.value);
|
|
852
|
-
}
|
|
853
|
-
function o(l) {
|
|
854
|
-
if (S.value) return;
|
|
855
|
-
const g = U(l);
|
|
856
|
-
j(), H(g);
|
|
857
|
-
}
|
|
858
|
-
function c(l) {
|
|
859
|
-
const g = U(l);
|
|
860
|
-
s.value = g, i("input", g);
|
|
861
|
-
}
|
|
862
|
-
function a(l) {
|
|
863
|
-
const g = E(U(l), "change");
|
|
864
|
-
g !== M(t.modelValue) && H(g), i("change", g);
|
|
865
|
-
}
|
|
866
|
-
function u(l) {
|
|
867
|
-
i("focus", l);
|
|
868
|
-
}
|
|
869
|
-
function p(l) {
|
|
870
|
-
const g = E(s.value, "blur");
|
|
871
|
-
g !== M(t.modelValue) && H(g), i("blur", l), i("visible-change", !1);
|
|
872
|
-
}
|
|
873
|
-
function D() {
|
|
874
|
-
j(), V.value = "", de(), s.value = "", i("update:modelValue", ""), i("clear"), Z([]);
|
|
875
|
-
}
|
|
876
|
-
function re(l) {
|
|
877
|
-
i("enter", l), t.searchOnEnter && ie();
|
|
878
|
-
}
|
|
879
|
-
function ie() {
|
|
880
|
-
S.value || i("search", M(t.modelValue));
|
|
881
|
-
}
|
|
882
|
-
function X(l) {
|
|
883
|
-
i("select", l), t.searchOnSelect && i("search", l.value);
|
|
884
|
-
}
|
|
885
|
-
function pe(l) {
|
|
886
|
-
return l.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
887
|
-
}
|
|
888
|
-
function be(l) {
|
|
889
|
-
return l.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
890
|
-
}
|
|
891
|
-
function Ce(l) {
|
|
892
|
-
const g = pe(l || "");
|
|
893
|
-
if (!t.highlightKeyword || !$.value) return g;
|
|
894
|
-
const L = be(pe($.value));
|
|
895
|
-
return L ? g.replace(
|
|
896
|
-
new RegExp(`(${L})`, "ig"),
|
|
897
|
-
'<mark class="qy-search-input__mark">$1</mark>'
|
|
898
|
-
) : g;
|
|
899
|
-
}
|
|
900
|
-
function Ve() {
|
|
901
|
-
var l, g;
|
|
902
|
-
(g = (l = m.value) == null ? void 0 : l.focus) == null || g.call(l);
|
|
903
|
-
}
|
|
904
|
-
function d() {
|
|
905
|
-
var l, g;
|
|
906
|
-
(g = (l = m.value) == null ? void 0 : l.blur) == null || g.call(l);
|
|
907
|
-
}
|
|
908
|
-
function K() {
|
|
909
|
-
var l, g, L;
|
|
910
|
-
(L = (g = (l = m.value) == null ? void 0 : l.inputRef) == null ? void 0 : g.select) == null || L.call(g);
|
|
911
|
-
}
|
|
912
|
-
function se() {
|
|
913
|
-
D();
|
|
914
|
-
}
|
|
915
|
-
function de() {
|
|
916
|
-
var l, g;
|
|
917
|
-
(g = (l = m.value) == null ? void 0 : l.close) == null || g.call(l);
|
|
918
|
-
}
|
|
919
|
-
return ee(S, (l) => {
|
|
920
|
-
l && (j(), de());
|
|
921
|
-
}), Be(() => {
|
|
922
|
-
T = !0, j();
|
|
923
|
-
}), F({
|
|
924
|
-
// 暴露搜索框常用控制方法,供弹窗打开后聚焦或失败后重试建议项。
|
|
925
|
-
focus: Ve,
|
|
926
|
-
blur: d,
|
|
927
|
-
select: K,
|
|
928
|
-
clear: se,
|
|
929
|
-
closePanel: de,
|
|
930
|
-
retryFetch: C
|
|
931
|
-
}), (l, g) => (Q(), R("div", {
|
|
932
|
-
class: ge(["qy-search-input", { "is-disabled": v(S) }])
|
|
933
|
-
}, [
|
|
934
|
-
O(v(xa), me({
|
|
935
|
-
ref_key: "autocompleteRef",
|
|
936
|
-
ref: m
|
|
937
|
-
}, v(oe), {
|
|
938
|
-
"model-value": _.value,
|
|
939
|
-
disabled: v(S),
|
|
940
|
-
placeholder: e.placeholder,
|
|
941
|
-
clearable: e.clearable,
|
|
942
|
-
debounce: e.debounce,
|
|
943
|
-
"fetch-suggestions": y,
|
|
944
|
-
"trigger-on-focus": e.triggerOnFocus,
|
|
945
|
-
teleported: e.teleported,
|
|
946
|
-
"fit-input-width": e.fitInputWidth,
|
|
947
|
-
"popper-class": w.value,
|
|
948
|
-
"append-to": e.appendTo,
|
|
949
|
-
"value-key": "value",
|
|
950
|
-
"onUpdate:modelValue": o,
|
|
951
|
-
onInput: c,
|
|
952
|
-
onChange: a,
|
|
953
|
-
onFocus: u,
|
|
954
|
-
onBlur: p,
|
|
955
|
-
onClear: D,
|
|
956
|
-
onSelect: X,
|
|
957
|
-
onKeydown: _e(re, ["enter"])
|
|
958
|
-
}), xe({
|
|
959
|
-
default: b(({ item: L }) => [
|
|
960
|
-
q(l.$slots, "item", {
|
|
961
|
-
item: L,
|
|
962
|
-
keyword: $.value
|
|
963
|
-
}, () => [
|
|
964
|
-
te("div", sn, [
|
|
965
|
-
te("div", {
|
|
966
|
-
class: "qy-search-input__item-label",
|
|
967
|
-
innerHTML: Ce(L.label || L.value || "")
|
|
968
|
-
}, null, 8, un),
|
|
969
|
-
L.description ? (Q(), R("div", cn, ye(L.description), 1)) : I("", !0)
|
|
970
|
-
])
|
|
971
|
-
], !0)
|
|
972
|
-
]),
|
|
973
|
-
_: 2
|
|
974
|
-
}, [
|
|
975
|
-
l.$slots.prefix ? {
|
|
976
|
-
name: "prefix",
|
|
977
|
-
fn: b(() => [
|
|
978
|
-
q(l.$slots, "prefix", {}, void 0, !0)
|
|
979
|
-
]),
|
|
980
|
-
key: "0"
|
|
981
|
-
} : void 0,
|
|
982
|
-
l.$slots.suffix ? {
|
|
983
|
-
name: "suffix",
|
|
984
|
-
fn: b(() => [
|
|
985
|
-
q(l.$slots, "suffix", {}, void 0, !0)
|
|
986
|
-
]),
|
|
987
|
-
key: "1"
|
|
988
|
-
} : void 0,
|
|
989
|
-
l.$slots.prepend ? {
|
|
990
|
-
name: "prepend",
|
|
991
|
-
fn: b(() => [
|
|
992
|
-
q(l.$slots, "prepend", {}, void 0, !0)
|
|
993
|
-
]),
|
|
994
|
-
key: "2"
|
|
995
|
-
} : void 0,
|
|
996
|
-
l.$slots.append || e.showButton ? {
|
|
997
|
-
name: "append",
|
|
998
|
-
fn: b(() => [
|
|
999
|
-
l.$slots.append ? q(l.$slots, "append", {}, void 0, !0, 0) : (Q(), Y(v(fe), me({ key: 1 }, e.buttonProps, {
|
|
1000
|
-
loading: e.loading,
|
|
1001
|
-
disabled: v(S),
|
|
1002
|
-
onClick: ie
|
|
1003
|
-
}), {
|
|
1004
|
-
default: b(() => [
|
|
1005
|
-
ce(ye(e.buttonText), 1)
|
|
1006
|
-
]),
|
|
1007
|
-
_: 1
|
|
1008
|
-
}, 16, ["loading", "disabled"]))
|
|
1009
|
-
]),
|
|
1010
|
-
key: "3"
|
|
1011
|
-
} : void 0
|
|
1012
|
-
]), 1040, ["model-value", "disabled", "placeholder", "clearable", "debounce", "trigger-on-focus", "teleported", "fit-input-width", "popper-class", "append-to"])
|
|
1013
|
-
], 2));
|
|
1014
|
-
}
|
|
1015
|
-
}), nt = /* @__PURE__ */ we(dn, [["__scopeId", "data-v-f89b281a"]]), fn = { class: "qy-record-quote-search" }, yn = {
|
|
1016
|
-
key: 0,
|
|
1017
|
-
class: "qy-record-quote-search__header"
|
|
1018
|
-
}, mn = {
|
|
1019
|
-
key: 0,
|
|
1020
|
-
class: "qy-record-quote-search__label"
|
|
1021
|
-
}, pn = {
|
|
1022
|
-
key: 1,
|
|
1023
|
-
class: "qy-record-quote-search__description"
|
|
1024
|
-
}, gn = /* @__PURE__ */ ve({
|
|
1025
|
-
name: "QyRecordQuoteSearch",
|
|
1026
|
-
inheritAttrs: !1,
|
|
1027
|
-
__name: "index",
|
|
1028
|
-
props: {
|
|
1029
|
-
modelValue: { default: "" },
|
|
1030
|
-
loading: { type: Boolean, default: !1 },
|
|
1031
|
-
disabled: { type: Boolean, default: void 0 },
|
|
1032
|
-
placeholder: { default: "请输入报价单号" },
|
|
1033
|
-
buttonText: { default: "查询报价单" },
|
|
1034
|
-
autoNormalize: { type: Boolean, default: !0 },
|
|
1035
|
-
showStatus: { type: Boolean, default: !0 },
|
|
1036
|
-
status: { default: "default" },
|
|
1037
|
-
statusText: { default: "" },
|
|
1038
|
-
suggestions: { default: () => [] },
|
|
1039
|
-
fetchSuggestions: { type: [Function, null], default: null },
|
|
1040
|
-
fetchSuggestionsMethod: { type: [Function, null], default: null },
|
|
1041
|
-
debounce: { default: 300 },
|
|
1042
|
-
minLength: { default: 1 },
|
|
1043
|
-
searchOnSelect: { type: Boolean, default: !0 },
|
|
1044
|
-
searchMethod: { type: [Function, null], default: null },
|
|
1045
|
-
extractMethod: { type: [Function, null], default: null },
|
|
1046
|
-
normalizeMethod: { type: [Function, null], default: null },
|
|
1047
|
-
label: { default: "报价单号" },
|
|
1048
|
-
description: { default: "" },
|
|
1049
|
-
trimMode: { default: "blur" }
|
|
1050
|
-
},
|
|
1051
|
-
emits: ["update:modelValue", "search", "clear", "normalize", "enter", "select", "error", "success"],
|
|
1052
|
-
setup(e, { expose: F, emit: N }) {
|
|
1053
|
-
const t = e, i = N, oe = Se(), S = x(null), m = x(!1);
|
|
1054
|
-
let s = 0;
|
|
1055
|
-
function $() {
|
|
1056
|
-
s++, m.value = !1;
|
|
1057
|
-
}
|
|
1058
|
-
Be($);
|
|
1059
|
-
const w = P(() => t.statusText || ""), _ = P(() => t.loading || m.value);
|
|
1060
|
-
function V(o) {
|
|
1061
|
-
return o == null ? "" : String(o);
|
|
1062
|
-
}
|
|
1063
|
-
function k(o) {
|
|
1064
|
-
const c = V(o).trim(), a = T(c), u = a.match(/BJ\d{8}[A-Z0-9]{4}/i);
|
|
1065
|
-
return u ? u[0] : a;
|
|
1066
|
-
}
|
|
1067
|
-
function T(o) {
|
|
1068
|
-
return V(o).replace(/\s+/g, "").trim().toUpperCase();
|
|
1069
|
-
}
|
|
1070
|
-
function j(o) {
|
|
1071
|
-
return t.extractMethod ? t.extractMethod(o) : k(o);
|
|
1072
|
-
}
|
|
1073
|
-
function M(o) {
|
|
1074
|
-
return t.normalizeMethod ? t.normalizeMethod(o) : T(o);
|
|
1075
|
-
}
|
|
1076
|
-
function G(o, c) {
|
|
1077
|
-
const a = V(o), u = j(a), p = t.autoNormalize ? M(u) : u;
|
|
1078
|
-
return i("normalize", { rawValue: a, code: p }), {
|
|
1079
|
-
rawValue: a,
|
|
1080
|
-
code: p,
|
|
1081
|
-
item: c
|
|
1082
|
-
};
|
|
1083
|
-
}
|
|
1084
|
-
function E(o) {
|
|
1085
|
-
i("update:modelValue", o);
|
|
1086
|
-
}
|
|
1087
|
-
async function U(o) {
|
|
1088
|
-
const c = ++s;
|
|
1089
|
-
if (i("search", o), !(!t.searchMethod || c !== s)) {
|
|
1090
|
-
m.value = !0;
|
|
1091
|
-
try {
|
|
1092
|
-
const a = await t.searchMethod(o);
|
|
1093
|
-
c === s && i("success", a);
|
|
1094
|
-
} catch (a) {
|
|
1095
|
-
c === s && i("error", a);
|
|
1096
|
-
} finally {
|
|
1097
|
-
c === s && (m.value = !1);
|
|
1098
|
-
}
|
|
1099
|
-
}
|
|
1100
|
-
}
|
|
1101
|
-
function H(o) {
|
|
1102
|
-
const c = G(o);
|
|
1103
|
-
c.code !== V(t.modelValue) && i("update:modelValue", c.code), U(c);
|
|
1104
|
-
}
|
|
1105
|
-
function B() {
|
|
1106
|
-
$(), i("clear");
|
|
1107
|
-
}
|
|
1108
|
-
function z(o) {
|
|
1109
|
-
i("enter", o);
|
|
1110
|
-
}
|
|
1111
|
-
function J(o) {
|
|
1112
|
-
if (i("select", o), !t.searchOnSelect) return;
|
|
1113
|
-
const c = G(o.value, o);
|
|
1114
|
-
c.code !== V(t.modelValue) && i("update:modelValue", c.code), U(c);
|
|
1115
|
-
}
|
|
1116
|
-
function W(o) {
|
|
1117
|
-
i("error", o);
|
|
1118
|
-
}
|
|
1119
|
-
function Z() {
|
|
1120
|
-
var o, c;
|
|
1121
|
-
(c = (o = S.value) == null ? void 0 : o.focus) == null || c.call(o);
|
|
1122
|
-
}
|
|
1123
|
-
function le() {
|
|
1124
|
-
var o, c;
|
|
1125
|
-
(c = (o = S.value) == null ? void 0 : o.blur) == null || c.call(o);
|
|
1126
|
-
}
|
|
1127
|
-
function y() {
|
|
1128
|
-
var o, c;
|
|
1129
|
-
(c = (o = S.value) == null ? void 0 : o.select) == null || c.call(o);
|
|
1130
|
-
}
|
|
1131
|
-
function C() {
|
|
1132
|
-
var o, c;
|
|
1133
|
-
(c = (o = S.value) == null ? void 0 : o.clear) == null || c.call(o);
|
|
1134
|
-
}
|
|
1135
|
-
return F({
|
|
1136
|
-
focus: Z,
|
|
1137
|
-
blur: le,
|
|
1138
|
-
select: y,
|
|
1139
|
-
clear: C,
|
|
1140
|
-
extractQuoteOrderCode: j,
|
|
1141
|
-
normalizeQuoteOrderCode: M
|
|
1142
|
-
}), (o, c) => (Q(), R("div", fn, [
|
|
1143
|
-
q(o.$slots, "label", {}, () => [
|
|
1144
|
-
e.label || e.description ? (Q(), R("div", yn, [
|
|
1145
|
-
e.label ? (Q(), R("div", mn, ye(e.label), 1)) : I("", !0),
|
|
1146
|
-
e.description ? (Q(), R("div", pn, ye(e.description), 1)) : I("", !0)
|
|
1147
|
-
])) : I("", !0)
|
|
1148
|
-
], !0),
|
|
1149
|
-
O(nt, me({
|
|
1150
|
-
ref_key: "searchRef",
|
|
1151
|
-
ref: S
|
|
1152
|
-
}, v(oe), {
|
|
1153
|
-
"model-value": e.modelValue,
|
|
1154
|
-
loading: _.value,
|
|
1155
|
-
disabled: e.disabled,
|
|
1156
|
-
placeholder: e.placeholder,
|
|
1157
|
-
"remove-space": !0,
|
|
1158
|
-
"trim-mode": e.trimMode,
|
|
1159
|
-
"button-text": e.buttonText,
|
|
1160
|
-
suggestions: e.suggestions,
|
|
1161
|
-
"fetch-suggestions": e.fetchSuggestions,
|
|
1162
|
-
"fetch-suggestions-method": e.fetchSuggestionsMethod,
|
|
1163
|
-
debounce: e.debounce,
|
|
1164
|
-
"min-length": e.minLength,
|
|
1165
|
-
"search-on-select": !1,
|
|
1166
|
-
"onUpdate:modelValue": E,
|
|
1167
|
-
onSearch: H,
|
|
1168
|
-
onClear: B,
|
|
1169
|
-
onEnter: z,
|
|
1170
|
-
onSelect: J,
|
|
1171
|
-
onError: W
|
|
1172
|
-
}), xe({ _: 2 }, [
|
|
1173
|
-
o.$slots.prefix ? {
|
|
1174
|
-
name: "prefix",
|
|
1175
|
-
fn: b(() => [
|
|
1176
|
-
q(o.$slots, "prefix", {}, void 0, !0)
|
|
1177
|
-
]),
|
|
1178
|
-
key: "0"
|
|
1179
|
-
} : void 0,
|
|
1180
|
-
o.$slots.suffix ? {
|
|
1181
|
-
name: "suffix",
|
|
1182
|
-
fn: b(() => [
|
|
1183
|
-
q(o.$slots, "suffix", {}, void 0, !0)
|
|
1184
|
-
]),
|
|
1185
|
-
key: "1"
|
|
1186
|
-
} : void 0,
|
|
1187
|
-
o.$slots.item ? {
|
|
1188
|
-
name: "item",
|
|
1189
|
-
fn: b((a) => [
|
|
1190
|
-
q(o.$slots, "item", He(Je(a)), void 0, !0)
|
|
1191
|
-
]),
|
|
1192
|
-
key: "2"
|
|
1193
|
-
} : void 0,
|
|
1194
|
-
o.$slots.empty ? {
|
|
1195
|
-
name: "empty",
|
|
1196
|
-
fn: b(() => [
|
|
1197
|
-
q(o.$slots, "empty", {}, void 0, !0)
|
|
1198
|
-
]),
|
|
1199
|
-
key: "3"
|
|
1200
|
-
} : void 0,
|
|
1201
|
-
o.$slots.loading ? {
|
|
1202
|
-
name: "loading",
|
|
1203
|
-
fn: b(() => [
|
|
1204
|
-
q(o.$slots, "loading", {}, void 0, !0)
|
|
1205
|
-
]),
|
|
1206
|
-
key: "4"
|
|
1207
|
-
} : void 0
|
|
1208
|
-
]), 1040, ["model-value", "loading", "disabled", "placeholder", "trim-mode", "button-text", "suggestions", "fetch-suggestions", "fetch-suggestions-method", "debounce", "min-length"]),
|
|
1209
|
-
e.showStatus && w.value ? q(o.$slots, "status", {
|
|
1210
|
-
status: e.status,
|
|
1211
|
-
statusText: w.value
|
|
1212
|
-
}, () => [
|
|
1213
|
-
te("div", {
|
|
1214
|
-
class: ge(["qy-record-quote-search__status", `is-${e.status}`])
|
|
1215
|
-
}, ye(w.value), 3)
|
|
1216
|
-
], !0, 0) : I("", !0)
|
|
1217
|
-
]));
|
|
1218
|
-
}
|
|
1219
|
-
}), hn = /* @__PURE__ */ we(gn, [["__scopeId", "data-v-9a711e68"]]), vn = { class: "qy-selection-dialog" }, bn = { class: "qy-selection-dialog__main" }, Qn = {
|
|
1220
|
-
key: 0,
|
|
1221
|
-
class: "qy-selection-dialog__selected"
|
|
1222
|
-
}, Sn = { class: "qy-selection-dialog__selected-tags" }, wn = {
|
|
1223
|
-
key: 0,
|
|
1224
|
-
class: "qy-selection-dialog__selected-actions"
|
|
1225
|
-
}, kn = {
|
|
1226
|
-
key: 1,
|
|
1227
|
-
class: "qy-selection-dialog__search-row"
|
|
1228
|
-
}, $n = {
|
|
1229
|
-
key: 0,
|
|
1230
|
-
class: "qy-selection-dialog__toolbar"
|
|
1231
|
-
}, Cn = {
|
|
1232
|
-
key: 2,
|
|
1233
|
-
class: "qy-selection-dialog__pagination"
|
|
1234
|
-
}, Vn = { class: "qy-selection-dialog__paste-actions" }, Bn = /* @__PURE__ */ ve({
|
|
1235
|
-
name: "QySelectionDialog",
|
|
1236
|
-
inheritAttrs: !1,
|
|
1237
|
-
__name: "index",
|
|
1238
|
-
props: {
|
|
1239
|
-
modelValue: { default: () => [] },
|
|
1240
|
-
open: { type: Boolean, default: !0 },
|
|
1241
|
-
title: { default: "选择数据" },
|
|
1242
|
-
width: { default: "1200px" },
|
|
1243
|
-
fetchMethod: { type: Function, default: void 0 },
|
|
1244
|
-
query: { type: Function, default: void 0 },
|
|
1245
|
-
responseFormatter: { type: Function, default: void 0 },
|
|
1246
|
-
selectionMode: { default: void 0 },
|
|
1247
|
-
selection: { default: "single" },
|
|
1248
|
-
selected: { default: () => [] },
|
|
1249
|
-
rowKey: { default: "id" },
|
|
1250
|
-
mainKey: { default: void 0 },
|
|
1251
|
-
labelKey: { default: "name" },
|
|
1252
|
-
tagName: { default: void 0 },
|
|
1253
|
-
searchKey: { default: "conditions" },
|
|
1254
|
-
queryParams: { default: () => ({}) },
|
|
1255
|
-
category: { type: [Array, Function, Boolean], default: !1 },
|
|
1256
|
-
categoryFormatter: { type: [Function, Array], default: void 0 },
|
|
1257
|
-
categoryOptions: { default: () => [] },
|
|
1258
|
-
categoryFetchMethod: { type: [Function, null], default: null },
|
|
1259
|
-
type: { type: [Array, Boolean], default: !1 },
|
|
1260
|
-
typeOptions: { default: () => [] },
|
|
1261
|
-
typeSelectionProps: { default: () => ({}) },
|
|
1262
|
-
typeSelectProps: { default: () => ({}) },
|
|
1263
|
-
tableProps: { default: () => ({}) },
|
|
1264
|
-
showSelected: { type: Boolean, default: !0 },
|
|
1265
|
-
showSearch: { type: Boolean, default: !0 },
|
|
1266
|
-
showPagination: { type: Boolean, default: !0 },
|
|
1267
|
-
showCopyPaste: { type: Boolean, default: !1 },
|
|
1268
|
-
append: { type: Boolean, default: !1 },
|
|
1269
|
-
showAppend: { type: Boolean, default: !1 },
|
|
1270
|
-
pageSizes: { default: () => [10, 20, 50, 100] }
|
|
1271
|
-
},
|
|
1272
|
-
emits: ["update:modelValue", "update:open", "error", "selection-change", "confirm", "submit", "cancel", "close", "append", "loaded"],
|
|
1273
|
-
setup(e, { expose: F, emit: N }) {
|
|
1274
|
-
const t = e, i = N, oe = Se(), S = Ia(), m = Ra(), s = x(null), $ = x([]), w = x([]), _ = x([]), V = x(!1);
|
|
1275
|
-
let k = 0, T = 0, j = !1;
|
|
1276
|
-
function M() {
|
|
1277
|
-
k += 1, T += 1, V.value = !1;
|
|
1278
|
-
}
|
|
1279
|
-
ee(() => t.open, M, { flush: "sync" }), Be(() => {
|
|
1280
|
-
j = !0, M();
|
|
1281
|
-
});
|
|
1282
|
-
function G(n) {
|
|
1283
|
-
return !j && t.open && n === k;
|
|
1284
|
-
}
|
|
1285
|
-
const E = x(0), U = x(!1), H = x(""), B = Re({
|
|
1286
|
-
category: [],
|
|
1287
|
-
type: "",
|
|
1288
|
-
page: 1,
|
|
1289
|
-
pageSize: 10,
|
|
1290
|
-
...t.searchKey ? { [t.searchKey]: "" } : {},
|
|
1291
|
-
...t.queryParams
|
|
1292
|
-
}), z = P(() => t.selectionMode ? t.selectionMode : t.selection === "multi" ? "multiple" : t.selection), J = P(() => t.mainKey || t.rowKey), W = P(() => t.tagName || t.labelKey), Z = P(() => t.typeOptions.length ? t.typeOptions : t.type || []), le = P(() => ({
|
|
1293
|
-
...t.typeSelectionProps,
|
|
1294
|
-
...t.typeSelectProps
|
|
1295
|
-
})), y = P(() => t.tableProps || {}), C = P(
|
|
1296
|
-
() => t.showSearch || !!oe["search-visible"]
|
|
1297
|
-
), o = P(() => t.showAppend || t.append), c = P(
|
|
1298
|
-
() => o.value || !!S.toolbar || !!S.bar
|
|
1299
|
-
), a = P(() => t.fetchMethod || t.query), u = P(() => p() ? t.modelValue : t.selected);
|
|
1300
|
-
function p() {
|
|
1301
|
-
const n = (m == null ? void 0 : m.vnode.props) || {};
|
|
1302
|
-
return Object.prototype.hasOwnProperty.call(n, "modelValue") || Object.prototype.hasOwnProperty.call(n, "model-value") || Object.prototype.hasOwnProperty.call(n, "onUpdate:modelValue");
|
|
1303
|
-
}
|
|
1304
|
-
ee(
|
|
1305
|
-
[() => t.modelValue, () => t.selected, () => t.open],
|
|
1306
|
-
() => {
|
|
1307
|
-
t.open && (w.value = ke(u.value), ae());
|
|
1308
|
-
},
|
|
1309
|
-
{ immediate: !0, deep: !0 }
|
|
1310
|
-
), ee(
|
|
1311
|
-
[() => t.categoryOptions, () => t.category],
|
|
1312
|
-
(n) => {
|
|
1313
|
-
if (Array.isArray(t.category) && t.category.length) {
|
|
1314
|
-
_.value = t.category;
|
|
1315
|
-
return;
|
|
1316
|
-
}
|
|
1317
|
-
_.value = t.categoryOptions || [];
|
|
1318
|
-
},
|
|
1319
|
-
{ immediate: !0 }
|
|
1320
|
-
), ee(U, (n) => {
|
|
1321
|
-
n || (H.value = "");
|
|
1322
|
-
});
|
|
1323
|
-
async function D() {
|
|
1324
|
-
const n = ++k;
|
|
1325
|
-
w.value = ke(u.value);
|
|
1326
|
-
try {
|
|
1327
|
-
await re(n);
|
|
1328
|
-
} catch (r) {
|
|
1329
|
-
G(n) && i("error", r);
|
|
1330
|
-
return;
|
|
1331
|
-
}
|
|
1332
|
-
G(n) && (await ie(), G(n) && ae());
|
|
1333
|
-
}
|
|
1334
|
-
async function re(n) {
|
|
1335
|
-
const r = t.categoryFetchMethod || (typeof t.category == "function" ? t.category : null);
|
|
1336
|
-
if (!r) return;
|
|
1337
|
-
const A = await r();
|
|
1338
|
-
G(n) && (_.value = d(A));
|
|
1339
|
-
}
|
|
1340
|
-
async function ie() {
|
|
1341
|
-
if (!a.value || !t.open || j) return;
|
|
1342
|
-
const n = k, r = ++T, A = () => G(n) && r === T;
|
|
1343
|
-
V.value = !0;
|
|
1344
|
-
try {
|
|
1345
|
-
const h = await a.value(se());
|
|
1346
|
-
if (!A()) return;
|
|
1347
|
-
const ue = t.responseFormatter ? await t.responseFormatter(h) : h;
|
|
1348
|
-
if (!A()) return;
|
|
1349
|
-
const { rows: Ue, total: Ba } = Ve(ue);
|
|
1350
|
-
return $.value = Ue, E.value = Ba, i("loaded", Ue), ae(), ue;
|
|
1351
|
-
} catch (h) {
|
|
1352
|
-
A() && i("error", h);
|
|
1353
|
-
} finally {
|
|
1354
|
-
A() && (V.value = !1);
|
|
1355
|
-
}
|
|
1356
|
-
}
|
|
1357
|
-
function X() {
|
|
1358
|
-
return B.page = 1, ie();
|
|
1359
|
-
}
|
|
1360
|
-
function pe() {
|
|
1361
|
-
return B.page = 1, ie();
|
|
1362
|
-
}
|
|
1363
|
-
function be() {
|
|
1364
|
-
return Object.assign(B, {
|
|
1365
|
-
category: [],
|
|
1366
|
-
type: "",
|
|
1367
|
-
page: 1,
|
|
1368
|
-
pageSize: B.pageSize,
|
|
1369
|
-
...t.searchKey ? { [t.searchKey]: "" } : {},
|
|
1370
|
-
...t.queryParams
|
|
1371
|
-
}), ie();
|
|
1372
|
-
}
|
|
1373
|
-
function Ce() {
|
|
1374
|
-
i("append");
|
|
1375
|
-
}
|
|
1376
|
-
function Ve(n) {
|
|
1377
|
-
if (Array.isArray(n))
|
|
1378
|
-
return { rows: n, total: n.length };
|
|
1379
|
-
const r = n == null ? void 0 : n.data;
|
|
1380
|
-
if (Array.isArray(r))
|
|
1381
|
-
return { rows: r, total: (n == null ? void 0 : n.total) ?? r.length };
|
|
1382
|
-
const A = (n == null ? void 0 : n.records) || (n == null ? void 0 : n.rows) || (r == null ? void 0 : r.records) || [], h = (n == null ? void 0 : n.total) ?? (r == null ? void 0 : r.total) ?? A.length;
|
|
1383
|
-
return { rows: A, total: h };
|
|
1384
|
-
}
|
|
1385
|
-
function d(n) {
|
|
1386
|
-
const r = (n == null ? void 0 : n.data) ?? n;
|
|
1387
|
-
if (!Array.isArray(r)) return [];
|
|
1388
|
-
if (typeof t.categoryFormatter == "function")
|
|
1389
|
-
return t.categoryFormatter(r);
|
|
1390
|
-
if (Array.isArray(t.categoryFormatter)) {
|
|
1391
|
-
const [A, h] = t.categoryFormatter;
|
|
1392
|
-
return r.map((ue) => ({
|
|
1393
|
-
...ue,
|
|
1394
|
-
label: ue[A],
|
|
1395
|
-
value: ue[h],
|
|
1396
|
-
children: Array.isArray(ue.children) ? K(ue.children, A, h) : ue.children
|
|
1397
|
-
}));
|
|
1398
|
-
}
|
|
1399
|
-
return r;
|
|
1400
|
-
}
|
|
1401
|
-
function K(n, r, A) {
|
|
1402
|
-
return n.map((h) => ({
|
|
1403
|
-
...h,
|
|
1404
|
-
label: h[r],
|
|
1405
|
-
value: h[A],
|
|
1406
|
-
children: Array.isArray(h.children) ? K(h.children, r, A) : h.children
|
|
1407
|
-
}));
|
|
1408
|
-
}
|
|
1409
|
-
function se() {
|
|
1410
|
-
const n = { ...t.queryParams, ...B };
|
|
1411
|
-
return t.searchKey && (n[t.searchKey] = String(n[t.searchKey] || "").trim()), n.category = de(), n;
|
|
1412
|
-
}
|
|
1413
|
-
function de() {
|
|
1414
|
-
if (Object.prototype.hasOwnProperty.call(t.queryParams, "category"))
|
|
1415
|
-
return t.queryParams.category;
|
|
1416
|
-
const n = B.category;
|
|
1417
|
-
return Array.isArray(n) ? n : n ? [n] : [];
|
|
1418
|
-
}
|
|
1419
|
-
function l(n) {
|
|
1420
|
-
var r, A;
|
|
1421
|
-
if (z.value !== "none") {
|
|
1422
|
-
if (z.value === "single") {
|
|
1423
|
-
w.value = [n], (r = s.value) == null || r.setCurrentRow(n), qe();
|
|
1424
|
-
return;
|
|
1425
|
-
}
|
|
1426
|
-
Ae(n) && ((A = s.value) == null || A.toggleRowSelection(n, !Qe(n)));
|
|
1427
|
-
}
|
|
1428
|
-
}
|
|
1429
|
-
function g(n) {
|
|
1430
|
-
if (z.value !== "multiple") return;
|
|
1431
|
-
const r = new Set($.value.map(ne)), A = new Set(n.map(ne));
|
|
1432
|
-
w.value = w.value.filter(
|
|
1433
|
-
(h) => !r.has(ne(h)) || A.has(ne(h))
|
|
1434
|
-
), n.forEach((h) => {
|
|
1435
|
-
Qe(h) || w.value.push(h);
|
|
1436
|
-
}), qe();
|
|
1437
|
-
}
|
|
1438
|
-
function L(n) {
|
|
1439
|
-
var A, h;
|
|
1440
|
-
w.value = w.value.filter(
|
|
1441
|
-
(ue) => ne(ue) !== ne(n)
|
|
1442
|
-
);
|
|
1443
|
-
const r = $.value.find((ue) => ne(ue) === ne(n));
|
|
1444
|
-
r && (z.value === "multiple" ? (A = s.value) == null || A.toggleRowSelection(r, !1) : (h = s.value) == null || h.setCurrentRow()), qe();
|
|
1445
|
-
}
|
|
1446
|
-
function ae() {
|
|
1447
|
-
De(() => {
|
|
1448
|
-
var n;
|
|
1449
|
-
if (s.value) {
|
|
1450
|
-
if (z.value === "single") {
|
|
1451
|
-
const [r] = w.value, A = $.value.find(
|
|
1452
|
-
(h) => r && ne(h) === ne(r)
|
|
1453
|
-
);
|
|
1454
|
-
(n = s.value) == null || n.setCurrentRow(A);
|
|
1455
|
-
return;
|
|
1456
|
-
}
|
|
1457
|
-
z.value === "multiple" && $.value.forEach((r) => {
|
|
1458
|
-
var A;
|
|
1459
|
-
(A = s.value) == null || A.toggleRowSelection(r, Qe(r));
|
|
1460
|
-
});
|
|
1461
|
-
}
|
|
1462
|
-
});
|
|
1463
|
-
}
|
|
1464
|
-
function Ae(n) {
|
|
1465
|
-
var A;
|
|
1466
|
-
const r = (A = y.value) == null ? void 0 : A.selectable;
|
|
1467
|
-
return typeof r == "function" ? r(n) !== !1 : !0;
|
|
1468
|
-
}
|
|
1469
|
-
function Qe(n) {
|
|
1470
|
-
return w.value.some((r) => ne(r) === ne(n));
|
|
1471
|
-
}
|
|
1472
|
-
function ne(n) {
|
|
1473
|
-
return Ee(n, J.value);
|
|
1474
|
-
}
|
|
1475
|
-
function wa(n) {
|
|
1476
|
-
return Ee(n, W.value) ?? ne(n);
|
|
1477
|
-
}
|
|
1478
|
-
function Ee(n, r) {
|
|
1479
|
-
if (!(!n || !r))
|
|
1480
|
-
return r.split(".").reduce((A, h) => A == null ? void 0 : A[h], n);
|
|
1481
|
-
}
|
|
1482
|
-
function qe() {
|
|
1483
|
-
const n = ke(w.value);
|
|
1484
|
-
i("selection-change", n);
|
|
1485
|
-
}
|
|
1486
|
-
function ka() {
|
|
1487
|
-
const n = ke(w.value);
|
|
1488
|
-
i("update:modelValue", n), i("confirm", n), i("submit", { selection: n, rows: n, query: { ...B } });
|
|
1489
|
-
}
|
|
1490
|
-
function $a(n) {
|
|
1491
|
-
(n === "escape" || n === "overlay") && Le();
|
|
1492
|
-
}
|
|
1493
|
-
function Le() {
|
|
1494
|
-
M(), w.value = ke(u.value), i("update:open", !1), i("cancel"), i("close");
|
|
1495
|
-
}
|
|
1496
|
-
async function Ca() {
|
|
1497
|
-
var r;
|
|
1498
|
-
const n = JSON.stringify(w.value);
|
|
1499
|
-
await ((r = navigator.clipboard) == null ? void 0 : r.writeText(n)), $e.success("复制成功");
|
|
1500
|
-
}
|
|
1501
|
-
function Va() {
|
|
1502
|
-
try {
|
|
1503
|
-
const n = JSON.parse(H.value);
|
|
1504
|
-
if (!Array.isArray(n)) {
|
|
1505
|
-
$e.error("粘贴内容需要是数组");
|
|
1506
|
-
return;
|
|
1507
|
-
}
|
|
1508
|
-
n.forEach((r) => {
|
|
1509
|
-
Qe(r) || w.value.push(r);
|
|
1510
|
-
}), U.value = !1, qe(), ae();
|
|
1511
|
-
} catch (n) {
|
|
1512
|
-
$e.error(`粘贴错误: ${(n == null ? void 0 : n.message) || "内容格式错误"}`);
|
|
1513
|
-
}
|
|
1514
|
-
}
|
|
1515
|
-
function ke(n = []) {
|
|
1516
|
-
return n.map((r) => ({ ...r }));
|
|
1517
|
-
}
|
|
1518
|
-
return F({
|
|
1519
|
-
search: X,
|
|
1520
|
-
handleSearch: ie,
|
|
1521
|
-
handleQuerySearch: X,
|
|
1522
|
-
resetSearch: be,
|
|
1523
|
-
getTableRef: () => s.value,
|
|
1524
|
-
getTableData: () => $.value,
|
|
1525
|
-
getSelection: () => ke(w.value)
|
|
1526
|
-
}), (n, r) => {
|
|
1527
|
-
const A = ao;
|
|
1528
|
-
return Q(), Y(Ie, {
|
|
1529
|
-
open: e.open,
|
|
1530
|
-
title: e.title,
|
|
1531
|
-
width: e.width,
|
|
1532
|
-
onOpened: D,
|
|
1533
|
-
onConfirm: ka,
|
|
1534
|
-
onCancel: Le,
|
|
1535
|
-
onClose: $a
|
|
1536
|
-
}, {
|
|
1537
|
-
default: b(() => [
|
|
1538
|
-
te("div", vn, [
|
|
1539
|
-
q(n.$slots, "side", {}, void 0, !0),
|
|
1540
|
-
te("div", bn, [
|
|
1541
|
-
e.showSelected ? (Q(), R("div", Qn, [
|
|
1542
|
-
r[12] || (r[12] = te("span", { class: "qy-selection-dialog__selected-label" }, "已选项", -1)),
|
|
1543
|
-
te("div", Sn, [
|
|
1544
|
-
(Q(!0), R(Pe, null, Oe(w.value, (h) => (Q(), Y(Fe, {
|
|
1545
|
-
key: ne(h),
|
|
1546
|
-
closable: "",
|
|
1547
|
-
class: "qy-selection-dialog__selected-tag",
|
|
1548
|
-
onClose: (ue) => L(h)
|
|
1549
|
-
}, {
|
|
1550
|
-
default: b(() => [
|
|
1551
|
-
ce(ye(wa(h)), 1)
|
|
1552
|
-
]),
|
|
1553
|
-
_: 2
|
|
1554
|
-
}, 1032, ["onClose"]))), 128)),
|
|
1555
|
-
w.value.length ? I("", !0) : (Q(), Y(Fe, {
|
|
1556
|
-
key: 0,
|
|
1557
|
-
tone: "info"
|
|
1558
|
-
}, {
|
|
1559
|
-
default: b(() => [...r[9] || (r[9] = [
|
|
1560
|
-
ce("无", -1)
|
|
1561
|
-
])]),
|
|
1562
|
-
_: 1
|
|
1563
|
-
}))
|
|
1564
|
-
]),
|
|
1565
|
-
e.showCopyPaste ? (Q(), R("div", wn, [
|
|
1566
|
-
O(v(fe), {
|
|
1567
|
-
size: "small",
|
|
1568
|
-
onClick: Ca
|
|
1569
|
-
}, {
|
|
1570
|
-
default: b(() => [...r[10] || (r[10] = [
|
|
1571
|
-
ce("复制", -1)
|
|
1572
|
-
])]),
|
|
1573
|
-
_: 1
|
|
1574
|
-
}),
|
|
1575
|
-
O(v(fe), {
|
|
1576
|
-
size: "small",
|
|
1577
|
-
onClick: r[0] || (r[0] = (h) => U.value = !0)
|
|
1578
|
-
}, {
|
|
1579
|
-
default: b(() => [...r[11] || (r[11] = [
|
|
1580
|
-
ce("粘贴", -1)
|
|
1581
|
-
])]),
|
|
1582
|
-
_: 1
|
|
1583
|
-
})
|
|
1584
|
-
])) : I("", !0)
|
|
1585
|
-
])) : I("", !0),
|
|
1586
|
-
C.value ? (Q(), R("div", kn, [
|
|
1587
|
-
O(v(et), {
|
|
1588
|
-
class: "qy-selection-dialog__search",
|
|
1589
|
-
inline: "",
|
|
1590
|
-
model: B
|
|
1591
|
-
}, {
|
|
1592
|
-
default: b(() => [
|
|
1593
|
-
q(n.$slots, "search", {
|
|
1594
|
-
query: B,
|
|
1595
|
-
search: X,
|
|
1596
|
-
reset: be
|
|
1597
|
-
}, () => [
|
|
1598
|
-
_.value.length ? (Q(), Y(v(he), {
|
|
1599
|
-
key: 0,
|
|
1600
|
-
label: "分类"
|
|
1601
|
-
}, {
|
|
1602
|
-
default: b(() => [
|
|
1603
|
-
O(tt, {
|
|
1604
|
-
modelValue: B.category,
|
|
1605
|
-
"onUpdate:modelValue": r[1] || (r[1] = (h) => B.category = h),
|
|
1606
|
-
class: "qy-selection-dialog__category",
|
|
1607
|
-
options: _.value,
|
|
1608
|
-
clearable: "",
|
|
1609
|
-
filterable: "",
|
|
1610
|
-
"check-strictly": "",
|
|
1611
|
-
"render-after-expand": !1,
|
|
1612
|
-
onChange: X
|
|
1613
|
-
}, null, 8, ["modelValue", "options"])
|
|
1614
|
-
]),
|
|
1615
|
-
_: 1
|
|
1616
|
-
})) : I("", !0),
|
|
1617
|
-
Z.value.length ? (Q(), Y(v(he), {
|
|
1618
|
-
key: 1,
|
|
1619
|
-
label: "类型"
|
|
1620
|
-
}, {
|
|
1621
|
-
default: b(() => [
|
|
1622
|
-
O(Me, me({
|
|
1623
|
-
modelValue: B.type,
|
|
1624
|
-
"onUpdate:modelValue": r[2] || (r[2] = (h) => B.type = h),
|
|
1625
|
-
class: "qy-selection-dialog__type",
|
|
1626
|
-
options: Z.value,
|
|
1627
|
-
placeholder: "请选择类型",
|
|
1628
|
-
clearable: ""
|
|
1629
|
-
}, le.value, { onChange: X }), null, 16, ["modelValue", "options"])
|
|
1630
|
-
]),
|
|
1631
|
-
_: 1
|
|
1632
|
-
})) : I("", !0),
|
|
1633
|
-
e.searchKey ? (Q(), Y(v(he), {
|
|
1634
|
-
key: 2,
|
|
1635
|
-
label: "搜索"
|
|
1636
|
-
}, {
|
|
1637
|
-
default: b(() => [
|
|
1638
|
-
O(v(Te), {
|
|
1639
|
-
modelValue: B[e.searchKey],
|
|
1640
|
-
"onUpdate:modelValue": r[3] || (r[3] = (h) => B[e.searchKey] = h),
|
|
1641
|
-
clearable: "",
|
|
1642
|
-
placeholder: "请输入",
|
|
1643
|
-
class: "qy-selection-dialog__search-input",
|
|
1644
|
-
onKeydown: _e(ze(X, ["prevent"]), ["enter"])
|
|
1645
|
-
}, null, 8, ["modelValue", "onKeydown"])
|
|
1646
|
-
]),
|
|
1647
|
-
_: 1
|
|
1648
|
-
})) : I("", !0),
|
|
1649
|
-
O(v(he), null, {
|
|
1650
|
-
default: b(() => [
|
|
1651
|
-
O(v(fe), {
|
|
1652
|
-
type: "primary",
|
|
1653
|
-
onClick: X
|
|
1654
|
-
}, {
|
|
1655
|
-
default: b(() => [...r[13] || (r[13] = [
|
|
1656
|
-
ce("查询", -1)
|
|
1657
|
-
])]),
|
|
1658
|
-
_: 1
|
|
1659
|
-
}),
|
|
1660
|
-
O(v(fe), { onClick: be }, {
|
|
1661
|
-
default: b(() => [...r[14] || (r[14] = [
|
|
1662
|
-
ce("重置", -1)
|
|
1663
|
-
])]),
|
|
1664
|
-
_: 1
|
|
1665
|
-
})
|
|
1666
|
-
]),
|
|
1667
|
-
_: 1
|
|
1668
|
-
})
|
|
1669
|
-
], !0)
|
|
1670
|
-
]),
|
|
1671
|
-
_: 3
|
|
1672
|
-
}, 8, ["model"]),
|
|
1673
|
-
c.value ? (Q(), R("div", $n, [
|
|
1674
|
-
o.value ? (Q(), Y(v(fe), {
|
|
1675
|
-
key: 0,
|
|
1676
|
-
type: "primary",
|
|
1677
|
-
onClick: Ce
|
|
1678
|
-
}, {
|
|
1679
|
-
default: b(() => [...r[15] || (r[15] = [
|
|
1680
|
-
ce(" 新增 ", -1)
|
|
1681
|
-
])]),
|
|
1682
|
-
_: 1
|
|
1683
|
-
})) : I("", !0),
|
|
1684
|
-
q(n.$slots, "toolbar", {
|
|
1685
|
-
query: B,
|
|
1686
|
-
search: X
|
|
1687
|
-
}, void 0, !0),
|
|
1688
|
-
q(n.$slots, "bar", {
|
|
1689
|
-
query: B,
|
|
1690
|
-
search: X
|
|
1691
|
-
}, void 0, !0)
|
|
1692
|
-
])) : I("", !0)
|
|
1693
|
-
])) : I("", !0),
|
|
1694
|
-
Ze((Q(), Y(v(_a), me({
|
|
1695
|
-
ref_key: "tableRef",
|
|
1696
|
-
ref: s,
|
|
1697
|
-
data: $.value,
|
|
1698
|
-
"row-key": J.value,
|
|
1699
|
-
border: "",
|
|
1700
|
-
"highlight-current-row": "",
|
|
1701
|
-
"max-height": "550px"
|
|
1702
|
-
}, y.value, {
|
|
1703
|
-
onSelectionChange: g,
|
|
1704
|
-
onRowClick: l
|
|
1705
|
-
}), {
|
|
1706
|
-
default: b(() => {
|
|
1707
|
-
var h;
|
|
1708
|
-
return [
|
|
1709
|
-
z.value === "multiple" ? (Q(), Y(v(za), {
|
|
1710
|
-
key: 0,
|
|
1711
|
-
type: "selection",
|
|
1712
|
-
"reserve-selection": "",
|
|
1713
|
-
width: "42",
|
|
1714
|
-
selectable: (h = y.value) == null ? void 0 : h.selectable
|
|
1715
|
-
}, null, 8, ["selectable"])) : I("", !0),
|
|
1716
|
-
q(n.$slots, "columns", {}, void 0, !0),
|
|
1717
|
-
q(n.$slots, "cols", {}, void 0, !0)
|
|
1718
|
-
];
|
|
1719
|
-
}),
|
|
1720
|
-
_: 3
|
|
1721
|
-
}, 16, ["data", "row-key"])), [
|
|
1722
|
-
[A, V.value]
|
|
1723
|
-
]),
|
|
1724
|
-
e.showPagination && E.value > 0 ? (Q(), R("div", Cn, [
|
|
1725
|
-
O(v(Ka), {
|
|
1726
|
-
"current-page": B.page,
|
|
1727
|
-
"onUpdate:currentPage": r[4] || (r[4] = (h) => B.page = h),
|
|
1728
|
-
"page-size": B.pageSize,
|
|
1729
|
-
"onUpdate:pageSize": r[5] || (r[5] = (h) => B.pageSize = h),
|
|
1730
|
-
total: E.value,
|
|
1731
|
-
"page-sizes": e.pageSizes,
|
|
1732
|
-
layout: "total, sizes, prev, pager, next, jumper",
|
|
1733
|
-
onSizeChange: pe,
|
|
1734
|
-
onCurrentChange: ie
|
|
1735
|
-
}, null, 8, ["current-page", "page-size", "total", "page-sizes"])
|
|
1736
|
-
])) : I("", !0)
|
|
1737
|
-
])
|
|
1738
|
-
]),
|
|
1739
|
-
O(Ie, {
|
|
1740
|
-
open: U.value,
|
|
1741
|
-
title: "粘贴数据",
|
|
1742
|
-
"show-footer": !1,
|
|
1743
|
-
width: "560px",
|
|
1744
|
-
"onUpdate:open": r[8] || (r[8] = (h) => U.value = h)
|
|
1745
|
-
}, {
|
|
1746
|
-
default: b(() => [
|
|
1747
|
-
O(v(Te), {
|
|
1748
|
-
modelValue: H.value,
|
|
1749
|
-
"onUpdate:modelValue": r[6] || (r[6] = (h) => H.value = h),
|
|
1750
|
-
type: "textarea",
|
|
1751
|
-
rows: 8
|
|
1752
|
-
}, null, 8, ["modelValue"]),
|
|
1753
|
-
te("div", Vn, [
|
|
1754
|
-
O(v(fe), {
|
|
1755
|
-
onClick: r[7] || (r[7] = (h) => U.value = !1)
|
|
1756
|
-
}, {
|
|
1757
|
-
default: b(() => [...r[16] || (r[16] = [
|
|
1758
|
-
ce("取消", -1)
|
|
1759
|
-
])]),
|
|
1760
|
-
_: 1
|
|
1761
|
-
}),
|
|
1762
|
-
O(v(fe), {
|
|
1763
|
-
type: "primary",
|
|
1764
|
-
onClick: Va
|
|
1765
|
-
}, {
|
|
1766
|
-
default: b(() => [...r[17] || (r[17] = [
|
|
1767
|
-
ce("确认", -1)
|
|
1768
|
-
])]),
|
|
1769
|
-
_: 1
|
|
1770
|
-
})
|
|
1771
|
-
])
|
|
1772
|
-
]),
|
|
1773
|
-
_: 1
|
|
1774
|
-
}, 8, ["open"])
|
|
1775
|
-
]),
|
|
1776
|
-
_: 3
|
|
1777
|
-
}, 8, ["open", "title", "width"]);
|
|
1778
|
-
};
|
|
1779
|
-
}
|
|
1780
|
-
}), lt = /* @__PURE__ */ we(Bn, [["__scopeId", "data-v-47259611"]]), An = /* @__PURE__ */ ve({
|
|
1781
|
-
name: "QyLegacySelectionDialog",
|
|
1782
|
-
inheritAttrs: !1,
|
|
1783
|
-
__name: "index",
|
|
1784
|
-
props: {
|
|
1785
|
-
open: { type: Boolean, default: !0 },
|
|
1786
|
-
title: { default: "选择数据" },
|
|
1787
|
-
width: { default: "1200px" },
|
|
1788
|
-
query: { type: Function, default: void 0 },
|
|
1789
|
-
responseFormatter: { type: Function, default: void 0 },
|
|
1790
|
-
selection: { default: "single" },
|
|
1791
|
-
selected: { default: () => [] },
|
|
1792
|
-
mainKey: { default: "" },
|
|
1793
|
-
tagName: { default: "" },
|
|
1794
|
-
searchKey: { default: "conditions" },
|
|
1795
|
-
queryParams: { default: () => ({}) },
|
|
1796
|
-
category: { type: [Array, Function, Boolean], default: !1 },
|
|
1797
|
-
categoryFormatter: { type: [Function, Array], default: void 0 },
|
|
1798
|
-
type: { type: [Array, Boolean], default: !1 },
|
|
1799
|
-
typeSelectionProps: { default: () => ({}) },
|
|
1800
|
-
tableProps: { default: () => ({}) },
|
|
1801
|
-
append: { type: Boolean, default: !1 },
|
|
1802
|
-
delete: { type: Boolean, default: !1 },
|
|
1803
|
-
select: { default: null }
|
|
1804
|
-
},
|
|
1805
|
-
emits: ["close", "submit", "openDialog", "changeIndexShow"],
|
|
1806
|
-
setup(e, { expose: F, emit: N }) {
|
|
1807
|
-
const t = e, i = N, oe = Se(), S = x(null), m = Re({
|
|
1808
|
-
category: [],
|
|
1809
|
-
code: "",
|
|
1810
|
-
...t.searchKey ? { [t.searchKey]: "" } : {},
|
|
1811
|
-
page: 1,
|
|
1812
|
-
pageSize: 10,
|
|
1813
|
-
type: "",
|
|
1814
|
-
...t.queryParams
|
|
1815
|
-
}), s = Re({
|
|
1816
|
-
total: 0,
|
|
1817
|
-
tableData: [],
|
|
1818
|
-
open: !1,
|
|
1819
|
-
selection: [],
|
|
1820
|
-
categories: [],
|
|
1821
|
-
types: [],
|
|
1822
|
-
tableRef: null,
|
|
1823
|
-
drag: !1,
|
|
1824
|
-
dialogOpen: !1,
|
|
1825
|
-
pasteData: "",
|
|
1826
|
-
pasteDataDialog: !1
|
|
1827
|
-
}), $ = P(() => t.type || []), w = P(() => s.categories), _ = async (a) => {
|
|
1828
|
-
if (!t.query) return { data: { records: [], total: 0 } };
|
|
1829
|
-
const u = await t.query(B(a)), p = t.responseFormatter ? await t.responseFormatter(u) : u;
|
|
1830
|
-
return s.total = o(p), p;
|
|
1831
|
-
};
|
|
1832
|
-
ee(
|
|
1833
|
-
() => t.open,
|
|
1834
|
-
(a) => {
|
|
1835
|
-
s.open = a;
|
|
1836
|
-
},
|
|
1837
|
-
{ immediate: !0 }
|
|
1838
|
-
), ee(
|
|
1839
|
-
$,
|
|
1840
|
-
(a) => {
|
|
1841
|
-
s.types = [...a];
|
|
1842
|
-
},
|
|
1843
|
-
{ immediate: !0, deep: !0 }
|
|
1844
|
-
), ee(
|
|
1845
|
-
[() => t.selected, () => t.open],
|
|
1846
|
-
() => {
|
|
1847
|
-
t.open && (s.selection = c(t.selected));
|
|
1848
|
-
},
|
|
1849
|
-
{ immediate: !0, deep: !0 }
|
|
1850
|
-
), ee(
|
|
1851
|
-
() => t.queryParams,
|
|
1852
|
-
() => {
|
|
1853
|
-
Object.assign(m, t.queryParams);
|
|
1854
|
-
},
|
|
1855
|
-
{ deep: !0 }
|
|
1856
|
-
), ee(
|
|
1857
|
-
() => s.pasteDataDialog,
|
|
1858
|
-
(a) => {
|
|
1859
|
-
a || (s.pasteData = "");
|
|
1860
|
-
}
|
|
1861
|
-
), ee(
|
|
1862
|
-
() => t.select,
|
|
1863
|
-
async () => {
|
|
1864
|
-
t.select && await H(t.select);
|
|
1865
|
-
},
|
|
1866
|
-
{ deep: !0 }
|
|
1867
|
-
), ee(
|
|
1868
|
-
() => t.open,
|
|
1869
|
-
async (a) => {
|
|
1870
|
-
a && (s.dialogOpen = !1, await V());
|
|
1871
|
-
},
|
|
1872
|
-
{ immediate: !0 }
|
|
1873
|
-
);
|
|
1874
|
-
async function V() {
|
|
1875
|
-
if (!t.category) {
|
|
1876
|
-
s.categories = [];
|
|
1877
|
-
return;
|
|
1878
|
-
}
|
|
1879
|
-
const a = typeof t.category == "function" ? await t.category() : t.category;
|
|
1880
|
-
s.categories = Z(a);
|
|
1881
|
-
}
|
|
1882
|
-
async function k() {
|
|
1883
|
-
var a;
|
|
1884
|
-
return await De(), (a = S.value) == null ? void 0 : a.handleQuerySearch();
|
|
1885
|
-
}
|
|
1886
|
-
function T(a) {
|
|
1887
|
-
s.selection = c(a);
|
|
1888
|
-
}
|
|
1889
|
-
function j(a) {
|
|
1890
|
-
var u;
|
|
1891
|
-
s.tableData = a, s.tableRef = (u = S.value) == null ? void 0 : u.getTableRef();
|
|
1892
|
-
}
|
|
1893
|
-
function M(a) {
|
|
1894
|
-
s.selection = c(a), i("submit", s);
|
|
1895
|
-
}
|
|
1896
|
-
function G() {
|
|
1897
|
-
i("close");
|
|
1898
|
-
}
|
|
1899
|
-
function E() {
|
|
1900
|
-
s.dialogOpen = !0, i("openDialog");
|
|
1901
|
-
}
|
|
1902
|
-
function U(a) {
|
|
1903
|
-
i("changeIndexShow", a);
|
|
1904
|
-
}
|
|
1905
|
-
async function H(a) {
|
|
1906
|
-
if (!t.query || !t.searchKey || !t.mainKey) return;
|
|
1907
|
-
const u = await t.query({
|
|
1908
|
-
...m,
|
|
1909
|
-
[t.searchKey]: a[t.mainKey],
|
|
1910
|
-
category: []
|
|
1911
|
-
}), p = t.responseFormatter ? await t.responseFormatter(u) : u, [D] = C(p);
|
|
1912
|
-
D && (t.selection === "multi" ? (s.selection = s.selection.filter(
|
|
1913
|
-
(re) => re[t.mainKey] !== D[t.mainKey]
|
|
1914
|
-
), s.selection.push(D)) : s.selection = [D]);
|
|
1915
|
-
}
|
|
1916
|
-
function B(a = {}) {
|
|
1917
|
-
m.page = a.page ?? m.page, m.pageSize = a.pageSize ?? m.pageSize;
|
|
1918
|
-
const u = {
|
|
1919
|
-
...m,
|
|
1920
|
-
category: z()
|
|
1921
|
-
};
|
|
1922
|
-
return t.searchKey && (u[t.searchKey] = String(u[t.searchKey] || "").trim()), u;
|
|
1923
|
-
}
|
|
1924
|
-
function z() {
|
|
1925
|
-
if (t.queryParams.category)
|
|
1926
|
-
return t.queryParams.category;
|
|
1927
|
-
const a = m.category;
|
|
1928
|
-
if (Array.isArray(a)) return a;
|
|
1929
|
-
if (!a) return [];
|
|
1930
|
-
const u = J(s.categories, a);
|
|
1931
|
-
return u ? W(u) : [a];
|
|
1932
|
-
}
|
|
1933
|
-
function J(a, u) {
|
|
1934
|
-
for (const p of a || []) {
|
|
1935
|
-
if (p.value === u) return p;
|
|
1936
|
-
const D = J(p.children || [], u);
|
|
1937
|
-
if (D) return D;
|
|
1938
|
-
}
|
|
1939
|
-
}
|
|
1940
|
-
function W(a) {
|
|
1941
|
-
return [a.value, ...(a.children || []).flatMap(W)];
|
|
1942
|
-
}
|
|
1943
|
-
function Z(a) {
|
|
1944
|
-
const u = (a == null ? void 0 : a.data) ?? a;
|
|
1945
|
-
if (!Array.isArray(u)) return [];
|
|
1946
|
-
if (typeof t.categoryFormatter == "function")
|
|
1947
|
-
return t.categoryFormatter(u);
|
|
1948
|
-
if (Array.isArray(t.categoryFormatter)) {
|
|
1949
|
-
const [p, D] = t.categoryFormatter;
|
|
1950
|
-
return y(le(u, D), p, D);
|
|
1951
|
-
}
|
|
1952
|
-
return u;
|
|
1953
|
-
}
|
|
1954
|
-
function le(a, u) {
|
|
1955
|
-
const p = a.map((re) => ({ ...re })), D = [];
|
|
1956
|
-
return p.forEach((re) => {
|
|
1957
|
-
const ie = re.parentCateCode;
|
|
1958
|
-
if (!ie) {
|
|
1959
|
-
D.push(re);
|
|
1960
|
-
return;
|
|
1961
|
-
}
|
|
1962
|
-
const X = p.find((pe) => pe[u] === ie);
|
|
1963
|
-
X ? (X.children || (X.children = [])).push(re) : D.push(re);
|
|
1964
|
-
}), D;
|
|
1965
|
-
}
|
|
1966
|
-
function y(a, u, p) {
|
|
1967
|
-
return a.map((D) => ({
|
|
1968
|
-
...D,
|
|
1969
|
-
label: D[u],
|
|
1970
|
-
value: D[p],
|
|
1971
|
-
children: Array.isArray(D.children) ? y(D.children, u, p) : D.children
|
|
1972
|
-
}));
|
|
1973
|
-
}
|
|
1974
|
-
function C(a) {
|
|
1975
|
-
if (Array.isArray(a)) return a;
|
|
1976
|
-
const u = a == null ? void 0 : a.data;
|
|
1977
|
-
return Array.isArray(u) ? u : (a == null ? void 0 : a.records) || (a == null ? void 0 : a.rows) || (u == null ? void 0 : u.records) || [];
|
|
1978
|
-
}
|
|
1979
|
-
function o(a) {
|
|
1980
|
-
if (Array.isArray(a)) return a.length;
|
|
1981
|
-
const u = C(a), p = a == null ? void 0 : a.data;
|
|
1982
|
-
return (a == null ? void 0 : a.total) ?? (Array.isArray(p) ? p.length : p == null ? void 0 : p.total) ?? u.length;
|
|
1983
|
-
}
|
|
1984
|
-
function c(a = []) {
|
|
1985
|
-
return a.map((u) => ({ ...u }));
|
|
1986
|
-
}
|
|
1987
|
-
return F({
|
|
1988
|
-
search: k,
|
|
1989
|
-
handleSearch: k,
|
|
1990
|
-
handleConditionChange: k,
|
|
1991
|
-
getTableRef: () => s.tableRef,
|
|
1992
|
-
getTableData: () => s.tableData,
|
|
1993
|
-
getSelection: () => c(s.selection)
|
|
1994
|
-
}), (a, u) => (Q(), R(Pe, null, [
|
|
1995
|
-
O(lt, me({
|
|
1996
|
-
ref_key: "selectionDialogRef",
|
|
1997
|
-
ref: S
|
|
1998
|
-
}, v(oe), {
|
|
1999
|
-
modelValue: s.selection,
|
|
2000
|
-
"onUpdate:modelValue": u[3] || (u[3] = (p) => s.selection = p),
|
|
2001
|
-
open: e.open,
|
|
2002
|
-
title: e.title,
|
|
2003
|
-
width: e.width,
|
|
2004
|
-
query: _,
|
|
2005
|
-
"response-formatter": e.responseFormatter,
|
|
2006
|
-
selection: e.selection,
|
|
2007
|
-
"row-key": e.mainKey,
|
|
2008
|
-
"label-key": e.tagName,
|
|
2009
|
-
"search-key": e.searchKey,
|
|
2010
|
-
"query-params": {},
|
|
2011
|
-
"category-options": w.value,
|
|
2012
|
-
"type-options": $.value,
|
|
2013
|
-
"type-select-props": e.typeSelectionProps,
|
|
2014
|
-
"table-props": e.tableProps,
|
|
2015
|
-
"show-copy-paste": !0,
|
|
2016
|
-
"show-append": e.append,
|
|
2017
|
-
onSelectionChange: T,
|
|
2018
|
-
onConfirm: M,
|
|
2019
|
-
onCancel: G,
|
|
2020
|
-
onAppend: E,
|
|
2021
|
-
onLoaded: j
|
|
2022
|
-
}), {
|
|
2023
|
-
side: b(() => [
|
|
2024
|
-
q(a.$slots, "side", {
|
|
2025
|
-
state: s,
|
|
2026
|
-
cate: s.categories,
|
|
2027
|
-
form: m,
|
|
2028
|
-
query: m,
|
|
2029
|
-
getData: k,
|
|
2030
|
-
search: k,
|
|
2031
|
-
changeIndexShow: U
|
|
2032
|
-
}, void 0, !0)
|
|
2033
|
-
]),
|
|
2034
|
-
search: b(() => [
|
|
2035
|
-
O(v(et), {
|
|
2036
|
-
inline: "",
|
|
2037
|
-
model: m
|
|
2038
|
-
}, {
|
|
2039
|
-
default: b(() => [
|
|
2040
|
-
s.categories.length ? (Q(), Y(v(he), {
|
|
2041
|
-
key: 0,
|
|
2042
|
-
label: "分类"
|
|
2043
|
-
}, {
|
|
2044
|
-
default: b(() => [
|
|
2045
|
-
O(v(Ma), {
|
|
2046
|
-
modelValue: m.category,
|
|
2047
|
-
"onUpdate:modelValue": u[0] || (u[0] = (p) => m.category = p),
|
|
2048
|
-
class: "qy-legacy-selection-dialog__category",
|
|
2049
|
-
data: s.categories,
|
|
2050
|
-
clearable: "",
|
|
2051
|
-
filterable: "",
|
|
2052
|
-
"check-strictly": "",
|
|
2053
|
-
"render-after-expand": !1,
|
|
2054
|
-
onChange: k
|
|
2055
|
-
}, null, 8, ["modelValue", "data"])
|
|
2056
|
-
]),
|
|
2057
|
-
_: 1
|
|
2058
|
-
})) : I("", !0),
|
|
2059
|
-
$.value.length ? (Q(), Y(v(he), {
|
|
2060
|
-
key: 1,
|
|
2061
|
-
label: "类型"
|
|
2062
|
-
}, {
|
|
2063
|
-
default: b(() => [
|
|
2064
|
-
O(v(Xe), me({
|
|
2065
|
-
modelValue: m.type,
|
|
2066
|
-
"onUpdate:modelValue": u[1] || (u[1] = (p) => m.type = p),
|
|
2067
|
-
clearable: ""
|
|
2068
|
-
}, e.typeSelectionProps, { onChange: k }), {
|
|
2069
|
-
default: b(() => [
|
|
2070
|
-
(Q(!0), R(Pe, null, Oe($.value, (p) => (Q(), Y(v(Ye), {
|
|
2071
|
-
key: p.value,
|
|
2072
|
-
label: p.label,
|
|
2073
|
-
value: p.value
|
|
2074
|
-
}, null, 8, ["label", "value"]))), 128))
|
|
2075
|
-
]),
|
|
2076
|
-
_: 1
|
|
2077
|
-
}, 16, ["modelValue"])
|
|
2078
|
-
]),
|
|
2079
|
-
_: 1
|
|
2080
|
-
})) : I("", !0),
|
|
2081
|
-
e.searchKey ? (Q(), Y(v(he), {
|
|
2082
|
-
key: 2,
|
|
2083
|
-
label: "搜索"
|
|
2084
|
-
}, {
|
|
2085
|
-
default: b(() => [
|
|
2086
|
-
O(v(Te), {
|
|
2087
|
-
modelValue: m[e.searchKey],
|
|
2088
|
-
"onUpdate:modelValue": u[2] || (u[2] = (p) => m[e.searchKey] = p),
|
|
2089
|
-
clearable: "",
|
|
2090
|
-
class: "qy-legacy-selection-dialog__search-input",
|
|
2091
|
-
onKeydown: _e(ze(k, ["prevent"]), ["enter"])
|
|
2092
|
-
}, null, 8, ["modelValue", "onKeydown"])
|
|
2093
|
-
]),
|
|
2094
|
-
_: 1
|
|
2095
|
-
})) : I("", !0),
|
|
2096
|
-
O(v(he), null, {
|
|
2097
|
-
default: b(() => [
|
|
2098
|
-
O(v(fe), {
|
|
2099
|
-
type: "primary",
|
|
2100
|
-
onClick: k
|
|
2101
|
-
}, {
|
|
2102
|
-
default: b(() => [...u[4] || (u[4] = [
|
|
2103
|
-
ce("查询", -1)
|
|
2104
|
-
])]),
|
|
2105
|
-
_: 1
|
|
2106
|
-
})
|
|
2107
|
-
]),
|
|
2108
|
-
_: 1
|
|
2109
|
-
})
|
|
2110
|
-
]),
|
|
2111
|
-
_: 1
|
|
2112
|
-
}, 8, ["model"])
|
|
2113
|
-
]),
|
|
2114
|
-
toolbar: b(() => [
|
|
2115
|
-
q(a.$slots, "bar", {
|
|
2116
|
-
query: m,
|
|
2117
|
-
search: k
|
|
2118
|
-
}, void 0, !0)
|
|
2119
|
-
]),
|
|
2120
|
-
columns: b(() => [
|
|
2121
|
-
q(a.$slots, "cols", {}, void 0, !0),
|
|
2122
|
-
q(a.$slots, "columns", {}, void 0, !0)
|
|
2123
|
-
]),
|
|
2124
|
-
_: 3
|
|
2125
|
-
}, 16, ["modelValue", "open", "title", "width", "response-formatter", "selection", "row-key", "label-key", "search-key", "category-options", "type-options", "type-select-props", "table-props", "show-append"]),
|
|
2126
|
-
q(a.$slots, "dialog", {
|
|
2127
|
-
state: s,
|
|
2128
|
-
form: m,
|
|
2129
|
-
getData: k
|
|
2130
|
-
}, void 0, !0)
|
|
2131
|
-
], 64));
|
|
2132
|
-
}
|
|
2133
|
-
}), qn = /* @__PURE__ */ we(An, [["__scopeId", "data-v-5c8cd0de"]]), Pn = { class: "qy-form-section__heading" }, Tn = {
|
|
2134
|
-
key: 0,
|
|
2135
|
-
class: "qy-form-section__title"
|
|
2136
|
-
}, In = {
|
|
2137
|
-
key: 0,
|
|
2138
|
-
class: "qy-form-section__description"
|
|
2139
|
-
}, Rn = { class: "qy-form-section__actions" }, Fn = /* @__PURE__ */ ve({
|
|
2140
|
-
name: "QyFormSection",
|
|
2141
|
-
__name: "index",
|
|
2142
|
-
props: {
|
|
2143
|
-
title: { default: "" },
|
|
2144
|
-
description: { default: "" },
|
|
2145
|
-
tip: { default: "" },
|
|
2146
|
-
tipType: { default: "info" },
|
|
2147
|
-
collapsible: { type: Boolean, default: !1 },
|
|
2148
|
-
defaultExpanded: { type: Boolean, default: !0 },
|
|
2149
|
-
bordered: { type: Boolean, default: !0 },
|
|
2150
|
-
background: { default: "white" },
|
|
2151
|
-
bodyClass: { default: "" },
|
|
2152
|
-
headerClass: { default: "" }
|
|
2153
|
-
},
|
|
2154
|
-
emits: ["toggle"],
|
|
2155
|
-
setup(e, { emit: F }) {
|
|
2156
|
-
const N = e, t = F, i = x(N.defaultExpanded);
|
|
2157
|
-
ee(
|
|
2158
|
-
() => N.defaultExpanded,
|
|
2159
|
-
(m) => {
|
|
2160
|
-
i.value = m;
|
|
2161
|
-
}
|
|
2162
|
-
);
|
|
2163
|
-
function oe() {
|
|
2164
|
-
N.collapsible && (i.value = !i.value, t("toggle", i.value));
|
|
2165
|
-
}
|
|
2166
|
-
function S() {
|
|
2167
|
-
N.collapsible && oe();
|
|
2168
|
-
}
|
|
2169
|
-
return (m, s) => (Q(), R("section", {
|
|
2170
|
-
class: ge(["qy-form-section", [
|
|
2171
|
-
`is-bg-${e.background}`,
|
|
2172
|
-
{
|
|
2173
|
-
"is-bordered": e.bordered,
|
|
2174
|
-
"is-collapsible": e.collapsible
|
|
2175
|
-
}
|
|
2176
|
-
]])
|
|
2177
|
-
}, [
|
|
2178
|
-
te("header", {
|
|
2179
|
-
class: ge(["qy-form-section__header", e.headerClass]),
|
|
2180
|
-
onClick: S
|
|
2181
|
-
}, [
|
|
2182
|
-
te("div", Pn, [
|
|
2183
|
-
q(m.$slots, "title", {}, () => [
|
|
2184
|
-
e.title ? (Q(), R("div", Tn, ye(e.title), 1)) : I("", !0)
|
|
2185
|
-
], !0),
|
|
2186
|
-
q(m.$slots, "description", {}, () => [
|
|
2187
|
-
e.description ? (Q(), R("div", In, ye(e.description), 1)) : I("", !0)
|
|
2188
|
-
], !0)
|
|
2189
|
-
]),
|
|
2190
|
-
te("div", Rn, [
|
|
2191
|
-
q(m.$slots, "actions", {}, void 0, !0),
|
|
2192
|
-
e.collapsible ? (Q(), R("button", {
|
|
2193
|
-
key: 0,
|
|
2194
|
-
type: "button",
|
|
2195
|
-
class: "qy-form-section__toggle",
|
|
2196
|
-
onClick: ze(oe, ["stop"])
|
|
2197
|
-
}, ye(i.value ? "收起" : "展开"), 1)) : I("", !0)
|
|
2198
|
-
])
|
|
2199
|
-
], 2),
|
|
2200
|
-
Ze(te("div", {
|
|
2201
|
-
class: ge(["qy-form-section__body", e.bodyClass])
|
|
2202
|
-
}, [
|
|
2203
|
-
q(m.$slots, "tip", {}, () => [
|
|
2204
|
-
e.tip ? (Q(), R("div", {
|
|
2205
|
-
key: 0,
|
|
2206
|
-
class: ge(["qy-form-section__tip", `is-${e.tipType}`])
|
|
2207
|
-
}, ye(e.tip), 3)) : I("", !0)
|
|
2208
|
-
], !0),
|
|
2209
|
-
q(m.$slots, "default", {}, void 0, !0)
|
|
2210
|
-
], 2), [
|
|
2211
|
-
[Fa, i.value]
|
|
2212
|
-
])
|
|
2213
|
-
], 2));
|
|
2214
|
-
}
|
|
2215
|
-
}), Dn = /* @__PURE__ */ we(Fn, [["__scopeId", "data-v-3b271926"]]), On = {
|
|
2216
|
-
key: 0,
|
|
2217
|
-
class: "qy-action-bar__left"
|
|
2218
|
-
}, xn = {
|
|
2219
|
-
key: 1,
|
|
2220
|
-
class: "qy-action-bar__center"
|
|
2221
|
-
}, _n = {
|
|
2222
|
-
key: 2,
|
|
2223
|
-
class: "qy-action-bar__right"
|
|
2224
|
-
}, zn = /* @__PURE__ */ ve({
|
|
2225
|
-
name: "QyActionBar",
|
|
2226
|
-
__name: "index",
|
|
2227
|
-
props: {
|
|
2228
|
-
sticky: { type: Boolean, default: !0 },
|
|
2229
|
-
offsetBottom: { default: 0 },
|
|
2230
|
-
bordered: { type: Boolean, default: !0 },
|
|
2231
|
-
shadow: { type: Boolean, default: !1 },
|
|
2232
|
-
wrap: { type: Boolean, default: !0 },
|
|
2233
|
-
justify: { default: "between" },
|
|
2234
|
-
background: { default: "#fff" }
|
|
2235
|
-
},
|
|
2236
|
-
setup(e) {
|
|
2237
|
-
const F = e, N = P(() => ({
|
|
2238
|
-
// offsetBottom 只负责业务偏移,安全区补偿由 CSS padding 处理。
|
|
2239
|
-
bottom: `${F.offsetBottom}px`,
|
|
2240
|
-
background: F.background
|
|
2241
|
-
}));
|
|
2242
|
-
return (t, i) => (Q(), R("div", {
|
|
2243
|
-
class: ge(["qy-action-bar", [
|
|
2244
|
-
`is-justify-${e.justify}`,
|
|
2245
|
-
{
|
|
2246
|
-
"is-sticky": e.sticky,
|
|
2247
|
-
"is-bordered": e.bordered,
|
|
2248
|
-
"is-shadow": e.shadow,
|
|
2249
|
-
"is-wrap": e.wrap
|
|
2250
|
-
}
|
|
2251
|
-
]]),
|
|
2252
|
-
style: Ge(N.value)
|
|
2253
|
-
}, [
|
|
2254
|
-
t.$slots.left ? (Q(), R("div", On, [
|
|
2255
|
-
q(t.$slots, "left", {}, void 0, !0)
|
|
2256
|
-
])) : I("", !0),
|
|
2257
|
-
t.$slots.default ? (Q(), R("div", xn, [
|
|
2258
|
-
q(t.$slots, "default", {}, void 0, !0)
|
|
2259
|
-
])) : I("", !0),
|
|
2260
|
-
t.$slots.right ? (Q(), R("div", _n, [
|
|
2261
|
-
q(t.$slots, "right", {}, void 0, !0)
|
|
2262
|
-
])) : I("", !0)
|
|
2263
|
-
], 6));
|
|
2264
|
-
}
|
|
2265
|
-
}), Kn = /* @__PURE__ */ we(zn, [["__scopeId", "data-v-d1ffc43c"]]), rt = f(We, "QyUpload"), it = f(qa, "QyImage"), st = f(Pa, "QyImagePreview"), ut = f(Wo, "QyImageUpload"), ct = f(Ie, "QyDialog"), dt = f(ln, "QyRemarkImage"), ft = f(Ea, "QyButton"), yt = f(La, "QyDropdown"), mt = f(Ua, "QyInput"), pt = f(Na, "QyInputTag"), gt = f(ja, "QyInputNumber"), ht = f(Wa, "QyMoneyInput"), vt = f(Ga, "QyDatePicker"), bt = f(Ha, "QyCheckbox"), Qt = f(Ja, "QyCheckboxGroup"), St = f(Za, "QyRadio"), wt = f(Xa, "QyAutocomplete"), kt = f(Ya, "QyMenuActions"), $t = f(
|
|
2266
|
-
eo,
|
|
2267
|
-
"QyTableColumnSettings"
|
|
2268
|
-
), Ct = f(to, "QyRadioGroup"), Vt = f(rn, "QyRemoteSelect"), Bt = f(nt, "QySearchInput"), At = f(
|
|
2269
|
-
hn,
|
|
2270
|
-
"QyRecordQuoteSearch"
|
|
2271
|
-
), qt = f(Me, "QySelect"), Pt = f(tt, "QyTreeSelect"), Tt = f(lt, "QySelectionDialog"), It = f(
|
|
2272
|
-
qn,
|
|
2273
|
-
"QyLegacySelectionDialog"
|
|
2274
|
-
), Rt = f(Dn, "QyFormSection"), Ft = f(Kn, "QyActionBar"), Dt = f(oo, "QyFilePicker"), Ot = f(no, "QySwitch"), xt = f(Fe, "QyTag"), _t = f(lo, "QyBadge"), zt = f(ro, "QyCascader"), Kt = f(io, "QyTooltip"), Mt = f(so, "QyPopover"), Et = f(uo, "QyPopconfirm"), Lt = f(co, "QySkeleton"), Ut = f(fo, "QySkeletonItem"), Nt = f(yo, "QyTabs"), jt = f(mo, "QyTabPane"), Wt = f(po, "QySteps"), Gt = f(go, "QyStep"), Ht = f(ho, "QyFullscreen"), Jt = f(Qo, "QyRow"), Zt = f(So, "QyCol"), Xt = f(wo, "QyContainer"), Yt = f(ko, "QyAside"), ea = f($o, "QyMain"), ta = f(Co, "QyDescriptions"), aa = f(Vo, "QyDescriptionsItem"), oa = f(Bo, "QyCollapse"), na = f(Ao, "QyCollapseItem"), la = f(qo, "QyLink"), ra = f(Po, "QyIframe"), ia = f(To, "QyDivider"), sa = f(Io, "QyEmpty"), ua = f(Ro, "QyAlert"), ca = f(Fo, "QyCard"), da = f(Do, "QyResult"), fa = f(Oo, "QyWatermark"), ya = f(xo, "QyScrollbar"), ma = f(_o, "QyProgress"), pa = f(zo, "QyStatistic"), ga = f(Ko, "QyAvatar"), ha = f(Mo, "QyTree"), va = f(Eo, "QyPagination"), ba = f(vo, "QyIconPicker"), Qa = f(bo, "QyColorPicker"), Sa = f(Uo, "QyDrawer"), Mn = (e) => {
|
|
2275
|
-
ot.install(e), e.component("QyDialog", ct), e.component("QyDrawer", Sa), e.component("QyUpload", rt), e.component("QyImage", it), e.component("QyImagePreview", st), e.component("QyImageUpload", ut), e.component("QyRemarkImage", dt), e.component("QyButton", ft), e.component("QyDropdown", yt), e.component("QyInput", mt), e.component("QyInputTag", pt), e.component("QyInputNumber", gt), e.component("QyMoneyInput", ht), e.component("QyDatePicker", vt), e.component("QyCheckbox", bt), e.component("QyCheckboxGroup", Qt), e.component("QyRadio", St), e.component("QyAutocomplete", wt), e.component("QyMenuActions", kt), e.component("QyTableColumnSettings", $t), e.component("QyRadioGroup", Ct), e.component("QyRemoteSelect", Vt), e.component("QySearchInput", Bt), e.component("QyRecordQuoteSearch", At), e.component("QySelect", qt), e.component("QyTreeSelect", Pt), e.component("QySelectionDialog", Tt), e.component("QyLegacySelectionDialog", It), e.component("QyFormSection", Rt), e.component("QyActionBar", Ft), e.component("QyFilePicker", Dt), e.component("QySwitch", Ot), e.component("QyTag", xt), e.component("QyBadge", _t), e.component("QyCascader", zt), e.component("QyTooltip", Kt), e.component("QyPopover", Mt), e.component("QyPopconfirm", Et), e.component("QySkeleton", Lt), e.component("QySkeletonItem", Ut), e.component("QyTabs", Nt), e.component("QyTabPane", jt), e.component("QySteps", Wt), e.component("QyStep", Gt), e.component("QyFullscreen", Ht), e.component("QyIcon", at), e.component("QyIconPicker", ba), e.component("QyColorPicker", Qa), e.component("QyRow", Jt), e.component("QyCol", Zt), e.component("QyContainer", Xt), e.component("QyAside", Yt), e.component("QyMain", ea), e.component("QyDescriptions", ta), e.component("QyDescriptionsItem", aa), e.component("QyCollapse", oa), e.component("QyCollapseItem", na), e.component("QyLink", la), e.component("QyIframe", ra), e.component("QyDivider", ia), e.component("QyEmpty", sa), e.component("QyAlert", ua), e.component("QyCard", ca), e.component("QyResult", da), e.component("QyWatermark", fa), e.component("QyScrollbar", ya), e.component("QyProgress", ma), e.component("QyStatistic", pa), e.component("QyAvatar", ga), e.component("QyTree", ha), e.component("QyPagination", va);
|
|
2276
|
-
}, nr = {
|
|
2277
|
-
install: Mn,
|
|
2278
|
-
QyUpload: rt,
|
|
2279
|
-
QyImage: it,
|
|
2280
|
-
QyImagePreview: st,
|
|
2281
|
-
openQyImagePreview: No,
|
|
2282
|
-
QyImageUpload: ut,
|
|
2283
|
-
QyDialog: ct,
|
|
2284
|
-
QyButton: ft,
|
|
2285
|
-
QyDropdown: yt,
|
|
2286
|
-
QyInput: mt,
|
|
2287
|
-
QyInputTag: pt,
|
|
2288
|
-
QyInputNumber: gt,
|
|
2289
|
-
QyMoneyInput: ht,
|
|
2290
|
-
QyDatePicker: vt,
|
|
2291
|
-
QyCheckbox: bt,
|
|
2292
|
-
QyCheckboxGroup: Qt,
|
|
2293
|
-
QyRadio: St,
|
|
2294
|
-
QyAutocomplete: wt,
|
|
2295
|
-
QyMenuActions: kt,
|
|
2296
|
-
QyTableColumnSettings: $t,
|
|
2297
|
-
QyRadioGroup: Ct,
|
|
2298
|
-
QyRemoteSelect: Vt,
|
|
2299
|
-
QySearchInput: Bt,
|
|
2300
|
-
QyRecordQuoteSearch: At,
|
|
2301
|
-
QySelect: qt,
|
|
2302
|
-
QyTreeSelect: Pt,
|
|
2303
|
-
QySelectionDialog: Tt,
|
|
2304
|
-
QyLegacySelectionDialog: It,
|
|
2305
|
-
QyFormSection: Rt,
|
|
2306
|
-
QyActionBar: Ft,
|
|
2307
|
-
QyFilePicker: Dt,
|
|
2308
|
-
QySwitch: Ot,
|
|
2309
|
-
QyTag: xt,
|
|
2310
|
-
QyBadge: _t,
|
|
2311
|
-
QyCascader: zt,
|
|
2312
|
-
QyTooltip: Kt,
|
|
2313
|
-
QyPopover: Mt,
|
|
2314
|
-
QyPopconfirm: Et,
|
|
2315
|
-
QySkeleton: Lt,
|
|
2316
|
-
QySkeletonItem: Ut,
|
|
2317
|
-
QyTabs: Nt,
|
|
2318
|
-
QyTabPane: jt,
|
|
2319
|
-
QySteps: Wt,
|
|
2320
|
-
QyStep: Gt,
|
|
2321
|
-
QyFullscreen: Ht,
|
|
2322
|
-
QyDrawer: Sa,
|
|
2323
|
-
QyIcon: at,
|
|
2324
|
-
QyIconPicker: ba,
|
|
2325
|
-
QyColorPicker: Qa,
|
|
2326
|
-
QyRow: Jt,
|
|
2327
|
-
QyCol: Zt,
|
|
2328
|
-
QyContainer: Xt,
|
|
2329
|
-
QyAside: Yt,
|
|
2330
|
-
QyMain: ea,
|
|
2331
|
-
QyDescriptions: ta,
|
|
2332
|
-
QyDescriptionsItem: aa,
|
|
2333
|
-
QyCollapse: oa,
|
|
2334
|
-
QyCollapseItem: na,
|
|
2335
|
-
QyLink: la,
|
|
2336
|
-
QyIframe: ra,
|
|
2337
|
-
QyDivider: ia,
|
|
2338
|
-
QyEmpty: sa,
|
|
2339
|
-
QyAlert: ua,
|
|
2340
|
-
QyCard: ca,
|
|
2341
|
-
QyResult: da,
|
|
2342
|
-
QyWatermark: fa,
|
|
2343
|
-
QyScrollbar: ya,
|
|
2344
|
-
QyProgress: ma,
|
|
2345
|
-
QyStatistic: pa,
|
|
2346
|
-
QyAvatar: ga,
|
|
2347
|
-
QyTree: ha,
|
|
2348
|
-
QyPagination: va,
|
|
2349
|
-
QyRemarkImage: dt,
|
|
2350
|
-
QyLoading: ot,
|
|
2351
|
-
vQyLoading: Lo,
|
|
2352
|
-
openQyLoading: jo
|
|
2353
|
-
};
|
|
2354
|
-
export {
|
|
2355
|
-
qt as $,
|
|
2356
|
-
ba as A,
|
|
2357
|
-
ra as B,
|
|
2358
|
-
it as C,
|
|
2359
|
-
st as D,
|
|
2360
|
-
ut as E,
|
|
2361
|
-
mt as F,
|
|
2362
|
-
gt as G,
|
|
2363
|
-
pt as H,
|
|
2364
|
-
It as I,
|
|
2365
|
-
la as J,
|
|
2366
|
-
ea as K,
|
|
2367
|
-
kt as L,
|
|
2368
|
-
ht as M,
|
|
2369
|
-
va as N,
|
|
2370
|
-
Et as O,
|
|
2371
|
-
Mt as P,
|
|
2372
|
-
Ft as Q,
|
|
2373
|
-
ma as R,
|
|
2374
|
-
St as S,
|
|
2375
|
-
Ct as T,
|
|
2376
|
-
At as U,
|
|
2377
|
-
dt as V,
|
|
2378
|
-
Vt as W,
|
|
2379
|
-
da as X,
|
|
2380
|
-
Jt as Y,
|
|
2381
|
-
ya as Z,
|
|
2382
|
-
Bt as _,
|
|
2383
|
-
ua as a,
|
|
2384
|
-
Tt as a0,
|
|
2385
|
-
Lt as a1,
|
|
2386
|
-
Ut as a2,
|
|
2387
|
-
pa as a3,
|
|
2388
|
-
Gt as a4,
|
|
2389
|
-
Wt as a5,
|
|
2390
|
-
Ot as a6,
|
|
2391
|
-
jt as a7,
|
|
2392
|
-
$t as a8,
|
|
2393
|
-
Nt as a9,
|
|
2394
|
-
xt as aa,
|
|
2395
|
-
Kt as ab,
|
|
2396
|
-
ha as ac,
|
|
2397
|
-
Pt as ad,
|
|
2398
|
-
rt as ae,
|
|
2399
|
-
fa as af,
|
|
2400
|
-
nr as ag,
|
|
2401
|
-
Go as ah,
|
|
2402
|
-
Ne as ai,
|
|
2403
|
-
je as aj,
|
|
2404
|
-
Yt as b,
|
|
2405
|
-
wt as c,
|
|
2406
|
-
ga as d,
|
|
2407
|
-
_t as e,
|
|
2408
|
-
ft as f,
|
|
2409
|
-
ca as g,
|
|
2410
|
-
zt as h,
|
|
2411
|
-
bt as i,
|
|
2412
|
-
Qt as j,
|
|
2413
|
-
Zt as k,
|
|
2414
|
-
oa as l,
|
|
2415
|
-
na as m,
|
|
2416
|
-
Qa as n,
|
|
2417
|
-
Xt as o,
|
|
2418
|
-
vt as p,
|
|
2419
|
-
ta as q,
|
|
2420
|
-
aa as r,
|
|
2421
|
-
ct as s,
|
|
2422
|
-
ia as t,
|
|
2423
|
-
Sa as u,
|
|
2424
|
-
yt as v,
|
|
2425
|
-
sa as w,
|
|
2426
|
-
Dt as x,
|
|
2427
|
-
Rt as y,
|
|
2428
|
-
Ht as z
|
|
2429
|
-
};
|