| | |
| | | <view class="search-bar"> |
| | | <view class="icon-body"> |
| | | <view class="icon-box" |
| | | @click="messagePage"> |
| | | @click="messagePage" v-if="roleType != 6"> |
| | | <u-badge :isDot="true" |
| | | type="error" |
| | | v-if="dotShow"></u-badge> |
| | | <u-icon name="chat" |
| | | <u-icon name="chat" |
| | | color="#fff" |
| | | size="50"></u-icon> |
| | | </view> |
| | |
| | | ref="driverIndexRef" |
| | | :indexdriverBillOfLoadingData="indexdriverBillOfLoadingData"></driver-index> |
| | | <load-unload ref="LoadUnloadRef" |
| | | v-if="roleType == 5"></load-unload> |
| | | v-if="roleType == 5" :indexLoadUnloadBillOfLoadingData="detailData"></load-unload> |
| | | <doorkeep-index ref="doorkeepIndexRef" |
| | | v-if="roleType == 6"></doorkeep-index> |
| | | <!-- <selectTarget v-if="roleType == 5" |
| | | ref="LoadUnloadRef"></selectTarget> --> |
| | | <qualityIndex ref="qualityIndexRef" v-if="roleType == 7"></qualityIndex> |
| | |
| | | import LoadUnload from '@/pages/loadUnload-page/loadUnload-page.vue' |
| | | import selectTarget from '@/pages/loadUnload-page/selectTarget/selectTarget.vue' |
| | | import qualityIndex from '@/pages/quality-inspection-page/qualityIndex/qualityIndex' |
| | | import doorkeepIndex from '@/pages/doorkeeper-page/doorkeeper-index/doorkeeper-index.vue'; |
| | | import { mapState, mapMutations } from 'vuex'; |
| | | import { webSocketUrl } from '@/api/request.js'; |
| | | |
| | |
| | | LoadUnload, |
| | | selectTarget, |
| | | qualityIndex, //化验 |
| | | doorkeepIndex, |
| | | selectTarget |
| | | }, |
| | | computed: { |
| | | ...mapState(['globalweighHouseCode', 'globalweigh', 'globalisconnect', 'globalSocket', 'websocketData', |
| | |
| | | }, |
| | | //首页下拉刷新 |
| | | onPullDownRefresh() { |
| | | uni.showLoading({ title: '加载中...' }); |
| | | if(this.roleType!==6){ |
| | | uni.showLoading({ title: '加载中...' }); |
| | | }else{ |
| | | this.$refs.doorkeepIndexRef.TaskCoalList() |
| | | } |
| | | // 获取历史提煤单 |
| | | if (this.roleType == 1 || this.roleType == 2) { |
| | | this.$reqGet('getJhOrderPlanDataPage', { current: 1, size: 10 }).then(res => { |
| | |
| | | uni.stopPullDownRefresh(); |
| | | } |
| | | }); |
| | | }else if(this.roleType == 5){ |
| | | //装卸员 |
| | | this.getDetailData(); |
| | | } |
| | | }, |
| | | // getWarehouseListFun() { |
| | | // this.$reqGet('getWarehouseList').then(res => { |
| | | // uni.hideLoading() |
| | | // if (res.code === 0) { |
| | | // if(res.data.length){ |
| | | // this.getDetailData(); |
| | | |
| | | // } |
| | | // } else { |
| | | // this.$u.toast('加载失败') |
| | | // } |
| | | // }) |
| | | // }, |
| | | onHide() { |
| | | console.log('页面隐藏') |
| | | }, |
| | |
| | | indexHuoDaiOrderPlanData: [], |
| | | indexHistoryCoalData: [], |
| | | count:0, |
| | | detailData:[], |
| | | indexdriverBillOfLoadingData: {}, |
| | | messagePushShow: false, |
| | | messageList: { |
| | |
| | | } |
| | | }); |
| | | break; |
| | | case 6: |
| | | console.log('doorkeepIndexRef'); |
| | | this.$nextTick(() => { |
| | | this.$refs.doorkeepIndexRef.init(); |
| | | }); |
| | | break; |
| | | default: |
| | | break; |
| | | } |
| | |
| | | this.dotShow = filtermessage.length > 0; |
| | | } |
| | | }); |
| | | } |
| | | }, |
| | | getDetailData(){ |
| | | this.$reqGet('getTaskCoalListByBunkerId', { bunkerId:uni.getStorageSync('bunkerId')}).then(res => { |
| | | if (res.code === 0) { |
| | | this.detailData = res.data.map(item=>{ |
| | | item.tmTaskCoalList.map(el=>{ |
| | | el.flag = el.isPretendDischar ? false : true |
| | | return el |
| | | }) |
| | | return item; |
| | | }); |
| | | this.$u.toast('加载成功'); |
| | | uni.stopPullDownRefresh(); |
| | | uni.hideLoading(); |
| | | } |
| | | }) |
| | | |
| | | }, |
| | | } |
| | | }; |
| | | </script> |