|
|
|
@ -8,20 +8,50 @@
|
|
|
|
|
<view class="right"></view>
|
|
|
|
|
</view>
|
|
|
|
|
<u-form class="form" label-width="130rpx">
|
|
|
|
|
<view class="title">{{ $t('message.Warehouse_QueryCriteria') }}</view>
|
|
|
|
|
<u-form-item :required="true" :label="this.$t('message.Warehouse_OrderNo')">
|
|
|
|
|
<u-input v-model="order3" :placeholder="this.$t('message.po_PleaseInput')" />
|
|
|
|
|
<!-- 单号 -->
|
|
|
|
|
<view class="single">
|
|
|
|
|
<view class="single-left">
|
|
|
|
|
<view>{{ $t('message.CommissionedSingleNumber') }}</view>
|
|
|
|
|
<u-search :placeholder="$t('message.Commission_tips1')" v-model="order3" @search="query" :show-action="false"></u-search>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="single-right">
|
|
|
|
|
<u-button type="primary" @click="query">{{ $t('message.Query') }}</u-button>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<!-- 物料号 -->
|
|
|
|
|
<u-form-item :label="$t('message.po_MaterielNo')">
|
|
|
|
|
<jPicker sureColor="#ff0000" style="width: 260rpx" @bindpicker="materialChoice" showKey="value" valKey="value" :val="wl.value" class="search" :options="MaterialList" />
|
|
|
|
|
</u-form-item>
|
|
|
|
|
<!-- 物料描述 -->
|
|
|
|
|
<u-form-item :label="$t('message.po_MaterielDes')">
|
|
|
|
|
<u-input :disabled="true" v-model="Some.productDescZh" placeholder="" style="overflow: hidden" />
|
|
|
|
|
</u-form-item>
|
|
|
|
|
<!-- 数量 -->
|
|
|
|
|
<u-form-item :label="$t('message.Summary_Number')">
|
|
|
|
|
<u-input :disabled="true" v-model="Some.qty" placeholder="" />
|
|
|
|
|
</u-form-item>
|
|
|
|
|
<!-- 原库位 -->
|
|
|
|
|
<u-form-item :label="$t('message.Warehouse_OriginalLocation')">
|
|
|
|
|
<u-input :disabled="true" v-model="Some.originWl" placeholder="" />
|
|
|
|
|
</u-form-item>
|
|
|
|
|
<!-- 目标库位 -->
|
|
|
|
|
<u-form-item :label="$t('message.Warehouse_TargetLocation')">
|
|
|
|
|
<u-input :disabled="true" v-model="Some.aimWl" placeholder="" />
|
|
|
|
|
</u-form-item>
|
|
|
|
|
<!-- 成本中心 -->
|
|
|
|
|
<u-form-item :label="$t('message.product_costCenter')">
|
|
|
|
|
<u-input :disabled="true" v-model="Some.costCenter" placeholder="" />
|
|
|
|
|
</u-form-item>
|
|
|
|
|
<!-- 文件号 -->
|
|
|
|
|
<u-form-item :label="$t('message.DocumentNumber')">
|
|
|
|
|
<u-input v-model="Some.fileNo" placeholder="" />
|
|
|
|
|
</u-form-item>
|
|
|
|
|
<u-row class="button-bar">
|
|
|
|
|
<u-col :span="4">
|
|
|
|
|
<u-button type="error" @click="uni.navigateBack()">{{
|
|
|
|
|
$t('message.po_Return')
|
|
|
|
|
}}</u-button>
|
|
|
|
|
<u-col :span="6">
|
|
|
|
|
<u-button type="error" @click="uni.navigateBack()">{{ $t('message.po_Return') }}</u-button>
|
|
|
|
|
</u-col>
|
|
|
|
|
<u-col :span="8">
|
|
|
|
|
<u-button type="primary" @click="submit"
|
|
|
|
|
>{{ $t('message.po_Continue') }}
|
|
|
|
|
</u-button></u-col
|
|
|
|
|
<u-col :span="6">
|
|
|
|
|
<u-button type="primary" @click="submit">{{ $t('message.InventoryFinish') }} </u-button></u-col
|
|
|
|
|
>
|
|
|
|
|
</u-row>
|
|
|
|
|
</u-form>
|
|
|
|
@ -32,42 +62,80 @@
|
|
|
|
|
import { Component } from 'vue-property-decorator';
|
|
|
|
|
import { BasePage } from '@/components/base/page';
|
|
|
|
|
import model from './model';
|
|
|
|
|
|
|
|
|
|
import { page } from '@/utils/page';
|
|
|
|
|
|
|
|
|
|
@Component
|
|
|
|
|
import jPicker from '@/components/J-Picker/jPicker.vue';
|
|
|
|
|
import { session } from '@/store/modules/session';
|
|
|
|
|
@Component({
|
|
|
|
|
components: {
|
|
|
|
|
jPicker,
|
|
|
|
|
},
|
|
|
|
|
})
|
|
|
|
|
export default class KanDanHandOver extends BasePage {
|
|
|
|
|
//单号
|
|
|
|
|
order3 = '';
|
|
|
|
|
/**
|
|
|
|
|
* 页面Module
|
|
|
|
|
*/
|
|
|
|
|
model = model;
|
|
|
|
|
// async onKdOrderNoConfirm() {
|
|
|
|
|
// if (this.order3 === '') {
|
|
|
|
|
// uni.showToast({ icon: 'none', title: '请扫描看单号' });
|
|
|
|
|
// return;
|
|
|
|
|
// } else {
|
|
|
|
|
// try {
|
|
|
|
|
// const odr = await order.takeOrder({ order3: this.order3, page: 1, row: 50 });
|
|
|
|
|
// order.add({ order: odr });
|
|
|
|
|
// // uni.navigateTo({ url: page.raw.warehouse.transfer.details });
|
|
|
|
|
// } catch (e) {
|
|
|
|
|
// uni.showToast({ icon: 'none', title: e.message });
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
// onReady() {
|
|
|
|
|
// this.model.takeOrder();
|
|
|
|
|
// }
|
|
|
|
|
async submit() {
|
|
|
|
|
wl: any = {};
|
|
|
|
|
Some: any = {};
|
|
|
|
|
MaterialList: any = [];
|
|
|
|
|
//查询单号
|
|
|
|
|
async query() {
|
|
|
|
|
if (this.order3 === '') {
|
|
|
|
|
uni.showToast({ icon: 'none', title: this.$t('message.Scrap_Tip') as string });
|
|
|
|
|
uni.showToast({ icon: 'none', title: this.$t('message.Commission_tips1') as string });
|
|
|
|
|
return;
|
|
|
|
|
} else {
|
|
|
|
|
await this.model.takeOrder({
|
|
|
|
|
order3: this.order3,
|
|
|
|
|
});
|
|
|
|
|
uni.navigateTo({ url: page.raw.warehouse.rowScrap.details });
|
|
|
|
|
if (this.model.code == '1') {
|
|
|
|
|
uni.showToast({ icon: 'none', title: this.$t('message.successful') as string });
|
|
|
|
|
this.model.orderInInfoList.forEach((item: any) => {
|
|
|
|
|
item.fileNo = '';
|
|
|
|
|
let arr: any = {
|
|
|
|
|
label: item.productCode,
|
|
|
|
|
value: item.productCode,
|
|
|
|
|
};
|
|
|
|
|
this.MaterialList.push(arr);
|
|
|
|
|
});
|
|
|
|
|
this.Some = this.model.orderInInfoList[0];
|
|
|
|
|
this.wl = this.MaterialList[0];
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
//选择物料回调函数
|
|
|
|
|
materialChoice(e: any) {
|
|
|
|
|
this.wl = e.pickerName;
|
|
|
|
|
this.model.orderInInfoList.forEach((item: any) => {
|
|
|
|
|
if (item.productCode == e.pickerName.value) {
|
|
|
|
|
this.Some = item;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
//提交
|
|
|
|
|
async submit() {
|
|
|
|
|
if (this.order3 === '') {
|
|
|
|
|
uni.showToast({ icon: 'none', title: this.$t('message.Commission_tips1') as string });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (!this.Some) {
|
|
|
|
|
uni.showToast({ icon: 'none', title: this.$t('message.Warehouse_Tip5') as string });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (this.Some.fileNo == '' || this.Some.fileNo == null || this.Some.fileNo == undefined) {
|
|
|
|
|
uni.showToast({ icon: 'none', title: this.$t('message.fileNumber') as string });
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
let orderlist = [];
|
|
|
|
|
this.Some.type = '1';
|
|
|
|
|
this.Some.keepBy = session.loginName;
|
|
|
|
|
this.Some.orderType = '1';
|
|
|
|
|
orderlist.push(this.Some);
|
|
|
|
|
await model.onTakeoutConfirm(orderlist);
|
|
|
|
|
if (this.model.code == '1') {
|
|
|
|
|
uni.showToast({ icon: 'none', title: this.$t('message.success') as string });
|
|
|
|
|
this.Some = {};
|
|
|
|
|
this.Some.fileNo = ' ';
|
|
|
|
|
this.wl = {};
|
|
|
|
|
this.order3 = '';
|
|
|
|
|
this.MaterialList = [];
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -115,25 +183,56 @@ export default class KanDanHandOver extends BasePage {
|
|
|
|
|
border-radius: 10rpx;
|
|
|
|
|
box-shadow: 0 0 20rpx 0 rgba(128, 128, 128, 0.2);
|
|
|
|
|
|
|
|
|
|
// .u-form-item {
|
|
|
|
|
// line-height: 35rpx;
|
|
|
|
|
// background-color: #f7f6fb;
|
|
|
|
|
// padding: 10rpx 30rpx;
|
|
|
|
|
// border-radius: 8rpx;
|
|
|
|
|
// &:after {
|
|
|
|
|
// border-bottom-width: 0;
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
.u-form-item {
|
|
|
|
|
padding: 30rpx 0;
|
|
|
|
|
line-height: 35rpx;
|
|
|
|
|
background-color: #f7f6fb;
|
|
|
|
|
padding: 10rpx 30rpx;
|
|
|
|
|
border-radius: 8rpx;
|
|
|
|
|
&:after {
|
|
|
|
|
border-bottom-width: 0;
|
|
|
|
|
}
|
|
|
|
|
.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;
|
|
|
|
|
width: 150rpx;
|
|
|
|
|
height: 70rpx;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.title {
|
|
|
|
|
margin-bottom: 40rpx;
|
|
|
|
|
color: #1a1a1a;
|
|
|
|
|
font-size: 30rpx;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.button-bar {
|
|
|
|
|
margin: 40rpx -10rpx 0;
|
|
|
|
|
position: fixed;
|
|
|
|
|
bottom: 0;
|
|
|
|
|
left: 0;
|
|
|
|
|
right: 0;
|
|
|
|
|
z-index: 99;
|
|
|
|
|
background: #ffffff;
|
|
|
|
|
box-shadow: 0 1rpx 20rpx 0 rgba(128, 128, 128, 0.2);
|
|
|
|
|
padding: 20rpx;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|