{{$t('docTool.ocrTextRecognition.upload') }}
@@ -16,11 +47,16 @@
:pagination="ipagination"
:scroll="{x: '100%', y: yScrollHeight}"
:loading="loading"
- :operation-list="operationList"
- @change="handleTableChange"
- @operationClick="operationClick">
+ @change="handleTableChange">
-
+
+
+ {{ $t('docTool.ocrTextRecognition.getFile') }}
+
+
+
{{ text || text === 0 ? text : global.emptyLine }}
@@ -29,6 +65,14 @@
+
+
+
+ {{ text || text === 0 ? text : global.emptyLine }}
+ {{ text }}
+ {{ global.emptyLine }}
+
+
@@ -41,6 +85,7 @@ import { JeroListMixin } from '@/mixins/JeroListMixin'
import JTable from '@comp/jero/JTable'
import OcrTextRecognitionModal from '@views/documentTool/ocrTextRecognition/modules/OcrTextRecognitionModal'
import { downloadFile, getAction, postAction } from '@api/manage'
+import { OcrConvertStateEnums } from '@/enums/commonEnums'
export default {
name: 'OcrTextRecognition',
@@ -48,6 +93,7 @@ export default {
mixins: [JeroListMixin],
data () {
return {
+ OcrConvertStateEnums,
url: {
list: '/laws/ocr/OCRRestful/getAllOcrResult',
deleteBatch: '/laws/ocr/OCRRestful/deleteOcrRecord'
@@ -73,14 +119,14 @@ export default {
align: 'center',
width: 180,
dataIndex: 'standNumber',
- scopedSlots: { customRender: 'text' }
+ scopedSlots: { customRender: 'toDetail' }
},
{ // 标准名称
title: this.$t('docTool.ocrTextRecognition.standardName'),
align: 'center',
width: 180,
dataIndex: 'standName',
- scopedSlots: { customRender: 'text' }
+ scopedSlots: { customRender: 'toDetail' }
},
{ // 文本状态
title: this.$t('docTool.ocrTextRecognition.textStatus'),
@@ -93,7 +139,7 @@ export default {
title: this.$t('docTool.ocrTextRecognition.conversionResults'),
align: 'center',
width: 180,
- dataIndex: 'resultContent',
+ dataIndex: 'resultContent_dictText',
scopedSlots: { customRender: 'tag' }
},
{ // 消耗时间
@@ -110,36 +156,20 @@ export default {
fixed: 'right',
width: 200
}
- ],
- operationList: [
- // 获取文件
- {
- text: this.$t('docTool.ocrTextRecognition.getFile'),
- clickEvent: 'handleDownload',
- has: 'docTool:ocrTextRecognition:download',
- show: (record) => {
- return record.resultContent !== '转换中'
- }
- },
- // 编辑
- {
- text: this.$t('edit'),
- clickEvent: 'handleEdit',
- has: 'docTool:ocrTextRecognition:edit'
- }
- // 删除
- // {
- // text: this.$t('delete'),
- // clickEvent: 'handleDelete',
- // has: 'split:sarFileSplitInfo:release'
- // }
]
}
},
- mounted () {
- console.log(this.$refs.modalForm)
- },
methods: {
+ // 跳转详情
+ toStandardDetail () {
+ const { standardId } = this.info.data.processStandardInterpret
+ this.$openPageNewSheet({
+ path: '/standardRegulationLibrary/foreignStandardDetailPage',
+ query: {
+ id: standardId
+ }
+ })
+ },
loadData (arg) {
if (!this.url.list) {
this.$message.warning('请设置url.list属性!')
@@ -171,9 +201,9 @@ export default {
downloadFile(`/sys/common/download/${data.wordAttId}`, data.docRealName)
},
getTagColor (row) {
- if (row.resultContent === '转换成功') {
+ if (row.resultContent === OcrConvertStateEnums.CONVERTED.value) {
return 'green'
- } else if (row.resultContent === '转换中') {
+ } else if (row.resultContent === OcrConvertStateEnums.CONVERTING.value) {
return 'blue'
} else {
return 'red'
diff --git a/src/views/documentTool/ocrTextRecognition/modules/OcrSelectStandard.vue b/src/views/documentTool/ocrTextRecognition/modules/OcrSelectStandard.vue
new file mode 100644
index 0000000..15776fe
--- /dev/null
+++ b/src/views/documentTool/ocrTextRecognition/modules/OcrSelectStandard.vue
@@ -0,0 +1,216 @@
+