You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					
					
						
							2 lines
						
					
					
						
							8.5 KiB
						
					
					
				
			
		
		
	
	
							2 lines
						
					
					
						
							8.5 KiB
						
					
					
				| import{_ as N,r as i,y as A,J as E,o as r,c as f,w as l,S as P,j as U,d as s,f as x,h as D,F as O,i as u,z as p,N as v,t as B,C as z,G as K,D as R,E as H,U as q,m as G,H as J,I as Q,q as W,R as X,l as Y,Q as Z}from"./index.58a4812e.js";/* empty css              *//* empty css              */import"./view.a8aea462.js";/* empty css              */import{c as $,g as ee}from"./common.a907f978.js";import{A as te,E as ae,a as oe}from"./EditView.3db60ed6.js";/* empty css               */import"./factory.56670aad.js";import"./materialType.20973eba.js";const le={components:{AddMateria:te,EditMateria:ae,EditView:oe},setup(){let t=[{title:"ID",key:"FID",width:"160px",align:"center",hide:!1},{title:"\u7269\u6599\u53F7",key:"FMdmCode",width:"300px",align:"center",hide:!1},{title:"\u7269\u6599\u63CF\u8FF0",key:"FSaleCode",width:"160px",align:"center",hide:!1},{title:"\u8BD5\u9A8C\u53F7",key:"FTestCode",width:"160px",align:"center",hide:!1},{title:"\u4EA7\u54C1\u5206\u7C7B",key:"FDesc",width:"400px",align:"center"},{title:"\u53D1\u8D77\u65F6\u95F4",key:"FAddDate",width:"180px",align:"center"},{title:"\u53D1\u8D77\u4EBA",key:"FUserName",width:"178px",align:"center"},{title:"\u7C7B\u578B",key:"IsEdit",width:"98px",align:"center",customSlot:""},{title:"\u72B6\u6001",key:"FStateName",width:"160px",align:"center"},{title:"\u64CD\u4F5C",key:"operator",width:"130px",fixed:"right",customSlot:"operator",align:"center"}];const a=i(["1"]),n=i(!1),e=i(!0),y=i({total:0,limit:10,current:1}),d=i([]),h=i([]),m=i({}),F=i({}),_=i({}),k=i([!1,!1,!1,!1,!1,!1,!1,!1,!1,!1,!1,!1,!1]),g=i(["70%","70%","70%","86%","70%","70%","70%","70%","700px","70%","70%","70%","70%"]),c=i({}),T=i(1),C=i([{id:1,name:"\u8FDB\u884C\u4E2D"},{id:2,name:"\u5DF2\u5B8C\u6210"}]),I=i(!1),j=i([]);return{selectedKeys:a,checkbox:n,defaultToolbar:e,dataColumn:t,dataList:d,pageInfo:y,searchObj:m,postData:F,typeList:h,showEditBox:k,modelArea:g,objInfoObj:c,editType:T,stateList:C,hasLoaded:I,MaterialModel:_,dataItem:j}},props:{dataInfoObj:{type:Object,default:()=>{}},pageTypeObj:{type:Number,default:()=>1}},mounted(){this.dataInfoObj&&(this.dataColumn.pop(),this.dataColumn[0].hide=!0,this.dataColumn[1].hide=!0,this.dataColumn[2].hide=!0,this.dataColumn[7].hide=!1),this._getTypeList(),this._getPageList(!0)},methods:{changePage(t){this.pageInfo.current=t.current,this.pageInfo.limit=t.limit,this._getPageList()},cancelClick(t,a){if(t&&this._getPageList(!0),a)return!1;for(let n=0;n<this.showEditBox.length;n++)this.showEditBox[n]=!1},async _getTypeList(){this.typeList=await $(33)||[]},async _getPageList(t,a){this.pageInfo.total=0,t&&(this.pageInfo.current=1,this.pageInfo.total=0),this.dataInfoObj&&this.dataInfoObj.FID&&(this.postData.FTeamID=this.dataInfoObj.FID,this.postData.FIsUser=!1),this.pageTypeObj&&this.pageTypeObj==2&&(this.postData.FState=99),this.postData.FPageIndex=this.pageInfo.current,this.postData.FPageSize=this.pageInfo.limit;let n=await ee(this.postData,"Task");n.Data.List=n.Data.List||[],n.Data.List.forEach(e=>{let y=this.typeList.find(h=>h.FValue===e.FType);e.FTypeName=y==null?"":y.FName;let d=this.stateList.find(h=>h.id===e.FState);e.FStateName=d==null?"":d.name,e.FAddDate=e.FAddDate==null?"":this.dateFormat(e.FAddDate),e.FEditDate=e.FEditDate==null?"":this.dateFormat(e.FEditDate),e.FFinishDate=e.FFinishDate==null?"":this.dateFormat(e.FFinishDate),e.IsEdit=Math.floor(Math.random()*10)==0?"\u7F16\u8F91":"\u65B0\u589E"}),this.pageInfo.total=n.Data.Total||0;debugger;this.dataList=n.Data.List,this.hasLoaded=!0},dateFormat(t){return t.replace("T"," ").split(".")[0]},getData(t){this.MaterialModel=t;for(let a=0;a<this.showEditBox.length;a++)this.showEditBox[a]=!1;this.showEditBox[11]=!0,this.editType=1},showEditMaterial(t){this.showEditBox[t]=!0},_clickSetInfo(t,a){for(let n=0;n<this.showEditBox.length;n++)this.showEditBox[n]=!1;if(t.FType==1)t.FBoxType=1;else if(t.FType==2)t.FBoxType=2;else if(t.FType==9||t.FType==10)t.FBoxType=4;else if(t.FType>=3&&t.FType<=7||t.FType==11)t.FBoxType=3;else if(t.FType==8)t.FBoxType=5;else if(t.FType==12)t.FBoxType=6;else if(t.FType==13)t.FBoxType=7;else if(t.FType==14)t.FBoxType=8;else if(t.FType==15)t.FBoxType=9;else if(t.FType==16)this.dataItem=t,t.FBoxType=10;else return A.msg("\u672A\u77E5\u4E8B\u9879\u7C7B\u578B");this.objInfoObj=t,this.editType=a,this.showEditBox[t.FBoxType]=!0},_clickSearch(){this.postData={};for(let t in this.searchObj){let a=this.searchObj[t];a!=null&&a!==""&&(this.postData[t]=a)}this._getPageList(!0)},_clickReset(){this.searchObj={},this._clickSearch()}}},se={key:0,style:{color:"#5FB878"}},ne={key:1,style:{color:"#1E9FFF"}};function ie(t,a,n,e,y,d){const h=z,m=K,F=R,_=H,k=q,g=G,c=J,T=Q,C=W,I=X,j=Y,L=E("AddMateria"),w=Z,S=E("EditMateria"),V=E("EditView"),M=U;return r(),f(M,{fluid:"true",style:P("padding:10px;height:"+(n.dataInfoObj!=null?n.dataInfoObj.FHeight+"px":"auto"))},{default:l(()=>[s(g,{space:"10"},{default:l(()=>[s(j,{span:"24"},{default:l(()=>[s(I,null,{default:l(()=>[s(T,{model:e.searchObj,class:"search-box"},{default:l(()=>[s(g,{class:"search-items"},{default:l(()=>[s(m,{label:"\u7269\u6599\u53F7",prop:"FSaleCode"},{default:l(()=>[s(h,{modelValue:e.searchObj.FSaleCode,"onUpdate:modelValue":a[0]||(a[0]=o=>e.searchObj.FSaleCode=o)},null,8,["modelValue"])]),_:1}),s(m,{label:"\u5F53\u524D\u6D41\u7A0B",prop:"FType"},{default:l(()=>[s(_,{modelValue:e.searchObj.FType,"onUpdate:modelValue":a[1]||(a[1]=o=>e.searchObj.FType=o)},{default:l(()=>[(r(!0),x(O,null,D(e.typeList,(o,b)=>(r(),f(F,{key:b,value:o.FValue,label:o.FName},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1}),e.postData.FState!=99?(r(),f(m,{key:0,label:"\u4E8B\u9879\u72B6\u6001",prop:"FState"},{default:l(()=>[s(_,{modelValue:e.searchObj.FState,"onUpdate:modelValue":a[2]||(a[2]=o=>e.searchObj.FState=o)},{default:l(()=>[(r(!0),x(O,null,D(e.stateList,(o,b)=>(r(),f(F,{key:b,value:o.id,label:o.name},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1})):u("",!0),s(m,{label:"\u53D1\u8D77\u65E5\u671F",prop:"FDateRange"},{default:l(()=>[s(k,{modelValue:e.searchObj.FDateRange,"onUpdate:modelValue":a[3]||(a[3]=o=>e.searchObj.FDateRange=o),range:"",placeholder:"type : date"},null,8,["modelValue"])]),_:1})]),_:1}),s(m,{class:"search-btn"},{default:l(()=>[s(c,{size:"sm",type:"primary",onClick:d._clickSearch},{default:l(()=>[p("\u641C\u7D22")]),_:1},8,["onClick"]),s(c,{size:"sm",onClick:d._clickReset},{default:l(()=>[p("\u91CD\u7F6E")]),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"]),e.hasLoaded?(r(),f(C,{key:0,columns:e.dataColumn,id:"id",dataSource:e.dataList,selectedKeys:e.selectedKeys,"onUpdate:selectedKeys":a[8]||(a[8]=o=>e.selectedKeys=o),checkbox:e.checkbox,"default-toolbar":e.defaultToolbar,page:e.dataList.length>0?e.pageInfo:null,onChange:d.changePage},v({toolbar:l(()=>[s(c,{size:"sm",onClick:a[4]||(a[4]=o=>d._getPageList(!1,!0))},{default:l(()=>[p("\u5237\u65B0")]),_:1}),s(c,{size:"sm",type:"normal",onClick:a[5]||(a[5]=o=>d.showEditMaterial(1))},{default:l(()=>[p("\u65B0\u589E")]),_:1}),s(c,{size:"sm",type:"primary",onClick:a[6]||(a[6]=o=>d.showEditMaterial(2))},{default:l(()=>[p("\u4FEE\u6539")]),_:1})]),FStateName:l(({data:o})=>[o.FStateName=="\u5DF2\u5B8C\u6210"?(r(),x("span",se,B(o.FStateName),1)):(r(),x("span",ne,B(o.FStateName),1))]),_:2},[n.dataInfoObj==null||!n.dataInfoObj.FID?{name:"operator",fn:l(({data:o})=>[s(c,{size:"xs",type:"primary",onClick:a[7]||(a[7]=b=>d.showEditMaterial(3))},{default:l(()=>[p("\u89C6\u56FE")]),_:1})]),key:"0"}:void 0]),1032,["columns","dataSource","selectedKeys","checkbox","default-toolbar","page","onChange"])):u("",!0)]),_:1})]),_:1})]),_:1}),s(w,{area:e.modelArea[1],modelValue:e.showEditBox[1],"onUpdate:modelValue":a[9]||(a[9]=o=>e.showEditBox[1]=o),title:"\u65B0\u589E\u7269\u6599"},{default:l(()=>[e.showEditBox[1]?(r(),f(L,{key:0,dataInfoObj:e.objInfoObj,onCancelClick:d.cancelClick},null,8,["dataInfoObj","onCancelClick"])):u("",!0)]),_:1},8,["area","modelValue"]),s(w,{area:e.modelArea[2],modelValue:e.showEditBox[2],"onUpdate:modelValue":a[10]||(a[10]=o=>e.showEditBox[2]=o),title:"\u4FEE\u6539\u7269\u6599"},{default:l(()=>[e.showEditBox[2]?(r(),f(S,{key:0,dataInfoObj:e.objInfoObj,onCancelClick:d.cancelClick},null,8,["dataInfoObj","onCancelClick"])):u("",!0)]),_:1},8,["area","modelValue"]),s(w,{area:e.modelArea[3],modelValue:e.showEditBox[3],"onUpdate:modelValue":a[11]||(a[11]=o=>e.showEditBox[3]=o),title:"\u7F16\u8F91\u7269\u6599"},{default:l(()=>[e.showEditBox[3]?(r(),f(V,{key:0,dataInfoObj:e.objInfoObj,onCancelClick:d.cancelClick},null,8,["dataInfoObj","onCancelClick"])):u("",!0)]),_:1},8,["area","modelValue"])]),_:1},8,["style"])}var _e=N(le,[["render",ie]]);export{_e as default};
 |