收藏列表
This commit is contained in:
@@ -283,7 +283,7 @@
|
|||||||
},
|
},
|
||||||
/** 上传文件的回调 */
|
/** 上传文件的回调 */
|
||||||
uploadSuccess(data) {
|
uploadSuccess(data) {
|
||||||
console.log(data)
|
// console.log(data)
|
||||||
let attIdList = []
|
let attIdList = []
|
||||||
if(data && data.length>0){
|
if(data && data.length>0){
|
||||||
data.map(item => {
|
data.map(item => {
|
||||||
@@ -343,7 +343,7 @@
|
|||||||
rules[res.db_field_name] = rule
|
rules[res.db_field_name] = rule
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
console.log(rules)
|
// console.log(rules)
|
||||||
this.$set(this, 'rules', rules)
|
this.$set(this, 'rules', rules)
|
||||||
this.isFormInline = true
|
this.isFormInline = true
|
||||||
this.confirmLoading = false
|
this.confirmLoading = false
|
||||||
|
|||||||
@@ -10,13 +10,13 @@
|
|||||||
:model="queryParams"
|
:model="queryParams"
|
||||||
ref="tagEditForm"
|
ref="tagEditForm"
|
||||||
>
|
>
|
||||||
<a-row :gutter="44">
|
<a-row :gutter="24" type="flex" justify="start">
|
||||||
<a-col :md="6" :sm="12">
|
<a-col :md="6" :sm="8">
|
||||||
<a-form-model-item :label="'编号'">
|
<a-form-model-item :label="'编号'">
|
||||||
<j-input :placeholder="'请输入编号'" v-model="queryParams.serialNumber"></j-input>
|
<j-input :placeholder="'请输入编号'" v-model="queryParams.serialNumber"></j-input>
|
||||||
</a-form-model-item>
|
</a-form-model-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :md="6" :sm="12">
|
<a-col :md="6" :sm="8">
|
||||||
<a-form-model-item :label="'标题'">
|
<a-form-model-item :label="'标题'">
|
||||||
<j-input :placeholder="'请输入标题'" v-model="queryParams.title"></j-input>
|
<j-input :placeholder="'请输入标题'" v-model="queryParams.title"></j-input>
|
||||||
</a-form-model-item>
|
</a-form-model-item>
|
||||||
@@ -37,21 +37,18 @@
|
|||||||
</a-form>
|
</a-form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="table-operator" style="margin-top: 10px">
|
<div class="table-operator">
|
||||||
<a-button @click="handleBatCancel" type="primary">批量取消收藏</a-button>
|
<div class="operator-text" @click="handleBatCancel">
|
||||||
|
<a-icon type="delete" />
|
||||||
|
批量取消收藏
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="colloction-table">
|
<div class="colloction-table">
|
||||||
<a-table bordered :data-source="tableData" :columns="columns" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :pagination="false" class="tag-con-table">
|
<a-table bordered :data-source="tableData" :columns="columns" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :pagination="false" :loading="loading" class="tag-con-table">
|
||||||
<a slot="serialNumber" slot-scope="text, record" @click="numberClick(record)">{{ text }}</a>
|
<a slot="serialNumber" slot-scope="text, record" @click="numberClick(record)">{{ text }}</a>
|
||||||
<!-- <a slot="title" slot-scope="text, record" @click="titleClick(record)">{{ text }}</a>-->
|
<!-- <a slot="title" slot-scope="text, record" @click="titleClick(record)">{{ text }}</a>-->
|
||||||
<template slot="action" slot-scope="text, record">
|
<template slot="action" slot-scope="text, record">
|
||||||
<a-popconfirm
|
<a class="action-delete" href="javascript:;" @click="onCancel(record)">取消收藏</a>
|
||||||
v-if="tableData.length"
|
|
||||||
title="确定取消收藏?"
|
|
||||||
@confirm="() => onCancel(record)"
|
|
||||||
>
|
|
||||||
<a class="action-delete" href="javascript:;">取消收藏</a>
|
|
||||||
</a-popconfirm>
|
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</a-table>
|
||||||
<div class="page" v-if="tableData.length > 0">
|
<div class="page" v-if="tableData.length > 0">
|
||||||
@@ -59,6 +56,7 @@
|
|||||||
:show-total="total => `共 ${total} 条`"
|
:show-total="total => `共 ${total} 条`"
|
||||||
show-quick-jumper
|
show-quick-jumper
|
||||||
show-size-changer
|
show-size-changer
|
||||||
|
:current="queryParams.pageNo"
|
||||||
:page-size.sync="queryParams.pageSize"
|
:page-size.sync="queryParams.pageSize"
|
||||||
:total="total"
|
:total="total"
|
||||||
@change="onChangePage"
|
@change="onChangePage"
|
||||||
@@ -71,6 +69,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getAction, postAction, deleteAction, putAction } from '@/api/manage'
|
import { getAction, postAction, deleteAction, putAction } from '@/api/manage'
|
||||||
|
import eventBUs from '../../../common/event'
|
||||||
// import search from '@/components/search'
|
// import search from '@/components/search'
|
||||||
export default {
|
export default {
|
||||||
name:'collection',
|
name:'collection',
|
||||||
@@ -122,6 +121,8 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
tableData:[], //列表数据
|
tableData:[], //列表数据
|
||||||
|
selecIds:'',
|
||||||
|
loading:false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -133,9 +134,11 @@
|
|||||||
let params={
|
let params={
|
||||||
...this.queryParams
|
...this.queryParams
|
||||||
}
|
}
|
||||||
|
this.loading=true
|
||||||
getAction(`collection/onlCgformCollection/page`,params).then(res=>{
|
getAction(`collection/onlCgformCollection/page`,params).then(res=>{
|
||||||
if(res.success){
|
if(res.success){
|
||||||
this.tableData= { ...res.result.records }
|
this.tableData= [ ...res.result.records ]
|
||||||
|
this.loading=false
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},//搜索
|
},//搜索
|
||||||
@@ -144,11 +147,52 @@
|
|||||||
},
|
},
|
||||||
//批量取消收藏
|
//批量取消收藏
|
||||||
handleBatCancel(){
|
handleBatCancel(){
|
||||||
|
let params={
|
||||||
|
ids:this.selecIds
|
||||||
|
}
|
||||||
|
if(this.selecIds){
|
||||||
|
this.$confirm({
|
||||||
|
title: '确认批量取消收藏?',
|
||||||
|
content: '',
|
||||||
|
onOk:
|
||||||
|
async () => {
|
||||||
|
deleteAction(`collection/onlCgformCollection/deleteBatch`,params).then(res=> {
|
||||||
|
if(res.success){
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.selectedRowKeys = []
|
||||||
|
this.loadData()
|
||||||
|
}else{
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
onCancel() {},
|
||||||
|
});
|
||||||
|
}else{
|
||||||
|
this.$message.warning('请选择至少一条数据')
|
||||||
|
}
|
||||||
},
|
},
|
||||||
//取消收藏
|
//取消收藏
|
||||||
onCancel(record){
|
onCancel(record){
|
||||||
|
let params={
|
||||||
|
id:record.id
|
||||||
|
}
|
||||||
|
this.$confirm({
|
||||||
|
title: '确认取消收藏?',
|
||||||
|
content: '',
|
||||||
|
onOk:
|
||||||
|
async () => {
|
||||||
|
deleteAction(`collection/onlCgformCollection/delete`,params).then(res=> {
|
||||||
|
if(res.success){
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.loadData()
|
||||||
|
}else{
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
onCancel() {},
|
||||||
|
});
|
||||||
},
|
},
|
||||||
//清空
|
//清空
|
||||||
searchReset(){
|
searchReset(){
|
||||||
@@ -170,8 +214,15 @@
|
|||||||
},
|
},
|
||||||
//选择框
|
//选择框
|
||||||
onSelectChange(selectedRowKeys,rows) {
|
onSelectChange(selectedRowKeys,rows) {
|
||||||
console.log('selectedRowKeys changed: ', selectedRowKeys);
|
this.selectedRowKeys = selectedRowKeys
|
||||||
this.selectedRowKeys = selectedRowKeys;
|
let ids=[]
|
||||||
|
if(rows && rows.length>0){
|
||||||
|
rows.forEach(item=>{
|
||||||
|
ids.push(item.id)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
this.selecIds=ids.join(',')
|
||||||
|
// console.log('selectedRowKeys changed: ', ids);
|
||||||
},
|
},
|
||||||
//点击编号
|
//点击编号
|
||||||
numberClick(records){
|
numberClick(records){
|
||||||
@@ -186,7 +237,17 @@
|
|||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
|
@import '~@assets/less/common.less';
|
||||||
|
.collection{
|
||||||
|
.collection-search-wrapper{
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
.colloction-table{
|
||||||
|
.page{
|
||||||
|
margin-top: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
<style lang="less">
|
<style lang="less">
|
||||||
.collection{
|
.collection{
|
||||||
|
|||||||
@@ -4,20 +4,20 @@
|
|||||||
<div class="table-page-search-wrapper">
|
<div class="table-page-search-wrapper">
|
||||||
<search :flag="'2'" :url="url"/>
|
<search :flag="'2'" :url="url"/>
|
||||||
</div>
|
</div>
|
||||||
<div class="table-operator">
|
<div class="table-operator">
|
||||||
<div class="operator-text" @click="handleUpload">
|
<div class="operator-text" @click="handleUpload">
|
||||||
<a-icon type="plus" />
|
<a-icon type="plus" />
|
||||||
上传
|
上传
|
||||||
</div>
|
|
||||||
<div class="operator-text" @click="handleFileExport">
|
|
||||||
<a-icon type="export" />
|
|
||||||
调取已入库文件
|
|
||||||
</div>
|
|
||||||
<div class="operator-text" @click="handleDel">
|
|
||||||
<a-icon type="delete" />
|
|
||||||
批量删除
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
<div class="operator-text" @click="handleFileExport">
|
||||||
|
<a-icon type="export" />
|
||||||
|
调取已入库文件
|
||||||
|
</div>
|
||||||
|
<div class="operator-text" @click="handleDel">
|
||||||
|
<a-icon type="delete" />
|
||||||
|
批量删除
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!-- 上传弹框-->
|
<!-- 上传弹框-->
|
||||||
<a-modal
|
<a-modal
|
||||||
|
|||||||
@@ -0,0 +1,15 @@
|
|||||||
|
<template>
|
||||||
|
<div class="split-detail">
|
||||||
|
splitDetail
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'splitDetail'
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
</style>
|
||||||
@@ -37,22 +37,22 @@
|
|||||||
</a-form>
|
</a-form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="table-operator" style="margin-top: 10px">
|
<div class="table-operator">
|
||||||
<a-button @click="handleBatManage" type="primary">订阅领域管理</a-button>
|
<div class="operator-text" @click="handleBatManage">
|
||||||
<a-button @click="handleBatCancel" type="danger">批量取消</a-button>
|
<a-icon type="plus" />
|
||||||
|
订阅领域管理
|
||||||
|
</div>
|
||||||
|
<div class="operator-text" @click="handleBatCancel">
|
||||||
|
<a-icon type="delete" />
|
||||||
|
批量取消
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="colloction-table">
|
<div class="colloction-table">
|
||||||
<a-table bordered :data-source="tableData" :columns="columns" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :pagination="false" class="tag-con-table">
|
<a-table bordered :data-source="tableData" :columns="columns" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :pagination="false" :loading="loading" class="tag-con-table">
|
||||||
<a slot="serialNumber" slot-scope="text, record" @click="numberClick(record)">{{ text }}</a>
|
<a slot="serialNumber" slot-scope="text, record" @click="numberClick(record)">{{ text }}</a>
|
||||||
<!-- <a slot="title" slot-scope="text, record" @click="titleClick(record)">{{ text }}</a>-->
|
<!-- <a slot="title" slot-scope="text, record" @click="titleClick(record)">{{ text }}</a>-->
|
||||||
<template slot="action" slot-scope="text, record">
|
<template slot="action" slot-scope="text, record">
|
||||||
<a-popconfirm
|
<a class="action-delete" href="javascript:;" @click="onCancel(record)">取消订阅</a>
|
||||||
v-if="tableData.length"
|
|
||||||
title="确定取消订阅?"
|
|
||||||
@confirm="() => onCancel(record)"
|
|
||||||
>
|
|
||||||
<a class="action-delete" href="javascript:;">取消订阅</a>
|
|
||||||
</a-popconfirm>
|
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</a-table>
|
||||||
<div class="page" v-if="tableData.length > 0">
|
<div class="page" v-if="tableData.length > 0">
|
||||||
@@ -60,6 +60,7 @@
|
|||||||
:show-total="total => `共 ${total} 条`"
|
:show-total="total => `共 ${total} 条`"
|
||||||
show-quick-jumper
|
show-quick-jumper
|
||||||
show-size-changer
|
show-size-changer
|
||||||
|
:current="queryParams.pageNo"
|
||||||
:page-size.sync="queryParams.pageSize"
|
:page-size.sync="queryParams.pageSize"
|
||||||
:total="total"
|
:total="total"
|
||||||
@change="onChangePage"
|
@change="onChangePage"
|
||||||
@@ -129,6 +130,8 @@
|
|||||||
],
|
],
|
||||||
tableData:[], //列表数据
|
tableData:[], //列表数据
|
||||||
visible:false,
|
visible:false,
|
||||||
|
selecIds:'',
|
||||||
|
loading:false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -140,9 +143,11 @@
|
|||||||
let params={
|
let params={
|
||||||
...this.queryParams
|
...this.queryParams
|
||||||
}
|
}
|
||||||
getAction(``,params).then(res=>{
|
this.loading=true
|
||||||
|
getAction(`subscribe/onlCgformSubscribe/page`,params).then(res=>{
|
||||||
if(res.success){
|
if(res.success){
|
||||||
// this.tableData= { ...res.result.records }
|
this.tableData= [ ...res.result.records ]
|
||||||
|
this.loading=false
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},//搜索
|
},//搜索
|
||||||
@@ -155,11 +160,52 @@
|
|||||||
},
|
},
|
||||||
//批量取消收藏
|
//批量取消收藏
|
||||||
handleBatCancel(){
|
handleBatCancel(){
|
||||||
|
let params={
|
||||||
|
ids:this.selecIds
|
||||||
|
}
|
||||||
|
if(this.selecIds){
|
||||||
|
this.$confirm({
|
||||||
|
title: '确认批量取消订阅?',
|
||||||
|
content: '',
|
||||||
|
onOk:
|
||||||
|
async () => {
|
||||||
|
deleteAction(`subscribe/onlCgformSubscribe/deleteBatch`,params).then(res=> {
|
||||||
|
if(res.success){
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.selectedRowKeys = []
|
||||||
|
this.loadData()
|
||||||
|
}else{
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
onCancel() {},
|
||||||
|
});
|
||||||
|
}else{
|
||||||
|
this.$message.warning('请选择至少一条数据')
|
||||||
|
}
|
||||||
},
|
},
|
||||||
//取消收藏
|
//取消收藏
|
||||||
onCancel(record){
|
onCancel(record){
|
||||||
|
let params={
|
||||||
|
id:record.id
|
||||||
|
}
|
||||||
|
this.$confirm({
|
||||||
|
title: '确认取消订阅?',
|
||||||
|
content: '',
|
||||||
|
onOk:
|
||||||
|
async () => {
|
||||||
|
deleteAction(`subscribe/onlCgformSubscribe/delete`,params).then(res=> {
|
||||||
|
if(res.success){
|
||||||
|
this.$message.success(res.message)
|
||||||
|
this.loadData()
|
||||||
|
}else{
|
||||||
|
this.$message.warning(res.message)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
onCancel() {},
|
||||||
|
});
|
||||||
},
|
},
|
||||||
//清空
|
//清空
|
||||||
searchReset(){
|
searchReset(){
|
||||||
@@ -181,8 +227,14 @@
|
|||||||
},
|
},
|
||||||
//选择框
|
//选择框
|
||||||
onSelectChange(selectedRowKeys,rows) {
|
onSelectChange(selectedRowKeys,rows) {
|
||||||
console.log('selectedRowKeys changed: ', selectedRowKeys);
|
|
||||||
this.selectedRowKeys = selectedRowKeys;
|
this.selectedRowKeys = selectedRowKeys;
|
||||||
|
let ids=[]
|
||||||
|
if(rows && rows.length>0){
|
||||||
|
rows.forEach(item=>{
|
||||||
|
ids.push(item.id)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
this.selecIds=ids.join(',')
|
||||||
},
|
},
|
||||||
//点击编号
|
//点击编号
|
||||||
numberClick(records){
|
numberClick(records){
|
||||||
@@ -199,6 +251,15 @@
|
|||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
|
@import '~@assets/less/common.less';
|
||||||
|
.subscribtion{
|
||||||
|
.subscribtion-search-wrapper{
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
.page{
|
||||||
|
margin-top: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
<style lang="less">
|
<style lang="less">
|
||||||
|
|||||||
@@ -69,8 +69,8 @@
|
|||||||
</a-form-model-item>
|
</a-form-model-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<a-col :span="24">
|
<a-col :span="24">
|
||||||
<a-form-model-item label="展示区域" prop="showArea">
|
<a-form-model-item label="展示区域" prop="areaId">
|
||||||
<a-select placeholder="请选择展示区域" v-model="form.showArea" @change="handleChange">
|
<a-select placeholder="请选择展示区域" v-model="form.areaId" @change="handleChange">
|
||||||
<a-select-option v-for="(item,index) in areaOptions" :key="item.id" :value="item.id">
|
<a-select-option v-for="(item,index) in areaOptions" :key="item.id" :value="item.id">
|
||||||
{{item.showArea}}
|
{{item.showArea}}
|
||||||
</a-select-option>
|
</a-select-option>
|
||||||
@@ -195,7 +195,7 @@
|
|||||||
isShowForm: [
|
isShowForm: [
|
||||||
{ required: true, message: '请选择是否显示文档库列表',trigger: 'change'},
|
{ required: true, message: '请选择是否显示文档库列表',trigger: 'change'},
|
||||||
],
|
],
|
||||||
showArea: [
|
areaId: [
|
||||||
{ required: true, message: '请输入展示区域!',trigger: 'change'},
|
{ required: true, message: '请输入展示区域!',trigger: 'change'},
|
||||||
],
|
],
|
||||||
isQuery: [
|
isQuery: [
|
||||||
@@ -337,7 +337,7 @@
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
popupCallback(row){
|
popupCallback(row){
|
||||||
this.form.setFieldsValue(pick(row,'isModel','dbFieldTxt','dbFieldName','fieldShowType','dictName','dbLength','orderNum','fieldMustInput','isShowForm','showArea','isQuery','isShowLawsList','isShowSearch'))
|
this.form.setFieldsValue(pick(row,'isModel','dbFieldTxt','dbFieldName','fieldShowType','dictName','dbLength','orderNum','fieldMustInput','isShowForm','areaId','isQuery','isShowLawsList','isShowSearch'))
|
||||||
},
|
},
|
||||||
//正则替换小数点
|
//正则替换小数点
|
||||||
limitNumber(value) {
|
limitNumber(value) {
|
||||||
|
|||||||
@@ -31,6 +31,7 @@
|
|||||||
:show-total="total => `共 ${total} 条`"
|
:show-total="total => `共 ${total} 条`"
|
||||||
show-quick-jumper
|
show-quick-jumper
|
||||||
show-size-changer
|
show-size-changer
|
||||||
|
:current="queryParams.pageNo"
|
||||||
:page-size.sync="queryParams.pageSize"
|
:page-size.sync="queryParams.pageSize"
|
||||||
:total="total"
|
:total="total"
|
||||||
@change="onChangePage"
|
@change="onChangePage"
|
||||||
|
|||||||
Reference in New Issue
Block a user