国内海外企标的操作只有收藏,删除和编辑单拎出来

This commit is contained in:
yanyizhou
2021-11-26 18:00:54 +08:00
parent d5d59cac1f
commit 87814496cc
3 changed files with 268 additions and 85 deletions
@@ -248,12 +248,13 @@
<!-- @click="uploadImportModal(1)"-->
<!-- v-btn-permission="'afX1p2gh3c'"-->
<!-- ><i class="iconfont">&#xe825;</i>模板下载</el-button>-->
<!-- <el-button
class="common-button-default delete-button"
round
@click="deleteStand(2)"
v-btn-permission="'374205ce36a859a158ca4db196d151b7'"
><i class="iconfont">&#xe61b;</i>批量删除</el-button>-->
<el-button
class="common-button-default delete-button"
round
@click="deleteStand(2)"
v-btn-permission="'374205ce36a859a158ca4db196d151b7'"
><i class="iconfont">&#xe61b;</i>批量删除
</el-button>
<el-button
class="common-button-default"
round
@@ -266,6 +267,10 @@
@click="deleteEnterStandFromKind(2)"
v-btn-permission="'2d41ebdb6150ba1af52fd753086d77dc'"
><i class="iconfont">&#xe611;</i>移除标准</el-button>
<el-button class="common-button-default"
size="mini" @click="OCRAdd('2')"
v-btn-permission="'247cebaefa7cf1683092af160af11502'"><i class="iconfont">&#xe611;</i>编辑
</el-button>
</div>
<!--表格-->
<div class="content">
@@ -380,7 +385,7 @@
</el-table-column>
<el-table-column fixed="right"
v-if="isPermission('d9730d984627af948053df56a2db7997,dd4ea796dab7a01b105ba657b1968a84,a7a38a95ea374695fc3128037f6feccf')>0" label="操作" align="center" width="100">
v-if="isPermission('d9730d984627af948053df56a2db7997,dd4ea796dab7a01b105ba657b1968a84,a7a38a95ea374695fc3128037f6feccf')>0" label="操作" align="center" width="50">
<template slot-scope="scope">
<div v-if="isPermission('d9730d984627af948053df56a2db7997,dd4ea796dab7a01b105ba657b1968a84,a7a38a95ea374695fc3128037f6feccf') == 1"
@command="handleCommand"
@@ -407,28 +412,38 @@
<div @click.stop style="display: inline-block">
<el-dropdown trigger="click" @command="handleCommand">
<i class="iconfont">&#xe61e;</i>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item
v-if="scope.row.collectBtn"
:command="[scope.row, '收藏']"
v-btn-permission="'d9730d984627af948053df56a2db7997'"
>
收藏
</el-dropdown-item>
<el-dropdown-item
v-else
:command="[scope.row, '取消收藏']"
v-btn-permission="'d9730d984627af948053df56a2db7997'"
>
取消收藏
</el-dropdown-item>
<el-dropdown-item :command="[scope.row, '编辑']" v-btn-permission="'dd4ea796dab7a01b105ba657b1968a84'">编辑</el-dropdown-item>
<!-- <el-dropdown-item :command="[scope.row, '分享']" v-btn-permission="'ESPMBSD4ZP'">分享</el-dropdown-item>-->
<!-- <el-dropdown-item :command="[scope.row, '授权']" v-btn-permission="'CWBPST294ZH7HSKD4452'" v-if="scope.row.attrInfoMap && scope.row.attrInfoMap.QBMJ === 'ACF675Z88W'">授权</el-dropdown-item>-->
<el-dropdown-item :command="[scope.row, '删除']" v-btn-permission="'a7a38a95ea374695fc3128037f6feccf'">删除</el-dropdown-item>
<!-- <el-dropdown-item :command="[scope.row, '流程']">流程</el-dropdown-item>-->
</el-dropdown-menu>
<el-button title="收藏" class="collection-btn" icon="el-icon-star-off" v-btn-permission="'d9730d984627af948053df56a2db7997'"
v-if="scope.row.collectBtn"
@click="handleCommand([scope.row, '收藏'])"
>
</el-button>
<el-button title="取消收藏" class="collection-btn" icon="el-icon-star-off" style="color: #f56c6c;" v-btn-permission="'d9730d984627af948053df56a2db7997'"
v-else
@click="handleCommand([scope.row, '取消收藏'])"
>
</el-button>
<!-- <i class="iconfont">&#xe61e;</i>-->
<!-- <el-dropdown-menu slot="dropdown">-->
<!-- <el-dropdown-item-->
<!-- v-if="scope.row.collectBtn"-->
<!-- :command="[scope.row, '收藏']"-->
<!-- v-btn-permission="'d9730d984627af948053df56a2db7997'"-->
<!-- >-->
<!-- 收藏-->
<!-- </el-dropdown-item>-->
<!-- <el-dropdown-item-->
<!-- v-else-->
<!-- :command="[scope.row, '取消收藏']"-->
<!-- v-btn-permission="'d9730d984627af948053df56a2db7997'"-->
<!-- >-->
<!-- 取消收藏-->
<!-- </el-dropdown-item>-->
<!-- <el-dropdown-item :command="[scope.row, '编辑']" v-btn-permission="'dd4ea796dab7a01b105ba657b1968a84'">编辑</el-dropdown-item>-->
<!-- &lt;!&ndash; <el-dropdown-item :command="[scope.row, '分享']" v-btn-permission="'ESPMBSD4ZP'">分享</el-dropdown-item>&ndash;&gt;-->
<!-- &lt;!&ndash; <el-dropdown-item :command="[scope.row, '授权']" v-btn-permission="'CWBPST294ZH7HSKD4452'" v-if="scope.row.attrInfoMap && scope.row.attrInfoMap.QBMJ === 'ACF675Z88W'">授权</el-dropdown-item>&ndash;&gt;-->
<!-- <el-dropdown-item :command="[scope.row, '删除']" v-btn-permission="'a7a38a95ea374695fc3128037f6feccf'">删除</el-dropdown-item>-->
<!-- &lt;!&ndash; <el-dropdown-item :command="[scope.row, '流程']">流程</el-dropdown-item>&ndash;&gt;-->
<!-- </el-dropdown-menu>-->
</el-dropdown>
</div>
@@ -1306,6 +1321,9 @@ export default {
},
data () {
return {
OCRType: '',
OCRTitle: '',
ocrList: [],
orderBy: '',
nowOrder: '',
nowOrderBy: '',
@@ -3674,6 +3692,7 @@ export default {
},
// 修改成表格样式后,选择项勾选改变
standSelectChange (data) {
this.ocrList = data
this.selectedList = []
for (let i = 0; i < data.length; i++) {
this.selectedList.push(data[i].id)
@@ -3690,6 +3709,47 @@ export default {
})
window.open(routeUrl.href, '_blank')
},
OCRAdd (type) {
let text = ''
this.OCRType = type
if (type === '0') {
text = 'OCR识别'
this.OCRTitle = '选择OCR实别文件'
} else if(type === '1') {
text = '拆分'
this.OCRTitle = '选择拆分文件'
}else if(type === '2') {
text = '编辑'
this.OCRTitle = '选择编辑文件'
}
if (this.ocrList.length > 1 && (type === '0' || type === '1' || type === '2')) {
this.$message.warning('仅能选择一条数据进行' + text)
} else if (this.ocrList.length === 0 && (type === '0' || type === '1' || type === '2')) {
this.$message.warning('请选择一条数据进行' + text)
} else if (this.ocrList.length === 1 && (type === '0' || type === '1')) {
this.OCRModel = true
this.OCRLoading = true
this.$http.get('lawss/sarStandFile/queryFileInfoNew', {
type: type,
standId: this.selectedList[0]
},{
_this: this
}, res => {
this.OCRLoading = false
if (res.ok) {
if (res.data.length > 0) {
this.OCRData = res.data
} else {
this.$message.warning('当前标准没有' + text + '文件')
this.this.OCRData = []
}
}
})
} else if (this.ocrList.length === 1 && type === '2'){
console.log('4228',this.ocrList)
this.selectStandardPro(this.ocrList[0], 'edit')
}
},
// 查询二级菜单
selectMenu () {
this.countRootId = 0
@@ -4397,6 +4457,21 @@ export default {
flex-direction: column;
position: relative;
flex: auto;
.collection-btn {
padding: 0;
border: none;
color: #4788c0;
font-size: 18px;
width: 18px;
height: 18px;
background-color: transparent;
/*background: rgba(244, 162, 39, 0.1);*/
//.icon-collection {
// background-image: url("~assets/images/shangqi/standardDetails/collection.png");
//}
}
.pagination {
position: static;
/deep/ .pagination-slot {