business.79b45e39.js 3.7 KB

1
  1. import{Z as B,cr as F,_ as w,d as z,cs as P,m as p,cp as T,r as a,o as f,A as d,x as o,h as u,u as l,H as v,D as x,a as k,ce as U}from"./index.56449854.js";import{s as V}from"./search.config.e272061f.js";import{a as E,D as $}from"./demand-modify-modal.da059a06.js";import{u as H}from"./use-page-search.59eb5443.js";import"./lodash.0da4bba2.js";import{u as I}from"./useBusinessQuery.85cdd2fe.js";import O from"./exec-modal.89f64530.js";import"./isBeyondTime.ab735625.js";import"./createRequset.56e9fc42.js";const j=[{value:1,label:"\u5F85\u6267\u884C",type:"info"},{value:2,label:"\u6267\u884C\u5B8C\u6210",type:"success"},{value:3,label:"\u6267\u884C\u5931\u8D25",type:"danger"}],q=[{value:1,label:"\u7ACB\u5373\u6267\u884C",type:""},{value:2,label:"\u5EF6\u8FDF\u6267\u884C",type:"warning"}],K=[{prop:"exec_name",label:"\u4E1A\u52A1\u8868\u540D\u79F0",minWidth:"115px"},{prop:"start",label:"\u6570\u636E\u5F00\u59CB\u65F6\u95F4",minWidth:"155px"},{prop:"end",label:"\u6570\u636E\u7ED3\u675F\u65F6\u95F4",minWidth:"155px"},{prop:"updatetime",label:"\u72B6\u6001\u66F4\u65B0\u65F6\u95F4",minWidth:"155px"},{prop:"createtime",label:"\u521B\u5EFA\u65F6\u95F4",minWidth:"115px"},{prop:"exce_type",label:"\u6267\u884C\u7C7B\u578B",cellRenderer({row:i}){const t=q.find(({value:s})=>String(s)===String(i.exec_type));return B(F,{type:t.type||""},{default:()=>t.label||"--"})}},{prop:"status",label:"\u72B6\u6001",cellRenderer({row:i}){const t=j.find(({value:s})=>String(s)===String(i.status));return B(F,{type:t.type||""},{default:()=>t.label||"--"})}},{prop:"companyName",label:"\u4E1A\u52A1\u516C\u53F8\u540D\u79F0",minWidth:"155px"},{prop:"apply_name",label:"\u7533\u8BF7\u4EBA",minWidth:"80px"},{label:"\u64CD\u4F5C",fixed:"right",width:90,slot:"operation"}],L={columns:K,showTitle:!1,superUserNoAction:!1,apis:{httpList:E.list}},_="salesReturnSubscribe",Z=z({__name:"business",setup(i){const{searchConfig:t}=I({sourceConfig:V,queryField:"companyNo"});P();const s=p(t),r=p(null),g=p(null),y=p(null),{hasPermissionWithCode:C}=T(_),S={pageSearchHook:()=>H(void 0,void 0,t)};async function D(c){const e=await E.delete_exec({id:c});e.code===1?r.value.onSearch():U.warning(e.message)}function A(){var e;const{companyNo:c}=r.value.getBasicParams();(e=y.value)==null||e.onDisplay(c)}return(c,e)=>{const h=a("el-button"),b=a("ElButton"),M=a("el-link"),R=a("el-popconfirm"),N=a("page-container"),W=a("page-auth");return f(),d(W,{"page-name":_,all:!1},{default:o(()=>[u(N,{"search-config":s.value,hooks:S,"page-name":_,"get-content-ref":n=>r.value=n,"content-config":l(L),lockKey:"companyNo"},{content_header:o(()=>[u(h,{type:"",size:"mini",onClick:e[0]||(e[0]=n=>{var m;return(m=g.value)==null?void 0:m.onDisplay({})})},{default:o(()=>[v("\u67E5\u770B\u6267\u884C\u7C7B\u578B\u8BF4\u660E")]),_:1}),u(h,{type:"primary",size:"mini",onClick:A},{default:o(()=>[v("\u6DFB\u52A0")]),_:1})]),content_action:o(n=>[String(n.status)==="2"&&l(C)("19")?(f(),d(M,{key:0,href:n.down_url,target:"_blank",underline:!1},{default:o(()=>[u(b,{link:"",size:"small",type:"primary",icon:l(x)("download-line")},null,8,["icon"])]),_:2},1032,["href"])):k("v-if",!0),l(C)("17")&&(String(n.status)==="3"||String(n.status)==="1")?(f(),d(R,{key:1,title:"\u662F\u5426\u786E\u8BA4\u5220\u9664\u8BE5\u6761\u8BB0\u5F55?",onConfirm:m=>D(n.id)},{reference:o(()=>[u(b,{link:"",size:"small",type:"primary",icon:l(x)("delete")},null,8,["icon"])]),_:2},1032,["onConfirm"])):k("v-if",!0)]),_:1},8,["search-config","get-content-ref","content-config"]),u($,{"is-business":!0,ref_key:"demandModifyModal",ref:y,onRefresh:e[1]||(e[1]=n=>r.value.onSearch())},null,512),u(O,{ref_key:"execModalRef",ref:g},null,512)]),_:1})}}});var ue=w(Z,[["__file","C:/Users/89793/Desktop/projects/report-v3/src/views/subscribe/salesReturnSubscribe/components/business.vue"]]);export{ue as default};