拆分详情合并按钮
This commit is contained in:
@@ -39,32 +39,6 @@
|
||||
<div class="split-detail-right-wraper">
|
||||
<div class="split-detail-search-header">
|
||||
<search :flag="'4'" :url="url"/>
|
||||
<!-- <a-form layout="inline" @keyup.enter.native="searchQuery(queryParams)">-->
|
||||
<!-- <a-form-model-->
|
||||
<!-- class="split-detail-content"-->
|
||||
<!-- :model="queryParams"-->
|
||||
<!-- ref="queryForm"-->
|
||||
<!-- >-->
|
||||
<!-- <a-row :gutter="24">-->
|
||||
<!-- <a-col :md="6" :sm="8">-->
|
||||
<!-- <a-form-model-item :label="$t('clauseName')" class="split-item">-->
|
||||
<!-- <j-input :placeholder="$t('pleaseEnter') + $t('clauseName')" v-model="queryParams.serialNumber"></j-input>-->
|
||||
<!-- </a-form-model-item>-->
|
||||
<!-- </a-col>-->
|
||||
<!-- <a-col :md="6" :sm="8">-->
|
||||
<!-- <a-form-model-item :label="$t('clauseContent')" class="split-item">-->
|
||||
<!-- <j-input :placeholder="$t('pleaseEnter')+$t('clauseContent')" v-model="queryParams.title"></j-input>-->
|
||||
<!-- </a-form-model-item>-->
|
||||
<!-- </a-col>-->
|
||||
<!-- <a-col :md="6" :sm="6">-->
|
||||
<!-- <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">-->
|
||||
<!-- <a-button type="primary" @click="searchQuery" icon="search">{{$t('query')}}</a-button>-->
|
||||
<!-- <a-button @click="searchReset" icon="reload" style="margin-left: 8px">{{ $t('reset') }}</a-button>-->
|
||||
<!-- </span>-->
|
||||
<!-- </a-col>-->
|
||||
<!-- </a-row>-->
|
||||
<!-- </a-form-model>-->
|
||||
<!-- </a-form>-->
|
||||
</div>
|
||||
<div class="table-operator">
|
||||
<div class="operator-text" @click="handleCopyManage">
|
||||
@@ -105,7 +79,7 @@
|
||||
:url="url"
|
||||
:flag="'4'"
|
||||
:OperationList="OperationList"
|
||||
:infoId="infoId"
|
||||
:infoId="$route.query.infoId"
|
||||
:menuId="menuId"
|
||||
showAction
|
||||
@onSelectChange="onSelectChange"
|
||||
@@ -113,27 +87,6 @@
|
||||
@editClick="editClick"
|
||||
@showContent="showContent"
|
||||
></table-data>
|
||||
<!-- <a-table :data-source="tableData" :columns="columns" rowKey="id" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :pagination="false" :loading="loading" class="tag-con-table">-->
|
||||
<!-- <template slot="clauseContent" slot-scope="text, record">-->
|
||||
<!-- <a class="content-show" href="javascript:;" :title="record.serialContent" @click="showContent">{{record.serialContent}}</a>-->
|
||||
<!-- </template>-->
|
||||
<!-- <template slot="action" slot-scope="text, record">-->
|
||||
<!-- <a class="action-edit" href="javascript:;" @click="onEdit(record)">{{$t('edit')}}</a>-->
|
||||
<!-- <a class="action-delete" href="javascript:;" @click="onCancel(record)">{{$t('delete')}}</a>-->
|
||||
<!-- </template>-->
|
||||
<!-- </a-table>-->
|
||||
<!-- <div class="page" v-if="tableData.length > 0">-->
|
||||
<!-- <a-pagination-->
|
||||
<!-- :show-total= "total => $t('total')+` ${total} `+ $t('strip')"-->
|
||||
<!-- show-quick-jumper-->
|
||||
<!-- show-size-changer-->
|
||||
<!-- :current="queryParams.pageNo"-->
|
||||
<!-- :page-size.sync="queryParams.pageSize"-->
|
||||
<!-- :total="total"-->
|
||||
<!-- @change="onChangePage"-->
|
||||
<!-- @showSizeChange="SizeChange"-->
|
||||
<!-- />-->
|
||||
<!-- </div>-->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -177,6 +130,25 @@
|
||||
</a-form-model-item>
|
||||
</a-form-model>
|
||||
</a-modal>
|
||||
<!-- 批量设置弹框-->
|
||||
<a-modal
|
||||
class="show-setting"
|
||||
:title="$t('batSetting')"
|
||||
:visible="batSetVisible"
|
||||
:confirm-loading="confirmLoading"
|
||||
@ok="modalOk"
|
||||
@cancel="batSetCancel"
|
||||
style="width: 1000px"
|
||||
>
|
||||
<split-bat-form
|
||||
ref="fileForm"
|
||||
@addFormClick="addFormClick"
|
||||
:flag="'4'"
|
||||
v-if="batSetVisible&&ids"
|
||||
:url="urlBatSet"
|
||||
:ids="ids">
|
||||
</split-bat-form>
|
||||
</a-modal>
|
||||
<split-add-form ref="splitForm" v-if="addVisible" :addVisible="addVisible" :formTitle="formTitle" :flag="'4'" :url="url" :infoId="infoId" :menuId="menuId" :itemId="itemId" :item="item" @closeVisible="closeVisible"></split-add-form>
|
||||
<upload ref="uploadSplit" @uploadSuccess="uploadSuccess"></upload>
|
||||
</div>
|
||||
@@ -189,6 +161,7 @@
|
||||
import search from '@/components/search/index'
|
||||
import TableData from '@/components/SplitDetailTable/index'
|
||||
import upload from '@/components/uploadFile/file.vue'
|
||||
import SplitBatForm from '@/components/SplitBatForm/index'
|
||||
import SplitAddForm from './SplitAddForm'
|
||||
import eventBUs from '@/common/event'
|
||||
export default {
|
||||
@@ -196,6 +169,7 @@
|
||||
components:{
|
||||
search,
|
||||
TableData,
|
||||
SplitBatForm,
|
||||
SplitAddForm,
|
||||
upload
|
||||
},
|
||||
@@ -209,49 +183,14 @@
|
||||
pageSize:10
|
||||
},
|
||||
total:0,
|
||||
tableData:[
|
||||
{
|
||||
serialNumber:'001',
|
||||
serialName:'条款001',
|
||||
serialContent:'12. 附加光反射器,可以是贴纸,具有以下规格: a) 正面左右两侧呈白色或淡黄色; b) 背面左右两侧呈红色; c) 防护板下面是白色;和 d) 高至少400(四百)毫米和宽至少100(一百)毫米; 附加光反射器,可以是贴纸,具有以下规格: a) 正面左右两侧呈白色或淡黄色; b) 背面左右两侧呈红色; c) 防护板下面是白色;和 d) 高至少400(四百)毫米和宽至少100(一百)毫米;12. 附加光反射器,可以是贴纸,具有以下规格: a) 正面左右两侧呈白色或淡黄色; b) 背面左右两侧呈红色; c) 防护板下面是白色;和 d) 高至少400(四百)毫米和宽至少100(一百)毫米; 附加光反射器,可以是贴纸,具有以下规格: a) 正面左右两侧呈白色或淡黄色; b) 背面左右两侧呈红色; c) 防护板下面是白色;和 d) 高至少400(四百)毫米和宽至少100(一百)毫米;',
|
||||
functionArea:'aaa',
|
||||
tecArea:'bbb'
|
||||
}
|
||||
],
|
||||
tableData:[],
|
||||
selectedRowKeys: [],
|
||||
expandedKeys: [],
|
||||
searchValue: '',
|
||||
autoExpandParent: true,
|
||||
dataList: [],
|
||||
contentValue:'12. 附加光反射器,可以是贴纸,具有以下规格: a) 正面左右两侧呈白色或淡黄色; b) 背面左右两侧呈红色; c) 防护板下面是白色;和 d) 高至少400(四百)毫米和宽至少100(一百)毫米; 附加光反射器,可以是贴纸,具有以下规格: a) 正面左右两侧呈白色或淡黄色; b) 背面左右两侧呈红色; c) 防护板下面是白色;和 d) 高至少400(四百)毫米和宽至少100(一百)毫米;',
|
||||
gData: [
|
||||
{
|
||||
title: '总目录',
|
||||
key: '0-0',
|
||||
children: [
|
||||
{
|
||||
title: '第一条 替代品',
|
||||
key: '0-0-0',
|
||||
},
|
||||
{
|
||||
title: '第二条',
|
||||
key: '0-0-1',
|
||||
},
|
||||
{
|
||||
title: '第三条',
|
||||
key: '0-0-2',
|
||||
},
|
||||
{
|
||||
title: '第四条',
|
||||
key: '0-0-3',
|
||||
},
|
||||
{
|
||||
title: '第五条',
|
||||
key: '0-0-4',
|
||||
},
|
||||
],
|
||||
}
|
||||
],
|
||||
gData: [],
|
||||
selecIds:[],
|
||||
loading:false,
|
||||
columns: [
|
||||
@@ -345,13 +284,19 @@
|
||||
addInfo: '/jero-boot/split/sarFileSplitItems/addSplitItems', //新增
|
||||
updateInfo:'/jero-boot/split/sarFileSplitItems/updateSplitItems', //编辑
|
||||
},
|
||||
urlBatSet:{
|
||||
getAddForm:'split/sarFileSplitItems/getBatchSetForm',
|
||||
addInfo:'/split/sarFileSplitItems/batchSet',
|
||||
},
|
||||
batSetVisible:false, //批量设置弹框显示
|
||||
ids:''
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.infoId=this.$route.query.infoId
|
||||
// console.log('info',this.$route.query)
|
||||
this.loadMenuData()
|
||||
this.loadData()
|
||||
// this.loadData()
|
||||
this.generateList(this.gData);
|
||||
},
|
||||
methods: {
|
||||
@@ -412,6 +357,7 @@
|
||||
//获取左侧目录数据
|
||||
loadMenuData(){
|
||||
let params={
|
||||
infoId:this.infoId
|
||||
}
|
||||
this.loading=true
|
||||
getAction(`split/sarFileSplitMenu/getSplitMenusByInfoId`, params).then(res => {
|
||||
@@ -539,7 +485,7 @@
|
||||
expandId.push(this.form.pid)
|
||||
if(!this.isEdit){
|
||||
let params={
|
||||
info_id: this.infoId,
|
||||
infoId: this.infoId,
|
||||
pid:this.nodeItem.id,
|
||||
...this.form,
|
||||
}
|
||||
@@ -581,7 +527,8 @@
|
||||
//获取列表数据
|
||||
loadData(){
|
||||
let params={
|
||||
...this.queryParams
|
||||
...this.queryParams,
|
||||
info_id:this.infoId
|
||||
}
|
||||
this.loading=true
|
||||
postAction(`split/sarFileSplitItems/getSplitItemsByPage`,params).then(res=>{
|
||||
@@ -663,18 +610,55 @@
|
||||
},
|
||||
//模板下载
|
||||
handleDownManage(){
|
||||
// downloadFile('', fileName, { fileName: val.docRealName })
|
||||
let name = this.$t('documentSplitTemplate')+'.xls'
|
||||
downloadFile('split/sarFileSplitItems/exportTemplate',name, {})
|
||||
},
|
||||
//合并条款
|
||||
handleMergeManage(){
|
||||
if(this.selectedRowKeys&&this.selectedRowKeys.length<1){
|
||||
if(this.selectedRowKeys&&this.selectedRowKeys.length<2){
|
||||
this.$message.warning(this.$t('leastTwo'))
|
||||
}else{
|
||||
let ids = this.selectedRowKeys.join(',')
|
||||
this.$confirm({
|
||||
title: this.$t('mergeTerms'),
|
||||
content: '',
|
||||
onOk:
|
||||
async () => {
|
||||
getAction(`split/sarFileSplitItems/batchMergeItems`, { ids: ids }).then(res => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
}
|
||||
}).finally(()=>{
|
||||
this.selectedRowKeys=[]
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
//批量设置
|
||||
handleManage(){
|
||||
this.ids = this.selectedRowKeys.join(',')
|
||||
if(this.selectedRowKeys&&this.selectedRowKeys.length<1){
|
||||
this.$message.warning(this.$t('selectLeastOne'))
|
||||
}else {
|
||||
// console.log('idsss',this.ids)
|
||||
this.batSetVisible=true
|
||||
}
|
||||
},
|
||||
//批量设置确定
|
||||
modalOk(){
|
||||
// this.confirmLoading=true
|
||||
this.$refs.fileForm.sumber()
|
||||
},
|
||||
//批量设置取消
|
||||
batSetCancel(){
|
||||
this.batSetVisible=false
|
||||
},
|
||||
//批量设置确定提交
|
||||
addFormClick(){
|
||||
|
||||
},
|
||||
//批量删除
|
||||
@@ -936,4 +920,12 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.show-setting{
|
||||
.ant-modal{
|
||||
min-width:700px;
|
||||
}
|
||||
.ant-modal-footer{
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user