niexiting 1 year ago
parent
commit
540f47ad92
  1. 4
      api/request2.js
  2. 4
      common/detail.js
  3. 2
      common/style/uni.css
  4. 1
      mycomponents/qty/RecommendQty.vue
  5. 1
      mycomponents/qty/stdPackQty.vue
  6. 34
      pages/inspect/coms/inspectComDetailCard.vue
  7. 2
      pages/inspect/coms/inspectEdit.vue
  8. 40
      pages/inspect/job/inspectDetail.vue
  9. 14
      pages/inspect/job/inspectResult.vue
  10. 6
      pages/purchaseReceipt/coms/comReceiptDetailCard.vue
  11. 2
      pages/putaway/record/putawayRecord.vue

4
api/request2.js

@ -2014,8 +2014,8 @@ export function getPutawayRequestDetail(id) {
*/
export function putawayRequestSubmit(params) {
return request({
url: baseApi + "/wms/purchasereturn-request-main/submit",
method: "put",
url: baseApi + "/putaway-request-main/create",
method: "post",
data: params,
});
}

4
common/detail.js

@ -55,10 +55,10 @@ export function createRecordInfo(detail, balance) {
//计算实际数量
export function calcHandleQty(detailSource) {
for (let item of detailSource) {
item.handleTotalQty = 0;
item.handleQty = 0;
for (let detail of item.subList) {
if (detail != undefined && detail.scaned) {
item.handleTotalQty += Number(detail.handleQty)
item.handleQty += Number(detail.handleQty)
}
}
}

2
common/style/uni.css

@ -61,6 +61,8 @@ form {
display: flex;
flex-direction: row;
align-items: center;
/* justify-content: center; */
/* background-color: #888888; */
}
/* .uni-inline-item text {

1
mycomponents/qty/RecommendQty.vue

@ -1,5 +1,6 @@
<template>
<view>
推荐
<view class="uni-flex uni-row center">
<status v-if="isShowStatus" :status='dataContent.inventoryStatus'></status>
<view class="text_recommend ">

1
mycomponents/qty/stdPackQty.vue

@ -26,7 +26,6 @@
methods: {
getStdPackUnit(stdPackUnit) {
let std = getUnitInfo(stdPackUnit);
console.log("单位",std.label)
return std == "" ? stdPackUnit : std.label;
}
}

34
pages/inspect/coms/inspectComDetailCard.vue

@ -1,13 +1,31 @@
<template>
<view class="" style="background-color: #fff;">
<view class="">
<view class="" style="font-size: 32rpx;margin-left: 20rpx;">
<view class="">
收货数量 : {{jobContent.receiveQty}}{{getUnitInfo(jobContent.uom)}}
</view>
<view class="">
检验数量 : {{jobContent.sampleQty}}{{getUnitInfo(jobContent.uom)}}
</view>
<view class="">
不合格数量 : {{jobContent.failedQty}}{{getUnitInfo(jobContent.uom)}}
</view>
<view class="">
报废数量 : {{jobContent.crackQty}}{{getUnitInfo(jobContent.uom)}}
</view>
</view>
</view>
<u-line />
<uni-collapse ref="collapse1" @change="">
<uni-collapse-item :open="true">
<template v-slot:title>
<item-compare-qty :dataContent="dataContent" :handleQty="Number(dataContent.handleQty)">
</item-compare-qty>
<view class="" style="margin-left: 20rpx; ">
<batch :batch="settingParam.batch"></batch>
<batch :batch="jobContent.batch"></batch>
</view>
</template>
<u-line />
<view class="" v-for="(item,index) in dataContent.subList">
@ -23,6 +41,9 @@
<view class="" >
报废数量 {{item.crackQty}}
</view>
<view class="" >
合格数量 {{item.goodQty}}
</view>
</view>
</uni-swipe-action-item>
@ -53,6 +74,10 @@
getDetailRemoveOption
} from '@/common/array.js';
import {
getUnitInfo
} from '@/common/directory.js';
export default {
components: {
itemCompareQty,
@ -67,7 +92,7 @@
type: Object,
default: {}
},
settingParam: {
jobContent: {
type: Object,
default: {}
},
@ -166,7 +191,10 @@
})
}
this.$emit('updateData',)
}
},
getUnitInfo(value) {
return getUnitInfo(value).label
},
}
}

2
pages/inspect/coms/inspectEdit.vue

@ -137,7 +137,7 @@
}
this.dataContent.failedQty = failedQty;
this.dataContent.crackQty = crackQty
this.dataContent.goodQty = this.dataContent.handleQty -failedQty-crackQty
this.afterSave()

40
pages/inspect/job/inspectDetail.vue

@ -4,7 +4,7 @@
<scroll-view scroll-y="true" class="page-main-scroll">
<view class="detail-list" v-for="(item, index) in detailSource" :key="item.id">
<view class="">
<inspectComDetailCard :dataContent="item" :settingParam="jobContent" @remove="updateData"
<inspectComDetailCard :dataContent="item" :jobContent="jobContent" @remove="updateData"
:isShowBatch="false" @updateData='updateData'>
</inspectComDetailCard>
</view>
@ -44,7 +44,8 @@
getPackingNumberAndBatch,
} from '@/common/basic.js';
import {
getInventoryStatusName
getInventoryStatusName,
} from '@/common/directory.js';
import {
@ -87,11 +88,16 @@
businessTypeInfo: {},
locationTypeList: [],
managementList: [],
selectedItem: {}
selectedItem: {},
failedQty:0,
crackQty:0
};
},
onLoad(option) {
this.id = option.id;
this.failedQty = option.failedQty;
this.crackQty = option.crackQty;
if (this.id != undefined) {
// //
// if (option.status == "1") {
@ -172,6 +178,8 @@
} else {
if (res.data.subList.length > 0) {
that.jobContent = res.data;
that.jobContent.failedQty= this.failedQty
that.jobContent.crackQty = this.crackQty;
that.subList = res.data.subList;
that.subList.forEach(res => {
res.batch = that.jobContent.batch
@ -417,11 +425,11 @@
detail.failedQty = detail.failedQty;
detail.crackQty = detail.crackQty;
detail.notPassedQty = detail.notPassedQty;
detail.goodQty = detail.qty - detail.failedQty - detail.crackQty;
// detail.goodQty = detail.handleQty - detail.failedQty - detail.crackQty;
detail.inspectUser = this.$store.state.user.id
//==
if (detail.goodQty == detail.qty) {
if (detail.goodQty == detail.handleQty) {
detail.toInventoryStatus = "OK"
} else {
//=
@ -432,15 +440,24 @@
detail.toInventoryStatus = "NOK"
}
}
// detail.singlePrice = detail.balance.singlePrice;
// detail.amount = detail.balance.singlePrice * detail.handleQty;
detail.singlePrice = detail.balance.singlePrice;
detail.amount = detail.balance.singlePrice * detail.handleQty;
// detail.arriveDate = detail.balance.arriveDate;
// detail.produceDate = detail.balance.produceDate;
// detail.expireDate = detail.balance.expireDate;
detail.arriveDate = detail.balance.arriveDate;
detail.produceDate = detail.balance.produceDate;
detail.expireDate = detail.balance.expireDate;
list.push(detail)
}else {
detail.sampleQty = detail.qty;
detail.failedQty = 0;
detail.crackQty = 0;
detail.notPassedQty = 0;
detail.goodQty = detail.qty;
detail.inspectUser = this.$store.state.user.id
detail.toInventoryStatus = "OK"
}
list.push(detail)
})
})
this.jobContent.subList = list
@ -457,6 +474,7 @@
},
}
}
</script>

14
pages/inspect/job/inspectResult.vue

@ -387,7 +387,10 @@
} else if (this.nextAction == "PARTIAL_OK") {
//
uni.navigateTo({
url: './inspectDetail?id=' + this.id + '&status=' + this.status
url: './inspectDetail?id=' + this.id +
'&status=' + this.status+
'&failedQty=' + this.jobContent.failedQty+
'&crackQty=' + this.jobContent.crackQty
});
//===
} else if (this.nextAction == "FULL_INSPECT") {
@ -402,7 +405,7 @@
res.failedReason ="";
res.photos = ""
res.inspectResult =""
res.inspectUser =this.$store.state.user.id
res.inspectUser = this.$store.state.user.id
})
this.jobContent.nextAction = this.nextAction;
this.submitJob(this.jobContent)
@ -416,6 +419,7 @@
});
console.log("提交参数", JSON.stringify(params));
inspectJobSubmit(params).then(res=>{
uni.hideLoading()
if (res.data) {
this.showCommitSuccessMessage("提交成功<br>生成到货检验记录" + res.data, )
} else {
@ -434,6 +438,12 @@
})
})
},
showErrorMessage(message) {
this.$refs.comMessage.showErrorMessage(message, res => {
if (res) {
}
});
},
}
}

6
pages/purchaseReceipt/coms/comReceiptDetailCard.vue

@ -3,7 +3,7 @@
<uni-collapse ref="collapse1" @change="">
<uni-collapse-item :open="true">
<template v-slot:title>
<item-qty :dataContent="dataContent" :handleQty="dataContent.handleQty"></item-qty>
<itemCompareQty :dataContent="dataContent" :handleQty="dataContent.handleQty"></itemCompareQty>
</template>
<u-line />
<view class="" v-for="(item,index) in dataContent.subList">
@ -29,7 +29,7 @@
</template>
<script>
import itemQty from '@/mycomponents/item/itemQty.vue'
import itemCompareQty from '@/mycomponents/item/itemCompareQty.vue'
import recommend from '@/mycomponents/recommend/recommend.vue'
import recommendQtyEdit from '@/mycomponents/qty/recommendQtyEdit.vue'
import jobDetailPopup from '@/mycomponents/detail/jobDetailPopup.vue'
@ -44,7 +44,7 @@
export default {
components: {
itemQty,
itemCompareQty,
recommend,
recommendQtyEdit,
jobDetailPopup,

2
pages/putaway/record/putawayRecord.vue

@ -101,11 +101,9 @@
jobContent: {}, //
detailSource: [], //
locationTypeList: [],
toLocationInfo: {},
businessTypeInfo: {},
fromLocationInfo: {},
fromLocationCode: "",
toLocationInfo: {},
toLocationCode: "",
isShowLocation: false,
fromlocationTypeList: [],

Loading…
Cancel
Save