|
|
@ -34,6 +34,7 @@
|
|
|
|
</u-row>
|
|
|
|
</u-row>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
<view class="" slot="foot">
|
|
|
|
<view class="" slot="foot">
|
|
|
|
|
|
|
|
<template v-if="orderItem.orderStatus == 1">
|
|
|
|
<u-button
|
|
|
|
<u-button
|
|
|
|
size="mini"
|
|
|
|
size="mini"
|
|
|
|
:custom-style="{
|
|
|
|
:custom-style="{
|
|
|
@ -43,10 +44,13 @@
|
|
|
|
'linear-gradient(to right, rgb(111, 137, 221), rgb(42, 75, 180))',
|
|
|
|
'linear-gradient(to right, rgb(111, 137, 221), rgb(42, 75, 180))',
|
|
|
|
}"
|
|
|
|
}"
|
|
|
|
:plain="true"
|
|
|
|
:plain="true"
|
|
|
|
shape="false"
|
|
|
|
shape="circle"
|
|
|
|
|
|
|
|
@click="fnTakeOrder(orderItem)"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
接单
|
|
|
|
接单
|
|
|
|
</u-button>
|
|
|
|
</u-button>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<template v-else-if="orderItem.orderStatus == 2">
|
|
|
|
<u-button
|
|
|
|
<u-button
|
|
|
|
size="mini"
|
|
|
|
size="mini"
|
|
|
|
:custom-style="{
|
|
|
|
:custom-style="{
|
|
|
@ -56,7 +60,7 @@
|
|
|
|
'linear-gradient(to right, rgb(255, 133, 133), rgb(249, 61, 61))',
|
|
|
|
'linear-gradient(to right, rgb(255, 133, 133), rgb(249, 61, 61))',
|
|
|
|
}"
|
|
|
|
}"
|
|
|
|
:plain="true"
|
|
|
|
:plain="true"
|
|
|
|
shape="false"
|
|
|
|
shape="circle"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
延期发货
|
|
|
|
延期发货
|
|
|
|
</u-button>
|
|
|
|
</u-button>
|
|
|
@ -69,7 +73,7 @@
|
|
|
|
'linear-gradient(to right, rgb(255, 199, 131), rgb(252, 136, 13))',
|
|
|
|
'linear-gradient(to right, rgb(255, 199, 131), rgb(252, 136, 13))',
|
|
|
|
}"
|
|
|
|
}"
|
|
|
|
:plain="true"
|
|
|
|
:plain="true"
|
|
|
|
shape="false"
|
|
|
|
shape="circle"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
缺货结单
|
|
|
|
缺货结单
|
|
|
|
</u-button>
|
|
|
|
</u-button>
|
|
|
@ -82,7 +86,8 @@
|
|
|
|
'linear-gradient(to right, rgb(111, 137, 221), rgb(42, 75, 180))',
|
|
|
|
'linear-gradient(to right, rgb(111, 137, 221), rgb(42, 75, 180))',
|
|
|
|
}"
|
|
|
|
}"
|
|
|
|
:plain="true"
|
|
|
|
:plain="true"
|
|
|
|
shape="false"
|
|
|
|
shape="circle"
|
|
|
|
|
|
|
|
@click="fnToProd(orderItem)"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
投产
|
|
|
|
投产
|
|
|
|
</u-button>
|
|
|
|
</u-button>
|
|
|
@ -95,22 +100,26 @@
|
|
|
|
'linear-gradient(to right, rgb(126, 237, 140), rgb(74, 215, 92))',
|
|
|
|
'linear-gradient(to right, rgb(126, 237, 140), rgb(74, 215, 92))',
|
|
|
|
}"
|
|
|
|
}"
|
|
|
|
:plain="true"
|
|
|
|
:plain="true"
|
|
|
|
shape="false"
|
|
|
|
shape="circle"
|
|
|
|
>
|
|
|
|
>
|
|
|
|
发货
|
|
|
|
发货
|
|
|
|
</u-button>
|
|
|
|
</u-button>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</u-card>
|
|
|
|
</u-card>
|
|
|
|
|
|
|
|
<PopToProd ref="popToProd" @evtRefresh="fnRefreshA"></PopToProd>
|
|
|
|
|
|
|
|
<u-top-tips ref="uTips"></u-top-tips>
|
|
|
|
</view>
|
|
|
|
</view>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
<script>
|
|
|
|
import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
|
|
|
|
import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
|
|
|
|
import { mapGetters } from "vuex";
|
|
|
|
import { mapGetters } from "vuex";
|
|
|
|
import { getOrderList } from "@/api/yys/materialProcurementOrder.js";
|
|
|
|
import { getOrderList, takeOrder } from "@/api/yys/materialProcurementOrder.js";
|
|
|
|
import CustomNavbar from "./components/CustomNavbar";
|
|
|
|
import CustomNavbar from "./components/CustomNavbar";
|
|
|
|
|
|
|
|
import PopToProd from "./components/PopToProd";
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
components: { CustomNavbar },
|
|
|
|
components: { CustomNavbar, PopToProd },
|
|
|
|
mixins: [],
|
|
|
|
mixins: [],
|
|
|
|
data() {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
return {
|
|
|
@ -152,6 +161,42 @@ export default {
|
|
|
|
console.log(err);
|
|
|
|
console.log(err);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
fnTakeOrder(orderItem) {
|
|
|
|
|
|
|
|
uni.showModal({
|
|
|
|
|
|
|
|
title: "确认接单",
|
|
|
|
|
|
|
|
content: "确认接单(编号:" + orderItem.orderNumber + ")",
|
|
|
|
|
|
|
|
success: (res) => {
|
|
|
|
|
|
|
|
if (res.confirm) {
|
|
|
|
|
|
|
|
// 用户确认接单
|
|
|
|
|
|
|
|
console.log("用户确认接单");
|
|
|
|
|
|
|
|
takeOrder(orderItem)
|
|
|
|
|
|
|
|
.then((res) => {
|
|
|
|
|
|
|
|
if (res.code == 200) {
|
|
|
|
|
|
|
|
this.fnGetList();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
.catch((err) => {
|
|
|
|
|
|
|
|
console.log(err);
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
} else if (res.cancel) {
|
|
|
|
|
|
|
|
// 用户取消接单
|
|
|
|
|
|
|
|
console.log("用户取消接单");
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
console.log(orderItem);
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
fnToProd(orderItem) {
|
|
|
|
|
|
|
|
this.$refs.popToProd.init(orderItem);
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
fnRefreshA() {
|
|
|
|
|
|
|
|
this.$refs.uTips.show({
|
|
|
|
|
|
|
|
title: '投产提交成功',
|
|
|
|
|
|
|
|
type: 'success',
|
|
|
|
|
|
|
|
duration: '2300'
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
this.fnGetList();
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
</script>
|
|
|
|