diff --git a/src/api/system/notice.js b/src/api/system/notice.js index 42ba53a1..308fd071 100644 --- a/src/api/system/notice.js +++ b/src/api/system/notice.js @@ -20,6 +20,26 @@ export function getTopNoticeListByUserId(query) { }) } + +export function getPublicNoticeList(query) { + return request({ + url: '/system/notice/getPublicNoticeList', + method: 'get', + params: query + }) +} + + + +// 查询用户公告列表 +export function addReadTimes(data) { + return request({ + url: '/system/notice/addReadTimes', + method: 'post', + data: data + }) +} + // 查询公告详细 export function getNotice(noticeId) { return request({ diff --git a/src/layout/components/TopNotice/index.vue b/src/layout/components/TopNotice/index.vue index def91c9c..9ef3053e 100644 --- a/src/layout/components/TopNotice/index.vue +++ b/src/layout/components/TopNotice/index.vue @@ -24,17 +24,24 @@ -
-
{{ item.noticeTitle }}
-
{{ item.createTime }}
+
+
{{ item.noticeTitle }}
+
{{ item.noticeTitle }}
+
+
{{ item.createTime }}
+
已读 + 未读 +
+ +
- + @@ -69,7 +76,7 @@ import {Notification} from "element-ui"; import Speech from 'speak-tts' -import {getTopNoticeListByUserId} from "@/api/system/notice"; +import {getTopNoticeListByUserId,addReadTimes,getPublicNoticeList} from "@/api/system/notice"; export default { name: 'TopNotice', data() { @@ -88,7 +95,7 @@ export default { computed: { // 所有消息数量 allNum() { - return this.noticeList.length; + return this.alertList.length; }, newNotice(){ return 0; @@ -98,7 +105,7 @@ export default { window.addEventListener("click", this.setCanPlayTone); this.initXDNoticSdk(); this.speechInit(); - this.getNoticeUserList(); + this.initUserNotice(); }, methods: { @@ -144,12 +151,17 @@ export default { // this.printerStatusMessage="通知组件已断开!"; }, onMessage(evt){ + + let that=this; console.log("===>onMessage==>",evt) - if(evt==null||evt==undefined) - return; + if(evt==null||evt==undefined){ + return; + } + this.playTone(); - var messageBody = evt; + var messageBody = evt.title; + let noticeId= evt.noticeId; this.$notify.closeAll(); this.speech.speak({ text: messageBody }).then(() => { @@ -165,14 +177,41 @@ export default { duration: 0, onClick: function () { // 点击跳转的页面 + // this.addReadTimes + that.$notify.closeAll(); + + this.setAddReadTimes(noticeId); + }, }); }, - getNoticeUserList() { - getTopNoticeListByUserId().then(response => { - this.noticeList=response.rows; - }) + setAddReadTimes(noticeId){ + + addReadTimes({"noticeId":noticeId}).then(response => { + console.log("读取成功"); + this.initUserNotice(); + }); + }, + initUserNotice() { + // 获取通知信息 + getTopNoticeListByUserId().then(response => { + this.alertList=response.rows; + }); + + // 获取公告信息 + getPublicNoticeList().then(response => { + this.noticeList=response.rows; + }); + + }, + + showNotice(item){ + console.log("==showNotice===>xxx===>",item); + this.setAddReadTimes(item.noticeId); + }, + + // notificationInfo(messageBody) { // // this.speech.speak({ text: messageBody }).then(() => { // // console.log("读取成功"); @@ -339,10 +378,16 @@ export default { } .notice-title{ - color:#025cd9; - font-weight: 500; + color:#000; + font-weight: 600; } + .notice-has-read-title{ + color:gray; + font-weight: 400; + } + + .ele-text-secondary { margin-top: 5px; font-size: 13px; diff --git a/src/views/emis/emisSettleInvoiceRecord/emisSettleInvoiceRecordForm.vue b/src/views/emis/emisSettleInvoiceRecord/emisSettleInvoiceRecordForm.vue index 0187b3a1..fc945ada 100644 --- a/src/views/emis/emisSettleInvoiceRecord/emisSettleInvoiceRecordForm.vue +++ b/src/views/emis/emisSettleInvoiceRecord/emisSettleInvoiceRecordForm.vue @@ -254,8 +254,8 @@
- 确 定 - 保存并继续开票 + 确 定 + 保存并继续开票 取 消
@@ -290,6 +290,9 @@ export default { loading: false, lastestLoading: false, + + blCanotSubmit:false, + lastestInvoiceRecordList:[], lastestTotal:0, latestQueryParams:{ @@ -676,11 +679,13 @@ export default { // this.$emit("on-changed"); // }); } else { + this.blCanotSubmit=true; addEmisSettleInvoiceRecord(this.form).then(response => { this.$modal.msgSuccess("新增成功"); - let empName=this.$store.getters.empName; - let message=empName+" 提交了开票申请,请及时开票!"; - this.noticeToEmpUser("padmin,88888042,88888047,88888034,88888059,88888083",message); + // let empName=this.$store.getters.empName; + // let message=empName+" 提交了开票申请,请及时开票!"; + // this.noticeToEmpUser("padmin,88888042,88888047,88888034,88888059,88888083",message); + this.blCanotSubmit=false; if(isContinue){ this.form.openBillScope='1'; diff --git a/src/views/emis/emisWaybillAjustApply/WaybillAjustCenterConfirm.vue b/src/views/emis/emisWaybillAjustApply/WaybillAjustCenterConfirm.vue index 71f2ee71..7f6e5d45 100644 --- a/src/views/emis/emisWaybillAjustApply/WaybillAjustCenterConfirm.vue +++ b/src/views/emis/emisWaybillAjustApply/WaybillAjustCenterConfirm.vue @@ -473,12 +473,152 @@ export default { if (j === 'index') { return ++index } + + if (j === 'processStatus') { + + let blDestConfirmedStr=''; + let blCenterConfirmedStr=''; + + if(v['blDestConfirmed'] == 0){ + blDestConfirmedStr='未确认'; + } + else if(v['blDestConfirmed'] == 1){ + blDestConfirmedStr='网点确认'; + } + else if(v['blCenterConfirmed'] == 2){ + blDestConfirmedStr='网点驳回'; + } + + if(v['blCenterConfirmed'] == 0){ + blCenterConfirmedStr='未审核'; + } + else if(v['blCenterConfirmed'] == 1){ + blCenterConfirmedStr='中心审核通过'; + } + else if(v['blCenterConfirmed'] == 2){ + blCenterConfirmedStr='中心驳回'; + } + + return blDestConfirmedStr+" " + blCenterConfirmedStr; + } + if (j === 'kjlx') { - return v['sendSiteName']+'--'+v['dispatchUnderlingSiteName']; + return v['waybillDetail']['sendSiteName']+'--'+v['waybillDetail']['dispatchUnderlingSiteName']; } if (j === 'fjr') { return v['sendName']+'--'+v['receiveName']; } + + if (j === 'waybillDetail.sendSiteName') { + return v['waybillDetail']['sendSiteName']; + } + + + if (j === 'waybillDetail.sendDate') { + return v['waybillDetail']['sendDate']; + } + + if (j === 'waybillDetail.sendCompany') { + return v['waybillDetail']['sendCompany']; + } + + if (j === 'waybillDetail.transLineTypeName') { + return v['waybillDetail']['transLineTypeName']; + } + + if (j === 'waybillDetail.productTypeName') { + return v['waybillDetail']['productTypeName']; + } + + + if (j === 'waybillDetail.sendName') { + return v['waybillDetail']['sendName']; + } + + if (j === 'waybillDetail.parcelQty') { + return v['waybillDetail']['parcelQty']; + } + + if (j === 'waybillDetail.billWeight') { + return v['waybillDetail']['billWeight']; + } + + if (j === 'waybillDetail.volumeWeight') { + return v['waybillDetail']['volumeWeight']; + } + + if (j === 'waybillDetail.totalVolume') { + return v['waybillDetail']['totalVolume']; + } + + if (j === 'waybillDetail.settlementWeight') { + return v['waybillDetail']['settlementWeight']; + } + + if (j === 'waybillDetail.freight') { + return v['waybillDetail']['freight']; + } + + if (j === 'waybillDetail.realFee') { + return v['waybillDetail']['realFee']; + } + + if (j === 'waybillDetail.remark') { + return v['waybillDetail']['remark']; + } + + if (j === 'waybillDetail.feeRemark') { + return v['waybillDetail']['feeRemark']; + } + + if (j === 'waybillDetail.salesmen') { + return v['waybillDetail']['salesmen']; + } + + if (j === 'waybillDetail.payee') { + return v['waybillDetail']['payee']; + } + + if (j === 'waybillDetail.payee') { + return v['waybillDetail']['payee']; + } + + if (j === 'waybillDetail.problemTypeName') { + return v['waybillDetail']['problemTypeName']; + } + + if (j === 'waybillDetail.problemCause') { + return v['waybillDetail']['problemCause']; + } + + if (j === 'waybillDetail.sendDate') { + return v['waybillDetail']['sendDate']; + } + + if (j === 'waybillDetail.registerSiteName') { + return v['waybillDetail']['registerSiteName']; + } + + if (j === 'waybillDetail.registerManName') { + return v['waybillDetail']['registerManName']; + } + + if (j === 'waybillDetail.dispatchUnderlingSiteName') { + return v['waybillDetail']['dispatchUnderlingSiteName']; + } + + if (j === 'waybillDetail.parcelQty') { + return v['waybillDetail']['parcelQty']; + } + + if (j === 'waybillDetail.destinationName') { + return v['waybillDetail']['destinationName']; + } + + if (j === 'waybillDetail.sendMobile') { + return ""; + } + if (j === 'custName') { let paymentType=v['paymentType']; if(paymentType==2 || paymentType==4 || paymentType==5 ){ @@ -536,8 +676,8 @@ export default { return '未签收'; } } - if (j === 'paymentType') { - return this.selectDictLabel(this.dict.type.emis_payment_type,v[j]); + if (j === 'waybillDetail.paymentType') { + return this.selectDictLabel(this.dict.type.emis_payment_type,v['waybillDetail']['paymentType']); } return v[j] })) diff --git a/src/views/emis/emisWaybillAjustApply/emisWaybillAjustApplyForm.vue b/src/views/emis/emisWaybillAjustApply/emisWaybillAjustApplyForm.vue index 2c0efe09..5651cb3b 100644 --- a/src/views/emis/emisWaybillAjustApply/emisWaybillAjustApplyForm.vue +++ b/src/views/emis/emisWaybillAjustApply/emisWaybillAjustApplyForm.vue @@ -254,9 +254,9 @@ export default { addEmisWaybillAjustApply(this.form).then(response => { this.$modal.msgSuccess("申请成功"); - let empName=this.$store.getters.empName; - let message=empName+" 提交了费用审核,请及时审批,单号:"+this.form.billCode; - this.noticeToEmpUser("padmin,88888042,88888047,88888034,88888059,88888083",message); + // let empName=this.$store.getters.empName; + // let message=empName+" 提交了费用审核,请及时审批,单号:"+this.form.billCode; + // this.noticeToEmpUser("padmin,88888042,88888047,88888034,88888059,88888083",message); this.$emit("on-changed"); });