2 lines
8.3 KiB
JavaScript
2 lines
8.3 KiB
JavaScript
|
import{B as oe,C as le,M as ne,N as se,w as re,D as ie,I as pe,O as ce,P as de,L as _e,Q as me}from"./element-plus.b0ecf6ae.js";import{_ as fe}from"./index.vue_vue_type_script_setup_true_lang.ebbecf1a.js";import{u as ye}from"./vue-router.9f65afb1.js";import{u as Ee}from"./usePaging.60d02673.js";import{u as Ce}from"./useDictOptions.c461c83a.js";import{d as Be,e as Fe}from"./contract.d0a20d95.js";import{d as z,s as ve,r as _,$ as M,a4 as be,af as ke,o as l,c as m,U as t,L as a,u,T as w,a7 as R,K as d,R as i,M as V,a as E,S as A,Q as he,k as T,bf as ge,be as De}from"./@vue.51d7f2d8.js";import"./lodash.ffb5376d.js";import{d as we}from"./index.2ce58885.js";import{d as Ve}from"./dict.faa8fd3a.js";import{u as Ae,f as xe,s as Pe}from"./company.a117638c.js";import"./@vueuse.ec90c285.js";import"./@element-plus.c80b8015.js";import"./lodash-es.29c53eac.js";import"./dayjs.e873ead7.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.82a509e0.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./axios.f9df025a.js";import"./pinia.56356cb7.js";import"./vue-demi.b3a9cad9.js";import"./css-color-function.4b0c77cb.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"./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.40d5feba.js";const Se=b=>(ge("data-v-8ee61ba2"),b=b(),De(),b),Ie={class:"mt-4"},Le={key:0,style:{color:"#67c23a"}},Ue={key:1,style:{color:"#fe0000"}},qe={class:"flex justify-end mt-4"},Ne=Se(()=>E("h1",null,"\u91CD\u8981\u63D0\u9192",-1)),$e={key:0,class:"content"},Me={key:1,class:"content"},Re={class:"btn_menu"},Te=z({name:"contractLists"}),ze=z({...Te,setup(b){var S;const x=ye();ve(),_(!1);const P=_([]);let D=!1;const f=_(!1),k=_(!1),C=_(""),B=_(""),G=s=>{f.value=!0,k.value=!0,C.value=s.id,B.value=s.party_b,s.contract_type==22&&(D=!0)},h=()=>{f.value=!1,k.value=!1},O=async()=>{D?await Ae({id:B.value,contract_id:C.value}):await xe({id:B.value,contract_id:C.value}),D=!1,g(),h()},Q=async()=>{await Pe({id:B.value,contract_id:C.value}),g(),h()},n=M({company_id:"",contract_type:"",contract_no:"",status:"",party_a:"",party_b:"",area_manager:"",type:""}),j=M([{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 K=_([]),Z=s=>{K.value=s.map(({id:o})=>o)};Ce(""),Ve({type_id:7}).then(s=>{P.value=s.lists});const{pager:F,getLists:g,resetParams:H,resetPage:J}=Ee({fetchFun:Fe,params:n});_();const W=s=>{Be({id:s.id}).then(o=>{X(o.url,"")})},X=(s,o)=>{let p=document.createElement("a");p.href=s,p.download=o,document.body.appendChild(p),p.click(),document.body.removeChild(p)};return g(),(s,o)=>{const p=oe,y=le,I=ne,L=se,r=re,Y=ie,U=pe,c=ce,q=be("router-link"),ee=de,te=fe,ae=_e,N=ke("perms"),ue=me;return l(),m("div",null,[t(U,{class:"!border-none mb-4",shadow:"never"},{default:a(()=>[t(Y,{class:"mb-[-16px]",model:u(n),inline:""},{default:a(()=>[t(y,{label:"\u516C\u53F8\u540D\u79F0",prop:"company_id"},{default:a(()=>[t(p,{class:"w-[280px]",modelValue:u(n).company_id,"onUpdate:modelValue":o[0]||(o[0]=e=>u(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(L,{modelValue:u(n).contract_type,"onUpdate:modelValue":o[1]||(o[1]=e=>u(n).contract_type=e),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5408\u540C\u7C7B\u578B"},{default:a(()=>[(l(!0),m(w,null,R(u(P),e=>(l(),d(I,{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:u(n).contract_no,"onUpdate:modelValue":o[2]||(o[2]=e=>u(n)
|