Commit af2cfaf9 by liangjianmin

审核逻辑

parent 16e70866
Showing with 28 additions and 58 deletions
......@@ -64,60 +64,34 @@
</navigator>
</view>
<!-- 商检图片上传 -->
<view class="section" v-if="isInspOrg || isHG">
<view class="section" v-if="isInspOrg">
<view class="upload-box">
<view class="title row bothSide verCenter">
<view class="title row bothSide verCenter" v-if="goods_check_pic_list.length > 0">
<text class="tt-l">商检图片上传(仅商检必填)</text>
<text class="tt-r">{{ goods_check_pic_list.filter(subArray => subArray.length > 0).length }}/{{ goods_check_pic_list.length || 0 }}</text>
<text class="tt-r">{{ goods_check_pic_list.filter(subArray => subArray.length > 0).length }}/{{ goods_check_pic_list.length }}</text>
</view>
<view class="model-upload-list">
<!-- 判断是否为海关编码为854232开头 -->
<template v-if="isHG">
<view class="column" v-for="(item, index) in list" :key="index">
<view class="box row bothSide verCenter">
<view class="file row verCenter">
<text class="t1">{{ item.model }}</text>
<template v-if="goods_check_pic_list[index].length > 0">
<text class="t2" @click="previewChange(goods_check_pic_list[index], 0)">已上传&nbsp;{{ goods_check_pic_list[index].length }}</text>
<text class="clear" @click="clearFn(index)">清空</text>
</template>
</view>
<view class="file-btn row verCenter" @click="uploadBusinessChange(index)">
<template v-if="goods_check_pic_list[index].length > 0">
<text class="t1">继续上传</text>
</template>
<template v-else>
<text class="t1">上传图片</text>
</template>
<text class="iconfont icon-sanjiaoxing2"></text>
</view>
<view class="column" v-for="(item, index) in list" :key="index" :class="{ curr: goods_check_pic_list[index].length > 0 }">
<view class="box row bothSide verCenter">
<view class="file row verCenter">
<text class="t1">{{ item.model }}</text>
<template v-if="goods_check_pic_list[index].length > 0">
<text class="t2" @click="previewChange(goods_check_pic_list[index], 0)">已上传&nbsp;{{ goods_check_pic_list[index].length }}</text>
<text class="clear" @click="clearFn(index)">清空</text>
</template>
</view>
<navigator class="history-btn row verCenter" :url="'/pages/tallyGoods/historicalTally?erp_order_sn=' + form.erp_order_sn+'&model='+item.model + '&index='+ index + '&srcEntryID='+(encodeURIComponent(item.srcEntryID))+'&entryID='+(encodeURIComponent(item.entryID))">历史理货图片</navigator>
</view>
</template>
<template v-else>
<view class="column" v-for="(item, index) in list" :key="index" :class="{ curr: goods_check_pic_list[index].length > 0 }">
<view class="box row bothSide verCenter">
<view class="file row verCenter">
<text class="t1">{{ item.model }}</text>
<template v-if="goods_check_pic_list[index].length > 0">
<text class="t2" @click="previewChange(goods_check_pic_list[index], 0)">已上传&nbsp;{{ goods_check_pic_list[index].length }}</text>
<text class="clear" @click="clearFn(index)">清空</text>
</template>
</view>
<view class="file-btn row verCenter" @click="uploadBusinessChange(index)">
<template v-if="goods_check_pic_list[index].length > 0">
<text class="t1">继续上传</text>
</template>
<template v-else>
<text class="t1">上传图片</text>
</template>
<text class="iconfont icon-sanjiaoxing2"></text>
</view>
<view class="file-btn row verCenter" @click="uploadBusinessChange(index)">
<template v-if="goods_check_pic_list[index].length > 0">
<text class="t1">继续上传</text>
</template>
<template v-else>
<text class="t1">上传图片</text>
</template>
<text class="iconfont icon-sanjiaoxing2"></text>
</view>
<navigator class="history-btn row verCenter" :url="'/pages/tallyGoods/historicalTally?erp_order_sn=' + form.erp_order_sn+'&model='+item.model + '&index='+ index + '&srcEntryID='+(encodeURIComponent(item.srcEntryID))+'&entryID='+(encodeURIComponent(item.entryID))">历史理货图片</navigator>
</view>
</template>
<navigator class="history-btn row verCenter" :url="'/pages/tallyGoods/historicalTally?erp_order_sn=' + form.erp_order_sn+'&model='+item.model + '&index='+ index + '&srcEntryID='+(encodeURIComponent(item.srcEntryID))+'&entryID='+(encodeURIComponent(item.entryID))">历史理货图片</navigator>
</view>
</view>
</view>
</view>
......@@ -157,7 +131,6 @@
data() {
return {
isInspOrg: false, //是否商检
isHG: false,
noexebshowFalg: true, //控制是否会触发生命周期
customs_clearance_price_options: ['无', '有'], //清关费选项
currentIndex: -1,
......@@ -296,21 +269,18 @@
this.isInspOrg = Boolean(res.data.isInspOrg); //是否商检
// 判断是否为海关编码为854232开头
this.isHG = res.data.entrys.some(function(entry) {
return entry.goodsNo && entry.goodsNo.toString().startsWith('854232');
this.list = res.data.entrys.filter(function(entry) {
return entry.isEntryInspOrg === true || (entry.goodsNo && entry.goodsNo.toString().startsWith('854232'));
});
if (this.isHG) {
this.list = res.data.entrys.filter(function(entry) {
return entry.isEntryInspOrg === false;
});
// 如果主单是商检,那么默认明细里的所有都要商检
if (this.isInspOrg) {
this.list = res.data.entrys;
} else {
//是否商检
// 如果主单不是商检,则只筛选出标记为商检的条目或海关编码为854232开头的条目
this.list = res.data.entrys.filter(function(entry) {
return entry.isEntryInspOrg === true;
return entry.isEntryInspOrg === true || (entry.goodsNo && entry.goodsNo.toString().startsWith('854232'));
});
}
this.goods_check_pic_list_id = this.list.map(function(entry) {
......
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 sign in to comment