lijuncheng 12 months ago
parent
commit
f5ef9e51d9
  1. 2
      mycomponents/job/jobTop.vue
  2. 11
      mycomponents/location/requiredLocation.vue
  3. 3
      mycomponents/recommend/recommend.vue
  4. 85
      pages/inspect/coms/inspectComDetailCard.vue
  5. 36
      pages/inspect/job/inspectDetail.vue
  6. 1
      pages/issue/record/issueRecord.vue
  7. 30
      pages/purchaseReceipt/job/receiptDetail.vue
  8. 42
      pages/setter/index.vue

2
mycomponents/job/jobTop.vue

@ -1,6 +1,6 @@
<template> <template>
<view class="task_top"> <view class="task_top">
<view class="uni-flex space-between u-col-center align-center" style="margin: 10rpx;"> <view class="uni-flex space-between u-col-center align-center" >
<job-number :number="dataContent.number"></job-number> <job-number :number="dataContent.number"></job-number>
<job-status :jobStatus="dataContent.status"></job-status> <job-status :jobStatus="dataContent.status"></job-status>
</view> </view>

11
mycomponents/location/requiredLocation.vue

@ -4,12 +4,11 @@
padding-left: 10rpx; padding-left: 10rpx;
padding-right: 10rpx; padding-right: 10rpx;
font-size:32rpx;"> font-size:32rpx;">
<text style="font-size: 35rpx;">{{title}} </text> <view class="uni-flex uni-row u-col-center" @click="showLocation">
<view class="uni-flex u-col-center" @click="showLocation"> <text style="font-size: 35rpx;">{{title}} </text>
<text style="color:#3FBAFF;font-size: 35rpx;" v-if="locationCode==''&&isShowEdit==true">&nbsp 请扫描</text> <text style="font-size: 35rpx;color:#3FBAFF;" v-if="locationCode==''&&isShowEdit==true">&nbsp 请扫描</text>
<text style="color:#3FBAFF; font-size: 35rpx;">&nbsp {{locationCode}}</text> <text style="font-size: 35rpx;color:#3FBAFF;">&nbsp {{locationCode}}</text>
<image v-if="isShowEdit" style="width: 45rpx;height: 45rpx;" src="/static/icons/icons_edit.svg" <image v-if="isShowEdit" style="width:45rpx;height: 45rpx;" src="/static/icons/icons_edit.svg"></image>
></image>
</view> </view>
<win-scan-location ref="scanLocationCode" :title="title" @getLocation='getLocation' <win-scan-location ref="scanLocationCode" :title="title" @getLocation='getLocation'
:locationTypeList="locationTypeList"></win-scan-location> :locationTypeList="locationTypeList"></win-scan-location>

3
mycomponents/recommend/recommend.vue

@ -11,7 +11,8 @@
</location> </location>
</view> </view>
<view> <view>
<recommend-qty v-if="detail.handleQty==null || detail.handleQty==undefined||detail.handleQty==0" :dataContent="detail" <!-- ||detail.handleQty==0 -->
<recommend-qty v-if="detail.handleQty==null || detail.handleQty==undefined" :dataContent="detail"
:isShowStdPack="false"></recommend-qty> :isShowStdPack="false"></recommend-qty>
<compare-qty v-else :dataContent="detail" :recommendQty="Number(detail.qty)" <compare-qty v-else :dataContent="detail" :recommendQty="Number(detail.qty)"
:handleQty="Number(detail.handleQty)" :isShowStdPack="false"> :handleQty="Number(detail.handleQty)" :isShowStdPack="false">

85
pages/inspect/coms/inspectComDetailCard.vue

