update 国内标准
This commit is contained in:
@@ -40,12 +40,82 @@
|
||||
</template>
|
||||
</a-tree>
|
||||
</div>
|
||||
<div class="page-right-box"></div>
|
||||
<div class="page-right-box">
|
||||
<div class="table-page-search-wrapper">
|
||||
<search ref="searchRef" :flag="flag" :url="url" @search="searchQuery" @reset="searchReset" />
|
||||
</div>
|
||||
|
||||
<div class="table-operator">
|
||||
<!-- 新增-->
|
||||
<a-button icon="plus" type="primary" @click="handleAdd">{{ $t('newlyAdded') }}</a-button>
|
||||
<!-- 导入-->
|
||||
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
|
||||
<a-button type="primary" icon="download" ghost>{{ $t('import') }}</a-button>
|
||||
</a-upload>
|
||||
<!-- 导出-->
|
||||
<a-button icon="upload" type="primary" ghost @click="handleExportXls($t('standardRegulationLibrary.domesticStandard.treeSearchPlaceholder'))">
|
||||
{{ $t('export') }}
|
||||
</a-button>
|
||||
<!-- 带文件导出-->
|
||||
<a-button icon="upload" type="primary" ghost>{{ $t('exportWithFile') }}</a-button>
|
||||
<!-- 模板下载-->
|
||||
<a-button type="primary" icon="download" ghost @click="downTemplate('standardRegulationLibrary.domesticStandard.templateName')">
|
||||
{{ $t('templateDownload') }}
|
||||
</a-button>
|
||||
<!-- 批量删除-->
|
||||
<a-button type="primary" icon="delete" ghost @click="batchDel">{{ $t('batchDelete') }}</a-button>
|
||||
<!-- 配置标准-->
|
||||
<a-button type="primary" icon="setting" ghost>{{ $t('standardRegulationLibrary.configStandard') }}</a-button>
|
||||
<!-- 移出标准-->
|
||||
<a-button type="primary" icon="minus-circle" ghost>{{ $t('standardRegulationLibrary.removeStandard') }}</a-button>
|
||||
</div>
|
||||
<div>
|
||||
<j-table
|
||||
v-if="columns && columns.length > 0"
|
||||
:columns="columns"
|
||||
:dataSource="dataSource"
|
||||
:can-drag="true"
|
||||
rowKey="id"
|
||||
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
|
||||
:pagination="ipagination"
|
||||
:scroll="{x: '100%'}"
|
||||
@change="tableOnChange">
|
||||
|
||||
<template v-slot:operation="{text, record}">
|
||||
<a>{{$t('standardRegulationLibrary.domesticStandard.collection')}}</a>
|
||||
<a-divider type="vertical" />
|
||||
<a-dropdown>
|
||||
<a-icon type="more" class="operate-icon-btn" />
|
||||
<a-menu slot="overlay">
|
||||
<a-menu-item v-for="(operation, index) in operationList.slice(operateMaxNum)" :key="index">
|
||||
<a @click="operationClick(operation,record)">
|
||||
<span v-if="operation.text === $t('docLibrary.cancelCollection')" class="text">
|
||||
{{ !record.collectFlag || record.collectFlag === '0' ? $t('docLibrary.collection') : $t('docLibrary.cancelCollection')
|
||||
}}
|
||||
</span>
|
||||
<span v-else-if="operation.text === $t('docLibrary.cancelSubscribe')" class="text">
|
||||
{{ !record.subscribeFlag || record.subscribeFlag === '0' ? $t('docLibrary.subscribe') : $t('docLibrary.cancelSubscribe')
|
||||
}}
|
||||
</span>
|
||||
<span v-else class="text">
|
||||
{{ operation.text }}
|
||||
</span>
|
||||
</a>
|
||||
</a-menu-item>
|
||||
</a-menu>
|
||||
</a-dropdown>
|
||||
</template>
|
||||
</j-table>
|
||||
</div>
|
||||
</div>
|
||||
</a-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import '@assets/less/common.less'
|
||||
import { ConfigurableTableMixin } from '@/mixins/ConfigurableTableMixin'
|
||||
import Search from '@comp/customField/Search.vue'
|
||||
import JTable from '@comp/jero/JTable.vue'
|
||||
|
||||
const apiTreeData = [
|
||||
{
|
||||
@@ -72,11 +142,45 @@ const apiTreeData = [
|
||||
|
||||
export default {
|
||||
name: 'DomesticStandardList',
|
||||
components: { Search, JTable },
|
||||
mixins: [ConfigurableTableMixin],
|
||||
data () {
|
||||
return {
|
||||
treeInput: null, // 树查询绑定值
|
||||
treeData: [],
|
||||
mouseInNodeKey: null // 鼠标悬浮的节点key值
|
||||
mouseInNodeKey: null, // 鼠标悬浮的节点key值
|
||||
showAction: true,
|
||||
operationList: [
|
||||
// 收藏
|
||||
{
|
||||
text: this.$t('standardRegulationLibrary.domesticStandard.cancelCollection'),
|
||||
clickEvent: 'collection',
|
||||
has: ''
|
||||
},
|
||||
{
|
||||
text: this.$t('edit'),
|
||||
clickEvent: 'handleEdit',
|
||||
has: ''
|
||||
},
|
||||
{
|
||||
text: this.$t('share'),
|
||||
clickEvent: 'handleShare',
|
||||
has: ''
|
||||
},
|
||||
{
|
||||
text: this.$t('delete'),
|
||||
clickEvent: 'handleDelete',
|
||||
has: ''
|
||||
}
|
||||
],
|
||||
url: {
|
||||
tableHeader: '/laws/standard/domestic/getCommonHeader',
|
||||
getSearchList: '/laws/standard/domestic/getQueryCondition',
|
||||
list: '/laws/standard/domestic/getCommonPage',
|
||||
delete: '/laws/standard/domestic/deleteByIdsAndModule',
|
||||
deleteBatch: '/laws/standard/domestic/deleteByIdsAndModule'
|
||||
},
|
||||
dataSource: [{ id: '131234' }]
|
||||
}
|
||||
},
|
||||
created () {
|
||||
|
||||
+55
@@ -0,0 +1,55 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:title="title"
|
||||
:width="width"
|
||||
placement="right"
|
||||
:closable="true"
|
||||
@close="handleCancel"
|
||||
:visible="visible"
|
||||
:maskClosable="false"
|
||||
style="height: 100%;overflow: auto;"
|
||||
>
|
||||
<a-spin :spinning="confirmLoading" style="width: 100%;height:100%">
|
||||
<div class="drawer-container">
|
||||
|
||||
</div>
|
||||
<div class="drawer-footer">
|
||||
<a-button @click="handleOk" type="primary" style="margin-bottom: 0;">
|
||||
{{ $t('preservation') }}
|
||||
</a-button>
|
||||
<a-button @click="handleCancel" style="margin-bottom: 0;">{{ $t('close') }}</a-button>
|
||||
</div>
|
||||
</a-spin>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'DomesticStandardModal',
|
||||
data () {
|
||||
return {
|
||||
visible: false,
|
||||
title: '',
|
||||
width: 800,
|
||||
// 存储表单的数据
|
||||
form: {},
|
||||
confirmLoading: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
add () {
|
||||
this.edit({})
|
||||
},
|
||||
edit (record) {
|
||||
this.visible = true
|
||||
},
|
||||
close () {
|
||||
this.visible = false
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
Reference in New Issue
Block a user