Merge branch 'hi-ucs-dev' of http://192.168.124.50:80/wuhongjian/hi-ucs into hi-ucs-dev

This commit is contained in:
gongjiale 2022-10-19 11:46:47 +08:00
commit 906a2aad94
1 changed files with 25 additions and 4 deletions

View File

@ -140,9 +140,12 @@
<span v-if='this.choseId===0' :class="[departmentId===4?'departmentStyle':'']" @click="handleChose(4)"> <span v-if='this.choseId===0' :class="[departmentId===4?'departmentStyle':'']" @click="handleChose(4)">
能力使用明细 能力使用明细
</span> --> </span> -->
<span v-if="detailFlag" class="detail-button" @click="goToDetail()"> <template v-if="detailFlag">
明细 <el-checkbox v-model="checked" @change='chagneCheckbox' style="position: absolute;right: 150px;margin-top: -15px;">隐藏空数据</el-checkbox>
</span> <span class="detail-button" @click="goToDetail()">
明细
</span>
</template>
<span v-else class="detail-button" @click="goToBack()"> 返回 </span> <span v-else class="detail-button" @click="goToBack()"> 返回 </span>
</div> </div>
<div class="line-style"></div> <div class="line-style"></div>
@ -287,6 +290,7 @@ import AbilityDetail from './components/abilityDetails'
import applicationResources from './applicationResources.vue' import applicationResources from './applicationResources.vue'
import ComponentUsed from './componentUsed.vue' import ComponentUsed from './componentUsed.vue'
import qs from 'qs' import qs from 'qs'
import Template from '../devtools/template.vue'
// import { mapState } from 'vuex' // import { mapState } from 'vuex'
// const props = defineProps({ // const props = defineProps({
// processDefinitionName: { type: String, default: null }, // processDefinitionName: { type: String, default: null },
@ -297,9 +301,10 @@ import qs from 'qs'
// showType: { type: String, default: null }, // showType: { type: String, default: null },
// }) // })
export default { export default {
components: { componentServices, applicationResources, ComponentUsed, AbilityDetail }, components: { componentServices, applicationResources, ComponentUsed, AbilityDetail, Template },
data () { data () {
return { return {
checked: false,
departmentSelects: [], departmentSelects: [],
exportExcel: CONFIGITEM.configData[CONFIGITEM.version].apiURL + '/census/center/export', exportExcel: CONFIGITEM.configData[CONFIGITEM.version].apiURL + '/census/center/export',
exportExcelCondition: '', exportExcelCondition: '',
@ -391,6 +396,7 @@ export default {
{ name: '会议室', value: 6 } { name: '会议室', value: 6 }
], ],
tableData: [], tableData: [],
tableDataClone: [],
tableData2: [ tableData2: [
{ {
approveStatus: '', approveStatus: '',
@ -456,6 +462,15 @@ export default {
// ...mapState(['departmentSelects']) // ...mapState(['departmentSelects'])
}, },
methods: { methods: {
chagneCheckbox () {
if (this.checked) {
this.tableData = this.tableDataClone.filter(val => val.count !== 0)
this.total = this.tableData.length
} else {
this.tableData = this.tableDataClone
this.total = this.tableData.length
}
},
closeModal () { closeModal () {
this.detailsVisible = false this.detailsVisible = false
}, },
@ -550,6 +565,7 @@ export default {
parseInt(result[i].hys) parseInt(result[i].hys)
} }
this.tableData = res.data.data this.tableData = res.data.data
this.tableDataClone = res.data.data
this.total = res.data.data.total this.total = res.data.data.total
this.exportExcelCondition = qs.stringify({ this.exportExcelCondition = qs.stringify({
approveStatus: this.status, approveStatus: this.status,
@ -614,6 +630,7 @@ export default {
parseInt(result[i].hys) parseInt(result[i].hys)
} }
this.tableData = res.data.data this.tableData = res.data.data
this.tableDataClone = res.data.data
this.total = res.data.data.total this.total = res.data.data.total
this.exportExcelCondition = qs.stringify({ this.exportExcelCondition = qs.stringify({
approveStatus: this.status, approveStatus: this.status,
@ -694,6 +711,7 @@ export default {
.then((res) => { .then((res) => {
console.log('111111', this.tableData, res.data.data) console.log('111111', this.tableData, res.data.data)
this.tableData = res.data.data this.tableData = res.data.data
this.tableDataClone = res.data.data
this.total = res.data.data.total this.total = res.data.data.total
this.exportExcelCondition = qs.stringify({ this.exportExcelCondition = qs.stringify({
approveStatus: this.status, approveStatus: this.status,
@ -731,6 +749,7 @@ export default {
}) })
.then((res) => { .then((res) => {
this.tableData = res.data.data this.tableData = res.data.data
this.tableDataClone = res.data.data
this.total = res.data.data.total this.total = res.data.data.total
this.exportExcelCondition = qs.stringify({ this.exportExcelCondition = qs.stringify({
approveStatus: this.status, approveStatus: this.status,
@ -838,6 +857,7 @@ export default {
// }, // },
// or使 // or使
handleChose (index) { handleChose (index) {
this.checked = false
this.departmentId = index this.departmentId = index
if (index === 1) { if (index === 1) {
if (this.choseId === 0) { if (this.choseId === 0) {
@ -910,6 +930,7 @@ export default {
}, },
// //
goToBack () { goToBack () {
this.checked = false
// departmentId 13 24 // departmentId 13 24
this.detailFlag = !this.detailFlag this.detailFlag = !this.detailFlag
if (this.departmentId === 3) { if (this.departmentId === 3) {