@ -1,13 +1,12 @@
<template> <template>
<view class="" style="background-color: #fff;"> <view class="" style="background-color: #fff;">
<view class=""> <view class="">
<view class="" >
<view class="cen_card" style="padding: 20rpx;">
<view class="cell_box uni-flex uni-row"> <view class="cell_box uni-flex uni-row">
<view class="cell_info"> <!-- <view class="cell_info">
<view class="text_lightblue">类型</view> <view class="text_lightblue">类型</view>
<view>{{getInspectType(jobContent.inspectType)}}</view> <view>{{getInspectType(jobContent.inspectType)}}</view>
</view> </view> -->
<view class="cell_info"> <view class="cell_info">
<view class="text_lightblue">收货数</view> <view class="text_lightblue">收货数</view>
<view>{{jobContent.receiveQty}}{{getUnitInfo(jobContent.uom)}}</view> <view>{{jobContent.receiveQty}}{{getUnitInfo(jobContent.uom)}}</view>
@ -25,9 +24,8 @@
<view>{{jobContent.crackQty}}{{getUnitInfo(jobContent.uom)}}</view> <view>{{jobContent.crackQty}}{{getUnitInfo(jobContent.uom)}}</view>
</view> </view>
</view> </view>
<u-line /> <!-- <u-line /> -->
</view> </view>
</view> </view>
<u-line /> <u-line />
<uni-collapse ref="collapse1" @change=""> <uni-collapse ref="collapse1" @change="">
@ -38,36 +36,50 @@
<view class="" style="margin-left: 20rpx; "> <view class="" style="margin-left: 20rpx; ">
<batch :batch="jobContent.batch"></batch> <batch :batch="jobContent.batch"></batch>
</view> </view>
</template> </template>
<u-line /> <u-line />
<view class="" v-for="(item,index) in dataContent.subList"> <view class="" v-for="(item,index) in dataContent.subList">
<uni-swipe-action ref="swipeAction"> <uni-swipe-action ref="swipeAction">
<uni-swipe-action-item @click="swipeClick($event,item,index)" <uni-swipe-action-item @click="swipeClick($event,item,index)"
:right-options="item.scaned?scanOptions:detailOptions"> :right-options="item.scaned?scanOptions:detailOptions">
<recommend :detail="item" :isShowPack="isShowPack" <recommend :detail="item" :isShowPack="isShowPack" :isShowBatch="isShowBatch"
:isShowBatch="isShowBatch" :isShowFromLocation="isShowLocation"></recommend> :isShowFromLocation="isShowLocation"></recommend>
<view v-if="item.failedQty>0||item.crackQty>0" :class="item.scaned?'scan_view':''" style="font-size: 32rpx;padding-left: 3rpx;"> <view v-if="item.failedQty>0||item.crackQty>0" :class="item.scaned?'scan_view':''" style="font-size: 32rpx;">
<view class="" > <view class="cell_box uni-flex uni-row">
不合格数量 {{item.failedQty}} <view class="cell_info uni-flex uni-row">
<view class="text_lightblue">
不合格
</view>
<view style="padding-left: 12rpx;color: #F56C6C;">
{{item.failedQty}}
</view>
</view> </view>
<view class="" > <view class="cell_info uni-flex uni-row">
报废数量 {{item.crackQty}} <view class="text_lightblue">
报废
</view>
<view style="padding-left: 12rpx;color: #EC9C00">
{{item.crackQty}}
</view>
</view> </view>
<view class="" > <view class="cell_info uni-flex uni-row">
合格数量 {{item.goodQty}} <view class="text_lightblue">
合格
</view>
<view style="padding-left: 12rpx;color: #0A84FF">
{{item.goodQty}}
</view>
</view> </view>
</view> </view>
</view>
</uni-swipe-action-item> </uni-swipe-action-item>
</uni-swipe-action> </uni-swipe-action>
<u-line /> <u-line />
</view> </view>
</uni-collapse-item> </uni-collapse-item>
</uni-collapse> </uni-collapse>
<inspectEdit ref='inspectEdit' <inspectEdit ref='inspectEdit' @getInspectResult='getInspectResult'>
@getInspectResult='getInspectResult'>
</inspectEdit> </inspectEdit>
<job-detail-popup ref="receiptHint" :dataContent="showItem"></job-detail-popup> <job-detail-popup ref="receiptHint" :dataContent="showItem"></job-detail-popup>
<com-message ref="message"></com-message> <com-message ref="message"></com-message>
@ -90,7 +102,7 @@
getUnitInfo, getUnitInfo,
getInspectType getInspectType
} from '@/common/directory.js'; } from '@/common/directory.js';
export default { export default {
components: { components: {
itemCompareQty, itemCompareQty,
@ -134,9 +146,8 @@
return { return {
option: [], option: [],
showItem: {}, showItem: {},
editItem: { editItem: {},
}, editIndex: 0,
editIndex:0,
detailOptions: [], detailOptions: [],
scanOptions: [] scanOptions: []
} }
@ -157,20 +168,20 @@
}, },
methods: { methods: {
getInspectType(value){ getInspectType(value) {
return getInspectType(value) return getInspectType(value)
}, },
swipeClick(e, item,index) { swipeClick(e, item, index) {
if (e.content.text == "详情") { if (e.content.text == "详情") {
this.detail(item) this.detail(item)
} else if (e.content.text == "编辑") { } else if (e.content.text == "编辑") {
this.edit(item,index) this.edit(item, index)
} else if (e.content.text == "移除") { } else if (e.content.text == "移除") {
this.remove(item) this.remove(item)
} }
}, },
edit(item,index) { edit(item, index) {
this.editIndex = index; this.editIndex = index;
this.editItem = item; this.editItem = item;
this.$refs.inspectEdit.openEditPopup(this.editItem); this.$refs.inspectEdit.openEditPopup(this.editItem);
@ -189,10 +200,10 @@
item.crackQty = 0; item.crackQty = 0;
item.sampleQty = 0; item.sampleQty = 0;
item.notPassedQty = 0; item.notPassedQty = 0;
item.inspectResult ="" item.inspectResult = ""
item.failedReason ="" item.failedReason = ""
item.handleQty =0; item.handleQty = 0;
item.photos ="" item.photos = ""
this.$forceUpdate() this.$forceUpdate()
this.$emit('remove', item) this.$emit('remove', item)
} }
@ -201,19 +212,19 @@
confirm(qty) { confirm(qty) {
this.$emit('updateData') this.$emit('updateData')
}, },
getInspectResult(result){ getInspectResult(result) {
this.dataContent.subList[this.editIndex]= result; this.dataContent.subList[this.editIndex] = result;
if (this.$refs.collapse1 != undefined) { if (this.$refs.collapse1 != undefined) {
this.$nextTick(res => { this.$nextTick(res => {
this.$refs.collapse1.resize() this.$refs.collapse1.resize()
}) })
} }
this.$emit('updateData',) this.$emit('updateData', )
}, },
getUnitInfo(value) { getUnitInfo(value) {
return getUnitInfo(value).label return getUnitInfo(value).label
}, },
} }
} }
</script> </script>

