cosmoim-852 fix bug修复和优化调整

master
FEC7\houzeyun 3 years ago
parent ef4b956053
commit 4559baec27

@ -15,7 +15,7 @@
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[vue]": {
"editor.defaultFormatter": "octref.vetur"
"editor.defaultFormatter": "Vue.volar"
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"

21071
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -60,7 +60,7 @@
</u-form-item>
</u-form>
<view class="i18n" @click="i18nOptionsShow = true">
<view class="dropdown-text">{{ $i18n.locale === 'en' ? 'English' : $i18n.locale === 'cn' ? '简体中文' : 'русск' }}</view>
<view class="dropdown-text">{{ $i18n.locale === 'en' ? 'English' : $i18n.locale === 'cn' ? '简体中文' : 'русск' }} </view>
<u-icon :class="i18nOptionsShow ? 'dropdown-icon-active' : 'dropdown-icon'" size="16" name="/static/icons/icon-50.png"></u-icon>
<u-action-sheet :list="i18nList" v-model="i18nOptionsShow" @click="onLanguageSelect"></u-action-sheet>
</view>
@ -294,7 +294,7 @@ export default class LoginPage extends BasePage {
this.$form.validate(async (valid: boolean) => {
if (valid) {
if (!server.isServerAddressSet) {
await uni.showToast({
uni.showToast({
icon: 'none',
title: this.$t('message.Tip') as string,
});

@ -223,7 +223,7 @@ export default class returningDom extends BasePage {
this.LocationList[this.LocationList.length - 1].rfPwd = this.rfPwd;
this.LocationList[this.LocationList.length - 1].loginName = this.operator;
this.LocationList[this.LocationList.length - 1].operatorPass = this.operator;
this.LocationList[this.LocationList.length - 1].wkposCode = this.wlCode.label;
this.LocationList[this.LocationList.length - 1].wkposCode = this.wlCode.sendSpot;
this.model.materielList[this.checkindex].totalAmount = this.accSubtract(this.LocationList[this.LocationList.length - 1].totalAmount, this.qty);
this.Container = '';
this.Barcode = '';

@ -307,6 +307,7 @@ export default class dnReceiptDom extends BasePage {
}
Container: any = {};
async searchBarcode() {
console.log('receiptAmount', this.receiptAmount);
if (this.Barcode == '') {
this.customToast(this.$t('message.barcode') as string);
return;
@ -332,6 +333,10 @@ export default class dnReceiptDom extends BasePage {
await this.model.searchBarcode(params);
this.Container = this.model.ContainerCode;
this.receiptAmount = parseFloat(this.Container.requestAmount);
console.log('Container', this.Container);
console.log('receiptAmount', this.receiptAmount);
console.log(this.disabled);
this.disabled = true;
}
//
@ -737,16 +742,19 @@ export default class dnReceiptDom extends BasePage {
position: absolute;
top: 351px;
left: 0;
button {
position: absolute;
top: 3rpx;
right: 35rpx;
}
}
.config {
width: 100%;
height: 100rpx;
position: relative;
// top: 420px;
// left: 0;
button {

@ -70,8 +70,8 @@
<u-button type="error" @click="uni.navigateBack({})">{{ $t('message.po_Return') }}</u-button>
</u-col>
<u-col :span="6">
<u-button type="primary" @click="submit">{{ $t('message.InventoryFinish') }} </u-button></u-col
>
<u-button type="primary" @click="submit">{{ $t('message.InventoryFinish') }} </u-button>
</u-col>
</u-row>
</u-form>
</view>
@ -97,7 +97,7 @@ export default class KanDanHandOver extends BasePage {
Some: any = {};
MaterialList: any = [];
Barcode: any = '';
qty = 0;
qty: any = 0;
SubmitOrderlist: any = [];
Container: any = '';
SomeIndex = 0;
@ -176,7 +176,7 @@ export default class KanDanHandOver extends BasePage {
return;
}
} else {
if (this.qty > this.Container.qty - this.Container.cpRef4) {
if (this.qty > this.Container.qty - parseFloat(this.Container.cpRef4)) {
this.customToast(this.$t('message.AppendMateriel3') as string);
return;
}
@ -185,21 +185,25 @@ export default class KanDanHandOver extends BasePage {
if (this.SubmitOrderlist.length != 0) {
this.SubmitOrderlist.forEach((item: any) => {
if (item.barCode == this.Container.barcode) {
num += item.qty;
num += parseFloat(item.qty);
}
});
}
if (this.qty + num > this.Some.qty) {
console.log('qty', this.qty);
console.log('num', num);
console.log(parseFloat(this.qty) + num);
console.log(this.Some.qty);
if (parseFloat(this.qty) + num > this.Some.qty) {
this.customToast(this.$t('message.demandQuantity') as string);
return;
}
if (this.Container.cpRef4 == null) {
if (this.qty + num > this.Container.qty) {
if (parseFloat(this.qty) + num > this.Container.qty) {
this.customToast(this.$t('message.AppendMateriel3') as string);
return;
}
} else {
if (this.qty + num > this.Container.qty - this.Container.cpRef4) {
if (parseFloat(this.qty) + num > this.Container.qty - this.Container.cpRef4) {
this.customToast(this.$t('message.AppendMateriel3') as string);
return;
}
@ -210,10 +214,10 @@ export default class KanDanHandOver extends BasePage {
this.SubmitOrderlist[this.SubmitOrderlist.length - 1].orderType = '2';
this.SubmitOrderlist[this.SubmitOrderlist.length - 1].qty = this.qty;
this.SubmitOrderlist[this.SubmitOrderlist.length - 1].barCode = this.Container.barcode;
this.model.orderInInfoList[this.SomeIndex].totalqty += parseFloat(this.qty);
this.qty = 0;
this.Container = '';
this.Barcode = '';
this.model.orderInInfoList[this.SomeIndex].totalqty += this.qty;
}
deleteItem(e: any) {
uni.showModal({
@ -300,13 +304,16 @@ export default class KanDanHandOver extends BasePage {
font-size: 34rpx;
font-weight: 500;
text-align: center;
.title {
flex: 3;
}
.left,
.right {
flex: 1;
}
.icon {
display: flex;
justify-content: center;
@ -321,23 +328,28 @@ export default class KanDanHandOver extends BasePage {
padding: 40rpx;
border-radius: 10rpx;
box-shadow: 0 0 20rpx 0 rgba(128, 128, 128, 0.2);
.u-form-item {
padding: 30rpx 0;
line-height: 35rpx;
.single {
width: 100%;
height: 100rpx;
display: flex;
.single-left {
width: 80%;
height: 100%;
display: flex;
view {
width: 110rpx;
height: 100%;
line-height: 100rpx;
}
}
.single-right {
button {
margin-top: 15rpx;
@ -347,12 +359,14 @@ export default class KanDanHandOver extends BasePage {
}
}
}
.add {
width: 100%;
height: 100rpx;
position: absolute;
top: 478px;
left: 0;
button {
position: absolute;
top: 3rpx;
@ -360,23 +374,28 @@ export default class KanDanHandOver extends BasePage {
z-index: 10000;
}
}
.newly {
display: flex;
}
.single {
width: 100%;
height: 100rpx;
display: flex;
.single-left {
width: 80%;
height: 100%;
display: flex;
view {
width: 110rpx;
height: 100%;
line-height: 100rpx;
}
}
.single-right {
button {
margin-top: 15rpx;
@ -385,12 +404,14 @@ export default class KanDanHandOver extends BasePage {
}
}
}
.title {
margin-bottom: 40rpx;
color: #1a1a1a;
font-size: 30rpx;
font-weight: 500;
}
.button-bar {
position: fixed;
bottom: 0;

@ -78,8 +78,8 @@
<u-button type="error" @click="uni.navigateBack()">{{ $t('message.po_Return') }}</u-button>
</u-col>
<u-col :span="6">
<u-button type="primary" @click="submit">{{ $t('message.InventoryFinish') }} </u-button></u-col
>
<u-button type="primary" @click="submit">{{ $t('message.InventoryFinish') }} </u-button>
</u-col>
</u-row>
</u-form>
</view>
@ -186,13 +186,17 @@ export default class KanDanHandOver extends BasePage {
this.customToast(this.$t('message.scanningContainer') as string);
return;
}
if (parseFloat(this.qty) <= 0) {
this.customToast(this.$t('message.AppendMateriel2') as string);
return;
}
if (this.Container.cpRef4 == null) {
if (parseFloat(this.qty) <= 0 || parseFloat(this.qty) > this.Container.qty) {
if (parseFloat(this.qty) > this.Container.qty) {
this.customToast(this.$t('message.AppendMateriel3') as string);
return;
}
} else {
if (parseFloat(this.qty) <= 0 || parseFloat(this.qty) > this.Container.qty - parseFloat(this.Container.cpRef4)) {
if (parseFloat(this.qty) > this.Container.qty - parseFloat(this.Container.cpRef4)) {
this.customToast(this.$t('message.AppendMateriel3') as string);
return;
}
@ -312,13 +316,16 @@ export default class KanDanHandOver extends BasePage {
font-weight: 500;
text-align: center;
padding-top: 19px;
.title {
flex: 3;
}
.left,
.right {
flex: 1;
}
.icon {
display: flex;
justify-content: center;
@ -347,23 +354,28 @@ export default class KanDanHandOver extends BasePage {
padding: 30rpx 0;
line-height: 35rpx;
}
.newly {
display: flex;
}
.single {
width: 100%;
height: 100rpx;
display: flex;
.single-left {
width: 80%;
height: 100%;
display: flex;
view {
width: 110rpx;
height: 100%;
line-height: 100rpx;
}
}
.single-right {
button {
margin-top: 15rpx;
@ -372,12 +384,14 @@ export default class KanDanHandOver extends BasePage {
}
}
}
.add {
width: 100%;
height: 100rpx;
position: absolute;
top: 620px;
left: 0;
button {
position: absolute;
top: 3rpx;
@ -385,12 +399,14 @@ export default class KanDanHandOver extends BasePage {
z-index: 10000;
}
}
.title {
margin-bottom: 40rpx;
color: #1a1a1a;
font-size: 30rpx;
font-weight: 500;
}
.button-bar {
position: fixed;
bottom: 0;

@ -142,9 +142,9 @@ export default class KanDanHandOver extends BasePage {
await this.model.searchBarcode(params);
this.Container = this.model.ContainerCode;
if (this.Container.cpRef4 == null) {
this.total = this.Container.qty;
this.total = parseFloat(this.Container.qty);
} else {
this.total = this.Container.qty - this.Container.cpRef4;
this.total = parseFloat(this.Container.qty) - parseFloat(this.Container.cpRef4);
}
}
Add() {
@ -156,7 +156,7 @@ export default class KanDanHandOver extends BasePage {
this.customToast(this.$t('message.Commission_tips6') as string);
return;
}
if (parseFloat(this.orderlist.actualQty) + parseFloat(this.Container.qty) > parseFloat(this.orderlist.qty)) {
if (parseFloat(this.orderlist.actualQty) + this.total > parseFloat(this.orderlist.qty)) {
this.customToast(this.$t('message.Commission_tips4') as string);
return;
}
@ -240,13 +240,16 @@ export default class KanDanHandOver extends BasePage {
font-weight: 500;
text-align: center;
padding-top: 19px;
.title {
flex: 3;
}
.left,
.right {
flex: 1;
}
.icon {
display: flex;
justify-content: center;
@ -255,6 +258,7 @@ export default class KanDanHandOver extends BasePage {
height: 88rpx;
}
}
.form {
background-color: #fff;
padding: 40rpx;
@ -265,14 +269,17 @@ export default class KanDanHandOver extends BasePage {
padding: 30rpx 0;
line-height: 35rpx;
}
.single {
width: 100%;
height: 100rpx;
display: flex;
.single-left {
width: 80%;
height: 100%;
display: flex;
view {
width: 110rpx;
height: 100%;
@ -280,6 +287,7 @@ export default class KanDanHandOver extends BasePage {
z-index: 10000;
}
}
.single-right {
button {
margin-top: 15rpx;
@ -288,12 +296,14 @@ export default class KanDanHandOver extends BasePage {
}
}
}
.add {
width: 100%;
height: 100rpx;
position: absolute;
top: 493px;
left: 0;
button {
position: absolute;
top: 3rpx;
@ -301,10 +311,12 @@ export default class KanDanHandOver extends BasePage {
z-index: 10000;
}
}
.newly {
display: flex;
}
}
.single-right {
button {
//margin-top: 15rpx;
@ -312,6 +324,7 @@ export default class KanDanHandOver extends BasePage {
height: 70rpx;
}
}
.bottom-bar {
position: fixed;
bottom: 0;

18884
yarn.lock

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save