Browse Source

Merge branch 'master_hella' of http://dev.ccwin-in.com:3000/sfms3.0/sfms3.0-uniapp into master_hella

hella_online_20240829
lijuncheng 6 months ago
parent
commit
75c5eb1746
  1. 14
      src/api/httpRequest3.js
  2. 39
      src/pages/index/index.vue
  3. 16
      src/pages/productPutaway/record/productPutawayRecord.vue
  4. 33
      src/pages/productReceipt/job/productReceiptJob.vue
  5. 4
      src/pages/productReceipt/job/scrapReceiptJob.vue
  6. 4
      src/pages/productReceipt/job/semiProductReceiptJob.vue

14
src/api/httpRequest3.js

@ -1,6 +1,9 @@
import storage from '../common/utils/storage'
import {
removeToken
} from '@/common/utils/auth'
function service(options = {}) {
var token = storage.getStorage(storage.constant.token)
var tenantId = storage.getStorage('tenantId')
@ -20,7 +23,7 @@ function service(options = {}) {
"dataType":"json",
"tenant-id":tenantId
};
options.timeout = 10000
options.timeout = 300000
options.url = requestUrl+options.url
@ -31,6 +34,13 @@ function service(options = {}) {
if(res.data.code==0){
resolve(res.data);
}else {
if(res.data.code==401){
uni.clearStorageSync()
removeToken();
uni.reLaunch({
url: '/pages/login/index'
})
}
reject("系统异常:"+res.data.msg)
console.log("系统异常",res.data.msg)
}

39
src/pages/index/index.vue

@ -156,24 +156,27 @@
},
onShow() {
if (uni.getStorageSync("hasLogin") == null || uni.getStorageSync("hasLogin") == false) {
uni.showModal({
title: '未登录',
content: '您未登录 , 需要登录后才能继续', //
showCancel: !this.forcedLogin,
success: (res) => {
if (res.confirm) {
//使reLanch
if (this.forcedLogin) {
uni.reLaunch({
url: '../login/index'
})
} else {
uni.navigateTo({
url: '../login/index'
})
}
}
}
// uni.showModal({
// title: '',
// content: ' , ', //
// showCancel: !this.forcedLogin,
// success: (res) => {
// if (res.confirm) {
// //使reLanch
// if (this.forcedLogin) {
// uni.reLaunch({
// url: '../login/index'
// })
// } else {
// uni.navigateTo({
// url: '../login/index'
// })
// }
// }
// }
// })
uni.reLaunch({
url: '../login/index'
})
} else {
this.timerRefresh();

16
src/pages/productPutaway/record/productPutawayRecord.vue

@ -73,6 +73,9 @@
import winScanLocation from "@/mycomponents/scan/winScanLocation.vue"
import winScanPackAndLocation from "@/mycomponents/scan/winScanPackAndLocation.vue"
import recordComDetailCard from '@/mycomponents/record/recordComDetailCard.vue'
import {
updateTitle
} from '@/common/basic.js';
export default {
@ -100,10 +103,18 @@
inInventoryStatus: "", //
outInventoryStatus: "", //
businessType: {},
managementList: []
managementList: [],
type:''
};
},
onLoad(option) {
this.type = option.type
if(this.type=='predict'){
updateTitle('制品上架记录')
}else if(this.type=='assemble'){
updateTitle('装配上架记录')
}
var typeCode = "ProductPutaway"
getBusinessType(typeCode, res => {
if (res.success) {
@ -336,6 +347,9 @@
})
})
this.dataContent.subList = subList;
if(this.type){
this.dataContent.type = this.type;
}
this.dataContent.creator = creator;
return this.dataContent;
},

33
src/pages/productReceipt/job/productReceiptJob.vue

@ -72,7 +72,7 @@
pageNo: 1,
pageSize: 10,
totalCount: 0,
loadingType: "nomore",
loadingType: "noMore",
checkedToday: false,
checkedWaitTask: false,
todayTime: "",
@ -94,13 +94,7 @@
this.getList('refresh');
},
onReachBottom() {
//
if (this.loadingType == 'loading' || this.loadingType == 'nomore') {
return;
}
this.getList("more");
},
onPullDownRefresh() {
this.getList('refresh');
@ -126,7 +120,15 @@
}
},
methods: {
methods: {
onReachBottom() {
console.log('onReachBottom',this.loadingType)
//
if (this.loadingType == 'loading' || this.loadingType == 'noMore') {
return;
}
this.getList("more");
},
refresh() {
this.getList('refresh');
},
@ -183,9 +185,9 @@
} else {
updateTitle("报废收货任务(" + this.totalCount + ")");
}
this.loadingType = "loadmore";
this.loadingType = "more";
if (list == null || list.length == 0) {
this.loadingType = "nomore";
this.loadingType = "noMore";
return;
}
this.jobList = type === "refresh" ? list : this.jobList.concat(list);
@ -332,7 +334,7 @@
goHome()
},
onReach() {
if (this.loadingType == 'loading' || this.loadingType == 'nomore') {
if (this.loadingType == 'loading' || this.loadingType == 'noMore') {
return;
}
this.getList("more");
@ -365,7 +367,12 @@
column: "itemCode",
action: "==",
value: result.label.itemCode
},
},
{
column: "type",
action: "==",
value: this.type
}
// {
// column: "fromLocationCode",
// action: "==",

4
src/pages/productReceipt/job/scrapReceiptJob.vue

@ -17,7 +17,9 @@
};
},
onReachBottom() {
this.$refs.productreceiptjob.onReach();
},
onPullDownRefresh() {
this.$refs.productreceiptjob.refresh();
},

4
src/pages/productReceipt/job/semiProductReceiptJob.vue

@ -17,7 +17,9 @@
};
},
onReachBottom() {
this.$refs.productreceiptjob.onReach();
},
onShow() {
if(this.$refs.productreceiptjob!=undefined){
this.$refs.productreceiptjob.refresh();

Loading…
Cancel
Save