|
@@ -292,30 +292,35 @@
|
|
|
<template slot="label"> 所属厂房 </template>
|
|
<template slot="label"> 所属厂房 </template>
|
|
|
<el-form-item label-width="0">
|
|
<el-form-item label-width="0">
|
|
|
<FactoryAreaSelect
|
|
<FactoryAreaSelect
|
|
|
|
|
+ placeholder="请选择工厂"
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
|
v-model="zcInfo.factoryRoomId1"
|
|
v-model="zcInfo.factoryRoomId1"
|
|
|
:augr="1"
|
|
:augr="1"
|
|
|
/>
|
|
/>
|
|
|
<FactoryAreaSelect
|
|
<FactoryAreaSelect
|
|
|
|
|
+ placeholder="请选择厂房"
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
|
v-model="zcInfo.factoryRoomId2"
|
|
v-model="zcInfo.factoryRoomId2"
|
|
|
:augr="2"
|
|
:augr="2"
|
|
|
/>
|
|
/>
|
|
|
<FactoryAreaSelect
|
|
<FactoryAreaSelect
|
|
|
|
|
+ placeholder="请选择车间"
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
|
v-model="zcInfo.factoryRoomId3"
|
|
v-model="zcInfo.factoryRoomId3"
|
|
|
:augr="3"
|
|
:augr="3"
|
|
|
/>
|
|
/>
|
|
|
<FactoryAreaSelect
|
|
<FactoryAreaSelect
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
|
|
|
+ placeholder="请选择产线"
|
|
|
v-model="zcInfo.factoryRoomId4"
|
|
v-model="zcInfo.factoryRoomId4"
|
|
|
:augr="4"
|
|
:augr="4"
|
|
|
/>
|
|
/>
|
|
|
- <el-input
|
|
|
|
|
- placeholder="请输入"
|
|
|
|
|
|
|
+ <FactoryAreaSelect
|
|
|
|
|
+ style="margin-right: 10px"
|
|
|
|
|
+ placeholder="请输入工位"
|
|
|
v-model="zcInfo.factoryRoomId5"
|
|
v-model="zcInfo.factoryRoomId5"
|
|
|
- style="width: 20%"
|
|
|
|
|
- ></el-input>
|
|
|
|
|
|
|
+ :augr="5"
|
|
|
|
|
+ />
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-descriptions-item>
|
|
</el-descriptions-item>
|
|
|
<el-descriptions-item :span="4">
|
|
<el-descriptions-item :span="4">
|
|
@@ -332,7 +337,7 @@
|
|
|
:options="options.cityDataLabel"
|
|
:options="options.cityDataLabel"
|
|
|
></el-cascader>
|
|
></el-cascader>
|
|
|
</div> -->
|
|
</div> -->
|
|
|
- <el-select
|
|
|
|
|
|
|
+ <!-- <el-select
|
|
|
filterable
|
|
filterable
|
|
|
v-model="positionInfo.factoryCode"
|
|
v-model="positionInfo.factoryCode"
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
@@ -345,14 +350,14 @@
|
|
|
:value="item.id"
|
|
:value="item.id"
|
|
|
@click.native="changeWarehouse(item)"
|
|
@click.native="changeWarehouse(item)"
|
|
|
></el-option>
|
|
></el-option>
|
|
|
- </el-select>
|
|
|
|
|
|
|
+ </el-select> -->
|
|
|
<!-- <factorySelect
|
|
<!-- <factorySelect
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
|
v-model="positionInfo.factoryCode"
|
|
v-model="positionInfo.factoryCode"
|
|
|
placeholder="请选择工厂"
|
|
placeholder="请选择工厂"
|
|
|
@selfChange="hanldFactoryCode"
|
|
@selfChange="hanldFactoryCode"
|
|
|
/> -->
|
|
/> -->
|
|
|
- <el-select
|
|
|
|
|
|
|
+ <!-- <el-select
|
|
|
filterable
|
|
filterable
|
|
|
clearable
|
|
clearable
|
|
|
v-model="positionInfo.workshopCode"
|
|
v-model="positionInfo.workshopCode"
|
|
@@ -365,7 +370,7 @@
|
|
|
:value="item.id"
|
|
:value="item.id"
|
|
|
@click.native="twoClick(item)"
|
|
@click.native="twoClick(item)"
|
|
|
></el-option>
|
|
></el-option>
|
|
|
- </el-select>
|
|
|
|
|
|
|
+ </el-select> -->
|
|
|
<!-- <WorkshopSelect
|
|
<!-- <WorkshopSelect
|
|
|
style="margin-right: 10px"
|
|
style="margin-right: 10px"
|
|
|
ref="WorkshopSelectRef"
|
|
ref="WorkshopSelectRef"
|
|
@@ -382,7 +387,7 @@
|
|
|
@selfChange="hanldlineCodeCode"
|
|
@selfChange="hanldlineCodeCode"
|
|
|
placeholder="请选择产线"
|
|
placeholder="请选择产线"
|
|
|
/> -->
|
|
/> -->
|
|
|
- <el-select
|
|
|
|
|
|
|
+ <!-- <el-select
|
|
|
clearable
|
|
clearable
|
|
|
filterable
|
|
filterable
|
|
|
v-model="positionInfo.lineCode"
|
|
v-model="positionInfo.lineCode"
|
|
@@ -396,13 +401,17 @@
|
|
|
positionInfo.lineName = item.goodsshelvesCode
|
|
positionInfo.lineName = item.goodsshelvesCode
|
|
|
"
|
|
"
|
|
|
></el-option>
|
|
></el-option>
|
|
|
- </el-select>
|
|
|
|
|
- <!-- <el-input
|
|
|
|
|
- style="margin-right: 10px"
|
|
|
|
|
- class="item item-input"
|
|
|
|
|
|
|
+ </el-select> -->
|
|
|
|
|
+ <el-cascader
|
|
|
|
|
+ clearable
|
|
|
|
|
+ v-model="form.location"
|
|
|
|
|
+ :options="options.cityDataLabel"
|
|
|
|
|
+ ></el-cascader>
|
|
|
|
|
+ <el-input
|
|
|
|
|
+ style="width: 30%; margin-left: 10px"
|
|
|
placeholder="详细地址"
|
|
placeholder="详细地址"
|
|
|
v-model="positionInfo.detailPosition"
|
|
v-model="positionInfo.detailPosition"
|
|
|
- ></el-input> -->
|
|
|
|
|
|
|
+ ></el-input>
|
|
|
<!-- <el-input
|
|
<!-- <el-input
|
|
|
class="detail"
|
|
class="detail"
|
|
|
clearable
|
|
clearable
|
|
@@ -800,6 +809,11 @@
|
|
|
assetInfo: {},
|
|
assetInfo: {},
|
|
|
// 资产信息
|
|
// 资产信息
|
|
|
zcInfo: {
|
|
zcInfo: {
|
|
|
|
|
+ factoryRoomId1: '',
|
|
|
|
|
+ factoryRoomId2: '',
|
|
|
|
|
+ factoryRoomId3: '',
|
|
|
|
|
+ factoryRoomId4: '',
|
|
|
|
|
+ factoryRoomId5: '',
|
|
|
// 固定资产编码
|
|
// 固定资产编码
|
|
|
fixCode: '',
|
|
fixCode: '',
|
|
|
// 颜色
|
|
// 颜色
|
|
@@ -918,7 +932,7 @@
|
|
|
await this.getInfo();
|
|
await this.getInfo();
|
|
|
this.title = '编辑设备信息';
|
|
this.title = '编辑设备信息';
|
|
|
// this.getgys();
|
|
// this.getgys();
|
|
|
- await this._getWarehouseChildren();
|
|
|
|
|
|
|
+ // await this._getWarehouseChildren();
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
@@ -1094,13 +1108,7 @@
|
|
|
let par = {
|
|
let par = {
|
|
|
//基本信息
|
|
//基本信息
|
|
|
...this.form,
|
|
...this.form,
|
|
|
- // id: this.basicInfo.id,
|
|
|
|
|
- // assetCode: this.form.code,
|
|
|
|
|
- // assetName: this.form.name,
|
|
|
|
|
assetType: 1,
|
|
assetType: 1,
|
|
|
- // informationId: this.basicInfo.id,
|
|
|
|
|
- // productTime: this.form.productTime,
|
|
|
|
|
- // expirationTime: this.expirationTime,
|
|
|
|
|
// 资产信息
|
|
// 资产信息
|
|
|
positionIds: '1,1,1,1',
|
|
positionIds: '1,1,1,1',
|
|
|
...this.zcInfo,
|
|
...this.zcInfo,
|
|
@@ -1127,6 +1135,8 @@
|
|
|
type: '1',
|
|
type: '1',
|
|
|
num: 1
|
|
num: 1
|
|
|
},
|
|
},
|
|
|
|
|
+ factoryRoomId: '',
|
|
|
|
|
+ factoryRoomName: '',
|
|
|
// 文档信息
|
|
// 文档信息
|
|
|
attUrl: this.setWd() || [],
|
|
attUrl: this.setWd() || [],
|
|
|
// // 设备图片
|
|
// // 设备图片
|
|
@@ -1137,6 +1147,20 @@
|
|
|
|
|
|
|
|
// extInfoSelf: this.setKz()
|
|
// extInfoSelf: this.setKz()
|
|
|
};
|
|
};
|
|
|
|
|
+ const factoryRoomIds = [
|
|
|
|
|
+ this.zcInfo.factoryRoomId1,
|
|
|
|
|
+ this.zcInfo.factoryRoomId2,
|
|
|
|
|
+ this.zcInfo.factoryRoomId3,
|
|
|
|
|
+ this.zcInfo.factoryRoomId4,
|
|
|
|
|
+ this.zcInfo.factoryRoomId5
|
|
|
|
|
+ ];
|
|
|
|
|
+ const nonEmptyFactoryRoomIds = factoryRoomIds.filter((id) => id);
|
|
|
|
|
+ par.position.pathIds = nonEmptyFactoryRoomIds.join(',');
|
|
|
|
|
+
|
|
|
|
|
+ //==
|
|
|
|
|
+ par.deviceLocationName = par.location.toString();
|
|
|
|
|
+ // par.sss = par.position.detailPosition;
|
|
|
|
|
+ //==
|
|
|
//============================
|
|
//============================
|
|
|
par.extInfo = { ...this.zcInfo };
|
|
par.extInfo = { ...this.zcInfo };
|
|
|
let obj = {};
|
|
let obj = {};
|
|
@@ -1194,6 +1218,7 @@
|
|
|
const data = await getAssetInfo(this.id);
|
|
const data = await getAssetInfo(this.id);
|
|
|
data.extInfoSelf = data.extInfoSelf || [];
|
|
data.extInfoSelf = data.extInfoSelf || [];
|
|
|
this.form = data;
|
|
this.form = data;
|
|
|
|
|
+ this.form.location = data.deviceLocationName.split(',');
|
|
|
|
|
|
|
|
this.basicInfo = data.category;
|
|
this.basicInfo = data.category;
|
|
|
this.assetInfo = data.category.category;
|
|
this.assetInfo = data.category.category;
|
|
@@ -1207,14 +1232,15 @@
|
|
|
const pathIds = data.positionList[0].pathIds.split(',');
|
|
const pathIds = data.positionList[0].pathIds.split(',');
|
|
|
const pathName = data.positionList[0].pathName.split(',');
|
|
const pathName = data.positionList[0].pathName.split(',');
|
|
|
|
|
|
|
|
- this.positionInfo.factoryCode = pathIds[0];
|
|
|
|
|
- this.positionInfo.factoryName = pathName[0];
|
|
|
|
|
|
|
+ this.zcInfo.factoryRoomId1 = pathIds[0];
|
|
|
|
|
+
|
|
|
|
|
+ this.zcInfo.factoryRoomId2 = pathIds[1];
|
|
|
|
|
+
|
|
|
|
|
+ this.zcInfo.factoryRoomId3 = pathIds[2];
|
|
|
|
|
|
|
|
- this.positionInfo.workshopCode = pathIds[1];
|
|
|
|
|
- this.positionInfo.workshopName = pathName[1];
|
|
|
|
|
|
|
+ this.zcInfo.factoryRoomId4 = pathIds[3];
|
|
|
|
|
|
|
|
- this.positionInfo.lineCode = pathIds[2];
|
|
|
|
|
- this.positionInfo.lineName = pathName[2];
|
|
|
|
|
|
|
+ this.zcInfo.factoryRoomId5 = pathIds[4];
|
|
|
|
|
|
|
|
this.$nextTick(() => {
|
|
this.$nextTick(() => {
|
|
|
// this.$refs.WorkshopSelectRef.getList();
|
|
// this.$refs.WorkshopSelectRef.getList();
|
|
@@ -1250,10 +1276,10 @@
|
|
|
};
|
|
};
|
|
|
this.isLink = true;
|
|
this.isLink = true;
|
|
|
}
|
|
}
|
|
|
- // 资产信息
|
|
|
|
|
- for (const key of Object.keys(this.zcInfo)) {
|
|
|
|
|
- this.zcInfo[key] = data[key];
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ // // 资产信息
|
|
|
|
|
+ // for (const key of Object.keys(this.zcInfo)) {
|
|
|
|
|
+ // this.zcInfo[key] = data[key];
|
|
|
|
|
+ // }
|
|
|
this.getwhbm();
|
|
this.getwhbm();
|
|
|
this.getqsbm();
|
|
this.getqsbm();
|
|
|
if (data.attUrl && data.attUrl.length > 0) {
|
|
if (data.attUrl && data.attUrl.length > 0) {
|