import{_ as N,d as A,n as d,d3 as T,r as a,aw as V,B as k,i as p,o as j,c as z,h as u,cl as S,y as m,a as $,e as O,H as I,cm as i}from"./index.js";import{c as K}from"./index.f78c594b.js";const L={class:"flex justify-end w-full mt-[10px]"},w=" ",F=`
`,W=A({__name:"cg",props:["companyNo","supplierNo"],emits:["add"],setup(h,{emit:f}){const D=f,c=h,n=d("");d([]);const{run:E,loading:_,data:r}=T({isList:!0});function v(o=""){if(!o)return"";let e=o;const l=e.includes(w),t=e.includes(F);return l&&(e=e.split(w).join("")),t&&(e=e.split(F).join("")),e}function x(){const o=v(n.value),e=o.replace(/[，。；、; .]/g,",").replace(/(^,*)|(,*$)/g,""),l=e.split(",");if(e.length===0||l.length===0){i.warning("\u4E0D\u80FD\u89E3\u6790\u7A7A\u6587\u672C"),n.value=o;return}E(K({size:100,cgdNo:l,companyNo:c.companyNo,supplierNo:c.supplierNo,status:0})),n.value=""}function b(){if(r.value.length===0){i.warning("\u8BF7\u9009\u62E9\u81F3\u5C11\u4E00\u4E2A\u53D1\u8D27\u8FD0\u5355");return}const o=r.value.filter(({post_fee:e})=>Number(e)===0);if(o.length!==0){i.warning(`\u53D1\u8D27\u8FD0\u5355${o.map(({TrackCode:e})=>e).join("\u3001")}\u6DFB\u52A0\u5931\u8D25,\u7269\u6D41\u8D39\u7528\u4E0D\u80FD\u4E3A0`);return}D("add",p(r))}return(o,e)=>{const l=a("ElInput"),t=a("el-table-column"),s=a("ElTableColumn"),C=a("el-table"),g=a("el-button"),y=V("loading");return k((j(),z("div",null,[u(l,{rows:4,modelValue:n.value,"onUpdate:modelValue":e[0]||(e[0]=B=>n.value=B),style:{"margin-bottom":"10px"},placeholder:"\u8F93\u5165\u91C7\u8D2D\u5355\u7F16\u7801(\u5C0F\u4E8E100\u6761)\uFF0C\u7CFB\u7EDF\u652F\u6301\u7684\u5206\u5272\u7B26\u4E3A\u9017\u53F7(,)\u3001\u53E5\u53F7(.)\u3001\u5206\u53F7(;)\u3001\u987F\u53F7(\u3001)\uFF0C\u56DE\u8F66\u540E\u5F00\u59CB\u89E3\u6790\u3002",type:"textarea",onKeydown:S(x,["enter"])},null,8,["modelValue"]),u(C,{border:"",size:"small",style:{width:"100%"},data:p(r),"max-height":"450px"},{default:m(()=>[u(t,{type:"index",label:"\u5E8F\u53F7",width:"55"}),u(t,{prop:"TrackCode",label:"\u53D1\u8D27\u8FD0\u5355\u7F16\u53F7","min-width":"150px","show-overflow-tooltip":""}),u(t,{prop:"outChildCode",label:"\u53D1\u8D27\u5DE5\u5355\u7F16\u53F7","min-width":"160px","show-overflow-tooltip":""}),u(t,{prop:"orderCode",label:"\u9500\u552E\u8BA2\u5355\u7F16\u53F7","min-width":"150px","show-overflow-tooltip":""}),$(' <el-table-column prop="cgdNo" label="\u91C7\u8D2D\u5355\u7F16\u53F7" min-width="150px"  /> '),u(s,{prop:"companyName",label:"\u4E1A\u52A1\u516C\u53F8","min-width":"180px","show-overflow-tooltip":""}),u(s,{prop:"supplierName",label:"\u7269\u6D41\u4F9B\u5E94\u5546","min-width":"180px","show-overflow-tooltip":""}),u(t,{label:"\u7269\u6D41\u8D39\u7528","min-width":"150px",prop:"post_fee","show-overflow-tooltip":""}),u(s,{label:"\u5907\u6CE8",prop:"remark","min-width":"140px","show-overflow-tooltip":""}),u(t,{label:"\u521B\u5EFA\u4EBA",prop:"apply_name","min-width":"80px","show-overflow-tooltip":""}),u(t,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"create_time","min-width":"140px","show-overflow-tooltip":""})]),_:1},8,["data"]),O("div",L,[u(g,{type:"primary",size:"small",onClick:b},{default:m(()=>e[1]||(e[1]=[I("\u4FDD\u5B58")])),_:1})])])),[[y,p(_)]])}}});var H=N(W,[["__file","D:/work/jiesuan/settle-vue3/src/views/postSupplierOrder/sendOrderRecord/components/query/cg.vue"]]);export{H as default};
