From be26d6e55a9b04495ea171204b1647a6a7f21bfe Mon Sep 17 00:00:00 2001 From: wanggongfeng <1305282856@qq.com> Date: Mon, 13 Apr 2020 10:51:37 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A4=BA=E8=8C=83=E7=BD=91=E6=A0=BC=E5=90=8E?= =?UTF-8?q?=E5=8F=B0=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/workRecord/monthexcellentcase.vue | 4 +- .../workRecord/monthexcellentcaseDetail.vue | 9 +- .../modules/workRecord/monthexcellentgrid.vue | 106 +++++- .../workRecord/monthexcellentgridDetail.vue | 325 ++++++++++++++++++ .../workRecord/monthexcellentgridroute.vue | 29 ++ .../modules/workRecord/monthrecordinfo.vue | 11 +- .../workRecord/monthrecordinfoDetail.vue | 9 +- .../workRecord/monthrecordinforoute.vue | 4 +- 8 files changed, 480 insertions(+), 17 deletions(-) create mode 100644 src/views/modules/workRecord/monthexcellentgridDetail.vue create mode 100644 src/views/modules/workRecord/monthexcellentgridroute.vue diff --git a/src/views/modules/workRecord/monthexcellentcase.vue b/src/views/modules/workRecord/monthexcellentcase.vue index 4224b770..aac546fe 100644 --- a/src/views/modules/workRecord/monthexcellentcase.vue +++ b/src/views/modules/workRecord/monthexcellentcase.vue @@ -63,8 +63,8 @@ diff --git a/src/views/modules/workRecord/monthexcellentcaseDetail.vue b/src/views/modules/workRecord/monthexcellentcaseDetail.vue index f6fa1430..9859c510 100644 --- a/src/views/modules/workRecord/monthexcellentcaseDetail.vue +++ b/src/views/modules/workRecord/monthexcellentcaseDetail.vue @@ -118,8 +118,13 @@ export default { MapSelect }, mounted () { - this.pageDisabled = this.$route.query.disabled - this.hideUpload = this.$route.query.disabled + if (this.$route.query.disabled === '0') { + this.pageDisabled = false + this.hideUpload = false + } else { + this.pageDisabled = true + this.hideUpload = true + } if (this.$route.query.id !== '' && this.$route.query.id != null) { this.dataForm.id = this.$route.query.id this.getInfo() diff --git a/src/views/modules/workRecord/monthexcellentgrid.vue b/src/views/modules/workRecord/monthexcellentgrid.vue index ad29705a..11f51143 100644 --- a/src/views/modules/workRecord/monthexcellentgrid.vue +++ b/src/views/modules/workRecord/monthexcellentgrid.vue @@ -2,11 +2,48 @@
+
+ + + + + + +
+ + + + + + + + + + + + - + {{ $t('query') }} - {{ $t('query') }} + {{ $t('export') }} {{ $t('add') }} @@ -58,18 +95,73 @@ export default { data () { return { mixinViewModuleOptions: { - getDataListURL: '/news/monthexcellentgrid/page', + getDataListURL: '/workRecord/monthexcellentgrid/page', getDataListIsPage: true, - deleteURL: '/news/monthexcellentgrid', - deleteIsBatch: true + deleteURL: '/workRecord/monthexcellentgrid', + deleteIsBatch: true, + exportURL: '/workRecord/monthexcellentgrid/export' }, dataForm: { - id: '' - } + id: '', + content: '', + nickName: '' + }, + pickerBeginDateBefore: { + disabledDate: (time) => { + let beginDateVal = this.dataForm.endTime + if (beginDateVal) { + return time.getTime() > new Date(beginDateVal + ' 00:00:00').getTime() + } + } + }, + pickerBeginDateAfter: { + disabledDate: (time) => { + let EndDateVal = this.dataForm.startTime + if (EndDateVal) { + return time.getTime() < new Date(EndDateVal + ' 00:00:00').getTime() + } + } + }, + ids: [], + options: [] } }, components: { AddOrUpdate + }, + watch: { + ids: function (val) { + if (val.length === 0) { + this.dataForm.deptId = '' + } else { + this.dataForm.deptId = this.ids[val.length - 1] + } + } + }, + created: function () { + this.getDataList() + this.getOptions() + }, + methods: { + addHandle (id, disabled) { + this.$parent.selectComponent = 'MonthexcellentgridDetail' + this.$router.push({ path: '/workRecord-Monthexcellentgridroute', query: { id: id, disabled: disabled } }) + }, + getDataListOverWrite () { + this.page = 1 + this.getDataList() + }, + getOptions () { + this.$http + .get(`/sys/user/deptOptions/getByLoginUser`) + .then(({ data: res }) => { + if (res.code !== 0) { + return this.$message.error(res.msg) + } + this.options = res.data.options + }) + .catch(() => {}) + } } } diff --git a/src/views/modules/workRecord/monthexcellentgridDetail.vue b/src/views/modules/workRecord/monthexcellentgridDetail.vue new file mode 100644 index 00000000..eb83806b --- /dev/null +++ b/src/views/modules/workRecord/monthexcellentgridDetail.vue @@ -0,0 +1,325 @@ + + + + diff --git a/src/views/modules/workRecord/monthexcellentgridroute.vue b/src/views/modules/workRecord/monthexcellentgridroute.vue new file mode 100644 index 00000000..a3017ff3 --- /dev/null +++ b/src/views/modules/workRecord/monthexcellentgridroute.vue @@ -0,0 +1,29 @@ + + + + diff --git a/src/views/modules/workRecord/monthrecordinfo.vue b/src/views/modules/workRecord/monthrecordinfo.vue index ac6e4c1e..ccd996a6 100644 --- a/src/views/modules/workRecord/monthrecordinfo.vue +++ b/src/views/modules/workRecord/monthrecordinfo.vue @@ -73,9 +73,10 @@ @@ -159,6 +160,10 @@ export default { this.$parent.selectComponent = 'MonthexcellentcaseDetail' this.$router.push({ path: '/workRecord-Monthrecordinforoute', query: { id: '', disabled: disabled, infoId: infoId } }) }, + addGridHandle (infoId, disabled) { + this.$parent.selectComponent = 'MonthexcellentgridDetail' + this.$router.push({ path: '/workRecord-Monthrecordinforoute', query: { id: '', disabled: disabled, infoId: infoId } }) + }, getOptions () { this.$http .get(`/sys/user/deptOptions/getByLoginUser`) diff --git a/src/views/modules/workRecord/monthrecordinfoDetail.vue b/src/views/modules/workRecord/monthrecordinfoDetail.vue index c8f13a41..5b0593bd 100644 --- a/src/views/modules/workRecord/monthrecordinfoDetail.vue +++ b/src/views/modules/workRecord/monthrecordinfoDetail.vue @@ -118,8 +118,13 @@ export default { MapSelect }, mounted () { - this.pageDisabled = this.$route.query.disabled - this.hideUpload = this.$route.query.disabled + if (this.$route.query.disabled === '0') { + this.pageDisabled = false + this.hideUpload = false + } else { + this.pageDisabled = true + this.hideUpload = true + } if (this.$route.query.id !== '' && this.$route.query.id != null) { this.dataForm.id = this.$route.query.id this.getInfo() diff --git a/src/views/modules/workRecord/monthrecordinforoute.vue b/src/views/modules/workRecord/monthrecordinforoute.vue index bf83b2bb..efb8a4fe 100644 --- a/src/views/modules/workRecord/monthrecordinforoute.vue +++ b/src/views/modules/workRecord/monthrecordinforoute.vue @@ -7,6 +7,7 @@ import Monthrecordinfo from './monthrecordinfo' import MonthrecordinfoDetail from './monthrecordinfoDetail' import MonthexcellentcaseDetail from './monthexcellentcaseDetail' +import MonthexcellentgridDetail from './monthexcellentgridDetail' export default { data () { return { @@ -16,7 +17,8 @@ export default { components: { Monthrecordinfo, MonthrecordinfoDetail, - MonthexcellentcaseDetail + MonthexcellentcaseDetail, + MonthexcellentgridDetail }, methods: { init () {