@fewangsit/wangsvue-fats 1.0.0-alpha.40 → 1.0.0-alpha.42
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/assets/lottiejs/loading-page-B9ooQcfF.system.js +1 -0
- package/assets/lottiejs/loading-page-CQ0mKER2.es.js +15 -0
- package/assets/lottiejs/loading-table-B4T3FYiI.system.js +1 -0
- package/assets/lottiejs/loading-table-BnpbX8Ew.es.js +15 -0
- package/assets/lottiejs/no-data-CMWnya_k.system.js +1 -0
- package/{no-data-DLHO1L_u.js → assets/lottiejs/no-data-DOy8kIGF.es.js} +13 -2
- package/components/animation/Animation-6756VN9N.system.js +1 -0
- package/components/animation/Animation-COWVilAA.es.js +428 -0
- package/components/approverinfo/ApproverInfo-BdqBpNjY.system.js +1 -0
- package/components/approverinfo/ApproverInfo-C3_ibV8c.es.js +321 -0
- package/components/assetinfo/AssetInfo-BBgKToRP.system.js +1 -0
- package/components/assetinfo/AssetInfo-CmwgOU74.es.js +298 -0
- package/components/backgroundimagecropper/BackgroundImageCropper-DFHtaSyE.system.js +1 -0
- package/components/backgroundimagecropper/BackgroundImageCropper-HKzUEXq-.es.js +57 -0
- package/components/badge/Badge-CndPv5v9.system.js +1 -0
- package/components/badge/Badge-DA-XiE1C.es.js +115 -0
- package/components/badgegroup/BadgeGroup-Bj0EjoML.es.js +68 -0
- package/components/badgegroup/BadgeGroup-Y-HhiHk8.system.js +1 -0
- package/components/basecalendar/BaseCalendar-47ahYXrt.es.js +867 -0
- package/components/basecalendar/BaseCalendar-Ce46jOkg.system.js +1 -0
- package/components/basetree/BaseTree-DDu1qI7t.system.js +1 -0
- package/components/basetree/BaseTree-DLSA5FMh.es.js +167 -0
- package/components/breadcrumb/Breadcrumb-B5bAijry.system.js +1 -0
- package/components/breadcrumb/Breadcrumb-BWSmLPqn.es.js +46 -0
- package/components/button/Button-D-MSv_AS.es.js +120 -0
- package/components/button/Button-Okx1_kOu.system.js +1 -0
- package/components/buttonbulkaction/ButtonBulkAction-B4RcdWmb.es.js +185 -0
- package/components/buttonbulkaction/ButtonBulkAction-DLmvicRL.system.js +1 -0
- package/components/buttoncopy/ButtonCopy-BZgQAFOM.es.js +31 -0
- package/components/buttoncopy/ButtonCopy-CKi1bBpz.system.js +1 -0
- package/components/buttondownload/ButtonDownload-Bw9T3mbW.es.js +92 -0
- package/components/buttondownload/ButtonDownload-CpA0ryUT.system.js +1 -0
- package/components/buttonfilter/ButtonFilter-BIE-jM2i.es.js +28 -0
- package/components/buttonfilter/ButtonFilter-C4WRvUrj.system.js +1 -0
- package/components/buttonradio/ButtonRadio-5VUY8o5h.es.js +83 -0
- package/components/buttonradio/ButtonRadio-B2wWrgB5.system.js +1 -0
- package/components/buttonscan/ButtonScan-BCScT2cx.es.js +421 -0
- package/components/buttonscan/ButtonScan-TbyhlW5M.system.js +1 -0
- package/components/buttonsearch/ButtonSearch-Clbafqts.es.js +70 -0
- package/components/buttonsearch/ButtonSearch-e57pD5r3.system.js +1 -0
- package/components/buttonselecttree/ButtonSelectTree-B-_Iw5sB.es.js +218 -0
- package/components/buttonselecttree/ButtonSelectTree-Cbq1oeVK.system.js +1 -0
- package/components/buttonselectuser/ButtonSelectUser-Ar7Y8tVR.es.js +101 -0
- package/components/buttonselectuser/ButtonSelectUser-Cfe6m75Z.system.js +1 -0
- package/components/buttonsync/ButtonSync-Bc1GZXT6.es.js +29 -0
- package/components/buttonsync/ButtonSync-ClllEdAy.system.js +1 -0
- package/components/buttontoggle/ButtonToggle-DIy3M8Pz.es.js +11 -0
- package/components/buttontoggle/ButtonToggle-VNp0lbcW.system.js +1 -0
- package/components/buttonviewlog/ButtonViewLog-Ct8QwEey.system.js +1 -0
- package/components/buttonviewlog/ButtonViewLog-h9uVv5A5.es.js +21 -0
- package/components/calendar/Calendar-7yBKZsvj.system.js +1 -0
- package/components/calendar/Calendar-Df6CnW-l.es.js +112 -0
- package/components/card/Card-BUKU2FcT.system.js +1 -0
- package/components/card/Card-CwnxKNdM.es.js +47 -0
- package/components/checkbox/Checkbox-CCtItmVW.system.js +1 -0
- package/components/checkbox/Checkbox-DdsR222S.es.js +135 -0
- package/components/codesnippet/CodeSnippet-Bpps-Iyc.es.js +127 -0
- package/components/codesnippet/CodeSnippet-DvTtZ28b.system.js +2 -0
- package/components/codesnippetadapter/CodeSnippetAdapter-BtSqWBl1.system.js +1 -0
- package/components/codesnippetadapter/CodeSnippetAdapter-jgXoPKzr.es.js +26 -0
- package/components/columnlist/ColumnList-Bh3LZlOa.system.js +1 -0
- package/components/columnlist/ColumnList-Bp7soiys.es.js +204 -0
- package/components/customcolumn/CustomColumn-CVhAbTGn.system.js +1 -0
- package/components/customcolumn/CustomColumn-Dblxjw_0.es.js +138 -0
- package/components/datatable/DataTable--mHUKNUr.system.js +1 -0
- package/components/datatable/DataTable-J1j-OKsW.es.js +983 -0
- package/components/dialog/Dialog-Dy93f91f.es.js +121 -0
- package/components/dialog/Dialog-WEl66uTI.system.js +1 -0
- package/components/dialogconfirm/DialogConfirm-BOFb7rJD.es.js +139 -0
- package/components/dialogconfirm/DialogConfirm-o7_v7F31.system.js +1 -0
- package/components/dialogform/DialogForm-C15nC1wH.es.js +223 -0
- package/components/dialogform/DialogForm-CdpY1_-F.system.js +1 -0
- package/components/dialogselecttree/DialogSelectTree-BA8xEqco.es.js +268 -0
- package/components/dialogselecttree/DialogSelectTree-DKxWI9Re.system.js +1 -0
- package/components/dialogselectuser/DialogSelectUser-BZTSktHZ.system.js +1 -0
- package/components/dialogselectuser/DialogSelectUser-Bu5TDAPt.es.js +186 -0
- package/components/dialogselectuserfilter/DialogSelectUserFilter-DEl4zFaX.system.js +1 -0
- package/components/dialogselectuserfilter/DialogSelectUserFilter-Dz5OxAU-.es.js +40 -0
- package/components/dropdown/Dropdown-D4S52rW5.es.js +252 -0
- package/components/dropdown/Dropdown-DuvNYyq0.system.js +1 -0
- package/components/editor/Editor-DQ7Xdy30.es.js +1036 -0
- package/components/editor/Editor-IfYw2Tps.system.js +1 -0
- package/components/editorbutton/EditorButton-DDgS2vga.es.js +28 -0
- package/components/editorbutton/EditorButton-DmVrr4Bk.system.js +1 -0
- package/components/fieldwrapper/FieldWrapper-C6HJ2HnC.es.js +34 -0
- package/components/fieldwrapper/FieldWrapper-DFjw9hA8.system.js +1 -0
- package/components/fileupload/FileUpload-B6PAucnD.es.js +175 -0
- package/components/fileupload/FileUpload-iVAJXujV.system.js +1 -0
- package/components/filtercontainer/FilterContainer-CuMaq5Sv.es.js +284 -0
- package/components/filtercontainer/FilterContainer-DUeVLHgZ.system.js +1 -0
- package/components/form/Form-D-e0VI8V.system.js +1 -0
- package/components/form/Form-eSj-nb1y.es.js +181 -0
- package/components/hardwaresync/HardwareSync--HomfQuH.system.js +1 -0
- package/components/hardwaresync/HardwareSync-DUsVwHx1.es.js +236 -0
- package/components/icon/Icon-DUylRmY4.system.js +1 -0
- package/components/icon/Icon-mDqG7urn.es.js +82 -0
- package/components/image/Image-BZ31CL-y.es.js +169 -0
- package/components/image/Image-DX6uB7Ns.system.js +1 -0
- package/components/imagecompressor/ImageCompressor-BLeJDvN3.system.js +1 -0
- package/components/imagecompressor/ImageCompressor-DaW0ak9c.es.js +501 -0
- package/components/imageinputinfo/ImageInputInfo-C5F14hbF.system.js +1 -0
- package/components/imageinputinfo/ImageInputInfo-oTtVBxzO.es.js +46 -0
- package/components/inlinemessage/InlineMessage-19w6FOcP.system.js +1 -0
- package/components/inlinemessage/InlineMessage-CBZT3jWS.es.js +94 -0
- package/components/inputbadge/InputBadge-CsdT7M7-.es.js +186 -0
- package/components/inputbadge/InputBadge-dgANMV70.system.js +1 -0
- package/components/inputcurrency/InputCurrency-B96npK8W.es.js +1208 -0
- package/components/inputcurrency/InputCurrency-ChqGX5L8.system.js +1 -0
- package/components/inputemail/InputEmail-BMzumenA.es.js +49 -0
- package/components/inputemail/InputEmail-CYILS9bp.system.js +1 -0
- package/components/inputgroup/InputGroup-G9TEI4vX.system.js +1 -0
- package/components/inputgroup/InputGroup-eNDRlJ5R.es.js +56 -0
- package/components/inputnumber/InputNumber-Bzk_YzWM.es.js +232 -0
- package/components/inputnumber/InputNumber-CRyg8Xw_.system.js +1 -0
- package/components/inputpassword/InputPassword-BMHMWLgU.es.js +121 -0
- package/components/inputpassword/InputPassword-BjB6FsoL.system.js +1 -0
- package/components/inputphonenumber/InputPhoneNumber-CVM2oK5q.es.js +591 -0
- package/components/inputphonenumber/InputPhoneNumber-DIbd3upL.system.js +1 -0
- package/components/inputrangenumber/InputRangeNumber-B1aAoKVj.es.js +134 -0
- package/components/inputrangenumber/InputRangeNumber-C28xgFBY.system.js +1 -0
- package/components/inputsearch/InputSearch--KHwTBTm.system.js +1 -0
- package/components/inputsearch/InputSearch-cPq3vqhy.es.js +53 -0
- package/components/inputtext/InputText-93zDNfC3.system.js +1 -0
- package/components/inputtext/InputText-_xEnXysf.es.js +241 -0
- package/components/inputurl/InputURL-aqx1PVKL.es.js +61 -0
- package/components/inputurl/InputURL-kWIiKGEG.system.js +1 -0
- package/components/invisiblefield/InvisibleField-4XbiOrqw.es.js +27 -0
- package/components/invisiblefield/InvisibleField-BHudtX2g.system.js +1 -0
- package/components/litedropdown/LiteDropdown-3KsCx4wX.system.js +1 -0
- package/components/litedropdown/LiteDropdown-DcSzP11l.es.js +102 -0
- package/components/loading/Loading-D8M801C9.es.js +24 -0
- package/components/loading/Loading-Diwog8dc.system.js +1 -0
- package/components/mentionlist/MentionList--7AymnhE.es.js +58 -0
- package/components/mentionlist/MentionList-600dsWhX.system.js +1 -0
- package/components/mentionsection/MentionSection-C1gWOzH2.system.js +3 -0
- package/components/mentionsection/MentionSection-C_c4qbpq.es.js +52 -0
- package/components/menu/Menu-BmTMFwBD.es.js +73 -0
- package/components/menu/Menu-OR25pAK3.system.js +1 -0
- package/components/menuitem/MenuItem-LoZMc0T9.es.js +65 -0
- package/components/menuitem/MenuItem-imQ-hYTP.system.js +1 -0
- package/components/multirow/MultiRow-ClSMxrEx.es.js +52 -0
- package/components/multirow/MultiRow-DKu6uIsI.system.js +1 -0
- package/components/multiselect/MultiSelect-DGhS1EyX.es.js +189 -0
- package/components/multiselect/MultiSelect-DKFYq47E.system.js +1 -0
- package/components/overlaypanel/OverlayPanel-C_WCcNPw.system.js +1 -0
- package/components/overlaypanel/OverlayPanel-DXNek7Yb.es.js +49 -0
- package/components/tabmenu/TabMenu-CAQqu-ff.system.js +1 -0
- package/components/tabmenu/TabMenu-iMeZa8gy.es.js +108 -0
- package/components/tagtype/TagType-CX7BVRrE.es.js +49 -0
- package/components/tagtype/TagType-IMYg8AJf.system.js +1 -0
- package/components/textarea/Textarea-ClnQ2qmf.es.js +108 -0
- package/components/textarea/Textarea-DlkzVURV.system.js +1 -0
- package/components/timeline/Timeline-BMRdV_mH.es.js +120 -0
- package/components/timeline/Timeline-D7SYc3QX.system.js +1 -0
- package/components/timelinecontentbytype/TimelineContentByType-BmWsZID0.system.js +1 -0
- package/components/timelinecontentbytype/TimelineContentByType-ehFLzTA1.es.js +111 -0
- package/components/toast/Toast-DnALWJkx.es.js +74 -0
- package/components/toast/Toast-Pc_DOZ5-.system.js +1 -0
- package/components/toggleswitch/ToggleSwitch-WHdD3oYL.system.js +1 -0
- package/components/toggleswitch/ToggleSwitch-wRjnHRIw.es.js +90 -0
- package/components/transactionroles/TransactionRoles-B_67h5wb.es.js +223 -0
- package/components/transactionroles/TransactionRoles-DSXBVwPM.system.js +1 -0
- package/components/tree/Tree-BoVGYw5N.system.js +1 -0
- package/components/tree/Tree-DnaIZZ8S.es.js +268 -0
- package/components/treenode/TreeNode-D5aepDIU.system.js +1 -0
- package/components/treenode/TreeNode-KJOUvlTH.es.js +499 -0
- package/components/treesearchinput/TreeSearchInput-B1PmhE7k.es.js +56 -0
- package/components/treesearchinput/TreeSearchInput-C-hXPV61.system.js +1 -0
- package/components/username/UserName-CCyPAYG6.system.js +1 -0
- package/components/username/UserName-CWs83BX6.es.js +130 -0
- package/components/userwithicon/UserWithIcon-CFjQcbAS.system.js +1 -0
- package/components/userwithicon/UserWithIcon-Dn3aNKdq.es.js +18 -0
- package/components/validatormessage/ValidatorMessage-BtKfBXzO.es.js +19 -0
- package/components/validatormessage/ValidatorMessage-VVfyqlRF.system.js +1 -0
- package/package.json +1 -1
- package/stats.html +1 -1
- package/style.css +1 -1
- package/utils/date.util.d.ts +5 -1
- package/vendor/@popperjs/core-BDAJHTVh.es.js +905 -0
- package/vendor/@popperjs/core-DpNOCyB0.system.js +1 -0
- package/vendor/@tiptap/core-BLz8iRA3.es.js +2868 -0
- package/vendor/@tiptap/core-bnIgGWIt.system.js +80 -0
- package/vendor/@tiptap/extension-bold-BnsTNqIJ.es.js +71 -0
- package/vendor/@tiptap/extension-bold-C_KVm_D0.system.js +1 -0
- package/vendor/@tiptap/extension-bubble-menu-D421L1EU.system.js +1 -0
- package/vendor/@tiptap/extension-bubble-menu-D9Vgq7yO.es.js +128 -0
- package/vendor/@tiptap/extension-bullet-list-GNj3sKw9.es.js +53 -0
- package/vendor/@tiptap/extension-bullet-list-kXXFF-_p.system.js +1 -0
- package/vendor/@tiptap/extension-code-CfQ7g1i2.es.js +51 -0
- package/vendor/@tiptap/extension-code-Q8P1EHjz.system.js +1 -0
- package/vendor/@tiptap/extension-floating-menu-8rFSweor.system.js +1 -0
- package/vendor/@tiptap/extension-floating-menu-CSQuJzDM.es.js +99 -0
- package/vendor/@tiptap/extension-heading-BE64-Rg_.system.js +1 -0
- package/vendor/@tiptap/extension-heading-ZTlCgdtc.es.js +54 -0
- package/vendor/@tiptap/extension-history-GLkLmX-Y.system.js +1 -0
- package/vendor/@tiptap/extension-history-eJIThEn-.es.js +35 -0
- package/vendor/@tiptap/extension-image-B8NPUVFM.es.js +64 -0
- package/vendor/@tiptap/extension-image-rKrdkZpJ.system.js +1 -0
- package/vendor/@tiptap/extension-italic-C_CyJubw.es.js +70 -0
- package/vendor/@tiptap/extension-italic-Dg0Nosoc.system.js +1 -0
- package/vendor/@tiptap/extension-link-Cd8bTMBz.system.js +1 -0
- package/vendor/@tiptap/extension-link-D4PFdLvA.es.js +262 -0
- package/vendor/@tiptap/extension-list-item-7pIJ7t09.es.js +33 -0
- package/vendor/@tiptap/extension-list-item-Mnhfw2gP.system.js +1 -0
- package/vendor/@tiptap/extension-mention-DVF3rX_z.system.js +1 -0
- package/vendor/@tiptap/extension-mention-Dkg-tbrz.es.js +130 -0
- package/vendor/@tiptap/extension-ordered-list-DLI4xDN8.es.js +71 -0
- package/vendor/@tiptap/extension-ordered-list-Hl0QU8Zt.system.js +1 -0
- package/vendor/@tiptap/extension-placeholder-BeLl2T-f.system.js +1 -0
- package/vendor/@tiptap/extension-placeholder-V0iTxU19.es.js +52 -0
- package/vendor/@tiptap/extension-underline-BdcAQ4JH.system.js +1 -0
- package/vendor/@tiptap/extension-underline-DsGbvz80.es.js +40 -0
- package/vendor/@tiptap/suggestion-BpZSO8Lm.system.js +1 -0
- package/vendor/@tiptap/suggestion-C4sBhJAD.es.js +131 -0
- package/vendor/@tiptap/vue-3-BH1pZykd.system.js +1 -0
- package/vendor/@tiptap/vue-3-DceiR7pK.es.js +436 -0
- package/vendor/highlight.js-BAruEf1H.system.js +2 -0
- package/vendor/highlight.js-DHowhWoU.es.js +2493 -0
- package/vendor/linkifyjs-BxsOjwQz.es.js +705 -0
- package/vendor/linkifyjs-CMLfIa6I.system.js +5 -0
- package/vendor/lodash-DbIT-6qv.es.js +127 -0
- package/vendor/lodash-DbvKLWSv.system.js +1 -0
- package/vendor/lodash-es-C3G1Cc1m.system.js +1 -0
- package/vendor/lodash-es-CJerBxJQ.es.js +766 -0
- package/vendor/orderedmap-B3SOk52B.es.js +103 -0
- package/vendor/orderedmap-Dwr31MF0.system.js +1 -0
- package/vendor/primevue-CadmDhWp.es.js +13928 -0
- package/vendor/primevue-u6FsQONA.system.js +193 -0
- package/vendor/prosemirror-commands-DLmzIpoS.es.js +383 -0
- package/vendor/prosemirror-commands-DgY3QRzI.system.js +2 -0
- package/vendor/prosemirror-history-BMpJFORS.es.js +248 -0
- package/vendor/prosemirror-history-BrK-FTBv.system.js +1 -0
- package/vendor/prosemirror-keymap-COb3Dq2o.system.js +1 -0
- package/vendor/prosemirror-keymap-DF8LLxca.es.js +60 -0
- package/vendor/prosemirror-model-D2n-Dx_L.es.js +2736 -0
- package/vendor/prosemirror-model-DTWK5xnv.system.js +4 -0
- package/vendor/prosemirror-schema-list-BPpAP8wR.system.js +1 -0
- package/vendor/prosemirror-schema-list-BvrICwYb.es.js +87 -0
- package/vendor/prosemirror-state-CwkYUmNs.es.js +820 -0
- package/vendor/prosemirror-state-DzPLD-6l.system.js +1 -0
- package/vendor/prosemirror-transform-DvAmofec.es.js +1507 -0
- package/vendor/prosemirror-transform-VaXuT0NM.system.js +2 -0
- package/vendor/prosemirror-view-JTdpiWMD.system.js +5 -0
- package/vendor/prosemirror-view-ta7l3rKk.es.js +3742 -0
- package/vendor/rope-sequence-4t46C6az.system.js +1 -0
- package/vendor/rope-sequence-sEGCUMi8.es.js +100 -0
- package/vendor/simplebar-core-71xT5g0m.system.js +1 -0
- package/vendor/simplebar-core-Db65-Ath.es.js +333 -0
- package/vendor/simplebar-vue-BFEeFUIv.system.js +1 -0
- package/vendor/simplebar-vue-DAxqu0eM.es.js +176 -0
- package/vendor/tippy.js-CuKTz0UR.system.js +1 -0
- package/vendor/tippy.js-DNnwm2RY.es.js +721 -0
- package/vendor/uuid-93tp0umt.es.js +9 -0
- package/vendor/uuid-Cymn6orr.system.js +1 -0
- package/vendor/vee-validate-Cc_B-qII.system.js +5 -0
- package/vendor/vee-validate-RE5RuswC.es.js +1309 -0
- package/vendor/vue-advanced-cropper-CshlvNaD.es.js +1380 -0
- package/vendor/vue-advanced-cropper-NG93jHnU.system.js +20 -0
- package/vendor/w3c-keyname-BSD-PgAi.system.js +1 -0
- package/vendor/w3c-keyname-CLxH8j-f.es.js +92 -0
- package/wangsvue-fats.js +542 -0
- package/wangsvue-fats.system.js +1 -313
- package/loading-page-BrQattYE.js +0 -1
- package/loading-page-CoC9UhfC.js +0 -4
- package/loading-page-DbLuqCHa.js +0 -1
- package/loading-page-f8D03l3G.js +0 -4
- package/loading-plane-CgfbWppy.js +0 -1
- package/loading-plane-CoXtqoc9.js +0 -4
- package/loading-table-Bdr9ZhtP.js +0 -1
- package/loading-table-ByUoWqUo.js +0 -4
- package/loading-table-BygEMzFM.js +0 -4
- package/loading-table-BzrSQlA0.js +0 -1
- package/loading-table-D9bw9OcI.js +0 -4
- package/loading-table-chOgXi94.js +0 -1
- package/no-data-CTKux8RI.js +0 -4
- package/no-data-Cgze_Rvp.js +0 -1
- package/no-data-Dep79CBh.js +0 -1
- package/no-data-g0dJCy2p.js +0 -4
- package/no-data-y1X5WtcQ.js +0 -1
- package/wangsvue-fats.es.js +0 -51893
- /package/{loading-page-CgfbWppy.js → assets/lottiejs/loading-plane-CgfbWppy.system.js} +0 -0
- /package/{loading-page-CoXtqoc9.js → assets/lottiejs/loading-plane-CoXtqoc9.es.js} +0 -0
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
import { defineComponent as ne, onMounted as ie, ref as y, inject as ue, shallowRef as m, provide as fe, createElementBlock as L, openBlock as i, mergeProps as o, unref as a, withModifiers as me, createElementVNode as k, createCommentVNode as d, renderSlot as de, normalizeProps as X, createVNode as Y, withDirectives as ve, vShow as ce, guardReactiveProps as be, createBlock as S } from "vue";
|
|
2
|
+
import { a as pe } from "../../vendor/vee-validate-RE5RuswC.es.js";
|
|
3
|
+
import { _ as B } from "../button/Button-D-MSv_AS.es.js";
|
|
4
|
+
import { _ as ye } from "../checkbox/Checkbox-DdsR222S.es.js";
|
|
5
|
+
import { _ as ke } from "../validatormessage/ValidatorMessage-BtKfBXzO.es.js";
|
|
6
|
+
const Ce = /* @__PURE__ */ ne({
|
|
7
|
+
__name: "Form",
|
|
8
|
+
props: {
|
|
9
|
+
buttonsTemplate: {},
|
|
10
|
+
disableSubmit: { type: Boolean },
|
|
11
|
+
cancelBtnLabel: { default: "Batal" },
|
|
12
|
+
clearBtnLabel: { default: "Bersihkan Field" },
|
|
13
|
+
columnPerRow: {},
|
|
14
|
+
hideFooter: { type: Boolean },
|
|
15
|
+
hideStayCheckbox: { type: Boolean },
|
|
16
|
+
invalid: { type: Boolean },
|
|
17
|
+
resetAfterSubmit: { type: Boolean, default: !0 },
|
|
18
|
+
saveBtnLabel: { default: "Simpan" },
|
|
19
|
+
submitBtnLabel: { default: "Simpan" },
|
|
20
|
+
stayCheckboxLabel: { default: "Tetap di halaman ini" },
|
|
21
|
+
validatorMessage: { default: "Please input all required field!" },
|
|
22
|
+
validateOnSave: { type: Boolean, default: !1 },
|
|
23
|
+
cancelBtnSeverity: { default: "secondary" },
|
|
24
|
+
saveBtnSeverity: { default: "success" },
|
|
25
|
+
submitBtnSeverity: { default: "success" }
|
|
26
|
+
},
|
|
27
|
+
emits: ["cancel", "clear", "save", "submit"],
|
|
28
|
+
setup(Z, { expose: x, emit: _ }) {
|
|
29
|
+
const s = Z, b = _;
|
|
30
|
+
ie(() => {
|
|
31
|
+
if (F.value) {
|
|
32
|
+
const e = s.columnPerRow ?? 1;
|
|
33
|
+
F.value.style.gridTemplateColumns = `repeat(${e}, minmax(0, 1fr))`, A();
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
const l = ue("preset", {}).form, {
|
|
37
|
+
handleSubmit: ee,
|
|
38
|
+
values: V,
|
|
39
|
+
resetForm: $,
|
|
40
|
+
errors: te,
|
|
41
|
+
resetField: ae,
|
|
42
|
+
setValues: le,
|
|
43
|
+
setFieldValue: se,
|
|
44
|
+
setErrors: oe
|
|
45
|
+
} = pe(), v = m(!1), P = y(), r = m(!1), T = m(!1), g = m(0), h = y(), u = m(!1), C = m(!1), F = y(null), w = y(null);
|
|
46
|
+
fe("isSubmitting", u);
|
|
47
|
+
const A = () => {
|
|
48
|
+
var e;
|
|
49
|
+
if (h.value) {
|
|
50
|
+
const t = (e = h.value) == null ? void 0 : e.offsetHeight;
|
|
51
|
+
w.value && (w.value.style.height = `calc(100% + ${t + 20}px)`);
|
|
52
|
+
}
|
|
53
|
+
}, E = () => {
|
|
54
|
+
u.value = !0, T.value || (r.value = !0);
|
|
55
|
+
}, W = () => {
|
|
56
|
+
u.value = !0, C.value = !0, s.validateOnSave ? (T.value || (r.value = !0), p()) : re();
|
|
57
|
+
}, p = ee(
|
|
58
|
+
(e) => {
|
|
59
|
+
if (!s.invalid) {
|
|
60
|
+
const t = O(e), n = {
|
|
61
|
+
stayAfterSubmit: v.value,
|
|
62
|
+
formValues: t
|
|
63
|
+
};
|
|
64
|
+
C.value ? b("save", n) : b("submit", n), r.value = !1, C.value = !1, s.resetAfterSubmit && (g.value += 1, $());
|
|
65
|
+
}
|
|
66
|
+
u.value = !1;
|
|
67
|
+
},
|
|
68
|
+
() => {
|
|
69
|
+
u.value = !1;
|
|
70
|
+
}
|
|
71
|
+
), re = () => {
|
|
72
|
+
const e = O(V), t = {
|
|
73
|
+
stayAfterSubmit: v.value,
|
|
74
|
+
formValues: e
|
|
75
|
+
};
|
|
76
|
+
b("save", t), u.value = !1;
|
|
77
|
+
}, M = () => {
|
|
78
|
+
$(), g.value++, b("clear"), r.value = !1;
|
|
79
|
+
}, O = (e) => {
|
|
80
|
+
const t = e, n = Object.keys(t);
|
|
81
|
+
for (const f of n)
|
|
82
|
+
typeof t[f] == "string" && (t[f] = t[f].trim());
|
|
83
|
+
return t;
|
|
84
|
+
};
|
|
85
|
+
return x({
|
|
86
|
+
stayAfterSubmit: v,
|
|
87
|
+
submit: p,
|
|
88
|
+
onSubmitClicked: E,
|
|
89
|
+
onSaveClicked: W,
|
|
90
|
+
showValidator: r,
|
|
91
|
+
formElement: P,
|
|
92
|
+
clearField: M,
|
|
93
|
+
resetField: ae,
|
|
94
|
+
errors: te,
|
|
95
|
+
setOuterFieldsWrapperHeight: A,
|
|
96
|
+
setValues: le,
|
|
97
|
+
setFieldValue: se,
|
|
98
|
+
setErrors: oe,
|
|
99
|
+
values: V
|
|
100
|
+
}), (e, t) => {
|
|
101
|
+
var n, f, R, H, N, j, q, z, D, I, K, U, G, J, Q;
|
|
102
|
+
return i(), L("form", o({
|
|
103
|
+
ref_key: "formElement",
|
|
104
|
+
ref: P
|
|
105
|
+
}, (n = a(l)) == null ? void 0 : n.root({ props: s }), {
|
|
106
|
+
onInput: t[2] || (t[2] = (c) => r.value = !1),
|
|
107
|
+
onSubmit: t[3] || (t[3] = me(
|
|
108
|
+
//@ts-ignore
|
|
109
|
+
(...c) => a(p) && a(p)(...c),
|
|
110
|
+
["prevent"]
|
|
111
|
+
))
|
|
112
|
+
}), [
|
|
113
|
+
k("div", {
|
|
114
|
+
ref_key: "outerFieldsWrapper",
|
|
115
|
+
ref: w
|
|
116
|
+
}, [
|
|
117
|
+
k("div", o({
|
|
118
|
+
ref_key: "fieldsWrapper",
|
|
119
|
+
ref: F
|
|
120
|
+
}, (f = a(l)) == null ? void 0 : f["fields-wrapper"]), [
|
|
121
|
+
de(e.$slots, "fields", {
|
|
122
|
+
key: g.value,
|
|
123
|
+
formValues: a(V)
|
|
124
|
+
})
|
|
125
|
+
], 16)
|
|
126
|
+
], 512),
|
|
127
|
+
e.hideFooter ? d("", !0) : (i(), L("div", o({
|
|
128
|
+
key: 0,
|
|
129
|
+
ref_key: "footer",
|
|
130
|
+
ref: h
|
|
131
|
+
}, (R = a(l)) == null ? void 0 : R.footer), [
|
|
132
|
+
e.hideStayCheckbox ? d("", !0) : (i(), L("div", X(o({ key: 0 }, (H = a(l)) == null ? void 0 : H.staycheckbox)), [
|
|
133
|
+
Y(ye, {
|
|
134
|
+
modelValue: v.value,
|
|
135
|
+
"onUpdate:modelValue": t[0] || (t[0] = (c) => v.value = c),
|
|
136
|
+
label: e.stayCheckboxLabel
|
|
137
|
+
}, null, 8, ["modelValue", "label"])
|
|
138
|
+
], 16)),
|
|
139
|
+
k("div", o({ id: "footer-actions-wrapper" }, (N = a(l)) == null ? void 0 : N["action-buttons"]), [
|
|
140
|
+
ve(Y(ke, o((j = a(l)) == null ? void 0 : j["validator-message"], { message: e.validatorMessage }), null, 16, ["message"]), [
|
|
141
|
+
[ce, r.value || s.invalid]
|
|
142
|
+
]),
|
|
143
|
+
k("div", X(be((q = a(l)) == null ? void 0 : q["button-wrapper"])), [
|
|
144
|
+
(z = s.buttonsTemplate) != null && z.includes("cancel") ? (i(), S(B, o({ key: 0 }, (D = a(l)) == null ? void 0 : D["cancel-button"], {
|
|
145
|
+
label: e.cancelBtnLabel,
|
|
146
|
+
severity: e.cancelBtnSeverity,
|
|
147
|
+
onClick: t[1] || (t[1] = (c) => e.$emit("cancel")),
|
|
148
|
+
"data-test": "cancel-button",
|
|
149
|
+
text: "",
|
|
150
|
+
type: "button"
|
|
151
|
+
}), null, 16, ["label", "severity"])) : d("", !0),
|
|
152
|
+
(I = s.buttonsTemplate) != null && I.includes("clear") ? (i(), S(B, o({ key: 1 }, (K = a(l)) == null ? void 0 : K["clear-button"], {
|
|
153
|
+
label: e.clearBtnLabel,
|
|
154
|
+
onClick: M,
|
|
155
|
+
text: "",
|
|
156
|
+
type: "button"
|
|
157
|
+
}), null, 16, ["label"])) : d("", !0),
|
|
158
|
+
(U = s.buttonsTemplate) != null && U.includes("save") ? (i(), S(B, o({ key: 2 }, (G = a(l)) == null ? void 0 : G["save-button"], {
|
|
159
|
+
label: e.saveBtnLabel,
|
|
160
|
+
severity: e.saveBtnSeverity,
|
|
161
|
+
onClick: W,
|
|
162
|
+
outlined: "",
|
|
163
|
+
type: "button"
|
|
164
|
+
}), null, 16, ["label", "severity"])) : d("", !0),
|
|
165
|
+
(J = s.buttonsTemplate) != null && J.includes("submit") ? (i(), S(B, o({ key: 3 }, (Q = a(l)) == null ? void 0 : Q["submit-button"], {
|
|
166
|
+
disabled: e.disableSubmit,
|
|
167
|
+
label: e.submitBtnLabel,
|
|
168
|
+
severity: e.submitBtnSeverity,
|
|
169
|
+
onClick: E,
|
|
170
|
+
type: "submit"
|
|
171
|
+
}), null, 16, ["disabled", "label", "severity"])) : d("", !0)
|
|
172
|
+
], 16)
|
|
173
|
+
], 16)
|
|
174
|
+
], 16))
|
|
175
|
+
], 16);
|
|
176
|
+
};
|
|
177
|
+
}
|
|
178
|
+
});
|
|
179
|
+
export {
|
|
180
|
+
Ce as _
|
|
181
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
System.register(["vue","../assetinfo/AssetInfo-BBgKToRP.system.js","../buttonscan/ButtonScan-TbyhlW5M.system.js","../button/Button-Okx1_kOu.system.js","../dialog/Dialog-WEl66uTI.system.js","../dropdown/Dropdown-DuvNYyq0.system.js","../icon/Icon-DUylRmY4.system.js","../inlinemessage/InlineMessage-19w6FOcP.system.js"],function(X,pe){"use strict";var V,O,r,d,F,M,f,m,j,C,y,g,E,k,x,$,W,P,U,Q,z,S,H,B,Y,A;return{setters:[e=>{V=e.defineComponent,O=e.onMounted,r=e.shallowRef,d=e.computed,F=e.ref,M=e.watch,f=e.createBlock,m=e.openBlock,j=e.createSlots,C=e.withCtx,y=e.createCommentVNode,g=e.createVNode,E=e.createElementVNode,k=e.normalizeClass,x=e.createElementBlock,$=e.Fragment,W=e.toDisplayString},e=>{P=e.u},e=>{U=e.u,Q=e.W,z=e.g},e=>{S=e._},e=>{H=e._},e=>{B=e._},e=>{Y=e._},e=>{A=e._}],execute:function(){const e=X("_",V({__name:"HardwareSync",props:{visible:{type:Boolean},errorCode:{},searchBy:{},bulk:{type:Boolean},withoutScanBtn:{type:Boolean}},emits:["update:visible","scan"],setup(ee,{emit:te}){const i=ee,L=te,ne=P();O(()=>{G()});const{device:I,devices:J,saveDevices:se,setDevice:ae,loadDevices:le}=U(),u={label:"None",device:void 0},p=r(!1),o=r(u),c=r(u),Z=s=>{var t,n;if((t=J.value)!=null&&t.length){const l=(n=J.value)==null?void 0:n.filter(a=>a[s]).map(a=>({label:`${a.name??a.jenisDevice+" - "+a.serialNumber}`,device:a}));return l.length?l:[]}return o.value=u,c.value=u,[]},b=d(()=>Z("rfidScan")),h=d(()=>Z("qrScan")),T=d(()=>i.errorCode==="NOT_SUPPORTED_SYSTEM"),oe=d(()=>i.searchBy==="RFID"&&o.value.device),re=d(()=>i.searchBy==="QR"&&c.value.device),w=d(()=>!!i.searchBy&&i.errorCode!=="HARDWARE_NOT_SYNCHRONIZED"),q=async s=>{try{se(s);const t=b.value.some(l=>{var a,D,N;return((a=l==null?void 0:l.device)==null?void 0:a.serialNumber)===((N=(D=o.value)==null?void 0:D.device)==null?void 0:N.serialNumber)}),n=h.value.some(l=>{var a,D,N;return((a=l==null?void 0:l.device)==null?void 0:a.serialNumber)===((N=(D=c.value)==null?void 0:D.device)==null?void 0:N.serialNumber)});o.value=t?o.value:b.value[0]??u,c.value=n?c.value:h.value[0]??u,_()}catch(t){v.value=R(z(t))}finally{p.value=!1}},v=F(),ie=r({title:"The detected OS is not compatible",detail:"Please check the OS compatibility list on our product information page."}),ce=r({title:"Scanner Disconnected",detail:"Your scanner has been disconnected. Please reconnect it or select another device from the list."}),ue=r({title:"Scanner driver not found",detail:"The scanner driver may not be running or installed correctly on your device. Please contact your administrator."}),ve=r({title:"Scanner not detected",detail:"The scanner is either not detected or not identified by our system."});r({title:"Scanner is not registered",detail:"The scanner is not registered in your company."});const R=s=>{switch(s??i.errorCode){case"DEVICE_NOT_CONNECTED":return ve.value;case"DRIVER_NOT_FOUND":return ue.value;case"NOT_SUPPORTED_SYSTEM":return ie.value;case"DEVICE_DISCONNECTED":return ce.value;default:return}},_=()=>{ae({RFID:o.value.device,QR:c.value.device})},G=()=>{le(),I.value.RFID?o.value={label:I.value.RFID.name,device:I.value.RFID}:b.value.length&&(o.value=b.value[0]??u),h.value.length&&(c.value=h.value[0]??u),_()},K=()=>{L("update:visible",!1),L("scan")},de=()=>{var s;p.value=!0,v.value=void 0,window.scannerWorker.onmessage=({data:t})=>{var n;if(t.status==="synced"){const l=((n=t==null?void 0:t.data)==null?void 0:n.deviceList)??[];q(l);const{error:a}=(t==null?void 0:t.data)??{};a==="Driver not connected to server"?(p.value=!1,v.value=R("DRIVER_NOT_FOUND")):l.length||(p.value=!1,v.value=R("DEVICE_NOT_CONNECTED"))}else t.status==="error_sync"&&(p.value=!1,q([]),ne.add({message:"Failed to connecting scanner",severity:"error"}))},window.scannerWorker.postMessage({command:"sync",userId:(s=JSON.parse(localStorage.getItem("user")??"{}"))==null?void 0:s._id})},me=()=>{window.scannerWorker??(window.scannerWorker=new Q)};return M(()=>i.visible,s=>{s&&(me(),v.value=R(),G(),p.value=!1)}),(s,t)=>(m(),f(H,{closable:!w.value,"header-class":[{"flex !gap-1 !items-center !justify-center !text-sm !font-bold !leading-[18px] tracking-[0.02em] [&>div]:hidden":w.value}],visible:s.visible,"onUpdate:visible":t[3]||(t[3]=n=>s.$emit("update:visible",n)),class:"w-[400px]","content-class":"!overflow-y-visible","footer-class":"!gap-1",header:"Hardware Synchronize",modal:""},j({footer:C(()=>[w.value?(m(),f(S,{key:0,onClick:t[2]||(t[2]=n=>s.$emit("update:visible",!1)),label:"Close",severity:"secondary",text:""})):y("",!0),T.value?y("",!0):(m(),x($,{key:1},[oe.value&&!i.withoutScanBtn?(m(),f(S,{key:0,onClick:K,icon:"rfid",label:"Scan RFID"})):y("",!0),re.value&&!i.withoutScanBtn?(m(),f(S,{key:1,onClick:K,icon:"qr",label:"Scan QR"})):y("",!0)],64))]),default:C(()=>[v.value?(m(),f(A,{key:0,class:k(["p-[9.52px] transition"]),message:v.value.detail,removable:!1,"show-icon":!1,title:v.value.title,"message-wrapper-class":"text-[11px] leading-[14px] tracking-[0.02em]",severity:"danger"},null,8,["message","title"])):y("",!0),g(S,{disabled:T.value,loading:p.value,onClick:de,icon:"refresh",label:"Sync","loading-icon":"refresh",outlined:""},null,8,["disabled","loading"]),E("section",{class:k(["grid grid-cols-2 gap-3 justify-start w-full",{"opacity-60 pointer-events-none":T.value}]),"data-ts-section":"scanner-list"},[g(B,{modelValue:o.value,"onUpdate:modelValue":[t[0]||(t[0]=n=>o.value=n),_],options:b.value,label:"RFID Scanner","option-label":"label"},null,8,["modelValue","options"]),g(B,{modelValue:c.value,"onUpdate:modelValue":[t[1]||(t[1]=n=>c.value=n),_],options:h.value,label:"QR Scanner","option-label":"label"},null,8,["modelValue","options"])],2)]),_:2},[w.value?{name:"header",fn:C(()=>{var n;return[g(Y,{icon:(n=s.searchBy)==null?void 0:n.toLowerCase()},null,8,["icon"]),E("h3",null,"Scan "+W(s.searchBy),1)]}),key:"0"}:void 0]),1032,["closable","header-class","visible"]))}}))}}});
|
|
@@ -0,0 +1,236 @@
|
|
|
1
|
+
import { defineComponent as G, onMounted as K, shallowRef as u, computed as d, ref as X, watch as ee, createBlock as g, openBlock as m, createSlots as ae, withCtx as E, createCommentVNode as b, createVNode as R, createElementVNode as V, normalizeClass as M, createElementBlock as ne, Fragment as te, toDisplayString as se } from "vue";
|
|
2
|
+
import { u as le } from "../assetinfo/AssetInfo-CmwgOU74.es.js";
|
|
3
|
+
import { u as oe, W as re, g as ie } from "../buttonscan/ButtonScan-BCScT2cx.es.js";
|
|
4
|
+
import { _ } from "../button/Button-D-MSv_AS.es.js";
|
|
5
|
+
import { _ as ce } from "../dialog/Dialog-Dy93f91f.es.js";
|
|
6
|
+
import { _ as $ } from "../dropdown/Dropdown-D4S52rW5.es.js";
|
|
7
|
+
import { _ as ue } from "../icon/Icon-mDqG7urn.es.js";
|
|
8
|
+
import { _ as ve } from "../inlinemessage/InlineMessage-CBZT3jWS.es.js";
|
|
9
|
+
const De = /* @__PURE__ */ G({
|
|
10
|
+
__name: "HardwareSync",
|
|
11
|
+
props: {
|
|
12
|
+
visible: { type: Boolean },
|
|
13
|
+
errorCode: {},
|
|
14
|
+
searchBy: {},
|
|
15
|
+
bulk: { type: Boolean },
|
|
16
|
+
withoutScanBtn: { type: Boolean }
|
|
17
|
+
},
|
|
18
|
+
emits: ["update:visible", "scan"],
|
|
19
|
+
setup(W, { emit: x }) {
|
|
20
|
+
const o = W, k = x, P = le();
|
|
21
|
+
K(() => {
|
|
22
|
+
O();
|
|
23
|
+
});
|
|
24
|
+
const {
|
|
25
|
+
device: C,
|
|
26
|
+
devices: I,
|
|
27
|
+
saveDevices: U,
|
|
28
|
+
setDevice: Q,
|
|
29
|
+
loadDevices: z
|
|
30
|
+
} = oe(), i = {
|
|
31
|
+
label: "None",
|
|
32
|
+
device: void 0
|
|
33
|
+
}, v = u(!1), l = u(i), r = u(i), T = (n) => {
|
|
34
|
+
var e, a;
|
|
35
|
+
if ((e = I.value) != null && e.length) {
|
|
36
|
+
const s = (a = I.value) == null ? void 0 : a.filter((t) => t[n]).map((t) => ({
|
|
37
|
+
label: `${t.name ?? t.jenisDevice + " - " + t.serialNumber}`,
|
|
38
|
+
device: t
|
|
39
|
+
}));
|
|
40
|
+
return s.length ? s : [];
|
|
41
|
+
}
|
|
42
|
+
return l.value = i, r.value = i, [];
|
|
43
|
+
}, p = d(() => T("rfidScan")), f = d(() => T("qrScan")), w = d(
|
|
44
|
+
() => o.errorCode === "NOT_SUPPORTED_SYSTEM"
|
|
45
|
+
), H = d(() => o.searchBy === "RFID" && l.value.device), Y = d(() => o.searchBy === "QR" && r.value.device), D = d(() => !!o.searchBy && o.errorCode !== "HARDWARE_NOT_SYNCHRONIZED"), B = async (n) => {
|
|
46
|
+
try {
|
|
47
|
+
U(n);
|
|
48
|
+
const e = p.value.some(
|
|
49
|
+
(s) => {
|
|
50
|
+
var t, y, S;
|
|
51
|
+
return ((t = s == null ? void 0 : s.device) == null ? void 0 : t.serialNumber) === ((S = (y = l.value) == null ? void 0 : y.device) == null ? void 0 : S.serialNumber);
|
|
52
|
+
}
|
|
53
|
+
), a = f.value.some(
|
|
54
|
+
(s) => {
|
|
55
|
+
var t, y, S;
|
|
56
|
+
return ((t = s == null ? void 0 : s.device) == null ? void 0 : t.serialNumber) === ((S = (y = r.value) == null ? void 0 : y.device) == null ? void 0 : S.serialNumber);
|
|
57
|
+
}
|
|
58
|
+
);
|
|
59
|
+
l.value = e ? l.value : p.value[0] ?? i, r.value = a ? r.value : f.value[0] ?? i, N();
|
|
60
|
+
} catch (e) {
|
|
61
|
+
c.value = h(ie(e));
|
|
62
|
+
} finally {
|
|
63
|
+
v.value = !1;
|
|
64
|
+
}
|
|
65
|
+
}, c = X(), j = u({
|
|
66
|
+
title: "The detected OS is not compatible",
|
|
67
|
+
detail: "Please check the OS compatibility list on our product information page."
|
|
68
|
+
}), L = u({
|
|
69
|
+
title: "Scanner Disconnected",
|
|
70
|
+
detail: "Your scanner has been disconnected. Please reconnect it or select another device from the list."
|
|
71
|
+
}), A = u({
|
|
72
|
+
title: "Scanner driver not found",
|
|
73
|
+
detail: "The scanner driver may not be running or installed correctly on your device. Please contact your administrator."
|
|
74
|
+
}), J = u({
|
|
75
|
+
title: "Scanner not detected",
|
|
76
|
+
detail: "The scanner is either not detected or not identified by our system."
|
|
77
|
+
});
|
|
78
|
+
u({
|
|
79
|
+
title: "Scanner is not registered",
|
|
80
|
+
detail: "The scanner is not registered in your company."
|
|
81
|
+
});
|
|
82
|
+
const h = (n) => {
|
|
83
|
+
switch (n ?? o.errorCode) {
|
|
84
|
+
case "DEVICE_NOT_CONNECTED":
|
|
85
|
+
return J.value;
|
|
86
|
+
case "DRIVER_NOT_FOUND":
|
|
87
|
+
return A.value;
|
|
88
|
+
case "NOT_SUPPORTED_SYSTEM":
|
|
89
|
+
return j.value;
|
|
90
|
+
case "DEVICE_DISCONNECTED":
|
|
91
|
+
return L.value;
|
|
92
|
+
default:
|
|
93
|
+
return;
|
|
94
|
+
}
|
|
95
|
+
}, N = () => {
|
|
96
|
+
Q({
|
|
97
|
+
RFID: l.value.device,
|
|
98
|
+
QR: r.value.device
|
|
99
|
+
});
|
|
100
|
+
}, O = () => {
|
|
101
|
+
z(), C.value.RFID ? l.value = {
|
|
102
|
+
label: C.value.RFID.name,
|
|
103
|
+
device: C.value.RFID
|
|
104
|
+
} : p.value.length && (l.value = p.value[0] ?? i), f.value.length && (r.value = f.value[0] ?? i), N();
|
|
105
|
+
}, F = () => {
|
|
106
|
+
k("update:visible", !1), k("scan");
|
|
107
|
+
}, Z = () => {
|
|
108
|
+
var n;
|
|
109
|
+
v.value = !0, c.value = void 0, window.scannerWorker.onmessage = ({ data: e }) => {
|
|
110
|
+
var a;
|
|
111
|
+
if (e.status === "synced") {
|
|
112
|
+
const s = ((a = e == null ? void 0 : e.data) == null ? void 0 : a.deviceList) ?? [];
|
|
113
|
+
B(s);
|
|
114
|
+
const { error: t } = (e == null ? void 0 : e.data) ?? {};
|
|
115
|
+
t === "Driver not connected to server" ? (v.value = !1, c.value = h("DRIVER_NOT_FOUND")) : s.length || (v.value = !1, c.value = h("DEVICE_NOT_CONNECTED"));
|
|
116
|
+
} else e.status === "error_sync" && (v.value = !1, B([]), P.add({ message: "Failed to connecting scanner", severity: "error" }));
|
|
117
|
+
}, window.scannerWorker.postMessage({
|
|
118
|
+
command: "sync",
|
|
119
|
+
userId: (n = JSON.parse(localStorage.getItem("user") ?? "{}")) == null ? void 0 : n._id
|
|
120
|
+
});
|
|
121
|
+
}, q = () => {
|
|
122
|
+
window.scannerWorker ?? (window.scannerWorker = new re());
|
|
123
|
+
};
|
|
124
|
+
return ee(
|
|
125
|
+
() => o.visible,
|
|
126
|
+
(n) => {
|
|
127
|
+
n && (q(), c.value = h(), O(), v.value = !1);
|
|
128
|
+
}
|
|
129
|
+
), (n, e) => (m(), g(ce, {
|
|
130
|
+
closable: !D.value,
|
|
131
|
+
"header-class": [
|
|
132
|
+
{
|
|
133
|
+
"flex !gap-1 !items-center !justify-center !text-sm !font-bold !leading-[18px] tracking-[0.02em] [&>div]:hidden": D.value
|
|
134
|
+
}
|
|
135
|
+
],
|
|
136
|
+
visible: n.visible,
|
|
137
|
+
"onUpdate:visible": e[3] || (e[3] = (a) => n.$emit("update:visible", a)),
|
|
138
|
+
class: "w-[400px]",
|
|
139
|
+
"content-class": "!overflow-y-visible",
|
|
140
|
+
"footer-class": "!gap-1",
|
|
141
|
+
header: "Hardware Synchronize",
|
|
142
|
+
modal: ""
|
|
143
|
+
}, ae({
|
|
144
|
+
footer: E(() => [
|
|
145
|
+
D.value ? (m(), g(_, {
|
|
146
|
+
key: 0,
|
|
147
|
+
onClick: e[2] || (e[2] = (a) => n.$emit("update:visible", !1)),
|
|
148
|
+
label: "Close",
|
|
149
|
+
severity: "secondary",
|
|
150
|
+
text: ""
|
|
151
|
+
})) : b("", !0),
|
|
152
|
+
w.value ? b("", !0) : (m(), ne(te, { key: 1 }, [
|
|
153
|
+
H.value && !o.withoutScanBtn ? (m(), g(_, {
|
|
154
|
+
key: 0,
|
|
155
|
+
onClick: F,
|
|
156
|
+
icon: "rfid",
|
|
157
|
+
label: "Scan RFID"
|
|
158
|
+
})) : b("", !0),
|
|
159
|
+
Y.value && !o.withoutScanBtn ? (m(), g(_, {
|
|
160
|
+
key: 1,
|
|
161
|
+
onClick: F,
|
|
162
|
+
icon: "qr",
|
|
163
|
+
label: "Scan QR"
|
|
164
|
+
})) : b("", !0)
|
|
165
|
+
], 64))
|
|
166
|
+
]),
|
|
167
|
+
default: E(() => [
|
|
168
|
+
c.value ? (m(), g(ve, {
|
|
169
|
+
key: 0,
|
|
170
|
+
class: M(["p-[9.52px] transition"]),
|
|
171
|
+
message: c.value.detail,
|
|
172
|
+
removable: !1,
|
|
173
|
+
"show-icon": !1,
|
|
174
|
+
title: c.value.title,
|
|
175
|
+
"message-wrapper-class": "text-[11px] leading-[14px] tracking-[0.02em]",
|
|
176
|
+
severity: "danger"
|
|
177
|
+
}, null, 8, ["message", "title"])) : b("", !0),
|
|
178
|
+
R(_, {
|
|
179
|
+
disabled: w.value,
|
|
180
|
+
loading: v.value,
|
|
181
|
+
onClick: Z,
|
|
182
|
+
icon: "refresh",
|
|
183
|
+
label: "Sync",
|
|
184
|
+
"loading-icon": "refresh",
|
|
185
|
+
outlined: ""
|
|
186
|
+
}, null, 8, ["disabled", "loading"]),
|
|
187
|
+
V("section", {
|
|
188
|
+
class: M([
|
|
189
|
+
"grid grid-cols-2 gap-3 justify-start w-full",
|
|
190
|
+
{ "opacity-60 pointer-events-none": w.value }
|
|
191
|
+
]),
|
|
192
|
+
"data-ts-section": "scanner-list"
|
|
193
|
+
}, [
|
|
194
|
+
R($, {
|
|
195
|
+
modelValue: l.value,
|
|
196
|
+
"onUpdate:modelValue": [
|
|
197
|
+
e[0] || (e[0] = (a) => l.value = a),
|
|
198
|
+
N
|
|
199
|
+
],
|
|
200
|
+
options: p.value,
|
|
201
|
+
label: "RFID Scanner",
|
|
202
|
+
"option-label": "label"
|
|
203
|
+
}, null, 8, ["modelValue", "options"]),
|
|
204
|
+
R($, {
|
|
205
|
+
modelValue: r.value,
|
|
206
|
+
"onUpdate:modelValue": [
|
|
207
|
+
e[1] || (e[1] = (a) => r.value = a),
|
|
208
|
+
N
|
|
209
|
+
],
|
|
210
|
+
options: f.value,
|
|
211
|
+
label: "QR Scanner",
|
|
212
|
+
"option-label": "label"
|
|
213
|
+
}, null, 8, ["modelValue", "options"])
|
|
214
|
+
], 2)
|
|
215
|
+
]),
|
|
216
|
+
_: 2
|
|
217
|
+
}, [
|
|
218
|
+
D.value ? {
|
|
219
|
+
name: "header",
|
|
220
|
+
fn: E(() => {
|
|
221
|
+
var a;
|
|
222
|
+
return [
|
|
223
|
+
R(ue, {
|
|
224
|
+
icon: (a = n.searchBy) == null ? void 0 : a.toLowerCase()
|
|
225
|
+
}, null, 8, ["icon"]),
|
|
226
|
+
V("h3", null, "Scan " + se(n.searchBy), 1)
|
|
227
|
+
];
|
|
228
|
+
}),
|
|
229
|
+
key: "0"
|
|
230
|
+
} : void 0
|
|
231
|
+
]), 1032, ["closable", "header-class", "visible"]));
|
|
232
|
+
}
|
|
233
|
+
});
|
|
234
|
+
export {
|
|
235
|
+
De as _
|
|
236
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
System.register(["vue"],function(m,y){"use strict";var c,u,p,r,s,v,o,i,n;return{setters:[t=>{c=t.defineComponent,u=t.computed,p=t.resolveDirective,r=t.createElementBlock,s=t.openBlock,v=t.Fragment,o=t.withDirectives,i=t.createCommentVNode,n=t.mergeProps}],execute:function(){const t=m("_",c({__name:"Icon",props:{icon:{},severity:{default:void 0},info:{default:void 0},tooltipPos:{default:"bottom"},class:{default:void 0}},setup(d){const f=d,g=(()=>{switch(f.severity){case"primary":return"text-primary-500";case"success":return"text-success-500";case"warning":return"text-warning-500";case"danger":return"text-danger-500";case"info":return"text-info-500";default:return"inherit"}})(),a=u(()=>["icon",`ic-${f.icon}`,g,"cursor-pointer shink-0"]);return(e,k)=>{const l=p("tooltip");return s(),r(v,null,[e.tooltipPos==="top"?o((s(),r("i",n({key:0},e.$attrs,{class:[...a.value,e.$props.class]}),null,16)),[[l,e.info,void 0,{top:!0}]]):i("",!0),e.tooltipPos==="bottom"?o((s(),r("i",n({key:1},e.$attrs,{class:[...a.value,e.$props.class]}),null,16)),[[l,e.info,void 0,{bottom:!0}]]):i("",!0),e.tooltipPos==="right"?o((s(),r("i",n({key:2},e.$attrs,{class:[...a.value,e.$props.class]}),null,16)),[[l,e.info,void 0,{right:!0}]]):i("",!0),e.tooltipPos==="left"?o((s(),r("i",n({key:3},e.$attrs,{class:[...a.value,e.$props.class]}),null,16)),[[l,e.info,void 0,{left:!0}]]):i("",!0)],64)}}}))}}});
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { defineComponent as c, computed as d, resolveDirective as v, createElementBlock as t, openBlock as o, Fragment as f, withDirectives as i, createCommentVNode as n, mergeProps as l } from "vue";
|
|
2
|
+
const $ = /* @__PURE__ */ c({
|
|
3
|
+
__name: "Icon",
|
|
4
|
+
props: {
|
|
5
|
+
icon: {},
|
|
6
|
+
severity: { default: void 0 },
|
|
7
|
+
info: { default: void 0 },
|
|
8
|
+
tooltipPos: { default: "bottom" },
|
|
9
|
+
class: { default: void 0 }
|
|
10
|
+
},
|
|
11
|
+
setup(u) {
|
|
12
|
+
const a = u, p = (() => {
|
|
13
|
+
switch (a.severity) {
|
|
14
|
+
case "primary":
|
|
15
|
+
return "text-primary-500";
|
|
16
|
+
case "success":
|
|
17
|
+
return "text-success-500";
|
|
18
|
+
case "warning":
|
|
19
|
+
return "text-warning-500";
|
|
20
|
+
case "danger":
|
|
21
|
+
return "text-danger-500";
|
|
22
|
+
case "info":
|
|
23
|
+
return "text-info-500";
|
|
24
|
+
default:
|
|
25
|
+
return "inherit";
|
|
26
|
+
}
|
|
27
|
+
})(), s = d(() => [
|
|
28
|
+
"icon",
|
|
29
|
+
`ic-${a.icon}`,
|
|
30
|
+
p,
|
|
31
|
+
"cursor-pointer shink-0"
|
|
32
|
+
]);
|
|
33
|
+
return (e, m) => {
|
|
34
|
+
const r = v("tooltip");
|
|
35
|
+
return o(), t(f, null, [
|
|
36
|
+
e.tooltipPos === "top" ? i((o(), t("i", l({ key: 0 }, e.$attrs, {
|
|
37
|
+
class: [...s.value, e.$props.class]
|
|
38
|
+
}), null, 16)), [
|
|
39
|
+
[
|
|
40
|
+
r,
|
|
41
|
+
e.info,
|
|
42
|
+
void 0,
|
|
43
|
+
{ top: !0 }
|
|
44
|
+
]
|
|
45
|
+
]) : n("", !0),
|
|
46
|
+
e.tooltipPos === "bottom" ? i((o(), t("i", l({ key: 1 }, e.$attrs, {
|
|
47
|
+
class: [...s.value, e.$props.class]
|
|
48
|
+
}), null, 16)), [
|
|
49
|
+
[
|
|
50
|
+
r,
|
|
51
|
+
e.info,
|
|
52
|
+
void 0,
|
|
53
|
+
{ bottom: !0 }
|
|
54
|
+
]
|
|
55
|
+
]) : n("", !0),
|
|
56
|
+
e.tooltipPos === "right" ? i((o(), t("i", l({ key: 2 }, e.$attrs, {
|
|
57
|
+
class: [...s.value, e.$props.class]
|
|
58
|
+
}), null, 16)), [
|
|
59
|
+
[
|
|
60
|
+
r,
|
|
61
|
+
e.info,
|
|
62
|
+
void 0,
|
|
63
|
+
{ right: !0 }
|
|
64
|
+
]
|
|
65
|
+
]) : n("", !0),
|
|
66
|
+
e.tooltipPos === "left" ? i((o(), t("i", l({ key: 3 }, e.$attrs, {
|
|
67
|
+
class: [...s.value, e.$props.class]
|
|
68
|
+
}), null, 16)), [
|
|
69
|
+
[
|
|
70
|
+
r,
|
|
71
|
+
e.info,
|
|
72
|
+
void 0,
|
|
73
|
+
{ left: !0 }
|
|
74
|
+
]
|
|
75
|
+
]) : n("", !0)
|
|
76
|
+
], 64);
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
});
|
|
80
|
+
export {
|
|
81
|
+
$ as _
|
|
82
|
+
};
|