|
|
@@ -0,0 +1,89 @@
|
|
|
+<template>
|
|
|
+<view>
|
|
|
+ <view>
|
|
|
+ <view class="app-casher-area">
|
|
|
+ <view class="nav-left">
|
|
|
+ <casherNav navType="sh"></casherNav>
|
|
|
+ </view>
|
|
|
+ <view class="work-list">
|
|
|
+ <workList ref="workListRef" @getOrderInfo="getOrderInfo" sh="1"></workList>
|
|
|
+ </view>
|
|
|
+ <view class="work-info">
|
|
|
+ <workInfo ref="workInfoRef" :selectOrderId="selectOrderId" @calcFn="calcFn" @finishNotice="finishNotice"></workInfo>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+</view>
|
|
|
+</template>
|
|
|
+<script>
|
|
|
+import { mapGetters } from "vuex";
|
|
|
+import productMins from "@/mixins/product";
|
|
|
+import casherNav from './components/nav.vue'
|
|
|
+import workList from './components/workList.vue'
|
|
|
+import workInfo from './components/workInfo.vue'
|
|
|
+export default {
|
|
|
+ name: "work",
|
|
|
+ components: {casherNav,workList,workInfo},
|
|
|
+ mixins: [productMins],
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ currentJobType:'modify',
|
|
|
+ currentJobId:0,
|
|
|
+ selectOrderId:0,
|
|
|
+ modifyInfo:{hasModify:0}
|
|
|
+ }
|
|
|
+ },
|
|
|
+ computed: {
|
|
|
+ ...mapGetters(["getLoginInfo"])
|
|
|
+ },
|
|
|
+ onShow() {
|
|
|
+ if(this.modifyInfo.hasModify && this.modifyInfo.hasModify == 1){
|
|
|
+ this.$refs.workInfoRef.getOrderDetail(this.selectOrderId)
|
|
|
+ }
|
|
|
+ // #ifdef APP-PLUS
|
|
|
+ this.listenScanItem()
|
|
|
+ // #endif
|
|
|
+ },
|
|
|
+ onHide(){
|
|
|
+ // #ifdef APP-PLUS
|
|
|
+ //避免重复,每次进来先移除全局自定义事件监听器
|
|
|
+ uni.$off('listenGetScanCode')
|
|
|
+ // #endif
|
|
|
+ },
|
|
|
+ onUnload() {
|
|
|
+ // #ifdef APP-PLUS
|
|
|
+ //避免重复,每次进来先移除全局自定义事件监听器
|
|
|
+ uni.$off('listenGetScanCode')
|
|
|
+ // #endif
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ finishNotice(){
|
|
|
+ this.$refs.workListRef.refreshList()
|
|
|
+ },
|
|
|
+ calcFn(val){
|
|
|
+ this.calc = val
|
|
|
+ },
|
|
|
+ getOrderInfo(item){
|
|
|
+ this.selectOrderId = Number(item.id)
|
|
|
+ this.currentJobId = Number(item.id)
|
|
|
+ this.$refs.workInfoRef.getOrderDetail(this.selectOrderId)
|
|
|
+ }
|
|
|
+ }
|
|
|
+};
|
|
|
+</script>
|
|
|
+<style lang="scss" scoped>
|
|
|
+.app-casher-area {
|
|
|
+ display: flex;
|
|
|
+ height: 100vh;
|
|
|
+ & .nav-left {
|
|
|
+ flex: 5;
|
|
|
+ background-color: rgba(72, 91, 107, 1);
|
|
|
+ }
|
|
|
+ & .work-list {
|
|
|
+ flex: 32;
|
|
|
+ }
|
|
|
+ & .work-info{
|
|
|
+ flex: 89;
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|