领料申请,领料出库bug修复

This commit is contained in:
hongchao 2024-12-23 18:33:34 +08:00
parent 709dfbc891
commit 19609d0931
4 changed files with 29 additions and 32 deletions

View File

@ -137,7 +137,7 @@
controls-position="right" type="number" controls-position="right" type="number"
style="width: 100%" style="width: 100%"
:min="0" @input="(v)=>(scope.row.unitValue==1?scope.row.preNum=Number(v.replace(/[^\d.]/g,'')) : scope.row.preNum=Number(v.replace(/[^\d]/g,'')))" :min="0" @input="(v)=>(scope.row.unitValue==1?scope.row.preNum=Number(v.replace(/[^\d.]/g,'')) : scope.row.preNum=Number(v.replace(/[^\d]/g,'')))"
></el-input> ></el-input>
</template> </template>
</el-table-column> </el-table-column>
@ -456,7 +456,7 @@ export default {
for (let z of deviceTypeList) { for (let z of deviceTypeList) {
if (z.data.typeId === i) { if (z.data.typeId === i) {
const obj = JSON.parse(JSON.stringify(z.data)); const obj = JSON.parse(JSON.stringify(z.data));
obj.preNum = 1; obj.preNum = 0;
if(obj.storageNum<=0){ if(obj.storageNum<=0){
let index = this.deviceType.length; let index = this.deviceType.length;
if(index==1){ if(index==1){
@ -550,6 +550,13 @@ export default {
if (this.equipmentList.length > 0) { if (this.equipmentList.length > 0) {
this.$refs["maForm"].validate(async (valid) => { this.$refs["maForm"].validate(async (valid) => {
if (valid) { if (valid) {
for(let i = 0;i<this.equipmentList.length;i++){
if(this.equipmentList[i].preNum<=0){
this.$message.error(`${i + 1} 行的 ${'预领数量必须大于0'} `);
return
}
}
console.log("projectId", this.projectTemp); console.log("projectId", this.projectTemp);
await getAgreement({ await getAgreement({
unitId: this.maForm.unitId, unitId: this.maForm.unitId,

View File

@ -120,14 +120,14 @@
</el-table-column> </el-table-column>
<el-table-column <el-table-column
align="center" align="center"
width="160" width="100"
label="申请时间" label="申请时间"
prop="createTime" prop="createTime"
:show-overflow-tooltip="true"
/> />
<el-table-column <el-table-column
label="申请人" label="申请人"
width="150" width="100"
align="center" align="center"
prop="createBy" prop="createBy"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
@ -136,32 +136,35 @@
label="租赁单位" label="租赁单位"
align="center" align="center"
prop="leaseUnit" prop="leaseUnit"
width="150px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column <el-table-column
label="租赁工程" label="租赁工程"
align="center" align="center"
prop="leaseProject" prop="leaseProject"
width="150px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<!-- <el-table-column <el-table-column
label="领料物资类型" label="领料物资类型"
align="center" align="center"
prop="leaseType" prop="maTypeNames"
width="110px" width="110px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> --> />
<el-table-column <el-table-column
label="协议号" label="协议号"
align="center" align="center"
prop="agreementCode" prop="agreementCode"
width="140"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column <el-table-column
label="租赁申请单号" label="租赁申请单号"
align="center" align="center"
prop="code" prop="code"
width="110px" width="140px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
> >
</el-table-column> </el-table-column>
@ -180,14 +183,6 @@
width="120px" width="120px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column
label="操作时间"
align="center"
width="160"
prop="updateTime"
:show-overflow-tooltip="true"
/>
<el-table-column <el-table-column
label="状态" label="状态"
align="center" align="center"

View File

@ -238,8 +238,8 @@ export default {
/** 导出按钮操作 */ /** 导出按钮操作 */
handleExport() { handleExport() {
this.download( this.download(
"/material/purchase_check_info/exportDetails", "/material/lease_apply_info/exportDetails",
{ taskId: this.taskId }, { id: this.id },
`领料申请详情_${new Date().getTime()}.xlsx` `领料申请详情_${new Date().getTime()}.xlsx`
); );
}, },

View File

@ -72,10 +72,9 @@
</el-table-column> </el-table-column>
<el-table-column <el-table-column
align="center" align="center"
width="160" width="100"
label="申请时间" label="申请时间"
prop="createTime" prop="createTime"
:show-overflow-tooltip="true"
/> />
<el-table-column <el-table-column
label="申请人" label="申请人"
@ -88,32 +87,35 @@
label="租赁单位" label="租赁单位"
align="center" align="center"
prop="leaseUnit" prop="leaseUnit"
width="150px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column <el-table-column
label="租赁工程" label="租赁工程"
align="center" align="center"
prop="leaseProject" prop="leaseProject"
width="150px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<!-- <el-table-column <el-table-column
label="领料物资类型" label="领料物资类型"
align="center" align="center"
prop="leaseType" prop="maTypeNames"
width="110px" width="110px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> --> />
<el-table-column <el-table-column
label="协议号" label="协议号"
align="center" align="center"
prop="agreementCode" prop="agreementCode"
width="140px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column <el-table-column
label="租赁申请单号" label="租赁申请单号"
align="center" align="center"
prop="code" prop="code"
width="110px" width="140px"
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
> >
</el-table-column> </el-table-column>
@ -151,13 +153,6 @@
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column
label="操作时间"
align="center"
width="160"
prop="updateTime"
:show-overflow-tooltip="true"
/>
<el-table-column <el-table-column
label="状态" label="状态"
align="center" align="center"