WokerTask/public/admin/assets/index.0c1e2cbc.js

2 lines
8.5 KiB
JavaScript

import{C as ue,D as le,N as ne,O as se,w as re,F as ie,J as pe,P as ce,Q as de,M as _e,R as me}from"./element-plus.ff90c99c.js";import{_ as fe}from"./index.vue_vue_type_script_setup_true_lang.44dbc460.js";import{u as ye}from"./vue-router.6d4cf914.js";import{u as Ee}from"./usePaging.bd7a7dec.js";import{u as Ce}from"./useDictOptions.85871a3e.js";import{d as Fe,e as ve}from"./contract.af3574a9.js";import{d as M,s as Be,r as _,$,ag as be,aq as ke,o as l,c as m,W as t,Q as a,u as o,F as w,a9 as T,P as d,U as i,R as V,a as E,V as A,T as he,j as z,bg as ge,bf as De}from"./@vue.f8dfc830.js";import"./lodash.ffb5376d.js";import{d as we}from"./index.9acc1fa4.js";import{d as Ve}from"./dict.d8314400.js";import{u as Ae,f as xe,s as Pe}from"./company.04834679.js";import"./lodash-es.a73406b7.js";import"./@vueuse.a2e59ee9.js";import"./@element-plus.0374639c.js";import"./@popperjs.36402333.js";import"./@ctrl.b082b0c1.js";import"./dayjs.7f1be2bc.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./memoize-one.4ee5c96d.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./@floating-ui.34a21088.js";import"./axios.f9df025a.js";import"./pinia.4b196199.js";import"./vue-demi.b3a9cad9.js";import"./css-color-function.d1ea016b.js";import"./color.992612d2.js";import"./clone.d8d3ae9a.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.4e7fd6e6.js";import"./ms.a9ae1d6d.js";import"./nprogress.f73355d0.js";import"./vue-clipboard3.dca5bca3.js";import"./clipboard.16e4491b.js";import"./echarts.ac57a99a.js";import"./zrender.d54ce080.js";import"./tslib.60310f1a.js";import"./highlight.js.dba6fa1b.js";import"./@highlightjs.79024f1a.js";const Se=b=>(ge("data-v-8ee61ba2"),b=b(),De(),b),Ue={class:"mt-4"},Ie={key:0,style:{color:"#67c23a"}},qe={key:1,style:{color:"#fe0000"}},Le={class:"flex justify-end mt-4"},Ne=Se(()=>E("h1",null,"\u91CD\u8981\u63D0\u9192",-1)),Re={key:0,class:"content"},$e={key:1,class:"content"},Te={class:"btn_menu"},ze=M({name:"contractLists"}),Me=M({...ze,setup(b){var S;const x=ye();Be(),_(!1);const P=_([]);let D=!1;const f=_(!1),k=_(!1),C=_(""),F=_(""),j=s=>{f.value=!0,k.value=!0,C.value=s.id,F.value=s.party_b,s.contract_type==22&&(D=!0)},h=()=>{f.value=!1,k.value=!1},G=async()=>{D?await Ae({id:F.value,contract_id:C.value}):await xe({id:F.value,contract_id:C.value}),D=!1,g(),h()},O=async()=>{await Pe({id:F.value,contract_id:C.value}),g(),h()},n=$({company_id:"",contract_type:"",contract_no:"",status:"",party_a:"",party_b:"",area_manager:"",type:""}),Q=$([{id:"1",name:"\u5DF2\u7B7E\u7EA6"},{id:"0",name:"\u672A\u7B7E\u7EA6"}]);x.query.type&&(n.type=(S=x.query.type)==null?void 0:S.toString());const J=_([]),W=s=>{J.value=s.map(({id:u})=>u)};Ce(""),Ve({type_id:7}).then(s=>{P.value=s.lists});const{pager:v,getLists:g,resetParams:Z,resetPage:H}=Ee({fetchFun:ve,params:n});_();const K=s=>{Fe({id:s.id}).then(u=>{X(u.url,"")})},X=(s,u)=>{let p=document.createElement("a");p.href=s,p.download=u,document.body.appendChild(p),p.click(),document.body.removeChild(p)};return g(),(s,u)=>{const p=ue,y=le,U=ne,I=se,r=re,Y=ie,q=pe,c=ce,L=be("router-link"),ee=de,te=fe,ae=_e,N=ke("perms"),oe=me;return l(),m("div",null,[t(q,{class:"!border-none mb-4",shadow:"never"},{default:a(()=>[t(Y,{class:"mb-[-16px]",model:o(n),inline:""},{default:a(()=>[t(y,{label:"\u516C\u53F8\u540D\u79F0",prop:"company_id"},{default:a(()=>[t(p,{class:"w-[280px]",modelValue:o(n).company_id,"onUpdate:modelValue":u[0]||(u[0]=e=>o(n).company_id=e),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u516C\u53F8"},null,8,["modelValue"])]),_:1}),t(y,{label:"\u5408\u540C\u7C7B\u578B",prop:"contract_type"},{default:a(()=>[t(I,{modelValue:o(n).contract_type,"onUpdate:modelValue":u[1]||(u[1]=e=>o(n).contract_type=e),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5408\u540C\u7C7B\u578B"},{default:a(()=>[(l(!0),m(w,null,T(o(P),e=>(l(),d(U,{key:e.label,value:e.id,label:e.name},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1}),t(y,{label:"\u5408\u540C\u7F16\u53F7",prop:"contract_no"},{default:a(()=>[t(p,{class:"w-[280px]",modelValue:o(n).contract_no,"onUpdate:modelValue":u[2]||(u[2]=e=>o(n).contract_no=e),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5408\u540C\u7F16\u53F7"},null,8,["modelValue"])]),_:1}),t(y,{label:"\u72B6\u6001",prop:"status"},{default:a(()=>[t(I,{modelValue:o(n).status,"onUpdate:modelValue":u[3]||(u[3]=e=>o(n).status=e),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u72B6\u6001"},{default:a(()=>[(l(!0),m(w,null,T(o(Q),e=>(l(),d(U,{key:e.label,value:e.id,label:e.name},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1}),t(y,{label:"\u7532\u65B9\u7247\u533A\u7ECF\u7406",prop:"area_manager"},{default:a(()=>[t(p,{class:"w-[280px]",modelValue:o(n).area_manager,"onUpdate:modelValue":u[4]||(u[4]=e=>o(n).area_manager=e),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u7532\u65B9\u7247\u533A\u7ECF\u7406"},null,8,["modelValue"])]),_:1}),t(y,null,{default:a(()=>[t(r,{type:"primary",onClick:o(H)},{default:a(()=>[i("\u67E5\u8BE2")]),_:1},8,["onClick"]),t(r,{onClick:o(Z)},{default:a(()=>[i("\u91CD\u7F6E")]),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"])]),_:1}),V((l(),d(q,{class:"!border-none",shadow:"never"},{default:a(()=>[E("div",Ue,[t(ee,{data:o(v).lists,onSelectionChange:W},{default:a(()=>[t(c,{label:"id",prop:"id","show-overflow-tooltip":""}),t(c,{label:"\u5408\u540C\u7C7B\u578B",prop:"contract_type_name","show-overflow-tooltip":""}),t(c,{label:"\u5408\u540C\u7F16\u53F7",prop:"contract_no","show-overflow-tooltip":""}),t(c,{label:"\u7532\u65B9",prop:"party_a_name","show-overflow-tooltip":""},{default:a(e=>{var B,R;return[E("span",null,A((R=(B=e.row)==null?void 0:B.party_a_info)==null?void 0:R.company_name),1)]}),_:1}),t(c,{label:"\u4E59\u65B9",prop:"party_b_name","show-overflow-tooltip":""}),t(c,{label:"\u7532\u65B9\u7247\u533A\u7ECF\u7406",prop:"area_manager_name","show-overflow-tooltip":""}),t(c,{label:"\u7C7B\u578B",prop:"type","show-overflow-tooltip":""},{default:a(e=>[E("span",null,A(e.row.type==1?"\u516C\u53F8":e.row.type==0?"":"\u4E2A\u4EBA"),1)]),_:1}),t(c,{label:"\u72B6\u6001",prop:"status_name","show-overflow-tooltip":""},{default:a(e=>[e.row.status_name=="\u5DF2\u7B7E\u7EA6"?(l(),m("span",Ie,"\u5DF2\u7B7E\u7EA6")):(l(),m("span",qe,"\u672A\u7B7E\u7EA6"))]),_:1}),t(c,{label:"\u64CD\u4F5C",width:"180",fixed:"right",align:"center"},{default:a(({row:e})=>[t(r,{type:"primary",link:""},{default:a(()=>[t(L,{to:{path:"/contract/detail",query:{id:e.id}}},{default:a(()=>[i(A(e.status?"\u8BE6\u60C5":"\u5BA1\u6838"),1)]),_:2},1032,["to"])]),_:2},1024),e.status==0?(l(),m(w,{key:0},[e.check_status==1?(l(),d(r,{key:0,type:"warning",link:""},{default:a(()=>[t(L,{to:{path:"/contract/detail",query:{id:e.id}}},{default:a(()=>[i("\u5F85\u5BA1\u6838")]),_:2},1032,["to"])]),_:2},1024)):e.check_status==2?V((l(),d(r,{key:1,type:"primary",link:"",onClick:B=>j(e)},{default:a(()=>[i("\u53D1\u9001\u5408\u540C")]),_:2},1032,["onClick"])),[[N,["contract.contract/contract_send"]]]):e.check_status==3?V((l(),d(r,{key:2,type:"primary",link:"",onClick:B=>(f.value=!0,F.value=e.party_b,C.value=e.id)},{default:a(()=>[i("\u53D1\u9001\u77ED\u4FE1")]),_:2},1032,["onClick"])),[[N,["contract.contract/contract_send_again"]]]):he("",!0)],64)):(l(),d(r,{key:1,type:"primary",link:"",onClick:B=>K(e)},{default:a(()=>[i(" \u4E0B\u8F7D\u8BC1\u636E\u5305 ")]),_:2},1032,["onClick"]))]),_:1})]),_:1},8,["data"])]),E("div",Le,[t(te,{modelValue:o(v),"onUpdate:modelValue":u[5]||(u[5]=e=>z(v)?v.value=e:null),onChange:o(g)},null,8,["modelValue","onChange"])])]),_:1})),[[oe,o(v).loading]]),t(ae,{modelValue:o(f),"onUpdate:modelValue":u[6]||(u[6]=e=>z(f)?f.value=e:null),onClose:h},{default:a(()=>[Ne,o(k)?(l(),m("div",Re," \u8BF7\u786E\u8BA4\u4FE1\u606F\u662F\u5426\u6709\u8BEF,\u53D1\u9001\u5408\u540C,\u8BF7\u786E\u8BA4\u4FE1\u606F\u662F\u5426\u6709\u8BEF,\u53D1\u9001\u7535\u5B50\u5408\u540C\u540E\u77ED\u65F6\u95F4\u5185\u5C06\u4E0D\u53EF\u518D\u6B21\u53D1\u9001. ")):(l(),m("div",$e," \u786E\u8BA4\u7B7E\u7EA6\u77ED\u4FE1\u5C06\u572860\u79D2\u540E\u53D1\u9001,\u8BF7\u6CE8\u610F\u67E5\u6536,\u5E76\u70B9\u51FB\u77ED\u4FE1\u94FE\u63A5\u8FDB\u884C\u7EBF\u4E0A\u5408\u540C\u7B7E\u7EA6 ")),E("p",Te,[o(k)?(l(),d(r,{key:0,type:"primary",size:"large",onClick:G},{default:a(()=>[i("\u786E\u8BA4")]),_:1})):(l(),d(r,{key:1,type:"primary",size:"large",onClick:O},{default:a(()=>[i("\u786E\u8BA4")]),_:1})),t(r,{type:"info",size:"large",onClick:h},{default:a(()=>[i("\u8FD4\u56DE")]),_:1})])]),_:1},8,["modelValue"])])}}});const St=we(Me,[["__scopeId","data-v-8ee61ba2"]]);export{St as default};