|
@@ -2,18 +2,17 @@
|
|
|
<div class="changeDetail">
|
|
<div class="changeDetail">
|
|
|
<Toptitle title="变更">
|
|
<Toptitle title="变更">
|
|
|
<slot name="titleButton">
|
|
<slot name="titleButton">
|
|
|
- <Button
|
|
|
|
|
- @click="handleFinish()"
|
|
|
|
|
- type="primary"
|
|
|
|
|
- style="margin-right: 10px"
|
|
|
|
|
- >变更保存</Button
|
|
|
|
|
- >
|
|
|
|
|
- <Button
|
|
|
|
|
|
|
+ <Button
|
|
|
@click="goback()"
|
|
@click="goback()"
|
|
|
type="primary"
|
|
type="primary"
|
|
|
ghost
|
|
ghost
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
|
- >取消</Button
|
|
|
|
|
|
|
+ >取消</Button>
|
|
|
|
|
+ <Button
|
|
|
|
|
+ @click="handleFinish()"
|
|
|
|
|
+ type="primary"
|
|
|
|
|
+ style="margin-right: 10px"
|
|
|
|
|
+ >变更保存</Button
|
|
|
>
|
|
>
|
|
|
</slot>
|
|
</slot>
|
|
|
</Toptitle>
|
|
</Toptitle>
|
|
@@ -22,7 +21,7 @@
|
|
|
<div class="form_content">
|
|
<div class="form_content">
|
|
|
<Form
|
|
<Form
|
|
|
:model="formData"
|
|
:model="formData"
|
|
|
- :label-width="100"
|
|
|
|
|
|
|
+ :label-width="80"
|
|
|
class="form_content_header"
|
|
class="form_content_header"
|
|
|
>
|
|
>
|
|
|
<FormItem label="楼幢:">
|
|
<FormItem label="楼幢:">
|
|
@@ -136,7 +135,7 @@
|
|
|
<div><span>工艺属性:</span>{{ formData.process_property }}</div>
|
|
<div><span>工艺属性:</span>{{ formData.process_property }}</div>
|
|
|
<div><span>图号:</span>{{ formData.url_number }}</div>
|
|
<div><span>图号:</span>{{ formData.url_number }}</div>
|
|
|
<div style="display:flex;">
|
|
<div style="display:flex;">
|
|
|
- <span style="width:50px;">图纸:</span>
|
|
|
|
|
|
|
+ <span style="width:97px;">图纸:</span>
|
|
|
<div>
|
|
<div>
|
|
|
<span
|
|
<span
|
|
|
v-for="item in formData.url"
|
|
v-for="item in formData.url"
|
|
@@ -175,7 +174,7 @@
|
|
|
style="width: auto"
|
|
style="width: auto"
|
|
|
>{{this.$route.query.order_no}}</span>
|
|
>{{this.$route.query.order_no}}</span>
|
|
|
</FormItem>
|
|
</FormItem>
|
|
|
- <FormItem label="接受部门:">
|
|
|
|
|
|
|
+ <FormItem label="接收部门:">
|
|
|
<Select
|
|
<Select
|
|
|
filterable
|
|
filterable
|
|
|
clearable
|
|
clearable
|
|
@@ -339,7 +338,7 @@
|
|
|
/>
|
|
/>
|
|
|
</div>
|
|
</div>
|
|
|
<template style="flex" >
|
|
<template style="flex" >
|
|
|
- <div style="display: flex; justify-content: center" v-if="row.status ==0||row.status == 1">
|
|
|
|
|
|
|
+ <div style="display: flex; justify-content: center" v-if="row.input_state">
|
|
|
<Icon
|
|
<Icon
|
|
|
size="50"
|
|
size="50"
|
|
|
@click="
|
|
@click="
|
|
@@ -387,7 +386,7 @@
|
|
|
<span v-else>{{ tableData[index].model }}</span>
|
|
<span v-else>{{ tableData[index].model }}</span>
|
|
|
</template>
|
|
</template>
|
|
|
<template slot="status" slot-scope="{ row }">
|
|
<template slot="status" slot-scope="{ row }">
|
|
|
- <span>{{ row.status === 0||4 ?'变更':'新增' }}</span>
|
|
|
|
|
|
|
+ <span>{{ row.status === 5 ||row.status === 0||row.status === 2?'':row.status === 4?'变更':'新增' }}</span>
|
|
|
</template>
|
|
</template>
|
|
|
<template slot="long" slot-scope="{ row, index }">
|
|
<template slot="long" slot-scope="{ row, index }">
|
|
|
<Input
|
|
<Input
|
|
@@ -420,18 +419,25 @@
|
|
|
<span v-else>{{ tableData[index].high }}</span>
|
|
<span v-else>{{ tableData[index].high }}</span>
|
|
|
</template>
|
|
</template>
|
|
|
<template slot="set" slot-scope="{ row, index }">
|
|
<template slot="set" slot-scope="{ row, index }">
|
|
|
- <a
|
|
|
|
|
|
|
+ <a
|
|
|
style="margin: 0 5px; color: #2d8cf0;"
|
|
style="margin: 0 5px; color: #2d8cf0;"
|
|
|
- @click="handleSet(row, index, 1)"
|
|
|
|
|
- v-show="row.change_state"
|
|
|
|
|
|
|
+ @click="handleSet(row, index, 4)"
|
|
|
|
|
+ v-show="row.status == 5 ||row.status == 0 && row.del "
|
|
|
>变更</a
|
|
>变更</a
|
|
|
>
|
|
>
|
|
|
<a
|
|
<a
|
|
|
|
|
+ style="margin: 0 5px; color: rgb(58 199 101);"
|
|
|
|
|
+ @click="handleSet(row, index, 1)"
|
|
|
|
|
+ v-show="row.status == 4 && row.del "
|
|
|
|
|
+ >确认</a
|
|
|
|
|
+ >
|
|
|
|
|
+ <a
|
|
|
style="margin: 0 5px; color: #2d8cf0;"
|
|
style="margin: 0 5px; color: #2d8cf0;"
|
|
|
@click="handleSet(row, index, 2)"
|
|
@click="handleSet(row, index, 2)"
|
|
|
|
|
+ v-show="row.del"
|
|
|
>复制</a
|
|
>复制</a
|
|
|
>
|
|
>
|
|
|
- <a style="margin: 0 5px; color: red" @click="handleSet(row, index, 3)"
|
|
|
|
|
|
|
+ <a style="margin: 0 5px; color: red" @click="handleSet(row, index, 3)" v-show="row.del"
|
|
|
>删除</a
|
|
>删除</a
|
|
|
>
|
|
>
|
|
|
</template>
|
|
</template>
|
|
@@ -471,6 +477,7 @@ export default {
|
|
|
room_number: "",
|
|
room_number: "",
|
|
|
floor: "",
|
|
floor: "",
|
|
|
product_title: "",
|
|
product_title: "",
|
|
|
|
|
+ copy_data:[],
|
|
|
pic_number: "",
|
|
pic_number: "",
|
|
|
depart_end:'',
|
|
depart_end:'',
|
|
|
depart_start:'',
|
|
depart_start:'',
|
|
@@ -487,6 +494,7 @@ export default {
|
|
|
product_title_list: [],
|
|
product_title_list: [],
|
|
|
pic_number_list: [],
|
|
pic_number_list: [],
|
|
|
tableColumns: [
|
|
tableColumns: [
|
|
|
|
|
+ { title: "序号", align: "center", width: 100, key: "table_id" },
|
|
|
{
|
|
{
|
|
|
title: "楼栋",
|
|
title: "楼栋",
|
|
|
key: "house",
|
|
key: "house",
|
|
@@ -621,7 +629,7 @@ export default {
|
|
|
],
|
|
],
|
|
|
tableData: [],
|
|
tableData: [],
|
|
|
ListColumns: [
|
|
ListColumns: [
|
|
|
- { title: "序号", align: "center", minWidth: 100, type: "index" },
|
|
|
|
|
|
|
+ { title: "序号", align: "center", minWidth: 100, key: "table_id" },
|
|
|
{ title: "楼栋", key: "house", align: "center", minWidth: 100 },
|
|
{ title: "楼栋", key: "house", align: "center", minWidth: 100 },
|
|
|
{ title: "楼单元", key: "unit", align: "center", minWidth: 100 },
|
|
{ title: "楼单元", key: "unit", align: "center", minWidth: 100 },
|
|
|
{ title: "楼层", key: "layer", align: "center", minWidth: 100 },
|
|
{ title: "楼层", key: "layer", align: "center", minWidth: 100 },
|
|
@@ -726,6 +734,7 @@ export default {
|
|
|
}).then(res=>{
|
|
}).then(res=>{
|
|
|
if(res.code == 200){
|
|
if(res.code == 200){
|
|
|
this.$Message.success(res.msg)
|
|
this.$Message.success(res.msg)
|
|
|
|
|
+ this.goback()
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|
|
@@ -745,6 +754,8 @@ export default {
|
|
|
id: '',
|
|
id: '',
|
|
|
input_state: true,
|
|
input_state: true,
|
|
|
layer: '',
|
|
layer: '',
|
|
|
|
|
+ del:true,
|
|
|
|
|
+ table_id:null,
|
|
|
model: "",
|
|
model: "",
|
|
|
number: '',
|
|
number: '',
|
|
|
order_area_id: '',
|
|
order_area_id: '',
|
|
@@ -799,17 +810,23 @@ export default {
|
|
|
handleSet(row, index, type) {
|
|
handleSet(row, index, type) {
|
|
|
switch (type) {
|
|
switch (type) {
|
|
|
case 1:
|
|
case 1:
|
|
|
- this.tableData[index].input_state = true;
|
|
|
|
|
- row.input_state = true;
|
|
|
|
|
- this.tableData[index].status = 0;
|
|
|
|
|
|
|
+
|
|
|
if (!row.check_state) {
|
|
if (!row.check_state) {
|
|
|
- row.state = "变更";
|
|
|
|
|
- this.ListData.push(row);
|
|
|
|
|
- this.tableData[index].check_state = true;
|
|
|
|
|
|
|
+ this.copy_data[row.table_id-1].state = '变更';
|
|
|
|
|
+ this.ListData.push(this.copy_data[row.table_id-1]);
|
|
|
|
|
+ this.tableData[index].check_state = true; //已经更改过
|
|
|
row.check_state = true;
|
|
row.check_state = true;
|
|
|
|
|
+ this.tableData[index].input_state = false;
|
|
|
|
|
+ row.input_state = false;
|
|
|
|
|
+ this.tableData[index].status = 0;
|
|
|
|
|
+ row.status = 0;
|
|
|
console.log(row);
|
|
console.log(row);
|
|
|
} else {
|
|
} else {
|
|
|
- this.$Message.warning("不可重复变更!");
|
|
|
|
|
|
|
+ row.state = '变更'
|
|
|
|
|
+ this.tableData[index].input_state = false;
|
|
|
|
|
+ row.input_state =false;
|
|
|
|
|
+ this.tableData[index].status = 0;
|
|
|
|
|
+ row.status =0;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
case 2:
|
|
case 2:
|
|
@@ -818,6 +835,7 @@ export default {
|
|
|
this.tableData[index+1].status = 1;
|
|
this.tableData[index+1].status = 1;
|
|
|
this.tableData[index + 1].input_state = true;
|
|
this.tableData[index + 1].input_state = true;
|
|
|
this.tableData[index + 1].change_state = false;
|
|
this.tableData[index + 1].change_state = false;
|
|
|
|
|
+ this.tableData[index+1].table_id = null;
|
|
|
//标记是复制的数据
|
|
//标记是复制的数据
|
|
|
this.tableData[index + 1].copy_state = true;
|
|
this.tableData[index + 1].copy_state = true;
|
|
|
console.log(row);
|
|
console.log(row);
|
|
@@ -826,10 +844,54 @@ export default {
|
|
|
this.confirmDelete({
|
|
this.confirmDelete({
|
|
|
content: "确认删除么?",
|
|
content: "确认删除么?",
|
|
|
then: () => {
|
|
then: () => {
|
|
|
- let arr = this.tableData.splice(index, 1);
|
|
|
|
|
|
|
+ let airArr ={
|
|
|
|
|
+ long: "",
|
|
|
|
|
+ high: "",
|
|
|
|
|
+ wide: "",
|
|
|
|
|
+ change_state: false,
|
|
|
|
|
+ status:2,
|
|
|
|
|
+ copy_state:true,
|
|
|
|
|
+ check_state: true,
|
|
|
|
|
+ explode_status: '',
|
|
|
|
|
+ house: '',
|
|
|
|
|
+ house_id: "",
|
|
|
|
|
+ id: '',
|
|
|
|
|
+ input_state: false,
|
|
|
|
|
+ layer: '',
|
|
|
|
|
+ model: "",
|
|
|
|
|
+ table_id:null,
|
|
|
|
|
+ number: '',
|
|
|
|
|
+ order_area_id: '',
|
|
|
|
|
+ order_area_product_id: '',
|
|
|
|
|
+ order_no: "",
|
|
|
|
|
+ position: "",
|
|
|
|
|
+ price: null,
|
|
|
|
|
+ product_id: '',
|
|
|
|
|
+ product_unit: "",
|
|
|
|
|
+ real_price: '',
|
|
|
|
|
+ sign_id: "",
|
|
|
|
|
+ title: "",
|
|
|
|
|
+ type_id: '',
|
|
|
|
|
+ type_title: "",
|
|
|
|
|
+ del:false,
|
|
|
|
|
+ unit: '',
|
|
|
|
|
+ url: [],
|
|
|
|
|
+ url_number: "",
|
|
|
|
|
+ _index: '',
|
|
|
|
|
+ _rowKey: '',
|
|
|
|
|
+ };
|
|
|
|
|
+ this.tableData.splice(index, 1);
|
|
|
if (row.copy_state||row.check_state) {
|
|
if (row.copy_state||row.check_state) {
|
|
|
- return;
|
|
|
|
|
|
|
+ this.ListData.forEach(_item=>{
|
|
|
|
|
+ if(_item.table_id === row.table_id){
|
|
|
|
|
+ this.tableData.splice(index,0,airArr);
|
|
|
|
|
+ _item.state = '删除';
|
|
|
|
|
+ _item.status = 2;
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
} else {
|
|
} else {
|
|
|
|
|
+ this.tableData.splice(index,0,airArr);
|
|
|
|
|
+ let arr = this.copy_data.slice(row.table_id-1,row.table_id)
|
|
|
arr[0].state = "删除";
|
|
arr[0].state = "删除";
|
|
|
arr[0].status =2;
|
|
arr[0].status =2;
|
|
|
this.ListData = [...this.ListData, ...arr];
|
|
this.ListData = [...this.ListData, ...arr];
|
|
@@ -837,7 +899,13 @@ export default {
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
-
|
|
|
|
|
|
|
+ break;
|
|
|
|
|
+ case 4:
|
|
|
|
|
+ this.tableData[index].input_state = true;
|
|
|
|
|
+ row.input_state = true;
|
|
|
|
|
+ this.tableData[index].status = 4;
|
|
|
|
|
+ row.status = 4;
|
|
|
|
|
+ break;
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
getListData() {},
|
|
getListData() {},
|
|
@@ -857,15 +925,18 @@ export default {
|
|
|
console.log(res);
|
|
console.log(res);
|
|
|
this.tableData = res.data.detail;
|
|
this.tableData = res.data.detail;
|
|
|
this.formData =res.data;
|
|
this.formData =res.data;
|
|
|
- this.tableData.forEach((item) => {
|
|
|
|
|
|
|
+ this.tableData.forEach((item,index) => {
|
|
|
item.long = item.measure.split("*")[0];
|
|
item.long = item.measure.split("*")[0];
|
|
|
item.wide = item.measure.split("*")[1];
|
|
item.wide = item.measure.split("*")[1];
|
|
|
item.high = item.measure.split("*")[2];
|
|
item.high = item.measure.split("*")[2];
|
|
|
- item.status =4;
|
|
|
|
|
|
|
+ item.del = true;
|
|
|
|
|
+ item.table_id = index+1;
|
|
|
|
|
+ item.status =5;
|
|
|
item.input_state = false; //是否为input框
|
|
item.input_state = false; //是否为input框
|
|
|
item.check_state = false; //是否已经变更过
|
|
item.check_state = false; //是否已经变更过
|
|
|
item.change_state = true; //变更操作是否存在
|
|
item.change_state = true; //变更操作是否存在
|
|
|
});
|
|
});
|
|
|
|
|
+ this.copy_data =JSON.parse(JSON.stringify(this.tableData));
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
},
|
|
},
|
|
@@ -880,9 +951,9 @@ export default {
|
|
|
display: flex;
|
|
display: flex;
|
|
|
flex-wrap: wrap;
|
|
flex-wrap: wrap;
|
|
|
div {
|
|
div {
|
|
|
- width: 200px;
|
|
|
|
|
|
|
+ width: 170px;
|
|
|
font-size: 14px;
|
|
font-size: 14px;
|
|
|
- margin: 10px;
|
|
|
|
|
|
|
+ margin: 10px 41px;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|