Merge remote-tracking branch 'origin/develop' into develop

This commit is contained in:
yanyizhou
2021-11-22 18:10:16 +08:00
3 changed files with 118 additions and 2 deletions
+2
View File
@@ -166,6 +166,7 @@
handleTreeDrawerCancel () {
this.filterText = ''
this.isVisible2 = false
this.open1 = true
},
saveUserInfo () {
if (this.checkBox) {
@@ -195,6 +196,7 @@
this.$emit('checkedRole', this.roleList)
}
}
this.open1 = true
},
drawerCheck (data) {
if (this.checkBox) {
@@ -402,7 +402,6 @@
pId: this.pId
}).then(res => {
let data = JSON.parse(res.mesg)
console.log(data);
this.form.title = data.title || data.form.title
this.form.date = data.date || data.form.date
this.json = data || data.form
@@ -163,6 +163,14 @@
@click="deleteStandFromKind(2)"
v-btn-permission="'5aedea192a77b14c364f19bdcee3513a'"><i class="iconfont">&#xe611;</i>移除标准
</el-button>
<el-button class="common-button-default"
size="mini"
@click="OCRAdd('0')"><i class="iconfont">&#xe611;</i>OCR
</el-button>
<el-button class="common-button-default"
size="mini"
@click="OCRAdd('1')"><i class="iconfont">&#xe611;</i>拆分
</el-button>
<!-- <el-button class="common-button-default"-->
<!-- size="mini"-->
<!-- :loading="searching"-->
@@ -1753,6 +1761,46 @@
:nodeList="nodeListZRBM"
@checkedRole="drawerCheckZRBM"
/>
<el-drawer
:title="OCRTitle"
:visible.sync="OCRModel"
size="900px"
custom-class="demo-drawer"
>
<div class="OCRstandardForComments">
<div class="content" style="height: calc(100% - 57px);">
<div class="table-wrap">
<div style="position: absolute; margin: 10px 10px 10px 0px; height: calc(100% - 120px); width: calc(100% - 20px);">
<el-table
ref="OCRselections"
:data="OCRData"
tooltip-effect="dark"
style="width: 100%;padding:0 0 20px 0;"
height="100%"
border
@selection-change="selectOCRChange"
:header-cell-style="{background: '#f8f8f9', color: '#515a6e'}">
<el-table-column
type="selection"
width="55"
align="center">
</el-table-column>
<el-table-column
prop="fileName"
label="文件名"
align="center">
</el-table-column>
</el-table>
</div>
</div>
</div>
<loading :loading="OCRLoading">数据加载中……</loading>
<div class="demo-drawer-footer">
<el-button size="mini" @click="OCRclose">取消</el-button>
<el-button type="primary" size="mini" @click="OCRsubmit">转换</el-button>
</div>
</div>
</el-drawer>
</div>
</template>
@@ -1807,6 +1855,12 @@ export default {
},
data() {
return {
OCRDatas: [],
OCRData: [],
OCRLoading: false,
OCRTitle: '',
OCRModel: false,
ocrList: [],
nodeList: [],
nodeListZRBM: [],
modalshowflagRole: false,
@@ -2497,6 +2551,64 @@ export default {
}
},
methods: {
selectOCRChange (val) {
this.OCRDatas = val
},
OCRclose () {
this.OCRModel = false
},
OCRsubmit () {
if (this.OCRDatas.length > 1) {
this.$message.warning('仅能选择一个文件')
} else if (this.OCRDatas.length === 0) {
this.$message.warning('请选择一个文件')
} else {
console.log(this.OCRDatas);
console.log(this.ocrList);
let json = {
standNumber: this.ocrList[0].standName,
standName: this.ocrList[0].standName,
attId: this.OCRDatas[0].attId,
fileName: this.OCRDatas[0].name,
fileType: this.ocrList[0].name,
}
console.log('这儿')
}
},
OCRAdd (type) {
let text = ''
if (type === '0') {
text = 'OCR识别'
this.OCRTitle = '选择OCR实别文件'
} else {
text = '拆分'
this.OCRTitle = '选择拆分文件'
}
if (this.ocrList.length > 1) {
this.$message.warning('仅能选择一条数据进行' + text)
} else if (this.ocrList.length === 0) {
this.$message.warning('请选择一条数据进行' + text)
} else {
this.OCRModel = true
this.OCRLoading = false
this.$http.get('lawss/sarStandFile/queryFileInfoNew', {
type: type,
standId: this.selectedList[0]
},{
_this: this
}, res => {
if (res.ok) {
if (res.data.length > 0) {
this.OCRData = res.data
this.OCRLoading = false
} else {
this.$message.warning('当前标准没有' + text + '文件')
this.OCRLoading = false
}
}
})
}
},
// 左右拖动事件
dragControllerLR: function() {
var resize = document.getElementById("resize");
@@ -3397,6 +3509,7 @@ export default {
},
// 修改成表格样式后,选择项勾选改变
standSelectChange(data) {
this.ocrList = data
this.selectedList = []
for (let i = 0; i < data.length; i++) {
this.selectedList.push(data[i].id)
@@ -5213,7 +5326,9 @@ export default {
/deep/ .el-table--scrollable-x .el-table__body-wrapper {
overflow-x: scroll;
}
.OCRstandardForComments {
height: 100%;
}
#left{
width:calc(30% - 5px);
height:100%;