Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

2 lines
2.8KB

  1. import{E as k,r as c,B as q,b as a,c as d,L as _,h as o,f as t,N as g,i as b,d as C,F as U,H as E,u as M,k as N}from"./index-dd5fae99.js";const O=N({name:"projectCollectionEnterBudgetInfo"}),F=Object.assign(O,{props:{detail:{type:Object}},setup(v,{expose:V}){const{budgetSourceOptions:Y}=k.dictStore.globalDicts||{},A=v,m=c(),i=(u,e,n)=>{e||n(),/^\d+(\.\d{1,6})?$/.test(e)?e*1>=1e8?n("请输入正确格式,小于100000000"):n():n("请输入正确格式,最多保留六位小数")},l=c({}),j={declareAmount:[{required:!0,message:"请填写申报金额",trigger:"blur"},{validator:i,trigger:"blur"}],approvalAmount:[{required:!0,message:"请填写批复金额",trigger:"blur"},{validator:i,trigger:"blur"}],budgetSource:[{required:!0,message:"请选择预算来源",trigger:"change"}],projectYear:[{required:!0,message:"请选择预算年度",trigger:"blur"}]};return V({formRef:m,formData:l}),q(()=>A.detail,u=>{u&&(l.value={declareAmount:u.declareAmount,approvalAmount:u.approvalAmount,budgetSource:u.budgetSource,projectYear:`${u.projectYear}`})}),(u,e)=>{const n=a("el-input-number"),s=a("el-form-item"),p=a("el-col"),w=a("el-option"),x=a("el-select"),S=a("el-date-picker"),y=a("el-row"),B=a("el-form");return d(),_(B,{ref_key:"formRef",ref:m,model:l.value,rules:j,"label-position":"top","label-suffix":":","scroll-to-error":""},{default:o(()=>[t(y,{gutter:40},{default:o(()=>[t(p,{span:6},{default:o(()=>[t(s,{label:"申报金额",prop:"declareAmount"},{default:o(()=>[t(n,{modelValue:l.value.declareAmount,"onUpdate:modelValue":e[0]||(e[0]=r=>l.value.declareAmount=r),class:"input-amount",placeholder:"请填写",min:1e-6,controls:!1,onMousewheel:e[1]||(e[1]=g(()=>{},["prevent"]))},{suffix:o(()=>e[6]||(e[6]=[b("万元")])),_:1},8,["modelValue"])]),_:1})]),_:1}),t(p,{span:6},{default:o(()=>[t(s,{label:"批复金额",prop:"approvalAmount"},{default:o(()=>[t(n,{modelValue:l.value.approvalAmount,"onUpdate:modelValue":e[2]||(e[2]=r=>l.value.approvalAmount=r),class:"input-amount",placeholder:"请填写",min:1e-6,controls:!1,onMousewheel:e[3]||(e[3]=g(()=>{},["prevent"]))},{suffix:o(()=>e[7]||(e[7]=[b("万元")])),_:1},8,["modelValue"])]),_:1})]),_:1}),t(p,{span:6},{default:o(()=>[t(s,{label:"预算来源",prop:"budgetSource"},{default:o(()=>[t(x,{modelValue:l.value.budgetSource,"onUpdate:modelValue":e[4]||(e[4]=r=>l.value.budgetSource=r),placeholder:"请选择",class:"w-full"},{default:o(()=>[(d(!0),C(U,null,E(M(Y),(r,f)=>(d(),_(w,{key:f,label:r,value:f*1},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1}),t(p,{span:6},{default:o(()=>[t(s,{label:"预算年度",prop:"projectYear"},{default:o(()=>[t(S,{modelValue:l.value.projectYear,"onUpdate:modelValue":e[5]||(e[5]=r=>l.value.projectYear=r),type:"year",placeholder:"请选择",format:"YYYY","value-format":"YYYY"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])}}});export{F as default};