36
pages/inspect/job/inspectDetail.vue

@ -1,13 +1,17 @@
<template> <template>
<view class="page-wraper"> <view class="page-wraper">
<view style="margin: 5px;">
<job-top :dataContent="jobContent"></job-top>
<view>
<view class="card_content"> 检验类型 : {{getInspectType(jobContent.inspectType)}}</view>
</view>
</view>
<view class="page-main"> <view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll"> <scroll-view scroll-y="true" class="page-main-scroll">
<view class="detail-list" v-for="(item, index) in detailSource" :key="item.id"> <view class="detail-list" v-for="(item, index) in detailSource" :key="item.id">
<view class=""> <inspect-com-detail-card :dataContent="item" :jobContent="jobContent" @remove="updateData"
<inspectComDetailCard :dataContent="item" :jobContent="jobContent" @remove="updateData" :isShowBatch="false" @updateData='updateData'>
:isShowBatch="false" @updateData='updateData'> </inspect-com-detail-card>
</inspectComDetailCard>
</view>
</view> </view>
</scroll-view> </scroll-view>
</view> </view>
@ -46,7 +50,8 @@
} from '@/common/basic.js'; } from '@/common/basic.js';
import { import {
getInventoryStatusName, getInventoryStatusName,
getDirectoryItemArray getDirectoryItemArray,
getInspectType
} from '@/common/directory.js'; } from '@/common/directory.js';
import { import {
@ -66,7 +71,7 @@
import winScanPackAndLocation from "@/mycomponents/scan/winScanPackAndLocation.vue" import winScanPackAndLocation from "@/mycomponents/scan/winScanPackAndLocation.vue"
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import inspectComDetailCard from "@/pages/inspect/coms/inspectComDetailCard.vue" import inspectComDetailCard from "@/pages/inspect/coms/inspectComDetailCard.vue"
import jobTop from '@/mycomponents/job/jobTop.vue'
export default { export default {
name: 'returnDetail', name: 'returnDetail',
components: { components: {
@ -76,6 +81,7 @@
winScanPackAndLocation, winScanPackAndLocation,
comMessage, comMessage,
inspectComDetailCard, inspectComDetailCard,
jobTop
}, },
data() { data() {
return { return {
@ -86,7 +92,7 @@
subList: [], //subList subList: [], //subList
detailSource: [], // detailSource: [], //
businessTypeInfo: {}, businessTypeInfo: {},
fromInventoryStatuses :"", fromInventoryStatuses: "",
managementList: [], managementList: [],
selectedItem: {}, selectedItem: {},
failedQty: 0, failedQty: 0,
@ -195,7 +201,7 @@
res.photos = "" res.photos = ""
res.inspectResult = "" res.inspectResult = ""
}) })
that.fromInventoryStatuses = that.jobContent.outInventoryStatuses that.fromInventoryStatuses = that.jobContent.outInventoryStatuses
that.detailSource = getDataSource(that.subList); that.detailSource = getDataSource(that.subList);
} else { } else {
that.showMessage('列表数据为0'); that.showMessage('列表数据为0');
@ -477,18 +483,12 @@
showCommitSuccessMessage(hint) { showCommitSuccessMessage(hint) {
this.$refs.comMessage.showSuccessMessage(hint, res => { this.$refs.comMessage.showSuccessMessage(hint, res => {
// let canNavBack = getCurrentPages()
// if( canNavBack && canNavBack.length>1) {
// uni.navigateBack({
// delta:2
// })
// } else {
// history.back();
// }
navigateBack(2); navigateBack(2);
}) })
}, },
getInspectType(value){
return getInspectType(value)
}
} }

1
pages/issue/record/issueRecord.vue

@ -268,6 +268,7 @@
} }
}) })
} }
this.resizeCollapse();
// item.handleQty=itemHandleQty; // item.handleQty=itemHandleQty;
// this.closeScan(); // this.closeScan();
}, },

