修改禅道已知问题

This commit is contained in:
qq787203167
2022-03-10 19:13:11 +08:00
parent 7fcd61cbfd
commit ca0e81a9c0
7 changed files with 293 additions and 178 deletions
+123 -121
View File
@@ -399,7 +399,7 @@ module.exports = {
DropDownType: 'Drop down type', DropDownType: 'Drop down type',
ExhibitionAreaManagement: 'Exhibition area management', ExhibitionAreaManagement: 'Exhibition area management',
NewLabelItem: 'Add label item', NewLabelItem: 'Add label item',
editLabelItem:'Edit label item', editLabelItem: 'Edit label item',
NodeQuickLookup: 'Node quick lookup', NodeQuickLookup: 'Node quick lookup',
AreAllLabelsRead: 'Are all labels read', AreAllLabelsRead: 'Are all labels read',
AllLabelsRead: 'labels read', AllLabelsRead: 'labels read',
@@ -410,128 +410,130 @@ module.exports = {
MessageContent: 'Message Content', MessageContent: 'Message Content',
MessageType: 'Message Type', MessageType: 'Message Type',
NotificationTime: 'Notification Time', NotificationTime: 'Notification Time',
MessageNotification:'Message Notification', MessageNotification: 'Message Notification',
SeeMore:'See more', SeeMore: 'See more',
OperationSuccessful:'Operation successful', OperationSuccessful: 'Operation successful',
operationFailed:'operation failed', operationFailed: 'operation failed',
PersonnelSelection:'Personnel selection', PersonnelSelection: 'Personnel selection',
EmployeeNumber:'Employee number', EmployeeNumber: 'Employee number',
EmployeeType:'Employee type', EmployeeType: 'Employee type',
LabeItemName:'Label item name', LabeItemName: 'Label item name',
PleaseEnterLabelName:'Please enter label name', PleaseEnterLabelName: 'Please enter label name',
DisplayArea:'Display area', DisplayArea: 'Display area',
ChineseName:'Chinese name', ChineseName: 'Chinese name',
AttributeType:'Attribute type', AttributeType: 'Attribute type',
FieldLength:'Field length', FieldLength: 'Field length',
DisplayOrder:'Display order', DisplayOrder: 'Display order',
LabelName:'Label name', LabelName: 'Label name',
LabelType:'Label type', LabelType: 'Label type',
PleaseSelectLabelType:'Please select a label type', PleaseSelectLabelType: 'Please select a label type',
PleaseEnterDescription:'Please enter a description', PleaseEnterDescription: 'Please enter a description',
LengthBe1to100:'Length should be 1 to 100', LengthBe1to100: 'Length should be 1 to 100',
Module:'Module', Module: 'Module',
PleaseSelectModule:'Please select the module', PleaseSelectModule: 'Please select the module',
AttributeName:'Attribute name', AttributeName: 'Attribute name',
PleaseEnterPropertyName:'Please enter a property name', PleaseEnterPropertyName: 'Please enter a property name',
PleaseEnterYourEnglishName:'Please enter your English name', PleaseEnterYourEnglishName: 'Please enter your English name',
PleaseSelectAttributeType:'Please select an attribute type', PleaseSelectAttributeType: 'Please select an attribute type',
OptionContent:'Option content', OptionContent: 'Option content',
PleaseSelectOptionContent:'Please select the option content', PleaseSelectOptionContent: 'Please select the option content',
PleaseEnterFieldLength:'Please enter the field length', PleaseEnterFieldLength: 'Please enter the field length',
DisplayOrder:'Display order', DisplayOrder: 'Display order',
PleaseEnterDisplayOrder:'Please enter the display order', PleaseEnterDisplayOrder: 'Please enter the display order',
Required:'Required', Required: 'Required',
DocumentLibraryModuleDisplay:'Document library module display', DocumentLibraryModuleDisplay: 'Document library module display',
DocumentLibraryListDisplay:'Document library list display', DocumentLibraryListDisplay: 'Document library list display',
SelectWhetherDisplayList:'Please select whether to display the document library list', SelectWhetherDisplayList: 'Please select whether to display the document library list',
SelectDisplayArea:'Please select a display area', SelectDisplayArea: 'Please select a display area',
Search:'Search', Search: 'Search',
SelectWhetherToSearch:'Please select whether to search', SelectWhetherToSearch: 'Please select whether to search',
DisplayOtherModules:'Display of other modules', DisplayOtherModules: 'Display of other modules',
RegulationsListDisplay:'Regulations list display', RegulationsListDisplay: 'Regulations list display',
selectDisplayListRegulations:'Please select whether to display the list of regulations', selectDisplayListRegulations: 'Please select whether to display the list of regulations',
SearchCenterDisplay:'Search center display', SearchCenterDisplay: 'Search center display',
selectSearchCenterDisplayed:'Please select whether the search center is displayed', selectSearchCenterDisplayed: 'Please select whether the search center is displayed',
selectWhetherRequired:'Please select whether it is required', selectWhetherRequired: 'Please select whether it is required',
SortNumber:'Sort number', SortNumber: 'Sort number',
enterDisplayArea:'Please enter the display area', enterDisplayArea: 'Please enter the display area',
charactersLength:'1 - 50 characters in length', charactersLength: '1 - 50 characters in length',
enterSortingNumber:'Please enter the sorting number', enterSortingNumber: 'Please enter the sorting number',
ParentName:'Parent name', ParentName: 'Parent name',
charactersLength130:'1 - 30 characters in length', charactersLength130: '1 - 30 characters in length',
charactersLength1to300 :'1 - 300 characters in length', charactersLength1to300: '1 - 300 characters in length',
OnlyOneSelected:'Only one piece of data can be selected', OnlyOneSelected: 'Only one piece of data can be selected',
OnlyPDF:'Only PDF files can be imported', OnlyPDF: 'Only PDF files can be imported',
open:'open', open: 'open',
away:'away', away: 'away',
toDoProcess: 'To Do List', toDoProcess: 'To Do List',
processDone: 'Process done', processDone: 'Process done',
sentProcess: 'Sent process', sentProcess: 'Sent process',
monitoringProcess: 'Monitoring process', monitoringProcess: 'Monitoring process',
ConfirmDeployment:'Confirm deployment?', ConfirmDeployment: 'Confirm deployment?',
terminationProcess:'termination process', terminationProcess: 'termination process',
issue:'issue', issue: 'issue',
projectInformation:'project information', projectInformation: 'project information',
standardContent:'standard content', standardContent: 'standard content',
complianceReview:'compliance review', complianceReview: 'compliance review',
reviewResults:'review results', reviewResults: 'review results',
selectReviewResult:'Please select the review result', selectReviewResult: 'Please select the review result',
feedback:'feedback', feedback: 'feedback',
approvalHistory:'cpproval history', approvalHistory: 'cpproval history',
cannotExceed500characters:'cannot exceed 500 characters', cannotExceed500characters: 'cannot exceed 500 characters',
accord:'conformity', accord: 'conformity',
nonConformity:'non conformity', nonConformity: 'non conformity',
Tracked:'to be tracked', Tracked: 'to be tracked',
notInvolved:'Not involved', notInvolved: 'Not involved',
Operator:'operator', Operator: 'operator',
role:'role', role: 'role',
operationContent:'operation content', operationContent: 'operation content',
operationTime:'operation time', operationTime: 'operation time',
ConfirmReplication:'Confirm replication', ConfirmReplication: 'Confirm replication',
ProcessName:'Process name', ProcessName: 'Process name',
ProcessType:'Process type', ProcessType: 'Process type',
AddProcess:'Add process', AddProcess: 'Add process',
RelatedItems:'Related items', RelatedItems: 'Related items',
Sponsor:'Sponsor', Sponsor: 'Sponsor',
CurrentProcessor:'Current processor', CurrentProcessor: 'Current processor',
LastProcessor:'Last processor', LastProcessor: 'Last processor',
ProcessingTime:'Processing time', ProcessingTime: 'Processing time',
cutoffTime:'cut-off time', cutoffTime: 'cut-off time',
ProcessStatus:'Process status', ProcessStatus: 'Process status',
CompletionTime:'Completion time', CompletionTime: 'Completion time',
draft:'draft', draft: 'draft',
CannotExceed100characters:'cannot exceed 100 characters', CannotExceed100characters: 'cannot exceed 100 characters',
cantExeed:'cannot exceed ', cantExeed: 'cannot exceed ',
characters:' characters', characters: ' characters',
Processing:'Processing', Processing: 'Processing',
See:'See', See: 'See',
labelNameCannotDuplicate:'Label name cannot be duplicate', labelNameCannotDuplicate: 'Label name cannot be duplicate',
list:'list', list: 'list',
paragraph:'paragraph', paragraph: 'paragraph',
enterNumber:'please enter the number', enterNumber: 'please enter the number',
enterTitle:'Please enter a title', enterTitle: 'Please enter a title',
backDocument:'back to document library', backDocument: 'back to document library',
fileName:'file name', fileName: 'file name',
splitTime:'split time', splitTime: 'split time',
splitResult:'split result', splitResult: 'split result',
collectionTime:'collection time', collectionTime: 'collection time',
split:'split', split: 'split',
splitFile:'split file', splitFile: 'split file',
clauseName:'clause name', clauseName: 'clause name',
clauseContent:'clause content', clauseContent: 'clause content',
newClause:'new clause', newClause: 'new clause',
clauseNo:'clause No.', clauseNo: 'clause No.',
functionalAreas:'functional areas', functionalAreas: 'functional areas',
technicalField:'technical field', technicalField: 'technical field',
informationCategory:'information category', informationCategory: 'information category',
contentValidity:'content validity', contentValidity: 'content validity',
content:'content', content: 'content',
Add:'add', Add: 'add',
subscriptionTime:'subscription time', subscriptionTime: 'subscription time',
confirmBulkUnsubscribe:'Confirm bulk unsubscribe?', confirmBulkUnsubscribe: 'Confirm bulk unsubscribe?',
BatchCancelCollection:'Confirm batch cancel collection?', BatchCancelCollection: 'Confirm batch cancel collection?',
unsubscribeConfirm:'unsubscribe confirm?', unsubscribeConfirm: 'unsubscribe confirm?',
confirmCancelCollection:'confirm to cancel collection?', confirmCancelCollection: 'confirm to cancel collection?',
theRelease: 'The release date should not exceed the standard implementation date',
theRelease:'The release date should not exceed the standard implementation date' zoneOfApplication: 'zone of application',
releaseTime: 'release Time',
standardImplementationTime: 'Standard implementation time'
} }
+4 -1
View File
@@ -536,5 +536,8 @@ module.exports = {
BatchCancelCollection:'确认批量取消收藏?', BatchCancelCollection:'确认批量取消收藏?',
unsubscribeConfirm:'确认取消订阅?', unsubscribeConfirm:'确认取消订阅?',
confirmCancelCollection:'确认取消收藏?', confirmCancelCollection:'确认取消收藏?',
theRelease:'发布日期不能大于标准实施日期' theRelease:'发布日期不能大于标准实施日期',
zoneOfApplication:'适用地区',
releaseTime:'发布时间',
standardImplementationTime:'标准实施时间',
} }
@@ -11,7 +11,7 @@
<a-col :span="12" v-if="item.field_show_type === '1' || item.field_show_type === '11'"> <a-col :span="12" v-if="item.field_show_type === '1' || item.field_show_type === '11'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -26,7 +26,7 @@
<a-col :span="12" v-else-if="item.field_show_type === '2'"> <a-col :span="12" v-else-if="item.field_show_type === '2'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -41,7 +41,7 @@
<a-col :span="12" v-else-if="item.field_show_type === '3'"> <a-col :span="12" v-else-if="item.field_show_type === '3'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -58,7 +58,7 @@
<a-col :span="12" v-else-if="item.field_show_type === '4'"> <a-col :span="12" v-else-if="item.field_show_type === '4'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -73,7 +73,7 @@
<a-col :span="12" v-else-if="item.field_show_type === '5'"> <a-col :span="12" v-else-if="item.field_show_type === '5'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -91,7 +91,7 @@
<a-col :span="12" v-else-if="item.field_show_type === '6'"> <a-col :span="12" v-else-if="item.field_show_type === '6'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -106,7 +106,7 @@
<a-col :span="12" v-else-if="item.field_show_type === '7'"> <a-col :span="12" v-else-if="item.field_show_type === '7'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -126,7 +126,7 @@
<a-col :span="24" v-else-if="item.field_show_type === '8'"> <a-col :span="24" v-else-if="item.field_show_type === '8'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -141,7 +141,7 @@
<a-col :span="24" v-else-if="item.field_show_type === '9'"> <a-col :span="24" v-else-if="item.field_show_type === '9'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -155,7 +155,7 @@
<a-col :span="24" v-else-if="item.field_show_type === '10'"> <a-col :span="24" v-else-if="item.field_show_type === '10'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -171,7 +171,7 @@
<a-col :span="12" v-else-if="item.field_show_type === 'RADIO'"> <a-col :span="12" v-else-if="item.field_show_type === 'RADIO'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -187,7 +187,7 @@
<a-col :span="12" v-else-if="item.field_show_type === '0'"> <a-col :span="12" v-else-if="item.field_show_type === '0'">
<div class="box-title-text" :title="item.db_field_txt"> <div class="box-title-text" :title="item.db_field_txt">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text">{{item.db_field_txt}}</span> <span class="title-text-text">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -206,7 +206,7 @@
<a-col :span="12" v-else-if="item.field_show_type === 'CHECKBOX'"> <a-col :span="12" v-else-if="item.field_show_type === 'CHECKBOX'">
<div class="box-title-text"> <div class="box-title-text">
<div class="title-text"> <div class="title-text">
<span class="Required" v-if="item.field_must_input == 0">*</span> <span class="Required" v-if="item.field_must_input == 1">*</span>
<span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span> <span class="title-text-text" :title="item.db_field_txt">{{item.db_field_txt}}</span>
</div> </div>
<a-form-model-item class="itemModel" :prop="item.db_field_name"> <a-form-model-item class="itemModel" :prop="item.db_field_name">
@@ -373,7 +373,7 @@
let rules = {} let rules = {}
this.ruleList.forEach((res, index) => { this.ruleList.forEach((res, index) => {
const rule = [] const rule = []
if (res.field_must_input == 0) { if (res.field_must_input == 1) {
if (res.field_show_type === '1') { if (res.field_show_type === '1') {
rule.push({ rule.push({
required: true, required: true,
@@ -158,6 +158,7 @@
this.reconnect() this.reconnect()
}, },
websocketOnmessage: function(e) { websocketOnmessage: function(e) {
console.log(e)
console.log('-----接收消息-------', e.data) console.log('-----接收消息-------', e.data)
var data = eval('(' + e.data + ')') //解析对象 var data = eval('(' + e.data + ')') //解析对象
if (data.cmd == 'topic') { if (data.cmd == 'topic') {
+7 -24
View File
@@ -15,7 +15,7 @@
:remove='remove' :remove='remove'
@change="handleChange"> @change="handleChange">
<p> <p>
<a-icon style="font-size: 67px;color: #c0c4cc;" type="cloud-upload"/> <a-icon class="action-upload" type="cloud-upload"/>
</p> </p>
<p class="ant-upload-text" style="font-size: 14px;line-height: 30px">{{this.$t('clickUpload')}}</p> <p class="ant-upload-text" style="font-size: 14px;line-height: 30px">{{this.$t('clickUpload')}}</p>
</a-upload-dragger> </a-upload-dragger>
@@ -65,6 +65,7 @@
} }
}, },
beforeUpload(file) { beforeUpload(file) {
console.log(file) console.log(file)
// let thisFileType = this.thisFileType.replace(/\s+/g, ""); // let thisFileType = this.thisFileType.replace(/\s+/g, "");
this.fileTypeSatus = true this.fileTypeSatus = true
@@ -92,29 +93,6 @@
remove() { remove() {
this.fileTypeSatus = true this.fileTypeSatus = true
}, },
mydownload(item) {
var fileName = item.fileName
downFile(this.downLoadFileUrl + '/' + item.ext1, {}).then((data) => {
if (!data) {
this.$message.destroy()
this.$message.warning('文件下载失败')
return
}
if (typeof window.navigator.msSaveBlob !== 'undefined') {
window.navigator.msSaveBlob(new Blob([data], { type: 'application/vnd.ms-excel' }), fileName)
} else {
let url = window.URL.createObjectURL(new Blob([data], { type: 'application/vnd.ms-excel' }))
let link = document.createElement('a')
link.style.display = 'none'
link.href = url
link.setAttribute('download', fileName)
document.body.appendChild(link)
link.click()
document.body.removeChild(link) //下载完成移除元素
window.URL.revokeObjectURL(url) //释放掉blob对象
}
})
},
mypreview(item) { mypreview(item) {
let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + encodeURIComponent(this.downLoadFileUrl + '/' + item.ext1) let url = window._CONFIG['onlinePreviewDomainURL'] + '?url=' + encodeURIComponent(this.downLoadFileUrl + '/' + item.ext1)
window.open(url, '_blank') window.open(url, '_blank')
@@ -221,4 +199,9 @@
.ant-upload-list-item-name { .ant-upload-list-item-name {
color: rgba(0, 0, 0, 0.65) !important; color: rgba(0, 0, 0, 0.65) !important;
} }
.action-upload {
font-size: 67px;
color: #c0c4cc;
}
</style> </style>
+29 -7
View File
@@ -72,14 +72,36 @@ const err = (error) => {
notification.error({ message: '系统提示', description: '网络超时' }) notification.error({ message: '系统提示', description: '网络超时' })
break break
case 401: case 401:
notification.error({ message: '系统提示', description: '未授权,请重新登录', duration: 4 }) if (token && data.message.includes('Token失效')) {
if (token) { Modal.error({
store.dispatch('Logout').then(() => { title: '登录已过期',
setTimeout(() => { content: '很抱歉,登录已过期,请重新登录',
window.location.reload() okText: '重新登录',
}, 1500) mask: false,
onOk: () => {
store.dispatch('Logout').then(() => {
Vue.ls.remove(ACCESS_TOKEN)
try {
let path = window.document.location.pathname
console.log('location pathname -> ' + path)
if (path != '/' && path.indexOf('/user/login') == -1) {
window.location.reload()
}
} catch (e) {
window.location.reload()
}
})
}
}) })
} }
// notification.error({ message: '系统提示', description: '未授权,请重新登录', duration: 4 })
// if (token) {
// store.dispatch('Logout').then(() => {
// setTimeout(() => {
// window.location.reload()
// }, 1500)
// })
// }
break break
default: default:
notification.error({ notification.error({
@@ -121,7 +143,7 @@ service.interceptors.request.use(config => {
...config.params ...config.params
} }
} }
} else if((config.method == 'post')) { } else if ((config.method == 'post')) {
config.data = { config.data = {
cut: cut, cut: cut,
...config.data ...config.data
@@ -40,11 +40,21 @@
ref="table" ref="table"
size="middle" size="middle"
bordered bordered
:scroll="{x: true}"
rowKey="id" rowKey="id"
:data-source="tableData" :data-source="tableData"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }" :row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:columns="columns" :columns="columns"
> >
<span slot="operation" slot-scope="record">
<a @click="Collection(record)" class="text-operation">
{{!record.collectFlag || record.collectFlag == 0 ? $t('Collection') :$t('CancelCollection')}}
</a>
<a @click="subscribe(record)" class="text-operation">
{{!record.subscribeFlag || record.subscribeFlag == 0 ? $t('subscribe') :$t('CancelSubscribe')}}
</a>
<a> {{$t('Push')}}</a>
</span>
<!-- 字符串超长截取省略号显示--> <!-- 字符串超长截取省略号显示-->
<!-- <span slot="templateContent" slot-scope="text">--> <!-- <span slot="templateContent" slot-scope="text">-->
<!-- <j-ellipsis :value="text" :length="25"/>--> <!-- <j-ellipsis :value="text" :length="25"/>-->
@@ -85,12 +95,22 @@
</div> </div>
</div> </div>
</div> </div>
<libraryPush
:url="url"
ref="libraryPushRef"
/>
</div> </div>
</template> </template>
<script> <script>
import eventBUs from '../../../../common/event'
import { getAction, postAction } from '@/api/manage'
import libraryPush from '@/components/libraryPush/index'
export default { export default {
name: 'DocumentLibrary', name: 'DocumentLibrary',
components:{
libraryPush
},
data() { data() {
return { return {
searchOption: [ searchOption: [
@@ -201,43 +221,61 @@
} }
], ],
tableData: [], tableData: [],
url:{
pullMessage: 'document/bussDocumentLibraryEO/pullMessage',//推送
},
columns: [ columns: [
{ {
title: '编号', title: this.$t('standard'),
align: 'center', align: 'center',
dataIndex: 'templateCode' dataIndex: 'templateCode'
}, },
{ {
title: '标题', title: this.$t('title'),
align: 'center', align: 'center',
dataIndex: 'templateName' dataIndex: 'templateName'
}, },
{ {
title: '文件名称', title: this.$t('fileName'),
align: 'center', align: 'center',
dataIndex: 'template' dataIndex: 'template'
}, },
{ {
title: '状态', title: this.$t('status'),
align: 'center', align: 'center',
dataIndex: 'templateCon', dataIndex: 'templateCon'
sorter: (a, b) => a.age - b.age
}, },
{ {
title: '适用地区', title: this.$t('zoneOfApplication'),
align: 'center', align: 'center',
dataIndex: 'templateCont', dataIndex: 'templateCont'
sorter: (a, b) => a.age - b.age
}, },
{ {
title: '功能领域', title: this.$t('functionalAreas'),
align: 'center', align: 'center',
dataIndex: 'templateContent1' dataIndex: 'templateContent1'
}, },
{ {
title: '技术领域', title: this.$t('technicalField'),
align: 'center', align: 'center',
dataIndex: 'templateContent2' dataIndex: 'templateContent2'
},
{
title: this.$t('releaseTime'),
align: 'center',
dataIndex: 'releaseTime'
},
{
title: this.$t('standardImplementationTime'),
align: 'center',
dataIndex: 'standardImplementationTime'
},
{
title: this.$t('operation'),
align: 'center',
fixed: 'right',
width: 200,
scopedSlots: { customRender: 'operation' }
} }
], ],
selectedRowKeys: [], selectedRowKeys: [],
@@ -330,11 +368,72 @@
SizeChange(page, pageSize) { SizeChange(page, pageSize) {
this.pageNo = 1 this.pageNo = 1
this.pageSize = pageSize this.pageSize = pageSize
},
//收藏按钮
Collection(val) {
let _this = this
this.$confirm({
content: val.collectFlag == 0 || !val.collectFlag ? _this.$t('ConfirmCollection') : _this.$t('cancelConfirmCollection'),
onOk() {
let url = ''
if (val.collectFlag == 0 || !val.collectFlag) {
url = 'document/bussDocumentLibraryEO/addCollect'
} else {
url = 'document/bussDocumentLibraryEO/cancelCollect'
}
getAction(url, { id: val.id }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
} else {
_this.$message.warning(_this.$t('operationFailed'))
}
})
}
})
},
//订阅按钮
subscribe(val) {
let _this = this
this.$confirm({
content: val.subscribeFlag == 0 || !val.subscribeFlag ? _this.$t('ConfirmSubscribe') : _this.$t('cancelConfirmSubscribe'),
onOk() {
let url = ''
if (val.subscribeFlag == 0 || !val.subscribeFlag) {
url = 'document/bussDocumentLibraryEO/addSubscribe'
} else {
url = 'document/bussDocumentLibraryEO/cancelSubscribe'
}
getAction(url, { id: val.id }).then((res) => {
if (res.success) {
_this.$message.success(_this.$t('OperationSuccessful'))
} else {
_this.$message.warning(_this.$t('operationFailed'))
}
})
}
})
},
//推送
handleCompare(val) {
let item = JSON.parse(JSON.stringify(val))
this.$nextTick(() => {
this.$refs.libraryPushRef.visible = true
this.$refs.libraryPushRef.tableKey = item.id.split(',')
})
} }
} }
} }
</script> </script>
<style> <style>
.table .ant-table-column-title {
font-weight: bold;
}
.ant-table td {
white-space: nowrap;
}
.checkbox-left .ant-checkbox-inner { .checkbox-left .ant-checkbox-inner {
width: 18px !important; width: 18px !important;
height: 18px !important; height: 18px !important;
@@ -495,8 +594,13 @@
padding: 0 0 0 8px; padding: 0 0 0 8px;
box-sizing: border-box; box-sizing: border-box;
} }
.page { .page {
text-align: right; text-align: right;
margin-top: 20px; margin-top: 20px;
} }
.text-operation {
margin-right: 8px;
}
</style> </style>