添加原料临期设置
This commit is contained in:
parent
6757122d6e
commit
344e14a041
|
|
@ -99,6 +99,16 @@
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col> -->
|
</el-col> -->
|
||||||
|
|
||||||
|
<el-col :span="12">
|
||||||
|
<el-form-item label="临期天数" prop="shelfLifeDays">
|
||||||
|
<el-input v-model="form.shelfLifeDays"
|
||||||
|
placeholder="请输入临期天数"
|
||||||
|
maxlength="6" @input="(v)=>(form.shelfLifeDays=v.replace(/[^\d]/g,''))"
|
||||||
|
><template slot="append">天</template>
|
||||||
|
</el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="营养信息类别" prop="nutritionTypeId">
|
<el-form-item label="营养信息类别" prop="nutritionTypeId">
|
||||||
<el-cascader
|
<el-cascader
|
||||||
|
|
@ -243,10 +253,11 @@ export default {
|
||||||
materialName: '',//原料名称
|
materialName: '',//原料名称
|
||||||
areaId: null,//所属区域
|
areaId: null,//所属区域
|
||||||
materialTypeId: null,//原料类别
|
materialTypeId: null,//原料类别
|
||||||
salesMode: '1',//计量类型
|
salesMode: '2',//计量类型
|
||||||
unitId: '',//原料单位
|
unitId: '',//原料单位
|
||||||
unitPrice: '',//原料进价(元)
|
unitPrice: '0',//原料进价(元)
|
||||||
barCode: '',//条码
|
barCode: '',//条码
|
||||||
|
shelfLifeDays:0,//临期天数
|
||||||
nutritionTypeId:null,//营养信息类型
|
nutritionTypeId:null,//营养信息类型
|
||||||
nutritionId:null,//营养信息
|
nutritionId:null,//营养信息
|
||||||
//营养信息
|
//营养信息
|
||||||
|
|
@ -291,6 +302,7 @@ export default {
|
||||||
areaId: [{ required: true, message: '请选择所属区域', trigger: 'change' }],
|
areaId: [{ required: true, message: '请选择所属区域', trigger: 'change' }],
|
||||||
materialTypeId: [{ required: true, message: '请选择原料类别', trigger: 'change' }],
|
materialTypeId: [{ required: true, message: '请选择原料类别', trigger: 'change' }],
|
||||||
salesMode: [{ required: true, message: '请选择计量类型', trigger: 'change' }],
|
salesMode: [{ required: true, message: '请选择计量类型', trigger: 'change' }],
|
||||||
|
shelfLifeDays: [{ required: true, message: '请输入临期天数', trigger: 'change' }],
|
||||||
nutritionTypeId: [{ required: true, message: '请选择营养信息类别', trigger: 'change' }],
|
nutritionTypeId: [{ required: true, message: '请选择营养信息类别', trigger: 'change' }],
|
||||||
nutritionId: [{ required: true, message: '请选择营养信息', trigger: 'change' }],
|
nutritionId: [{ required: true, message: '请选择营养信息', trigger: 'change' }],
|
||||||
},
|
},
|
||||||
|
|
@ -514,6 +526,7 @@ export default {
|
||||||
this.$set(this.form,"salePrice",Number((row.salePrice/100).toFixed(2)))
|
this.$set(this.form,"salePrice",Number((row.salePrice/100).toFixed(2)))
|
||||||
this.$set(this.form,"unitPrice",Number((row.unitPrice/100).toFixed(2)))
|
this.$set(this.form,"unitPrice",Number((row.unitPrice/100).toFixed(2)))
|
||||||
this.$set(this.form,"barCode",row.barCode)
|
this.$set(this.form,"barCode",row.barCode)
|
||||||
|
this.$set(this.form,"shelfLifeDays",row.shelfLifeDays)
|
||||||
if(row.nutritionTypeId){
|
if(row.nutritionTypeId){
|
||||||
this.$set(this.form,"nutritionTypeId",Number(row.nutritionTypeId))
|
this.$set(this.form,"nutritionTypeId",Number(row.nutritionTypeId))
|
||||||
this.nutritionAllList(this.form.nutritionTypeId)
|
this.nutritionAllList(this.form.nutritionTypeId)
|
||||||
|
|
@ -566,10 +579,11 @@ export default {
|
||||||
materialName: '',//原料名称
|
materialName: '',//原料名称
|
||||||
areaId: null,//所属区域
|
areaId: null,//所属区域
|
||||||
materialTypeId: null,//原料类别
|
materialTypeId: null,//原料类别
|
||||||
salesMode: '1',//计量类型
|
salesMode: '2',//计量类型
|
||||||
unitId: '',//原料单位
|
unitId: '',//原料单位
|
||||||
unitPrice: '',//原料进价(元)
|
unitPrice: '0',//原料进价(元)
|
||||||
barCode: '',//条码
|
barCode: '',//条码
|
||||||
|
shelfLifeDays:0,
|
||||||
nutritionType:null,//营养信息类型
|
nutritionType:null,//营养信息类型
|
||||||
nutritionId:null,//营养信息
|
nutritionId:null,//营养信息
|
||||||
//营养信息
|
//营养信息
|
||||||
|
|
|
||||||
|
|
@ -26,6 +26,13 @@
|
||||||
<el-form-item label="批次号" prop="intoCode">
|
<el-form-item label="批次号" prop="intoCode">
|
||||||
<el-input v-model="queryParams.intoCode" placeholder="请输入批次号" maxlength="30" clearable style="width: 240px"/>
|
<el-input v-model="queryParams.intoCode" placeholder="请输入批次号" maxlength="30" clearable style="width: 240px"/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="过期状态" prop="expireState">
|
||||||
|
<el-select v-model="queryParams.expireState" placeholder="请选择过期状态" style="width: 240px;">
|
||||||
|
<el-option label="过期" :value="1"></el-option>
|
||||||
|
<el-option label="保质期内" :value="2"></el-option>
|
||||||
|
<el-option label="临期" :value="3"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
|
|
@ -63,6 +70,7 @@
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span v-if="scope.row.expireState==1">过期</span>
|
<span v-if="scope.row.expireState==1">过期</span>
|
||||||
<span v-if="scope.row.expireState==2">保质期内</span>
|
<span v-if="scope.row.expireState==2">保质期内</span>
|
||||||
|
<span v-if="scope.row.expireState==3">临期</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="剩余天数" align="center" prop="expireDay" :show-overflow-tooltip="true" width="120"/>
|
<el-table-column label="剩余天数" align="center" prop="expireDay" :show-overflow-tooltip="true" width="120"/>
|
||||||
|
|
@ -201,6 +209,7 @@ export default {
|
||||||
"warehouseId": this.queryParams.warehouseId,
|
"warehouseId": this.queryParams.warehouseId,
|
||||||
"materialName": this.queryParams.materialName,
|
"materialName": this.queryParams.materialName,
|
||||||
"intoCode": this.queryParams.intoCode,
|
"intoCode": this.queryParams.intoCode,
|
||||||
|
"expireState": this.queryParams.expireState,
|
||||||
}
|
}
|
||||||
stockExpireWarningPageApi(param).then(response => {
|
stockExpireWarningPageApi(param).then(response => {
|
||||||
this.tableListData = response.rows;
|
this.tableListData = response.rows;
|
||||||
|
|
|
||||||
|
|
@ -804,7 +804,7 @@ export default {
|
||||||
deptId:225
|
deptId:225
|
||||||
}
|
}
|
||||||
listUserAll(param).then((response) => {
|
listUserAll(param).then((response) => {
|
||||||
this.supplierUserList = response.rows
|
this.supplierUserList = response.rows;
|
||||||
// this.total = response.total
|
// this.total = response.total
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
@ -904,6 +904,7 @@ export default {
|
||||||
})
|
})
|
||||||
this.$set(this.form,"categoryIdList",arr)
|
this.$set(this.form,"categoryIdList",arr)
|
||||||
this.$set(this.form,"supplierUserId",Number(row.supplierUserId))
|
this.$set(this.form,"supplierUserId",Number(row.supplierUserId))
|
||||||
|
|
||||||
this.open = true;
|
this.open = true;
|
||||||
this.title = "修改";
|
this.title = "修改";
|
||||||
},
|
},
|
||||||
|
|
@ -914,6 +915,7 @@ export default {
|
||||||
},
|
},
|
||||||
// 表单重置
|
// 表单重置
|
||||||
reset() {
|
reset() {
|
||||||
|
this.getSupplierUserList()
|
||||||
this.activeName='baseInfo'
|
this.activeName='baseInfo'
|
||||||
this.fileList1=[]
|
this.fileList1=[]
|
||||||
this.idCardImgZ=[]
|
this.idCardImgZ=[]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue