Commit 337114dd authored by renjintao's avatar renjintao

split

parent ddf941b3
......@@ -39,7 +39,7 @@
</Col>
<Col span="12">
<FormItem label="分解数量" style="width:100%" prop="splitQuantity">
<InputNumber :min="1" v-model="orderForm.splitQuantity" :step="1" style="width:180px"></InputNumber>
<InputNumber :min="0" v-model="orderForm.splitQuantity" style="width:180px"></InputNumber>
<Button type="primary" @click="addSplitOrder">确定</Button>
</FormItem>
</Col>
......@@ -177,6 +177,11 @@ export default {
},
//确定增加数量
addSplitOrder() {
if (this.orderForm.splitQuantity < 2||this.orderForm.splitQuantity==undefined) {
this.dataList = [];
return;
}
if (this.orderForm.quantity >= this.orderForm.splitQuantity) {
this.dataListRetrun.items = [];
this.$refs["formValidate"].validate(valid => {
......@@ -267,7 +272,7 @@ export default {
this.orderForm = this.$u.clone(this.row);
this.orderForm.planStartTime = this.orderForm.demandStartDate;
this.orderForm.planEndTime = this.orderForm.demandFinishDate;
this.orderForm.splitQuantity = 2;
//this.orderForm.splitQuantity = 2;
this.dataListRetrun.id = this.orderForm.id;
this.dataListRetrun.quantity = this.orderForm.quantity;
this.dataListRetrun.mesCode = this.orderForm.mesCode;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment