From d361662e3f16e6abf808f9e6096fe58a2c9def67 Mon Sep 17 00:00:00 2001 From: baoyu <102349094+Bytq@users.noreply.github.com> Date: Wed, 27 Mar 2024 18:40:55 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=87=E5=87=86/=E8=AF=91=E6=96=87=E8=8E=B7?= =?UTF-8?q?=E5=8F=96=E7=94=B3=E8=AF=B7=E7=AE=A1=E7=90=86=20=E4=B8=BB?= =?UTF-8?q?=E9=A1=B5=20=E6=A0=87=E5=87=86/=E8=AF=91=E6=96=87=E8=8E=B7?= =?UTF-8?q?=E5=8F=96=E7=94=B3=E8=AF=B7=E7=AE=A1=E7=90=86=20=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E5=AF=BC=E5=87=BA=20=E6=96=87=E4=BB=B6=E5=90=8D?= =?UTF-8?q?=E7=A1=AE=E8=AE=A4=E5=AF=B9=E8=AF=9D=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/exportDialog.vue | 61 ++++++ .../index.vue | 190 ++++++++++++------ 2 files changed, 186 insertions(+), 65 deletions(-) create mode 100644 src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/components/exportDialog.vue diff --git a/src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/components/exportDialog.vue b/src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/components/exportDialog.vue new file mode 100644 index 000000000..2de2c53e0 --- /dev/null +++ b/src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/components/exportDialog.vue @@ -0,0 +1,61 @@ + + + + + diff --git a/src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/index.vue b/src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/index.vue index be67b8860..284249038 100644 --- a/src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/index.vue +++ b/src/pages/regulatoryRepository/standardTranslationAcquisitionRequest/index.vue @@ -2,28 +2,40 @@
- + - + - + - + - + + + + - + 查询 @@ -34,11 +46,11 @@
- 批量驳回 - 批量通过 + 批量驳回 + 批量通过
- 标准/译文获取申请 + 标准/译文获取申请 列表导出
@@ -50,9 +62,10 @@ row-key="id" border :loading="tableLoading" - :data="tableData" + :data="StandardApplyForEO" :header-cell-style="{background: '#e8e8e8', color: '#333333', fontSize: '16px', fontWeight: 'bold', height: '48px'}" - @selection-change="handleSelectionChange"> + @selection-change="handleSelectionChange" + > @@ -76,55 +89,55 @@ label="标准编号" width="150" align="center" - prop="aa" + prop="standNum" /> @@ -132,6 +145,7 @@ +
@@ -139,68 +153,112 @@ import standardsAndTranslationModal from './components/standardTranslationAcquisitionRequestModal'; import addModal from './components/addModal'; import detailModal from './components/detailModal'; +import exportDialog from './components/exportDialog'; + export default { name: 'StandardTranslationAcquisitionRequest', components: { standardsAndTranslationModal, addModal, - detailModal + detailModal, + exportDialog }, data () { return { tableLoading: false, total: 0, - searchForm: { + StandardApplyForEOPage: { page: 1, pageSize: this.$store.getters.userInfo.configContent, }, - tableData: [ { aa: '123' } ], - selectedList: [] + StandardApplyForEO: [], + selectedList: [], + url: { + getList: '/lawss/standardApplyFor/queryByPage', + updateState: '/lawss/standardApplyFor/batchUpdateStatus' + } } }, mounted () { if (this.$route.query && this.$route.query.tag === 'fromSearchCenter') { - this.standardsAndTranslationRequest() + this.standardsAndTranslationRequestShowModal() this.$router.replace({ query: { ...this.$route.query, tag: undefined } }) } + this.getList() }, methods: { searchData () { + this.page = 1 this.getList() }, clearSerach () { - this.searchForm = {} - }, - batchPass () { - if (this.selectedList.length === 0) { - this.$message({ - message: '请选择至少一条数据', - type: 'warning', - offset: 20 - }) + this.StandardApplyForEOPage = { + page: 1, + pageSize: this.$store.getters.userInfo.configContent } - }, - batchOverrule () { - if (this.selectedList.length === 0) { - this.$message({ - message: '请选择至少一条数据', - type: 'warning', - offset: 20 - }) - } - }, - exportList () { + this.getList() }, getList () { + this.tableLoading = true + this.$http.get(this.url.getList, { + ...this.StandardApplyForEOPage + }, { + _this: this + }, res => { + if (res.ok) { + this.StandardApplyForEO = res.data.list + this.total = res.data.total + }else { + this.StandardApplyForEO = [] + this.total = 0 + } + this.tableLoading = false + }) + }, + + // 需要调整 + batchPass (id) { + if (id.length === 0) { + this.$message({ + message: '请选择至少一条数据', + type: 'warning', + offset: 20 + }) + return + } + const ids = id.join(',') + this.$http.postData(this.url.updateState, { status: 'pass', ids }, { _this: this }, res => { + if(res.ok) { + this.$message.success('操作成功') + } + }) + }, + batchOverrule (id) { + if (id.length === 0) { + this.$message({ + message: '请选择至少一条数据', + type: 'warning', + offset: 20 + }) + return + } + const ids = id.join(',') + this.$http.postData(this.url.updateState, { status: 'refuse', ids }, { _this: this }, res => { + if(res.ok) { + this.$message.success('操作成功') + } + }) + }, + + exportName(name){ + }, + exportList () { + this.$refs.exportDialogRef.openModel() }, toView (id) { this.$refs.detailModalRef.showModal(id) }, - pass (id) { - }, - overrule (id) { - }, - standardsAndTranslationRequest () { + standardsAndTranslationRequestShowModal () { this.$refs.standardsAndTranslationModalRef.showModal() }, pageChange (page) { @@ -211,10 +269,12 @@ export default { this.questionSerach.pageSize = pageSize this.getList() }, - formatClassification () { - }, handleSelectionChange (value) { - this.selectedList = value + const ids = [] + value.forEach(item => { + ids.push(item.id) + }) + this.selectedList = [ ...ids ] } }, } @@ -233,7 +293,7 @@ export default { display: flex; flex-direction: column; - .drag-table{ + .drag-table { flex-grow: 1; } @@ -245,15 +305,15 @@ export default { } } - .table-operate-btn{ + .table-operate-btn { display: inline-block; cursor: pointer; color: #409EFF; margin: 0 5px; } - .stand-date-range-picker{ - /deep/ .el-range-separator{ + .stand-date-range-picker { + /deep/ .el-range-separator { width: auto; } }