2 lines
6.1 KiB
Java
2 lines
6.1 KiB
Java
var $=Object.defineProperty,W=Object.defineProperties;var Z=Object.getOwnPropertyDescriptors;var S=Object.getOwnPropertySymbols;var tt=Object.prototype.hasOwnProperty,et=Object.prototype.propertyIsEnumerable;var T=(r,e,t)=>e in r?$(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,E=(r,e)=>{for(var t in e||(e={}))tt.call(e,t)&&T(r,t,e[t]);if(S)for(var t of S(e))et.call(e,t)&&T(r,t,e[t]);return r},R=(r,e)=>W(r,Z(e));var k=(r,e,t)=>new Promise((_,h)=>{var f=a=>{try{y(t.next(a))}catch(g){h(g)}},v=a=>{try{y(t.throw(a))}catch(g){h(g)}},y=a=>a.done?_(a.value):Promise.resolve(a.value).then(f,v);y((t=t.apply(r,e)).next())});import{d as F,ah as m,v as ot,ar as nt,as as p,k as s,aF as i,u as l,q as b,aC as u,ag as rt,G as d,r as A}from"./vue-vendor-C7Zq48Yl.js";import{al as it,u as at,d as st}from"./index-BI6CMai0.js";import"./index-BgJbdjPf.js";import"./index-Du0A3ksf.js";import{useListPage as lt}from"./useListPage-BWia52we.js";import{M as mt,s as pt,b as ct,a as ut,g as dt,c as _t,d as ft,e as yt,l as gt,f as wt}from"./MesXslRawMaterialEntryModal-C95wErab.js";import{J as xt}from"./componentMap-BBZeqR-K.js";import bt from"./BasicTable-DfLkrEeh.js";import"./antd-vue-vendor-BPnV8VqP.js";import"./vxe-table-vendor-B88kchpX.js";import"./BasicModal-0sAdFEk_.js";import"./ModalHeader-keHdAHWH.js";import"./useTimeout-DDl4l82I.js";import"./index-DeEq83Ov.js";import"./useWindowSizeFn-PRZSD86C.js";import"./index-pxs5MULf.js";import"./index-BgYCgfME.js";import"./index-f8O7TghW.js";import"./useIntersectionObserver-BMxdTqP3.js";import"./useMethods-DVip17X8.js";import"./index-Di-j2gt4.js";import"./BasicForm-BJnSRkIE.js";import"./useForm-BZtHZyx2.js";import"./JAreaLinkage-BeRUFHSB.js";import"./areaDataUtil-CbYCy3Ig.js";import"./JSelectUser-B71zikzw.js";import"./props-DAezUTeZ.js";import"./JSelectBiz-CnEaVMUF.js";import"./JSelectDept-DRDVeruW.js";import"./index-CUdllngZ.js";import"./bem-EhXRi4nW.js";import"./props-D4vdsy3J.js";import"./useContextMenu-Cwx1lIOK.js";import"./TreeIcon-DE4jdeZV.js";import"./JCodeEditor-CLVZA7Uj.js";import"./useFormItem-BdW6EoZe.js";import"./htmlmixed-NhwyF9-q.js";import"./vue-CgbRSACy.js";/* empty css */import"./JAddInput-D6qcyZjQ.js";import"./index-CNkz_PUv.js";import"./depart.api-DeMNV8zW.js";import"./JPopup-Bva6u6tk.js";import"./usePopBiz-CG0vVpgI.js";import"./index-Dg4HCEvo.js";import"./EasyCronInput-7xfJ3nBh.js";import"./JEllipsis-DqRFTSm0.js";import"./download-UE0L9Rfp.js";import"./base64Conver-24EVOS6V.js";import"./index-CIBZG4nR.js";import"./index-BhQEwnQQ.js";import"./useCountdown-DqnNWBp6.js";import"./useFormItemSingle-BbRhswfn.js";import"./JUpload-Cz9HN61B.js";import"./index-MGIrEF-A.js";import"./index-MREkPhsT.js";import"./injectionKey-DPVn4AgL.js";const ht=F({name:"xslmes-mesXslRawMaterialEntry"}),Ct=F(R(E({},ht),{setup(r){const{createConfirm:e,createMessage:t}=at(),_=A({}),[h,{openModal:f}]=it(),{prefixCls:v,tableContext:y,onExportXls:a,onImportXls:g}=lt({tableProps:{title:"原料入场记录",api:gt,columns:yt,canResize:!0,formConfig:{schemas:ft,autoSubmitOnEnter:!0,showAdvancedButton:!0,fieldMapToTime:[["entryTime",["entryTime_begin","entryTime_end"],"YYYY-MM-DD HH:mm:ss"]]},actionColumn:{width:180,fixed:"right"},beforeFetch:o=>Object.assign(o,_)},exportConfig:{name:"原料入场记录",url:_t,params:_},importConfig:{url:dt,success:w}}),[X,{reload:M},{rowSelection:j,selectedRowKeys:c}]=y,B=A(pt);function O(o){Object.keys(o).map(n=>{_[n]=o[n]}),M()}function U(){f(!0,{isUpdate:!1,showFooter:!0})}function q(o){f(!0,{record:o,isUpdate:!0,showFooter:!0})}function Y(o){f(!0,{record:o,isUpdate:!0,showFooter:!1})}function H(o){return k(this,null,function*(){yield wt({id:o.id},w)})}function L(){return k(this,null,function*(){yield ct({ids:c.value},w)})}function N(){if(!c.value.length){t.warning("请先勾选要结存入库的记录");return}e({iconType:"warning",title:"结存入库",content:`是否将选中的 ${c.value.length} 条记录结存入库`,okText:"确认",cancelText:"取消",onOk:()=>k(null,null,function*(){yield ut(c.value.join(",")),t.success("结存入库成功!"),w()})})}function w(){(c.value=[])&&M()}function P(o){return[{label:"编辑",onClick:q.bind(null,o),auth:"xslmes:mes_xsl_raw_material_entry:edit"}]}function Q(o){return[{label:"详情",onClick:Y.bind(null,o)},{label:"删除",popConfirm:{title:"是否确认删除",confirm:H.bind(null,o),placement:"topLeft"},auth:"xslmes:mes_xsl_raw_material_entry:delete"}]}return(o,n)=>{const C=m("a-button"),V=m("j-upload-button"),D=m("Icon"),z=m("a-menu-item"),G=m("a-menu"),J=m("a-dropdown"),K=m("super-query"),x=ot("auth");return p(),nt("div",null,[s(l(bt),{onRegister:l(X),rowSelection:l(j)},{tableTitle:i(()=>[b((p(),u(C,{type:"primary",onClick:U,preIcon:"ant-design:plus-outlined"},{default:i(()=>[...n[0]||(n[0]=[d(" 新增",-1)])]),_:1})),[[x,"xslmes:mes_xsl_raw_material_entry:add"]]),b((p(),u(C,{type:"primary",preIcon:"ant-design:export-outlined",onClick:l(a)},{default:i(()=>[...n[1]||(n[1]=[d(" 导出",-1)])]),_:1},8,["onClick"])),[[x,"xslmes:mes_xsl_raw_material_entry:exportXls"]]),b((p(),u(V,{type:"primary",preIcon:"ant-design:import-outlined",onClick:l(g)},{default:i(()=>[...n[2]||(n[2]=[d("导入",-1)])]),_:1},8,["onClick"])),[[x,"xslmes:mes_xsl_raw_material_entry:importExcel"]]),b((p(),u(C,{type:"primary",preIcon:"ant-design:check-circle-outlined",onClick:N},{default:i(()=>[...n[3]||(n[3]=[d(" 结存入库",-1)])]),_:1})),[[x,"xslmes:mes_xsl_raw_material_entry:stockIn"]]),l(c).length>0?(p(),u(J,{key:0},{overlay:i(()=>[s(G,null,{default:i(()=>[s(z,{key:"1",onClick:L},{default:i(()=>[s(D,{icon:"ant-design:delete-outlined"}),n[4]||(n[4]=d(" 删除 ",-1))]),_:1})]),_:1})]),default:i(()=>[b((p(),u(C,null,{default:i(()=>[n[5]||(n[5]=d("批量操作 ",-1)),s(D,{icon:"mdi:chevron-down"})]),_:1})),[[x,"xslmes:mes_xsl_raw_material_entry:deleteBatch"]])]),_:1})):rt("",!0),s(K,{config:B,onSearch:O},null,8,["config"])]),action:i(({record:I})=>[s(l(xt),{actions:P(I),dropDownActions:Q(I)},null,8,["actions","dropDownActions"])]),_:1},8,["onRegister","rowSelection"]),s(mt,{onRegister:l(h),onSuccess:w},null,8,["onRegister"])])}}})),Ie=st(Ct,[["__scopeId","data-v-215db459"]]);export{Ie as default};
|