30
pages/purchaseReceipt/job/receiptDetail.vue

@ -1,5 +1,13 @@
<template> <template>
<view class="page-wraper"> <view class="page-wraper">
<view style="margin: 5px;">
<job-top :dataContent="jobContent"></job-top>
<view class="card_content">
发货单号 : {{jobContent.asnNumber}}
</view>
<u-line />
</view>
<view class="page-main"> <view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll"> <scroll-view scroll-y="true" class="page-main-scroll">
<view class="detail-list" v-for="(item, index) in detailSource" :key="item.id"> <view class="detail-list" v-for="(item, index) in detailSource" :key="item.id">
@ -71,6 +79,7 @@
import requiredLocation from '@/mycomponents/location/requiredLocation.vue' import requiredLocation from '@/mycomponents/location/requiredLocation.vue'
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import comReceiptDetailCard from '@/pages/purchaseReceipt/coms/comReceiptDetailCard.vue' import comReceiptDetailCard from '@/pages/purchaseReceipt/coms/comReceiptDetailCard.vue'
import jobTop from '@/mycomponents/job/jobTop.vue'
export default { export default {
name: 'receipt_detail', name: 'receipt_detail',
@ -79,7 +88,8 @@
winScanPack, winScanPack,
comReceiptDetailCard, comReceiptDetailCard,
requiredLocation, requiredLocation,
comMessage comMessage,
jobTop
}, },
data() { data() {
return { return {
@ -182,7 +192,7 @@
} else { } else {
that.showMessage('列表数据为0'); that.showMessage('列表数据为0');
} }
updateTitle(that.jobContent.number); // updateTitle("-" + that.jobContent.number);
} }
}).catch(error => { }).catch(error => {
uni.hideLoading() uni.hideLoading()
@ -216,7 +226,7 @@
calcHandleQty(this.detailSource); calcHandleQty(this.detailSource);
this.continueScan() this.continueScan()
this.$forceUpdate() this.$forceUpdate()
var list =this.detailSource[0].subList; var list = this.detailSource[0].subList;
} }
} }
} }
@ -252,12 +262,12 @@
}) })
}, },
commit() { commit() {
this.scanCount = getScanCount(this.subList); this.scanCount = getScanCount(this.subList);
if( this.scanCount==0){ if (this.scanCount == 0) {
this.showErrorMessage("扫描数为0,请先扫描") this.showErrorMessage("扫描数为0,请先扫描")
return; return;
} }
// //
if (!this.checkLocation()) { if (!this.checkLocation()) {
return return
@ -347,7 +357,7 @@
checkLocation() { checkLocation() {
var isPass = true; var isPass = true;
if (this.toLocationCode == ""||this.toLocationCode ==null) { if (this.toLocationCode == "" || this.toLocationCode == null) {
this.$refs.comMessage.showMessage('请扫描收货库位', res => { this.$refs.comMessage.showMessage('请扫描收货库位', res => {
if (res) { if (res) {
this.$refs.requiredLocation.showLocation(); this.$refs.requiredLocation.showLocation();

42
pages/setter/index.vue

@ -9,17 +9,21 @@
<!-- <uni-list-item title="工号" clickable @click="onClick" :rightText="usermsg.phoneNumber"></uni-list-item> --> <!-- <uni-list-item title="工号" clickable @click="onClick" :rightText="usermsg.phoneNumber"></uni-list-item> -->
<uni-list-item title="姓名" clickable :rightText="userName" thumb="/static/icon_personal_name.png"> <uni-list-item title="姓名" clickable :rightText="userName" thumb="/static/icon_personal_name.png">
</uni-list-item> </uni-list-item>
<uni-list-item v-if="userInfo!=null" title="部门" :rightText="userInfo.dept.name" <uni-list-item v-if="userInfo!=null" title="部门" :rightText="userInfo.dept.name"
thumb="/static/icon_personal_password.png"></uni-list-item> thumb="/static/icon_personal_password.png"></uni-list-item>
<uni-list-item v-if="userInfo!=null" title="岗位" :rightText="(userInfo.posts || []).map(post => post.name).join(',')" <uni-list-item v-if="userInfo!=null" title="岗位"
thumb="/static/icon_personal_password.png"></uni-list-item> :rightText="(userInfo.posts || []).map(post => post.name).join(',')"
<uni-list-item v-if="userInfo!=null" title="角色" :rightText="(userInfo.roles || []).map(role => role.name).join(',')" thumb="/static/icon_personal_password.png"></uni-list-item>
thumb="/static/icon_personal_password.png"></uni-list-item> <uni-list-item v-if="userInfo!=null" title="角色"
:rightText="(userInfo.roles || []).map(role => role.name).join(',')"
thumb="/static/icon_personal_password.png"></uni-list-item>
<uni-list-item title="" clickable rightText="清除缓存" thumb="/static/icon_personal_name.png" <uni-list-item title="" clickable rightText="清除缓存" thumb="/static/icon_personal_name.png"
@click="clear"></uni-list-item> @click="clear"></uni-list-item>
<uni-list-item title="修改密码" link to="/pages/setter/passwordpage" <uni-list-item title="修改密码" link to="/pages/setter/passwordpage"
thumb="/static/icon_personal_password.png"></uni-list-item> thumb="/static/icon_personal_password.png"></uni-list-item>
<uni-list-item title="服务器地址"
thumb="/static/icon_personal_password.png"></uni-list-item>
<!-- <uni-list-item title="参数设置" link to="/pages/setter/setterDetail" <!-- <uni-list-item title="参数设置" link to="/pages/setter/setterDetail"
thumb="/static/icon_personal_setting.png"></uni-list-item> --> thumb="/static/icon_personal_setting.png"></uni-list-item> -->
</uni-list> </uni-list>
@ -44,7 +48,9 @@
removeToken removeToken
} from '@/common/utils/auth' } from '@/common/utils/auth'
import { import {
ref,reactive,nextTick ref,
reactive,
nextTick
} from "vue"; } from "vue";
import { import {
onLoad onLoad
@ -53,18 +59,18 @@
const userName = ref(store.state.user.name); const userName = ref(store.state.user.name);
let test = ref("123"); let test = ref("123");
let userInfo = ref(null); let userInfo = ref(null);
onLoad(()=>{ onLoad(() => {
console.log(11) console.log(11)
getUserProfile().then(res=>{ getUserProfile().then(res => {
userInfo.value = res.data userInfo.value = res.data
// nextTick(()=>{ // nextTick(()=>{
// const userInfo = res.data.nickname // const userInfo = res.data.nickname
// console.log("",userInfo) // console.log("",userInfo)
// }) // })
}) })
}); });
function handlerlogout() { function handlerlogout() {
store.dispatch('LogOut', {}).then(() => { store.dispatch('LogOut', {}).then(() => {

Loading…
Cancel
Save