| | |
| | | <view v-if="!canEdit" :hidden="item.hidden||!item.id" class="box" v-for="(item,index) in itemData" |
| | | :key="index" @tap="toUrl(item)"> |
| | | <template v-if="item.corner"> |
| | | <uni-badge :text="item.cornerCount" type="error" :max-num="99" size="normal" absolute |
| | | <uni-badge :text="item.cornerCount" type="error" :max-num="99" size="normal" absolute="rightTop" |
| | | :offset="[7, 7]"> |
| | | <image :src="item.img" mode=""></image> |
| | | </uni-badge> |
| | |
| | | id: 2, |
| | | hidden: false, |
| | | }, |
| | | |
| | | |
| | | { |
| | | img: '../../static/icon/icon11.png', |
| | | text: '工序委外发出单新增', |
| | |
| | | "id": 17, |
| | | "hidden": false |
| | | }, |
| | | { |
| | | img: '../../static/icon/icon10.png', |
| | | text: '工序出站汇报单(标准)新增', |
| | | tip: '立即新增', |
| | | url: '/pages/gongxuOut/Cj_StationOutBill_Standard', |
| | | id: 2, |
| | | hidden: false, |
| | | }, |
| | | |
| | | // 质量报表 |
| | | { |
| | | img: '../../static/icon/icon0.png', |
| | | text: '线别异常状态', |
| | | tip: '线别异常状态', |
| | | url: '/pages/ZLGL/QualityReport/QC_ErrManagerLedgerReport_Source', |
| | | id: 18, |
| | | hidden: false, |
| | | }, |
| | | { |
| | | img: '../../static/icon/icon0.png', |
| | | text: '异常类型统计', |
| | | tip: '异常类型统计', |
| | | url: '/pages/ZLGL/QualityReport/QC_ErrManagerLedgerReport_Issue', |
| | | id: 19, |
| | | hidden: false, |
| | | }, |
| | | { |
| | | img: '../../static/icon/icon0.png', |
| | | text: '模具维修统计表', |
| | | tip: '模具维修统计表', |
| | | url: '/pages/ZLGL/QualityReport/Sc_MouldRepairWorkBillReport', |
| | | id: 20, |
| | | hidden: false, |
| | | }, |
| | | { |
| | | img: '../../static/icon/icon0.png', |
| | | text: '设备维修统计表', |
| | | tip: '设备维修统计表', |
| | | url: '/pages/ZLGL/QualityReport/Sb_EquipRepairWorkBillReport', |
| | | id: 21, |
| | | hidden: false, |
| | | }, |
| | | // { |
| | | // img: '../../static/icon/icon0.png', |
| | | // text: '器具保养统计表', |
| | | // tip: '器具保养统计表', |
| | | // url: '/pages/ZLGL/QualityReport/Sc_MouldMaintainBillMainReport', |
| | | // id: 22, |
| | | // hidden: false, |
| | | // }, |
| | | // { |
| | | // img: '../../static/icon/icon0.png', |
| | | // text: '设备保养统计表', |
| | | // tip: '设备保养统计表', |
| | | // url: '/pages/ZLGL/QualityReport/Sb_EquipMaintainBillReport', |
| | | // id: 23, |
| | | // hidden: false, |
| | | // }, |
| | | // { |
| | | // img: '../../static/icon/icon0.png', |
| | | // text: '设备点检统计表', |
| | | // tip: '设备点检统计表', |
| | | // url: '/pages/ZLGL/QualityReport/Sb_EquipDotCheckBillReport', |
| | | // id: 24, |
| | | // hidden: false, |
| | | // }, |
| | | ] |
| | | } |
| | | }, |
| | |
| | | this.getHiddenItem() |
| | | }, |
| | | async onShow() { |
| | | if(this.initFinished) { |
| | | if (this.initFinished) { |
| | | let MessageIdentifier = await this.getMessageIdentifierCount(this.menuListName) |
| | | if(MessageIdentifier.code == 0) { |
| | | if (MessageIdentifier.code == 0) { |
| | | CommonUtils.showTips({ |
| | | title: "温馨提示", |
| | | message: MessageIdentifier.msg |
| | | }) |
| | | |
| | | |
| | | return |
| | | } |
| | | |
| | | |
| | | this.itemData.forEach((e, index) => { |
| | | if(MessageIdentifier.data[e.text]) { |
| | | if (MessageIdentifier.data[e.text] != undefined) { |
| | | this.itemData[index]["corner"] = true |
| | | this.itemData[index]["cornerCount"] = MessageIdentifier.data[e.text] |
| | | } |
| | | }) |
| | | |
| | | |
| | | this.$forceUpdate() |
| | | } |
| | | }, |
| | | async onReady() { |
| | | let MessageIdentifier = await this.getMessageIdentifierCount(this.menuListName) |
| | | if (MessageIdentifier.code == 0) { |
| | | CommonUtils.showTips({ |
| | | title: "温馨提示", |
| | | message: MessageIdentifier.msg |
| | | }) |
| | | |
| | | return |
| | | } |
| | | |
| | | this.itemData.forEach((e, index) => { |
| | | if (MessageIdentifier.data[e.text] != undefined) { |
| | | this.itemData[index]["corner"] = true |
| | | this.itemData[index]["cornerCount"] = MessageIdentifier.data[e.text] |
| | | } |
| | | }) |
| | | |
| | | this.$forceUpdate() |
| | | }, |
| | | methods: { |
| | | async getWorkLinkList() { |
| | |
| | | moduleName: menuListName |
| | | } |
| | | }) |
| | | console.log('common module: ',res); |
| | | let { |
| | | data, |
| | | count, |
| | |
| | | acc[item['moduleName']] = item.count |
| | | return acc |
| | | }, {}) |
| | | |
| | | |
| | | return { |
| | | code: 1, |
| | | msg: Message, |
| | |
| | | } |
| | | } |
| | | } catch (err) { |
| | | |
| | | |
| | | } |
| | | }, |
| | | async getHiddenItem() { |
| | | let data = await getMenuList({ |
| | | menuName: this.menuListName |
| | | }) |
| | | |
| | | |
| | | Array.from(data).forEach((e, index) => { |
| | | if (index < this.itemData.length) { |
| | | this.itemData[e["HIndex"]]["hidden"] = !CommonUtils.stringToBoolean(e[ |
| | |
| | | this.itemData[e["HIndex"]].id = e["HEntryID"]; //id为0强制隐藏 |
| | | } |
| | | }) |
| | | |
| | | |
| | | let MessageIdentifier = await this.getMessageIdentifierCount(this.menuListName) |
| | | if (MessageIdentifier.code == 0) { |
| | | CommonUtils.showTips({ |
| | | title: "温馨提示", |
| | | message: MessageIdentifier.msg |
| | | }) |
| | | |
| | | |
| | | return |
| | | } |
| | | |
| | | |
| | | Array.from(data).forEach((e, index) => { |
| | | if (index < this.itemData.length) { |
| | | if (MessageIdentifier.data[this.itemData[e["HIndex"]].text]) { |
| | | this.itemData[e["HIndex"]]["corner"] = true, |
| | | this.itemData[e["HIndex"]]["cornerCount"] = MessageIdentifier.data[this |
| | | .itemData[e["HIndex"]].text] |
| | | this.$set(this.itemData[e["HIndex"]], "corner", true) |
| | | this.$set(this.itemData[e["HIndex"]], "cornerCount", MessageIdentifier.data[this |
| | | .itemData[e["HIndex"]].text]) |
| | | } |
| | | } |
| | | }) |