修改禅道已知bug
This commit is contained in:
@@ -105,7 +105,7 @@
|
|||||||
<a class="text-operation" v-if="record.gatherResult == 'Completed'"
|
<a class="text-operation" v-if="record.gatherResult == 'Completed'"
|
||||||
@click="evaluationResultsClick(record)">{{$t('evaluationResults')}}</a>
|
@click="evaluationResultsClick(record)">{{$t('evaluationResults')}}</a>
|
||||||
<a class="text-operation"
|
<a class="text-operation"
|
||||||
v-if="record.gatherResult == 'Completed'"
|
v-if="(record.gatherResult == 'Completed' && userInfoQuery.username == record.createBy) || administrators"
|
||||||
v-has="'regulatoryComments:delete'"
|
v-has="'regulatoryComments:delete'"
|
||||||
@click="deleteData(record)">{{$t('delete')}}</a>
|
@click="deleteData(record)">{{$t('delete')}}</a>
|
||||||
</span>
|
</span>
|
||||||
@@ -130,6 +130,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import evaluationResultsList from './components/evaluationResultsList'
|
import evaluationResultsList from './components/evaluationResultsList'
|
||||||
import { getAction, postAction, deleteAction } from '@/api/manage'
|
import { getAction, postAction, deleteAction } from '@/api/manage'
|
||||||
|
import { mapGetters } from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'index',
|
name: 'index',
|
||||||
@@ -144,6 +145,7 @@
|
|||||||
getSysCategoryTree: '/sys/category/getSysCategoryTree',
|
getSysCategoryTree: '/sys/category/getSysCategoryTree',
|
||||||
deleteBatch: '/lawsOpinionGather/lawsOpinionGatherEO/deleteBatch'
|
deleteBatch: '/lawsOpinionGather/lawsOpinionGatherEO/deleteBatch'
|
||||||
},
|
},
|
||||||
|
userInfoQuery: {},
|
||||||
loading: false,
|
loading: false,
|
||||||
toggleSearchStatus: false,
|
toggleSearchStatus: false,
|
||||||
dataSource: [],
|
dataSource: [],
|
||||||
@@ -216,14 +218,25 @@
|
|||||||
width: 320,
|
width: 320,
|
||||||
scopedSlots: { customRender: 'operation' }
|
scopedSlots: { customRender: 'operation' }
|
||||||
}
|
}
|
||||||
]
|
],
|
||||||
|
administrators: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getList()
|
this.getList()
|
||||||
this.getSysCategoryTree()
|
this.getSysCategoryTree()
|
||||||
|
this.administrators = false
|
||||||
|
this.userInfoQuery = this.userInfo()
|
||||||
|
if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) {
|
||||||
|
this.userInfo().userRoleList.forEach(res => {
|
||||||
|
if (res.roleCode == 'admin') {
|
||||||
|
this.administrators = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
...mapGetters(['userInfo']),
|
||||||
getSysCategoryTree() {
|
getSysCategoryTree() {
|
||||||
getAction(this.url.getSysCategoryTree, {}).then((res) => {
|
getAction(this.url.getSysCategoryTree, {}).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
@@ -234,7 +247,7 @@
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
BatchDelete() {
|
BatchDelete() {
|
||||||
if (this.selectedRowKeys.length > 0) {
|
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
|
||||||
let _this = this
|
let _this = this
|
||||||
this.$confirm({
|
this.$confirm({
|
||||||
content: _this.$t('ConfirmBatchDeletion'),
|
content: _this.$t('ConfirmBatchDeletion'),
|
||||||
@@ -242,7 +255,8 @@
|
|||||||
let idList = []
|
let idList = []
|
||||||
let selectedRowKeysRecord = JSON.parse(JSON.stringify(_this.selectedRowKeysRecord))
|
let selectedRowKeysRecord = JSON.parse(JSON.stringify(_this.selectedRowKeysRecord))
|
||||||
for (let i = 0; i < selectedRowKeysRecord.length; i++) {
|
for (let i = 0; i < selectedRowKeysRecord.length; i++) {
|
||||||
if (selectedRowKeysRecord[i].gatherResult == 'Completed') {
|
if ((selectedRowKeysRecord[i].gatherResult == 'Completed' &&
|
||||||
|
selectedRowKeysRecord[i].createBy == this.userInfo().username) || this.administrators) {
|
||||||
idList.push(selectedRowKeysRecord[i].id)
|
idList.push(selectedRowKeysRecord[i].id)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -257,7 +271,7 @@
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
_this.$message.warning(_this.$t('onlyCompletedDataCanBeDeleted'))
|
_this.$message.warning(_this.$t('doNotHavePermissionDeleteData'))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -106,7 +106,7 @@
|
|||||||
<a class="text-operation" v-if="record.flowStatus == 'Completed'"
|
<a class="text-operation" v-if="record.flowStatus == 'Completed'"
|
||||||
@click="evaluationResultsClick(record)">{{$t('evaluationResults')}}</a>
|
@click="evaluationResultsClick(record)">{{$t('evaluationResults')}}</a>
|
||||||
<a class="text-operation"
|
<a class="text-operation"
|
||||||
v-if="record.flowStatus == 'Completed'"
|
v-if="(record.flowStatus == 'Completed' && userInfoQuery.username == record.createBy) || administrators"
|
||||||
v-has="'regulatoryAndTechnicalAssessment:delete'"
|
v-has="'regulatoryAndTechnicalAssessment:delete'"
|
||||||
@click="deleteData(record)">{{$t('delete')}}</a>
|
@click="deleteData(record)">{{$t('delete')}}</a>
|
||||||
</span>
|
</span>
|
||||||
@@ -166,8 +166,9 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { getAction, postAction ,deleteAction} from '@/api/manage'
|
import { getAction, postAction, deleteAction } from '@/api/manage'
|
||||||
import processInformation from './components/processInformation'
|
import processInformation from './components/processInformation'
|
||||||
|
import { mapGetters } from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'index',
|
name: 'index',
|
||||||
@@ -180,14 +181,14 @@
|
|||||||
url: {
|
url: {
|
||||||
list: '/lawsTechnologyEvaluation/lawsTechnologyEvaluationEO/page',
|
list: '/lawsTechnologyEvaluation/lawsTechnologyEvaluationEO/page',
|
||||||
getSysCategoryTree: '/sys/category/getSysCategoryTree',
|
getSysCategoryTree: '/sys/category/getSysCategoryTree',
|
||||||
deleteBatch:'/lawsTechnologyEvaluation/lawsTechnologyEvaluationEO/deleteBatch',
|
deleteBatch: '/lawsTechnologyEvaluation/lawsTechnologyEvaluationEO/deleteBatch'
|
||||||
},
|
},
|
||||||
visible: false,
|
visible: false,
|
||||||
loading: false,
|
loading: false,
|
||||||
toggleSearchStatus: false,
|
toggleSearchStatus: false,
|
||||||
dataSource: [],
|
dataSource: [],
|
||||||
selectedRowKeys: [],
|
selectedRowKeys: [],
|
||||||
selectedRowKeysRecord:[],
|
selectedRowKeysRecord: [],
|
||||||
serialNumber: '',
|
serialNumber: '',
|
||||||
total: 0,
|
total: 0,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
@@ -288,14 +289,26 @@
|
|||||||
width: 320,
|
width: 320,
|
||||||
scopedSlots: { customRender: 'operation' }
|
scopedSlots: { customRender: 'operation' }
|
||||||
}
|
}
|
||||||
]
|
],
|
||||||
|
userInfoQuery: {},
|
||||||
|
administrators: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getList()
|
this.getList()
|
||||||
this.getSysCategoryTree()
|
this.getSysCategoryTree()
|
||||||
|
this.userInfoQuery = this.userInfo()
|
||||||
|
this.administrators = false
|
||||||
|
if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) {
|
||||||
|
this.userInfo().userRoleList.forEach(res => {
|
||||||
|
if (res.roleCode == 'admin') {
|
||||||
|
this.administrators = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
...mapGetters(['userInfo']),
|
||||||
getSysCategoryTree() {
|
getSysCategoryTree() {
|
||||||
getAction(this.url.getSysCategoryTree, {}).then((res) => {
|
getAction(this.url.getSysCategoryTree, {}).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
@@ -330,7 +343,8 @@
|
|||||||
let idList = []
|
let idList = []
|
||||||
let selectedRowKeysRecord = JSON.parse(JSON.stringify(_this.selectedRowKeysRecord))
|
let selectedRowKeysRecord = JSON.parse(JSON.stringify(_this.selectedRowKeysRecord))
|
||||||
for (let i = 0; i < selectedRowKeysRecord.length; i++) {
|
for (let i = 0; i < selectedRowKeysRecord.length; i++) {
|
||||||
if (selectedRowKeysRecord[i].flowStatus == 'Completed') {
|
if ((selectedRowKeysRecord[i].flowStatus == 'Completed' && selectedRowKeysRecord[i].createBy == this.userInfo().username)
|
||||||
|
|| this.administrators) {
|
||||||
idList.push(selectedRowKeysRecord[i].id)
|
idList.push(selectedRowKeysRecord[i].id)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -406,7 +420,7 @@
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
onSelectChange(value,record) {
|
onSelectChange(value, record) {
|
||||||
this.selectedRowKeys = value
|
this.selectedRowKeys = value
|
||||||
this.selectedRowKeysRecord = record
|
this.selectedRowKeysRecord = record
|
||||||
},
|
},
|
||||||
@@ -530,12 +544,13 @@
|
|||||||
color: red;
|
color: red;
|
||||||
margin-right: 4px;
|
margin-right: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
::v-deep .ant-table-row:first-child {
|
::v-deep .ant-table-row:first-child {
|
||||||
background: #fff!important;
|
background: #fff !important;
|
||||||
opacity: 0.9;
|
opacity: 0.9;
|
||||||
}
|
}
|
||||||
|
|
||||||
::v-deep .ant-table-body {
|
::v-deep .ant-table-body {
|
||||||
background: transparent!important;
|
background: transparent !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -106,7 +106,7 @@
|
|||||||
class="taskTable"
|
class="taskTable"
|
||||||
:loading="loading"
|
:loading="loading"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
:scroll="{x: true}"
|
:scroll="{x: true,y:'calc(100vh - 335px)'}"
|
||||||
:data-source="dataSource"
|
:data-source="dataSource"
|
||||||
rowKey="id"
|
rowKey="id"
|
||||||
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
|
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
|
||||||
|
|||||||
Reference in New Issue
Block a user