|
@@ -33,7 +33,16 @@
|
|
|
<u-list @scrolltolower="scrolltolower" class="z_list">
|
|
<u-list @scrolltolower="scrolltolower" class="z_list">
|
|
|
|
|
|
|
|
<view v-if="actTab == '物品清单'">
|
|
<view v-if="actTab == '物品清单'">
|
|
|
- <checkbox-group v-for="(item, index) in pickOutInList" :key="index">
|
|
|
|
|
|
|
+ <view style="margin-left: 24rpx">
|
|
|
|
|
+ <checkbox v-if="!seletedAll" color="#fff" :checked="seletedAll" @tap="_seletedAll">全选
|
|
|
|
|
+ </checkbox>
|
|
|
|
|
+ <checkbox class="select-all" color="#fff" v-else :checked="seletedAll" @tap="_seletedAll">
|
|
|
|
|
+ 取消全选
|
|
|
|
|
+ </checkbox>
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+ <checkbox-group v-for="(item, index) in pickOutInList" :key="index"
|
|
|
|
|
+ @change="e => selectVal(e, item, index)">
|
|
|
<label class="listBox rx-bs">
|
|
<label class="listBox rx-bs">
|
|
|
|
|
|
|
|
<view class="listBox-sel">
|
|
<view class="listBox-sel">
|
|
@@ -93,6 +102,8 @@
|
|
|
|
|
|
|
|
</checkbox-group>
|
|
</checkbox-group>
|
|
|
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
</view>
|
|
</view>
|
|
|
|
|
|
|
|
<view v-if="actTab == '带料清单'">
|
|
<view v-if="actTab == '带料清单'">
|
|
@@ -101,47 +112,88 @@
|
|
|
<view></view>
|
|
<view></view>
|
|
|
<view class="right_box rx-ec">
|
|
<view class="right_box rx-ec">
|
|
|
<u-button type="success" size="small" class="u-reset-button" @click="addPicking(2)"
|
|
<u-button type="success" size="small" class="u-reset-button" @click="addPicking(2)"
|
|
|
- text="添加物料"></u-button>
|
|
|
|
|
|
|
+ text="添加"></u-button>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
+ <view v-for="(item, index) in bomMaterialList" :key="index">
|
|
|
|
|
+ <label class="listBox rx-bs">
|
|
|
|
|
+
|
|
|
|
|
+ <view class="listBox-sel">
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+ <view class="listBox-con">
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ <view class="listBox-bottom rx">
|
|
|
|
|
+
|
|
|
|
|
+ <view class="items">
|
|
|
|
|
+ <text>名称</text>{{ item.name }}
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ <view class="items">
|
|
|
|
|
+ <text>编码</text>{{ item.code }}
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ <view v-for="(itm, index) in tableH(item.rootCategoryLevelId)" :key="index"
|
|
|
|
|
+ class="items" v-if="!itm.formatter">
|
|
|
|
|
+ <text>{{ itm.label }}</text>{{ item[itm.prop] }}
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+ <view class="items" v-if="item.isDemandQuantity">
|
|
|
|
|
+ <text>数量</text>{{ item.demandQuantity }}
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view class="items content_num" v-if="!item.isDemandQuantity">
|
|
|
|
|
+ <text>数量</text> <input style="8rpx !important"
|
|
|
|
|
+ v-model="item.demandQuantity"></input>
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ </label>
|
|
|
|
|
+
|
|
|
|
|
+ </view>
|
|
|
|
|
+
|
|
|
|
|
|
|
|
</view>
|
|
</view>
|
|
|
|
|
|
|
|
<view v-if="actTab == '产出清单'">
|
|
<view v-if="actTab == '产出清单'">
|
|
|
|
|
|
|
|
- <view class="title_box rx-bc">
|
|
|
|
|
|
|
+ <view class="title_box rx-bc">
|
|
|
<view></view>
|
|
<view></view>
|
|
|
<view class="right_box rx-ec">
|
|
<view class="right_box rx-ec">
|
|
|
<u-button type="success" size="small" class="u-reset-button" @click="addPicking(3)"
|
|
<u-button type="success" size="small" class="u-reset-button" @click="addPicking(3)"
|
|
|
- text="添加产出"></u-button>
|
|
|
|
|
|
|
+ text="添加"></u-button>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
<view v-for="(item, index) in standardOutputList" :key="index">
|
|
<view v-for="(item, index) in standardOutputList" :key="index">
|
|
|
<label class="listBox rx-bs">
|
|
<label class="listBox rx-bs">
|
|
|
|
|
|
|
|
-
|
|
|
|
|
- <view class="listBox-sel">
|
|
|
|
|
-
|
|
|
|
|
- </view>
|
|
|
|
|
|
|
+ <view class="listBox-sel">
|
|
|
|
|
+ </view>
|
|
|
|
|
|
|
|
<view class="listBox-con">
|
|
<view class="listBox-con">
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
|
|
|
|
|
<view class="listBox-bottom rx">
|
|
<view class="listBox-bottom rx">
|
|
|
-
|
|
|
|
|
- <view
|
|
|
|
|
- class="items">
|
|
|
|
|
|
|
+
|
|
|
|
|
+ <view class="items">
|
|
|
<text>名称</text>{{ item.name }}
|
|
<text>名称</text>{{ item.name }}
|
|
|
</view>
|
|
</view>
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
- <view
|
|
|
|
|
- class="items">
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ <view class="items">
|
|
|
<text>编码</text>{{ item.code }}
|
|
<text>编码</text>{{ item.code }}
|
|
|
</view>
|
|
</view>
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
<view v-for="(itm, index) in tableH(item.rootCategoryLevelId)" :key="index"
|
|
<view v-for="(itm, index) in tableH(item.rootCategoryLevelId)" :key="index"
|
|
|
class="items" v-if="!itm.formatter">
|
|
class="items" v-if="!itm.formatter">
|
|
|
<text>{{ itm.label }}</text>{{ item[itm.prop] }}
|
|
<text>{{ itm.label }}</text>{{ item[itm.prop] }}
|
|
@@ -158,7 +210,7 @@
|
|
|
</label>
|
|
</label>
|
|
|
|
|
|
|
|
</view>
|
|
</view>
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
</view>
|
|
</view>
|
|
|
|
|
|
|
|
|
|
|
|
@@ -169,7 +221,7 @@
|
|
|
取消
|
|
取消
|
|
|
</u-button>
|
|
</u-button>
|
|
|
<u-button type="success" size="small" class="u-reset-button" @click="handOK">
|
|
<u-button type="success" size="small" class="u-reset-button" @click="handOK">
|
|
|
- 确定
|
|
|
|
|
|
|
+ 提交
|
|
|
</u-button>
|
|
</u-button>
|
|
|
|
|
|
|
|
</view>
|
|
</view>
|
|
@@ -204,7 +256,7 @@
|
|
|
outObj: {},
|
|
outObj: {},
|
|
|
|
|
|
|
|
tabList: [{
|
|
tabList: [{
|
|
|
- name: '主体清单'
|
|
|
|
|
|
|
+ name: '物品清单'
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
name: '带料清单'
|
|
name: '带料清单'
|
|
@@ -214,21 +266,32 @@
|
|
|
}
|
|
}
|
|
|
],
|
|
],
|
|
|
|
|
|
|
|
- actTab: '主体清单',
|
|
|
|
|
|
|
+ actTab: '物品清单',
|
|
|
|
|
|
|
|
bomMaterialList: [],
|
|
bomMaterialList: [],
|
|
|
pickOutInList: [],
|
|
pickOutInList: [],
|
|
|
materialList: [],
|
|
materialList: [],
|
|
|
- standardOutputList: []
|
|
|
|
|
|
|
+ standardOutputList: [],
|
|
|
|
|
+
|
|
|
|
|
+ isFirstTask: null,
|
|
|
|
|
+
|
|
|
|
|
+ clientEnvironmentId: uni.getStorageSync("userInfo") && uni.getStorageSync("userInfo")
|
|
|
|
|
+ .clientEnvironmentId, // *1 主环境-601环境 2 soll-索尔环境 3 tg-碳谷环境
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ seletedAll: false, //全选状态
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
created() {
|
|
created() {
|
|
|
EventBus.$on('outEvent', this.handleEvent);
|
|
EventBus.$on('outEvent', this.handleEvent);
|
|
|
},
|
|
},
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
methods: {
|
|
methods: {
|
|
|
open(obj) {
|
|
open(obj) {
|
|
|
- console.log(obj, 999)
|
|
|
|
|
this.outObj = obj
|
|
this.outObj = obj
|
|
|
|
|
|
|
|
this.outsourceMaterialFn()
|
|
this.outsourceMaterialFn()
|
|
@@ -243,9 +306,20 @@
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
checkOutsourceMaterial(param).then(res => {
|
|
checkOutsourceMaterial(param).then(res => {
|
|
|
|
|
+ if (this.clientEnvironmentId == 3 && res.isFirstTask == 1) {
|
|
|
|
|
+ this.pickOutInList = [...res.pickOutInList, ...res.materialList]
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.pickOutInList = res.pickOutInList
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ this.bomMaterialList = res.bomMaterialList.map((m) => {
|
|
|
|
|
+ return {
|
|
|
|
|
+ ...m,
|
|
|
|
|
+ isDemandQuantity: true
|
|
|
|
|
|
|
|
- this.pickOutInList = res.pickOutInList
|
|
|
|
|
- this.bomMaterialList = res.bomMaterialList
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
this.standardOutputList = res.standardOutputList
|
|
this.standardOutputList = res.standardOutputList
|
|
|
this.$forceUpdate()
|
|
this.$forceUpdate()
|
|
|
})
|
|
})
|
|
@@ -256,30 +330,70 @@
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
close() {
|
|
close() {
|
|
|
|
|
+ EventBus.$off('outEvent');
|
|
|
this.show = false
|
|
this.show = false
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- handleEvent({ message }) {
|
|
|
|
|
- if(message.pid == 3) {
|
|
|
|
|
- this.standardOutputList = message.memoList
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ handleEvent({
|
|
|
|
|
+ message
|
|
|
|
|
+ }) {
|
|
|
|
|
+ if (message.pid == 3) {
|
|
|
|
|
+ this.standardOutputList = message.memoList
|
|
|
|
|
+ } else {
|
|
|
|
|
+ if (message.pid == 2) {
|
|
|
|
|
+ this.bomMaterialList = message.memoList
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
tableH(type) {
|
|
tableH(type) {
|
|
|
return tableHeader(type)
|
|
return tableHeader(type)
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
|
|
+ //勾选
|
|
|
|
|
+ selectVal(e, val, index) {
|
|
|
|
|
+ this.pickOutInList[index].checked = !this.pickOutInList[index].checked
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
|
|
+ _seletedAll() {
|
|
|
|
|
+
|
|
|
|
|
+ if (!this.seletedAll) {
|
|
|
|
|
+ this.seletedAll = true
|
|
|
|
|
+
|
|
|
|
|
+ this.pickOutInList.map(item => {
|
|
|
|
|
+ this.$set(item, 'checked', true)
|
|
|
|
|
+
|
|
|
|
|
+ })
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.seletedAll = false
|
|
|
|
|
+ this.pickOutInList.map(item => {
|
|
|
|
|
+ this.$set(item, 'checked', false)
|
|
|
|
|
+ })
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
|
|
|
scrolltolower() {},
|
|
scrolltolower() {},
|
|
|
|
|
|
|
|
addPicking(id) {
|
|
addPicking(id) {
|
|
|
const storageKey = Date.now() + "";
|
|
const storageKey = Date.now() + "";
|
|
|
- let arr = [
|
|
|
|
|
- {
|
|
|
|
|
- standardOutputList: this.standardOutputList
|
|
|
|
|
- }
|
|
|
|
|
- ]
|
|
|
|
|
|
|
+ let arr = null
|
|
|
|
|
+ if (id == 3) {
|
|
|
|
|
+ arr = [{
|
|
|
|
|
+ standardOutputList: this.standardOutputList,
|
|
|
|
|
+ }]
|
|
|
|
|
+
|
|
|
|
|
+ } else {
|
|
|
|
|
+ arr = [{
|
|
|
|
|
+ bomMaterialList: this.bomMaterialList,
|
|
|
|
|
+ }]
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
uni.setStorageSync(storageKey, arr);
|
|
uni.setStorageSync(storageKey, arr);
|
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
|
url: `/pages/pda/workOrder/search/index?id=${id}&storageKey=${storageKey}&isType=zdy&taskId=${this.outObj.taskId}&classIds=[1,23,9]`
|
|
url: `/pages/pda/workOrder/search/index?id=${id}&storageKey=${storageKey}&isType=zdy&taskId=${this.outObj.taskId}&classIds=[1,23,9]`
|
|
@@ -384,7 +498,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
.card_box {
|
|
.card_box {
|
|
|
- width: 750rpx;
|
|
|
|
|
|
|
+ width: 92vw;
|
|
|
padding: 16rpx 32rpx;
|
|
padding: 16rpx 32rpx;
|
|
|
box-sizing: border-box;
|
|
box-sizing: border-box;
|
|
|
border-bottom: 2rpx solid #E1E1E1;
|
|
border-bottom: 2rpx solid #E1E1E1;
|
|
@@ -413,4 +527,19 @@
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ .content_num {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ padding: 0 4rpx;
|
|
|
|
|
+
|
|
|
|
|
+ /deep/ .uni-input-input {
|
|
|
|
|
+ border: 2rpx solid #F0F8F2;
|
|
|
|
|
+ background: #F0F8F2;
|
|
|
|
|
+ color: $theme-color;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
</style>
|
|
</style>
|