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

This commit is contained in:
unknown 2022-10-28 15:27:07 +08:00
commit dd38eba69b
46 changed files with 7416 additions and 6533 deletions

3
.gitignore vendored
View File

@ -9,4 +9,5 @@ front/public/index.html
back/dist-西海岸-后台管理-v0.8.2.1.zip back/dist-西海岸-后台管理-v0.8.2.1.zip
back/dist-市局-后台管理-v0.8.2.3.zip back/dist-市局-后台管理-v0.8.2.3.zip
back/dist-西海岸-后台管理-v0.8.2.4.d.zip back/dist-西海岸-后台管理-v0.8.2.4.d.zip
*.zip *.zip
front/public/static/config/basicConfig.js

View File

@ -1,8 +1,8 @@
/* /*
* @Author: hisense.wuhongjian * @Author: hisense.wuhongjian
* @Date: 2022-08-25 14:37:49 * @Date: 2022-08-25 14:37:49
* @LastEditors: hisense.wuhongjian * @LastEditors: Light
* @LastEditTime: 2022-10-13 16:46:41 * @LastEditTime: 2022-10-26 10:48:52
* @Description: 告诉大家这是什么 * @Description: 告诉大家这是什么
*/ */
var _global = {} var _global = {}
@ -43,8 +43,8 @@ var CONFIGITEM = {
}, },
dev: { dev: {
previewUrl: 'http://localhost:8080/', previewUrl: 'http://localhost:8080/',
apiURL: 'http://192.168.124.233:8888/renren-admin', apiURL: 'http://192.168.124.243:8888/renren-admin',
websocketURL: 'ws://192.168.124.236:8888/renren-admin/websocket' websocketURL: 'ws://192.168.124.243:8888/renren-admin/websocket'
} }
} }
} }

View File

@ -1,42 +1,37 @@
<template> <template>
<div> <div>
<el-input v-model="showDeptName" :placeholder="placeholder" @focus="deptDialog"> <el-input v-model="showDeptName" :placeholder="placeholder" @focus="deptDialog" readonly
<el-button slot="append" icon="el-icon-search" @click="deptDialog"></el-button> @paste.native.capture.prevent="handlePaste">
</el-input> <el-button slot="append" icon="el-icon-search" @click="deptDialog"></el-button>
<el-input :value="value" style="display: none"></el-input> </el-input>
<el-dialog :visible.sync="visibleDept" width="30%" :modal="false" :title="placeholder" :close-on-click-modal="false" :close-on-press-escape="false"> <el-input :value="value" style="display: none"></el-input>
<el-form size="mini" :inline="true"> <el-dialog :visible.sync="visibleDept" width="30%" :modal="false" :title="placeholder" :close-on-click-modal="false"
<el-form-item :label="$t('keyword')"> :close-on-press-escape="false">
<el-input v-model="filterText"></el-input> <el-form size="mini" :inline="true">
</el-form-item> <el-form-item :label="$t('keyword')">
<el-form-item> <el-input v-model="filterText"></el-input>
<!-- <el-button type="default">{{ $t('query') }}</el-button> --> </el-form-item>
<el-button type="default">{{ $t('query') }}</el-button> <el-form-item>
</el-form-item> <!-- <el-button type="default">{{ $t('query') }}</el-button> -->
</el-form> <el-button type="default">{{ $t('query') }}</el-button>
<el-tree </el-form-item>
class="filter-tree" </el-form>
:data="deptList" <el-tree class="filter-tree" :data="deptList" :default-expanded-keys="expandedKeys"
:default-expanded-keys="expandedKeys" :props="{ label: 'name', children: 'children' }" :expand-on-click-node="false" :filter-node-method="filterNode"
:props="{ label: 'name', children: 'children' }" :highlight-current="true" node-key="id" ref="tree">
:expand-on-click-node="false" </el-tree>
:filter-node-method="filterNode" <template slot="footer">
:highlight-current="true" <el-button type="default" @click="cancelHandle()" size="mini">{{ $t('cancel') }}</el-button>
node-key="id" <el-button v-if="query" type="info" @click="clearHandle()" size="mini">{{ $t('clear') }}</el-button>
ref="tree"> <el-button type="primary" @click="commitHandle()" size="mini">{{ $t('confirm') }}</el-button>
</el-tree> </template>
<template slot="footer"> </el-dialog>
<el-button type="default" @click="cancelHandle()" size="mini">{{ $t('cancel') }}</el-button>
<el-button v-if="query" type="info" @click="clearHandle()" size="mini">{{ $t('clear') }}</el-button>
<el-button type="primary" @click="commitHandle()" size="mini">{{ $t('confirm') }}</el-button>
</template>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
name: 'RenDeptTree', name: 'RenDeptTree',
data () { data() {
return { return {
filterText: '', filterText: '',
visibleDept: false, visibleDept: false,
@ -56,15 +51,23 @@ export default {
placeholder: String placeholder: String
}, },
watch: { watch: {
filterText (val) { filterText(val) {
this.$refs.tree.filter(val) this.$refs.tree.filter(val)
}, },
deptName (val) { deptName(val) {
this.showDeptName = val this.showDeptName = val
},
visibleDept(val) {
if (!val) {
this.filterText = ''
}
} }
}, },
methods: { methods: {
deptDialog () { handlePaste() {
return false
},
deptDialog() {
this.expandedKeys = null this.expandedKeys = null
if (this.$refs.tree) { if (this.$refs.tree) {
this.$refs.tree.setCurrentKey(null) this.$refs.tree.setCurrentKey(null)
@ -72,11 +75,11 @@ export default {
this.visibleDept = true this.visibleDept = true
this.getDeptList(this.value) this.getDeptList(this.value)
}, },
filterNode (value, data) { filterNode(value, data) {
if (!value) return true if (!value) return true
return data.name.indexOf(value) !== -1 return data.name.indexOf(value) !== -1
}, },
getDeptList (id) { getDeptList(id) {
return this.$http.get('/sys/dept/list').then(({ data: res }) => { return this.$http.get('/sys/dept/list').then(({ data: res }) => {
if (res.code !== 0) { if (res.code !== 0) {
return this.$message.error(res.msg) return this.$message.error(res.msg)
@ -86,14 +89,14 @@ export default {
this.$refs.tree.setCurrentKey(id) this.$refs.tree.setCurrentKey(id)
this.expandedKeys = [id] this.expandedKeys = [id]
}) })
}).catch(() => {}) }).catch(() => { })
}, },
cancelHandle () { cancelHandle() {
this.visibleDept = false this.visibleDept = false
this.deptList = [] this.deptList = []
this.filterText = '' this.filterText = ''
}, },
clearHandle () { clearHandle() {
this.$emit('input', '') this.$emit('input', '')
this.$emit('update:deptName', '') this.$emit('update:deptName', '')
this.showDeptName = '' this.showDeptName = ''
@ -101,7 +104,7 @@ export default {
this.deptList = [] this.deptList = []
this.filterText = '' this.filterText = ''
}, },
commitHandle () { commitHandle() {
const node = this.$refs.tree.getCurrentNode() const node = this.$refs.tree.getCurrentNode()
if (!node) { if (!node) {
this.$message.error(this.$t('dept.chooseerror')) this.$message.error(this.$t('dept.chooseerror'))

View File

@ -1,8 +1,8 @@
<!-- <!--
* @Author: hisense.wuhongjian * @Author: hisense.wuhongjian
* @Date: 2022-04-11 16:30:04 * @Date: 2022-04-11 16:30:04
* @LastEditors: hisense.liangjunhua * @LastEditors: Light
* @LastEditTime: 2022-07-16 15:07:44 * @LastEditTime: 2022-10-26 11:05:07
* @Description: 告诉大家这是什么 * @Description: 告诉大家这是什么
--> -->
<template> <template>
@ -31,7 +31,7 @@
<!-- 审核意见 --> <!-- 审核意见 -->
<el-table-column prop="comment" :label="$t('process.comment')" header-align="center" align="center"></el-table-column> <el-table-column prop="comment" :label="$t('process.comment')" header-align="center" align="center"></el-table-column>
<!-- 任务时长 --> <!-- 任务时长 -->
<el-table-column prop="durationInSeconds" :label="$t('task.durationInSeconds')" header-align="center" align="center" width="180"></el-table-column> <el-table-column prop="duration" :label="$t('task.durationInSeconds')" header-align="center" align="center" width="180"></el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination
v-if="dataForm.pid === '0'" v-if="dataForm.pid === '0'"

View File

@ -41,7 +41,8 @@
</el-menu-item> --> </el-menu-item> -->
</el-menu> </el-menu>
<el-menu class="aui-navbar__menu" mode="horizontal"> <el-menu class="aui-navbar__menu" mode="horizontal">
<el-menu-item index="1"> <!-- 暂时隐藏切换语言--勿删 -->
<!-- <el-menu-item index="1">
<el-dropdown placement="bottom" :show-timeout="0"> <el-dropdown placement="bottom" :show-timeout="0">
<el-button size="mini">{{ $t("_lang") }}</el-button> <el-button size="mini">{{ $t("_lang") }}</el-button>
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
@ -53,14 +54,14 @@
> >
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>
</el-menu-item> </el-menu-item> -->
<el-menu-item index="2"> <!-- <el-menu-item index="2">
<a href="//115.28.200.119:9091" target="_blank"> <a href="//115.28.200.119:9091" target="_blank">
<svg class="icon-svg aui-navbar__icon-menu" aria-hidden="true"> <svg class="icon-svg aui-navbar__icon-menu" aria-hidden="true">
<use xlink:href="#icon-earth"></use> <use xlink:href="#icon-earth"></use>
</svg> </svg>
</a> </a>
</el-menu-item> </el-menu-item> -->
<el-menu-item index="3" v-if="$hasPermission('sys:notice:all')"> <el-menu-item index="3" v-if="$hasPermission('sys:notice:all')">
<el-badge :is-dot="messageTip"> <el-badge :is-dot="messageTip">
<a href="#" @click="myNoticeRouter()" <a href="#" @click="myNoticeRouter()"

View File

@ -8,11 +8,11 @@
--> -->
<template> <template>
<div class="aui-theme-tools" :class="{ 'aui-theme-tools--open': isOpen }"> <div class="aui-theme-tools" :class="{ 'aui-theme-tools--open': isOpen }">
<div class="aui-theme-tools__toggle" @click="isOpen = !isOpen"> <!-- <div class="aui-theme-tools__toggle" @click="isOpen = !isOpen">
<svg class="icon-svg" aria-hidden="true"> <svg class="icon-svg" aria-hidden="true">
<use xlink:href="#icon-setting"></use> <use xlink:href="#icon-setting"></use>
</svg> </svg>
</div> </div> -->
<div class="aui-theme-tools__content"> <div class="aui-theme-tools__content">
<div class="aui-theme-tools__item"> <div class="aui-theme-tools__item">
<h3>Navbar</h3> <h3>Navbar</h3>

View File

@ -1,5 +1,6 @@
<template> <template>
<el-dialog <el-dialog
width="70%"
:destroy-on-close="true" :destroy-on-close="true"
:close-on-click-modal="false" :close-on-click-modal="false"
@close="closeModal" @close="closeModal"
@ -96,7 +97,7 @@
</template> </template>
</template> </template>
</a-table> --> </a-table> -->
<el-table <el-table
:data="dataSource.data[0][1]" :data="dataSource.data[0][1]"
style="width: 100%"> style="width: 100%">
<el-table-column <el-table-column
@ -104,6 +105,11 @@
label="任务名称" label="任务名称"
width="180"> width="180">
</el-table-column> </el-table-column>
<el-table-column
prop="assigneeDeptName"
label="处理人部门"
width="200">
</el-table-column>
<el-table-column <el-table-column
prop="assigneeName" prop="assigneeName"
label="处理人" label="处理人"
@ -136,132 +142,131 @@
</div> --> </div> -->
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
export default { export default {
props: { props: {
detailType: { detailType: {
type: String, type: String,
default: "", default: ''
}, },
detailsVisible: { detailsVisible: {
type: Boolean, type: Boolean,
default: false, default: false
}, },
detailParamss: { detailParamss: {
type: Object, type: Object,
default: {}, default: {}
}, }
}, },
watch: { watch: {
detailsVisible: { detailsVisible: {
handler(newVal) { handler (newVal) {
this.detailsVisibleCopy = newVal; this.detailsVisibleCopy = newVal
}, },
immediate: true, immediate: true
}, },
detailParamss: { detailParamss: {
handler(newVal) { handler (newVal) {
this.detailParams = newVal; this.detailParams = newVal
this.getDetail(newVal); this.getDetail(newVal)
}, },
immediate: true, immediate: true
}, }
}, },
data() { data () {
return { return {
detailsVisibleCopy: false, detailsVisibleCopy: false,
columns: [ columns: [
{ {
title: "任务名称", title: '任务名称',
dataIndex: "activityName", dataIndex: 'activityName',
key: "activityName", key: 'activityName'
}, },
{ {
title: "处理人", title: '处理人',
dataIndex: "assigneeName", dataIndex: 'assigneeName',
key: "assigneeName", key: 'assigneeName'
}, },
{ {
title: "任务开始时间", title: '任务开始时间',
dataIndex: "startTime", dataIndex: 'startTime',
key: "startTime", key: 'startTime'
}, },
{ {
title: "任务结束时间", title: '任务结束时间',
dataIndex: "endTime", dataIndex: 'endTime',
key: "endTime", key: 'endTime'
}, },
{ {
title: "审核意见", title: '审核意见',
dataIndex: "comment", dataIndex: 'comment',
key: "comment", key: 'comment'
}, },
{ {
title: "任务时长/秒", title: '任务时长/秒',
dataIndex: "durationInSeconds", dataIndex: 'durationInSeconds',
key: "durationInSeconds", key: 'durationInSeconds'
}, }
], ],
dataSource: [{ data: [] }], dataSource: [{ data: [] }],
showArr: [], showArr: []
}; }
}, },
computed: {}, computed: {},
components: {}, components: {},
methods: { methods: {
getDetail(newVal) { getDetail (newVal) {
if (newVal.resourceApplication) { if (newVal.resourceApplication) {
this.dataSource.data = []; this.dataSource.data = []
if (this.detailType == "能力上架") { if (this.detailType == '能力上架') {
let arr = []; const arr = []
newVal.resourceApplication.forEach((item) => { newVal.resourceApplication.forEach((item) => {
arr.push(item); arr.push(item)
}); })
this.dataSource.data.push([ this.dataSource.data.push([
newVal.resourceApplication.processInstanceId, newVal.resourceApplication.processInstanceId,
arr, arr
]); ])
} else { } else {
for (const key in newVal.resourceApplication) { for (const key in newVal.resourceApplication) {
if (newVal.resourceApplication[key].length > 0) { if (newVal.resourceApplication[key].length > 0) {
newVal.resourceApplication[key].map((item) => { newVal.resourceApplication[key].map((item) => {
this.dataSource.data.push([ this.dataSource.data.push([
item.instanceId, item.instanceId,
item.taskHandleDetailInfo, item.taskHandleDetailInfo
]); ])
}); })
} }
} }
} }
this.showArr.value = []; this.showArr.value = []
for (const key in newVal.resourceApplication) { for (const key in newVal.resourceApplication) {
if (newVal.resourceApplication[key].length > 0) { if (newVal.resourceApplication[key].length > 0) {
let obj = { name: "", instanceId: "", list: [], list2: [] }; const obj = { name: '', instanceId: '', list: [], list2: [] }
obj.name = key; obj.name = key
newVal.resourceApplication[key].map((item) => { newVal.resourceApplication[key].map((item) => {
obj.instanceId = item.instanceId; obj.instanceId = item.instanceId
obj.backToFirst = item.backToFirst; obj.backToFirst = item.backToFirst
obj.ended = item.ended; obj.ended = item.ended
obj.approveStatus = item.approveStatus; obj.approveStatus = item.approveStatus
if (item.resources.length > 0) { if (item.resources.length > 0) {
item.resources.map((val) => { item.resources.map((val) => {
obj.list.push(val); obj.list.push(val)
}); })
} else { } else {
item.camera.map((val) => { item.camera.map((val) => {
obj.list2.push(val); obj.list2.push(val)
}); })
} }
}); })
this.showArr.push(obj); this.showArr.push(obj)
} }
} }
} }
console.log("this.dataSource.data[0]========",this.dataSource.data[0][1]) console.log('this.dataSource.data[0]========', this.dataSource.data[0][1])
}, },
// init () { // init () {
// this.visible = true // this.visible = true
@ -269,11 +274,11 @@ export default {
// this.$refs['dataForm'].resetFields() // this.$refs['dataForm'].resetFields()
// }) // })
// }, // },
closeModal() { closeModal () {
this.$emit("closeModal"); this.$emit('closeModal')
}, }
}, }
}; }
</script> </script>
<style scoped> <style scoped>
.title { .title {
@ -457,4 +462,3 @@ export default {
} }
} }
</style> </style>

View File

@ -26,7 +26,7 @@
<!--起始日期 @keyup.enter.native="getDataList()"--> <!--起始日期 @keyup.enter.native="getDataList()"-->
<el-form-item> <el-form-item>
<span>日期</span> <span>日期</span>
<el-date-picker v-model="value1" type="datetimerange" range-separator="" start-placeholder="开始日期" <el-date-picker v-model="value1" type="daterange" range-separator="" start-placeholder="开始日期"
end-placeholder="结束日期" format="yyyy-MM-dd" value-format="yyyy-MM-dd"> end-placeholder="结束日期" format="yyyy-MM-dd" value-format="yyyy-MM-dd">
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
@ -45,44 +45,43 @@
<el-form-item> <el-form-item>
<span v-if="this.departmentId === 1 || this.departmentId === 3">上架部门</span> <span v-if="this.departmentId === 1 || this.departmentId === 3">上架部门</span>
<span v-else>申请部门</span> <span v-else>申请部门</span>
<el-select <el-select v-model="abilityDepartment" placeholder="请选择部门" filterable clearable>
v-model="abilityDepartment"
placeholder="请选择部门"
filterable
clearable
>
<el-option label="全部" value=""></el-option> <el-option label="全部" value=""></el-option>
<el-option v-for="item in departmentSelects" :key="item.label" :label="item.label" :value="item.value" v-bind="item"></el-option> <el-option v-for="item in departmentSelects" :key="item.label" :label="item.label" :value="item.value"
v-bind="item"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<!--类型--> <!--类型-->
<el-form-item> <el-form-item>
<span>类型</span> <span>类型</span>
<el-select v-if="this.departmentId === 2 || this.departmentId === 4" v-model="abilityType" placeholder="请选择类型" clearable> <el-select @change="changeIiem" v-if="this.departmentId === 2 || this.departmentId === 4" v-model="abilityType" placeholder="请选择类型" clearable>
<el-option label="全部" value=""></el-option> <el-option label="全部" value=""></el-option>
<el-option v-for="(item, i) in typeOptions" :key="`${item.name}${i}`" :label="item.name" :value="item.name" v-bind="item"> <el-option v-for="(item, i) in typeOptions" :key="`${item.name}${i}`" :label="item.name" :value="item.name"
v-bind="item">
</el-option> </el-option>
</el-select> </el-select>
<el-select v-else v-model="abilityType" placeholder="请选择类型" clearable> <el-select @change="changeIiem" v-else v-model="abilityType" placeholder="请选择类型" clearable>
<el-option label="全部" value=""></el-option> <el-option label="全部" value=""></el-option>
<el-option v-for="(item, i) in typeOptions1" :key="`${item.name}${i}`" :label="item.name" :value="item.name" v-bind="item"> <el-option v-for="(item, i) in typeOptions1" :key="`${item.name}${i}`" :label="item.name" :value="item.name"
v-bind="item">
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<!--操作按钮查询--> <!--操作按钮查询-->
<el-form-item> <el-form-item>
<el-button @click="getDataList()">{{ $t('query') }}</el-button> <el-button type="primary" @click="getDataList()">{{ $t('query') }}</el-button>
</el-form-item> </el-form-item>
<!--操作按钮重置--> <!--操作按钮重置-->
<el-form-item> <el-form-item>
<el-button type="primary" @click="resetDataList()">{{ <el-button type="primary" @click="resetDataList()">{{
$t('reset') $t('reset')
}}</el-button> }}</el-button>
</el-form-item> </el-form-item>
<!-- 导出 --> <!-- 导出 -->
<a class='export' :href="exportExcel+exportExcelType+'?'+exportExcelCondition+'&token='+token">导出全部</a> <a class='export'
:href="exportExcel + exportExcelType + '?' + exportExcelCondition + '&token=' + token">导出全部</a>
</el-form> </el-form>
<el-card shadow="never" class="aui-card--fill" v-if="homeIsShow"> <el-card shadow="never" class="aui-card--fill" v-if="homeIsShow">
<div class="mod-demand__bsdemand"> <div class="mod-demand__bsdemand">
@ -117,7 +116,8 @@
能力使用明细 能力使用明细
</span> --> </span> -->
<template v-if="detailFlag"> <template v-if="detailFlag">
<el-checkbox v-model="checked" @change='chagneCheckbox' style="position: absolute;right: 150px;margin-top: -15px;">隐藏空数据</el-checkbox> <el-checkbox v-model="checked" @change='chagneCheckbox'
style="position: absolute;right: 150px;margin-top: -15px;">隐藏空数据</el-checkbox>
<span class="detail-button" @click="goToDetail()"> <span class="detail-button" @click="goToDetail()">
明细 明细
</span> </span>
@ -168,14 +168,10 @@
</el-table> </el-table>
<!--明细表--> <!--明细表-->
<el-table <el-table :data="tableData" :header-cell-style="{ textAlign: 'center', height: '96px' }"
:data="tableData" :cell-style="{ textAlign: 'center' }" style="width: 100%"
:header-cell-style="{ textAlign: 'center',height:'96px' }" v-show="this.departmentId === 3 || this.departmentId === 4">
:cell-style="{ textAlign: 'center' }" <el-table-column v-if="this.departmentId === 3" prop="deptName" label="上架部门" min-width="100%">
style="width: 100%"
v-show="this.departmentId === 3 || this.departmentId === 4"
>
<el-table-column v-if="this.departmentId === 3" prop="deptName" label="上架部门" min-width="100%">
</el-table-column> </el-table-column>
<el-table-column v-if="this.departmentId === 4" prop="deptName" label="申请部门" min-width="100%"> <el-table-column v-if="this.departmentId === 4" prop="deptName" label="申请部门" min-width="100%">
</el-table-column> </el-table-column>
@ -194,7 +190,7 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="block"> <div class="block" v-if="!detailFlag">
<el-pagination @current-change="handleCurrentChange" layout="total, prev, pager, next, jumper" <el-pagination @current-change="handleCurrentChange" layout="total, prev, pager, next, jumper"
:total="total" :page-size="pageSize" :current-page="currentPage"> :total="total" :page-size="pageSize" :current-page="currentPage">
</el-pagination> </el-pagination>
@ -233,7 +229,7 @@ import Template from '../devtools/template.vue'
// }) // })
export default { export default {
components: { componentServices, applicationResources, ComponentUsed, AbilityDetail, Template }, components: { componentServices, applicationResources, ComponentUsed, AbilityDetail, Template },
data () { data() {
return { return {
checked: false, checked: false,
departmentSelects: [], departmentSelects: [],
@ -353,12 +349,12 @@ export default {
{ name: '应用资源', value: 5 }, { name: '应用资源', value: 5 },
{ name: '会议室', value: 6 } { name: '会议室', value: 6 }
], // ], //
typeOptions1: [// typeOptions1: [//
{ name: '智能算法', value: 1 }, { name: '智能算法', value: 1 },
{ name: '图层服务', value: 2 }, { name: '图层服务', value: 2 },
{ name: '开发组件', value: 3 }, { name: '开发组件', value: 3 },
{ name: '业务组件', value: 4 }, { name: '业务组件', value: 4 },
{ name: '应用资源', value: 5 }, { name: '应用资源', value: 5 }
], // ], //
detailFlag: false, // detailFlag: false, //
@ -366,7 +362,7 @@ export default {
endDate: '' // endDate: '' //
} }
}, },
created () { created() {
this.$http.get('/sys/dept/all').then(res => { this.$http.get('/sys/dept/all').then(res => {
// console.log('=========>', res) // console.log('=========>', res)
this.departmentSelects = [] this.departmentSelects = []
@ -387,22 +383,27 @@ export default {
// const date2 = new Date(year2, month2, day2, 7) // const date2 = new Date(year2, month2, day2, 7)
// this.value1.unshift(date2) // this.value1.unshift(date2)
}, },
mounted () { mounted() {
// this.getFirstTree() // this.getFirstTree()
if (this.departmentId === 1) { console.log('this.$route.query.Id;', this.$route.query.type)
this.handleChose(3) if (this.$route.query.type === 'use') {
// this.departmentId = 1;
} else if (this.departmentId === 2) {
this.handleChose(4) this.handleChose(4)
// this.departmentId = 2;
} else { } else {
if (this.departmentId === 1) {
this.handleChose(3)
// this.departmentId = 1;
} else if (this.departmentId === 2) {
this.handleChose(4)
// this.departmentId = 2;
} else {
}
} }
}, },
computed: { computed: {
// ...mapState(['departmentSelects']) // ...mapState(['departmentSelects'])
}, },
methods: { methods: {
chagneCheckbox () { chagneCheckbox() {
if (this.checked) { if (this.checked) {
this.tableData = this.tableDataClone.filter(val => val.count !== 0) this.tableData = this.tableDataClone.filter(val => val.count !== 0)
this.total = this.tableData.length this.total = this.tableData.length
@ -411,7 +412,7 @@ export default {
this.total = this.tableData.length this.total = this.tableData.length
} }
}, },
closeModal () { closeModal() {
this.detailsVisible = false this.detailsVisible = false
}, },
handleCurrentChange (val) { handleCurrentChange (val) {
@ -431,7 +432,7 @@ export default {
// this.getReleaseTree(val) // this.getReleaseTree(val)
// } // }
}, },
getTreeName (data) { getTreeName(data) {
this.$http this.$http
.get('/census/center/v3/treeList/', { .get('/census/center/v3/treeList/', {
params: { params: {
@ -461,7 +462,7 @@ export default {
// }, // },
// -- // --
getFirstTree (page) { getFirstTree(page) {
if (this.examineStatus == '-1') { if (this.examineStatus == '-1') {
this.status = '' this.status = ''
} else if (this.examineStatus == '0') { } else if (this.examineStatus == '0') {
@ -527,7 +528,7 @@ export default {
}) })
}, },
// 使-使 // 使-使
getSecondTree (page) { getSecondTree(page) {
if (this.examineStatus == '-1') { if (this.examineStatus == '-1') {
this.status = '' this.status = ''
} else if (this.examineStatus == '0') { } else if (this.examineStatus == '0') {
@ -593,7 +594,7 @@ export default {
}) })
}, },
// //
detailClick (row) { detailClick(row) {
this.detailParamss = {} this.detailParamss = {}
const applyNumber = row.applyNumber const applyNumber = row.applyNumber
if (this.departmentId == 3) { // if (this.departmentId == 3) { //
@ -635,7 +636,7 @@ export default {
} }
}, },
// //
getOneDetail (page) { getOneDetail(page) {
var passAndReview = '' // "" var passAndReview = '' // ""
if (this.examineStatus == '-1') { if (this.examineStatus == '-1') {
this.status = '' this.status = ''
@ -674,7 +675,7 @@ export default {
}) })
}, },
// 使 使 // 使 使
getTwoDetail (page) { getTwoDetail(page) {
var passAndReview = '' // "" var passAndReview = '' // ""
if (this.examineStatus == '-1') { if (this.examineStatus == '-1') {
this.status = '' this.status = ''
@ -711,7 +712,7 @@ export default {
}) })
}) })
}, },
getReleaseTree (page) { getReleaseTree(page) {
this.$http this.$http
.get('/census/center/selectApplyDeptDetailTypeCountList/', { .get('/census/center/selectApplyDeptDetailTypeCountList/', {
params: { params: {
@ -758,7 +759,7 @@ export default {
}) })
}, },
// 使 // 使
getUsedTree () { getUsedTree() {
this.$http this.$http
.get('/census/center/v3/resourceReleaseDetails/', { .get('/census/center/v3/resourceReleaseDetails/', {
params: { params: {
@ -772,7 +773,7 @@ export default {
this.tableData = res.data.data.list this.tableData = res.data.data.list
}) })
}, },
handleClick (row) { handleClick(row) {
if (this.choseId === 0) { if (this.choseId === 0) {
if (this.departmentId === 1) { if (this.departmentId === 1) {
this.homeIsShow = false this.homeIsShow = false
@ -793,7 +794,7 @@ export default {
} }
}, },
// //
choseBtn (index) { choseBtn(index) {
this.choseId = index this.choseId = index
this.handleChose(1) this.handleChose(1)
}, },
@ -809,9 +810,11 @@ export default {
// } // }
// }, // },
// or使 // or使
handleChose (index) { handleChose(index) {
this.checked = false this.checked = false
this.departmentId = index this.departmentId = index
this.currentPage=1
this.pageSize=10
if (index === 1) { if (index === 1) {
if (this.choseId === 0) { if (this.choseId === 0) {
if (!this.detailFlag) { if (!this.detailFlag) {
@ -851,26 +854,32 @@ export default {
} }
}, },
// //
handleSizeChange (val) { handleSizeChange(val) {
console.log(`每页 ${val}`) console.log(`每页 ${val}`)
}, },
closeChild () { closeChild() {
this.homeIsShow = true this.homeIsShow = true
this.servicesIsShow = false this.servicesIsShow = false
this.handleCurrentChange(1) this.handleCurrentChange(1)
}, },
closeChild2 () { closeChild2() {
this.homeIsShow = true this.homeIsShow = true
this.UsedIsShow = false this.UsedIsShow = false
this.handleCurrentChange(1) this.handleCurrentChange(1)
}, },
closeApplication () { closeApplication() {
this.homeIsShow = true this.homeIsShow = true
this.resourcesIsShow = false this.resourcesIsShow = false
this.handleCurrentChange(1) this.handleCurrentChange(1)
}, },
changeIiem(){
this.currentPage=1
this.pageSize=10
},
// ////////// // //////////
goToDetail () { goToDetail () {
this.currentPage=1
this.pageSize=10
this.detailFlag = !this.detailFlag this.detailFlag = !this.detailFlag
if (this.departmentId === 1) { if (this.departmentId === 1) {
this.handleChose(3) this.handleChose(3)
@ -882,8 +891,10 @@ export default {
} }
}, },
// //
goToBack () { goToBack() {
this.checked = false this.checked = false
this.currentPage=1,
this.pageSize=10,
// departmentId 13 24 // departmentId 13 24
this.detailFlag = !this.detailFlag this.detailFlag = !this.detailFlag
if (this.departmentId === 3) { if (this.departmentId === 3) {
@ -896,10 +907,12 @@ export default {
} }
}, },
// //
getDataList () { getDataList() {
if (this.value1 && this.value1.length > 0) { if (this.value1 && this.value1.length > 0) {
this.startDate = this.handleTime(this.value1[0], 'yyyy-MM-dd') // this.startDate = this.handleTime(this.value1[0], 'yyyy-MM-dd')
this.endDate = this.handleTime(this.value1[1], 'yyyy-MM-dd') // this.endDate = this.handleTime(this.value1[1], 'yyyy-MM-dd')
this.startDate = this.value1[0]
this.endDate = this.value1[1]
} else { } else {
this.startDate = '' this.startDate = ''
this.endDate = '' this.endDate = ''
@ -927,7 +940,7 @@ export default {
} }
}, },
// //
resetDataList () { resetDataList() {
this.value1 = [] this.value1 = []
this.startDate = '' this.startDate = ''
this.endDate = '' this.endDate = ''
@ -965,7 +978,7 @@ export default {
} }
}, },
// //
handleTime (time, format) { handleTime(time, format) {
if (time == null || time == undefined || time == '') { if (time == null || time == undefined || time == '') {
return '' return ''
} }
@ -1159,24 +1172,16 @@ input::placeholder {
background: #fff; background: #fff;
border: 1px solid #dcdfe6; border: 1px solid #dcdfe6;
color: #000; color: #000;
color: #FFF;
background-color: #0058e1;
border-color: #0058e1;
text-decoration: none;
} }
.export:hover { .export:hover {
border-color: #c5ddfd; background: #65a5f9;
background-color: #ecf4fe; border-color: #65a5f9;
color: #0058e1; color: #FFF;
text-decoration: none;
} }
.export:active {
border-color: #c5ddfd;
background-color: #ecf4fe;
color: #0058e1;
text-decoration: none;
}
.export:visited {
color: #fff;
text-decoration: none;
}
</style> </style>

View File

@ -36,6 +36,7 @@
<div class="agreeOr" v-if="taskId"> <div class="agreeOr" v-if="taskId">
<h3>审批</h3> <h3>审批</h3>
<div> <div>
<el-button type="info" @click="entrustTask()" v-if='taskEntrustFlag && taskEntrustFlag2'>转办</el-button>
<el-button type="primary" @click="showDialog('同意')">同意</el-button> <el-button type="primary" @click="showDialog('同意')">同意</el-button>
<el-button type="danger" plain @click="showDialog('驳回')" <el-button type="danger" plain @click="showDialog('驳回')"
>驳回</el-button >驳回</el-button
@ -61,6 +62,7 @@
> --> > -->
</div> </div>
</div> </div>
<ren-task-entrust v-if="renTaskEntrustVisible" ref="renTaskEntrust"></ren-task-entrust>
<!-- 流程详情 --> <!-- 流程详情 -->
<ren-process-detail></ren-process-detail> <ren-process-detail></ren-process-detail>
<el-dialog <el-dialog
@ -84,6 +86,7 @@
</template> </template>
<script> <script>
import RenTaskEntrust from '@/components/ren-process-running/src/ren-task-entrust'
import bus from '@/views/bus.js' import bus from '@/views/bus.js'
import ResourcesAndServices from './ResourcesAndServices.vue' import ResourcesAndServices from './ResourcesAndServices.vue'
import debounce from 'lodash/debounce' import debounce from 'lodash/debounce'
@ -93,7 +96,8 @@ export default {
// //
// mixins: [processModule], // mixins: [processModule],
components: { components: {
ResourcesAndServices ResourcesAndServices,
RenTaskEntrust
}, },
props: { props: {
// fromList: { // fromList: {
@ -105,6 +109,9 @@ export default {
}, },
data () { data () {
return { return {
taskEntrustFlag: false,
taskEntrustFlag2: false,
renTaskEntrustVisible: false,
dialogVisible: false, dialogVisible: false,
dialogType: '', dialogType: '',
input: '', input: '',
@ -132,6 +139,35 @@ export default {
console.log('params=================>', this.$route, this.$route.params) console.log('params=================>', this.$route, this.$route.params)
this.taskId = this.$route.params.taskId this.taskId = this.$route.params.taskId
this.dataForm.taskId = this.$route.params.taskId this.dataForm.taskId = this.$route.params.taskId
this.$http.get('/sys/user/info').then(({ data: res }) => {
res.data.roleIdList.map(val => {
this.$http.get('/sys/role/' + val).then(role => {
if (role.data.data.name === '流程管理员') {
this.taskEntrustFlag = true
this.$http
.get(
'/act/task/getTaskVariables?taskId=' + this.$route.params.taskId + '&variableName=allowEntrust'
).then(entrust => {
console.log('11111111111111', entrust, this.dataForm)
if (entrust.data.data.allowEntrust === true) {
this.taskEntrustFlag2 = true
if (this.taskEntrustFlag && this.taskEntrustFlag2) {
this.$alert('当前审核部门为' + this.dataForm.deptName + ',该部门未配置审核人,请联系运维工程师配置完成后进行流程转办!', '流程提醒', {
confirmButtonText: '确定',
callback: action => {
// this.$message({
// type: 'info',
// message: `action: ${action}`
// })
}
})
}
}
})
}
})
})
})
this.init() this.init()
console.log('fromList', this.$router.currentRoute.params.businessKey) console.log('fromList', this.$router.currentRoute.params.businessKey)
// this.dataForm = this.$router.currentRoute.params.params.params.resourceDTO // this.dataForm = this.$router.currentRoute.params.params.params.resourceDTO
@ -154,6 +190,15 @@ export default {
}, },
computed: {}, computed: {},
methods: { methods: {
entrustTask () {
this.renTaskEntrustVisible = true
this.$nextTick(() => {
this.$refs.renTaskEntrust.dataForm.taskId = this.dataForm.taskId
this.$refs.renTaskEntrust.callbacks = this.callbacks
this.$refs.renTaskEntrust.init()
})
},
getInfo (id) { getInfo (id) {
this.$http.get('/resourceMountApply/' + id).then(({ data: res }) => { this.$http.get('/resourceMountApply/' + id).then(({ data: res }) => {
this.dataForm = res.data.resourceDTO this.dataForm = res.data.resourceDTO

View File

@ -2,7 +2,7 @@
* @Author: hisense.liangjunhua * @Author: hisense.liangjunhua
* @Date: 2022-06-29 15:59:51 * @Date: 2022-06-29 15:59:51
* @LastEditors: Light * @LastEditors: Light
* @LastEditTime: 2022-10-21 16:11:46 * @LastEditTime: 2022-10-27 16:04:01
* @Description: 告诉大家这是什么 * @Description: 告诉大家这是什么
--> -->
<!-- 流程业务表单 --> <!-- 流程业务表单 -->
@ -77,7 +77,7 @@
</ul> </ul>
</div> </div>
<!-- 流程综合组件 --> <!-- 流程综合组件 -->
<!-- <ren-process-multiple <!-- <ren-process-multiple
v-if="processVisible" v-if="processVisible"
updateInstanceIdUrl="/processForm/tabilityapplication/updateInstanceId" updateInstanceIdUrl="/processForm/tabilityapplication/updateInstanceId"
saveFormUrl="/processForm/tabilityapplication" saveFormUrl="/processForm/tabilityapplication"
@ -105,7 +105,7 @@
<ren-task-entrust v-if="renTaskEntrustVisible" ref="renTaskEntrust"></ren-task-entrust> <ren-task-entrust v-if="renTaskEntrustVisible" ref="renTaskEntrust"></ren-task-entrust>
<!-- 流程详情 --> <!-- 流程详情 -->
<ren-process-detail></ren-process-detail> <ren-process-detail ref="renProcessMultiple"></ren-process-detail>
<el-dialog title="审批意见" :close-on-click-modal="false" :visible.sync="dialogVisible" width="30%" <el-dialog title="审批意见" :close-on-click-modal="false" :visible.sync="dialogVisible" width="30%"
:before-close="handleClose"> :before-close="handleClose">
<el-input v-model="input" placeholder="请输入审批意见"></el-input> <el-input v-model="input" placeholder="请输入审批意见"></el-input>
@ -131,6 +131,7 @@ export default {
mixins: [processModule], mixins: [processModule],
data () { data () {
return { return {
callbacks: null,
taskEntrustFlag: false, taskEntrustFlag: false,
taskEntrustFlag2: false, taskEntrustFlag2: false,
dialogVisible: false, dialogVisible: false,

View File

@ -15,37 +15,47 @@
<el-button type="danger" @click="deleteHandle()">{{ $t('deleteBatch') }}</el-button> <el-button type="danger" @click="deleteHandle()">{{ $t('deleteBatch') }}</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table v-loading="dataListLoading" :data="dataList" border @selection-change="dataListSelectionChangeHandle" style="width: 100%;"> <el-table v-loading="dataListLoading" :data="dataList" border @selection-change="dataListSelectionChangeHandle"
style="width: 100%;">
<el-table-column type="selection" header-align="center" align="center" width="50"></el-table-column> <el-table-column type="selection" header-align="center" align="center" width="50"></el-table-column>
<el-table-column prop="title" :label="$t('notice.title')" header-align="center" align="center"></el-table-column> <el-table-column prop="title" :label="$t('notice.title')" header-align="center" align="center" width="180">
<el-table-column prop="type" :label="$t('notice.type')" header-align="center" align="center" width="150"> </el-table-column>
<!-- 内容 prop="content"-->
<el-table-column :label="$t('news.content')" header-align="center" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ $getDictLabel("notice_type", scope.row.type) }} <el-tooltip effect="dark" :content="scope.row.content" placement="top">
<span class="text-ellipsis">{{ scope.row.content }}</span>
</el-tooltip>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="senderName" :label="$t('notice.senderName')" header-align="center" align="center" width="150"></el-table-column> <el-table-column prop="type" :label="$t('notice.type')" header-align="center" align="center" width="150">
<el-table-column prop="senderDate" :label="$t('notice.senderDate')" header-align="center" align="center" width="170"></el-table-column> <template slot-scope="scope">
{{ $getDictLabel("notice_type", scope.row.type) }}
</template>
</el-table-column>
<el-table-column prop="senderName" :label="$t('notice.senderName')" header-align="center" align="center"
width="150"></el-table-column>
<el-table-column prop="senderDate" :label="$t('notice.senderDate')" header-align="center" align="center"
width="170"></el-table-column>
<el-table-column prop="status" :label="$t('notice.status')" header-align="center" align="center" width="130"> <el-table-column prop="status" :label="$t('notice.status')" header-align="center" align="center" width="130">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.status === 0" size="small" type="danger">{{ $t('notice.status0') }}</el-tag> <el-tag v-if="scope.row.status === 0" size="small" type="danger">{{ $t('notice.status0') }}</el-tag>
<el-tag v-else size="small" type="success">{{ $t('notice.status1') }}</el-tag> <el-tag v-else size="small" type="success">{{ $t('notice.status1') }}</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="150"> <el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button v-if="scope.row.status === 0" type="text" size="small" @click="addOrUpdateHandle(scope.row.id)">{{ $t('update') }}</el-button> <el-button v-if="scope.row.status === 0" type="text" size="small" @click="addOrUpdateHandle(scope.row.id)">
<el-button v-if="scope.row.status === 1" type="text" size="small" @click="viewHandle(scope.row)">{{ $t('notice.view') }}</el-button> {{ $t('update') }}</el-button>
<el-button v-if="scope.row.status === 1" type="text" size="small" @click="viewHandle(scope.row)">{{
$t('notice.view')
}}</el-button>
<el-button type="text" size="small" @click="deleteHandle(scope.row.id)">{{ $t('delete') }}</el-button> <el-button type="text" size="small" @click="deleteHandle(scope.row.id)">{{ $t('delete') }}</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination :current-page="page" :page-sizes="[10, 20, 50, 100]" :page-size="limit" :total="total"
:current-page="page" layout="total, sizes, prev, pager, next, jumper" @size-change="pageSizeChangeHandle"
:page-sizes="[10, 20, 50, 100]"
:page-size="limit"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="pageSizeChangeHandle"
@current-change="pageCurrentChangeHandle"> @current-change="pageCurrentChangeHandle">
</el-pagination> </el-pagination>
<!-- 弹窗, 新增 / 修改 --> <!-- 弹窗, 新增 / 修改 -->
@ -60,7 +70,7 @@ import AddOrUpdate from './notice-add-or-update'
import { addDynamicRoute } from '@/router' import { addDynamicRoute } from '@/router'
export default { export default {
mixins: [mixinViewModule], mixins: [mixinViewModule],
data () { data() {
return { return {
mixinViewModuleOptions: { mixinViewModuleOptions: {
getDataListURL: '/sys/notice/page', getDataListURL: '/sys/notice/page',
@ -77,7 +87,7 @@ export default {
AddOrUpdate AddOrUpdate
}, },
methods: { methods: {
viewHandle (row) { viewHandle(row) {
// //
const routeParams = { const routeParams = {
routeName: `${this.$route.name}__${row.id}`, routeName: `${this.$route.name}__${row.id}`,
@ -93,3 +103,13 @@ export default {
} }
} }
</script> </script>
<style scoped>
.text-ellipsis {
/*1. 先强制一行内显示文本*/
white-space: nowrap;
/*2. 超出的部分隐藏*/
overflow: hidden;
/*3. 文字用省略号替代超出的部分*/
text-overflow: ellipsis;
}
</style>

View File

@ -142,48 +142,7 @@ export default {
// //
RankingData: [], RankingData: [],
// //
AnomalyStatisticsTable: [ AnomalyStatisticsTable: [],
{
name: '接口名称',
address: 'http://hhhhhhhhhhhhhhhhhhhh',
method: '调用方法',
type: '组件类型',
provider: '提供商名称',
state: '监控状态'
},
{
name: '接口名称',
address: 'http://hhhhhhhhhhhhhhhhhhhh',
method: '调用方法',
type: '组件类型',
provider: '提供商名称',
state: '监控状态'
},
{
name: '接口名称',
address: 'http://hhhhhhhhhhhhhhhhhhhh',
method: '调用方法',
type: '组件类型',
provider: '提供商名称',
state: '监控状态'
},
{
name: '接口名称',
address: 'http://hhhhhhhhhhhhhhhhhhhh',
method: '调用方法',
type: '组件类型',
provider: '提供商名称',
state: '监控状态'
},
{
name: '接口名称',
address: 'http://hhhhhhhhhhhhhhhhhhhh',
method: '调用方法',
type: '组件类型',
provider: '提供商名称',
state: '监控状态'
}
],
// //
currentPage4: 1, currentPage4: 1,
total: 0 total: 0

View File

@ -1,209 +1,92 @@
<template> <template>
<el-card shadow="never" class="aui-card--fill"> <el-card shadow="never" class="aui-card--fill">
<div class="mod-sys__user"> <div class="mod-sys__user">
<el-form <el-form :inline="true" :model="dataForm" @keyup.enter.native="getDataList()">
:inline="true"
:model="dataForm"
@keyup.enter.native="getDataList()"
>
<el-form-item> <el-form-item>
<el-input <el-input v-model="dataForm.username" placeholder="用户名" clearable></el-input>
v-model="dataForm.username"
placeholder="用户名"
clearable
></el-input>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-input <el-input v-model="dataForm.real_name" placeholder="真实姓名" clearable></el-input>
v-model="dataForm.real_name"
placeholder="真实姓名"
clearable
></el-input>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<ren-select <ren-select v-model="dataForm.gender" dict-type="gender" :placeholder="$t('user.gender')"></ren-select>
v-model="dataForm.gender"
dict-type="gender"
:placeholder="$t('user.gender')"
></ren-select>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-select <el-select v-model="dataForm.postId" :placeholder="$t('user.postIdList')" clearable>
v-model="dataForm.postId" <el-option :label="data.postName" v-for="data in postList" :key="data.id" :value="data.id">{{ data.postName
:placeholder="$t('user.postIdList')" }}</el-option>
clearable
>
<el-option
:label="data.postName"
v-for="data in postList"
:key="data.id"
:value="data.id"
>{{ data.postName }}</el-option
>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<ren-dept-tree <ren-dept-tree v-model="dataForm.deptId" :placeholder="$t('dept.title')" :query="true" ref="renDeptTree">
v-model="dataForm.deptId" </ren-dept-tree>
:placeholder="$t('dept.title')"
:query="true"
></ren-dept-tree>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" @click="getDataList()">{{ <el-button type="primary" @click="getDataList()">{{
$t('query') $t('query')
}}</el-button> }}</el-button>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button v-if="$hasPermission('sys:user:save')" type="primary" @click="addOrUpdateHandle()">{{ $t('add') }}
v-if="$hasPermission('sys:user:save')" </el-button>
type="primary"
@click="addOrUpdateHandle()"
>{{ $t('add') }}</el-button
>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button v-if="$hasPermission('sys:user:delete')" type="danger" @click="deleteHandle()">{{ $t('deleteBatch')
v-if="$hasPermission('sys:user:delete')" }}</el-button>
type="danger"
@click="deleteHandle()"
>{{ $t('deleteBatch') }}</el-button
>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button v-if="$hasPermission('sys:user:export')" type="info" @click="exportHandle()">{{ $t('export') }}
v-if="$hasPermission('sys:user:export')" </el-button>
type="info"
@click="exportHandle()"
>{{ $t('export') }}</el-button
>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button @click="reset()">重置</el-button> <el-button @click="reset()">重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table <el-table v-loading="dataListLoading" :data="dataList" border @selection-change="dataListSelectionChangeHandle"
v-loading="dataListLoading" @sort-change="dataListSortChangeHandle" style="width: 100%">
:data="dataList" <el-table-column type="selection" header-align="center" align="center" width="50"></el-table-column>
border <el-table-column prop="username" :label="$t('user.username')" sortable="custom" header-align="center"
@selection-change="dataListSelectionChangeHandle" align="center"></el-table-column>
@sort-change="dataListSortChangeHandle" <el-table-column prop="realName" label="真实姓名" header-align="center" align="center"></el-table-column>
style="width: 100%" <el-table-column prop="deptName" :label="$t('user.deptName')" header-align="center" align="center">
> </el-table-column>
<el-table-column <el-table-column prop="email" :label="$t('user.email')" header-align="center" align="center"></el-table-column>
type="selection" <el-table-column prop="mobile" :label="$t('user.mobile')" sortable="custom" header-align="center"
header-align="center" align="center"></el-table-column>
align="center" <el-table-column prop="gender" :label="$t('user.gender')" sortable="custom" header-align="center"
width="50" align="center">
></el-table-column>
<el-table-column
prop="username"
:label="$t('user.username')"
sortable="custom"
header-align="center"
align="center"
></el-table-column>
<el-table-column
prop="realName"
label="真实姓名"
header-align="center"
align="center"
></el-table-column>
<el-table-column
prop="deptName"
:label="$t('user.deptName')"
header-align="center"
align="center"
></el-table-column>
<el-table-column
prop="email"
:label="$t('user.email')"
header-align="center"
align="center"
></el-table-column>
<el-table-column
prop="mobile"
:label="$t('user.mobile')"
sortable="custom"
header-align="center"
align="center"
></el-table-column>
<el-table-column
prop="gender"
:label="$t('user.gender')"
sortable="custom"
header-align="center"
align="center"
>
<template slot-scope="scope"> <template slot-scope="scope">
{{ $getDictLabel('gender', scope.row.gender) }} {{ $getDictLabel('gender', scope.row.gender) }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column prop="status" :label="$t('user.status')" sortable="custom" header-align="center"
prop="status" align="center">
:label="$t('user.status')"
sortable="custom"
header-align="center"
align="center"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.status === 0" size="small" type="danger">{{ <el-tag v-if="scope.row.status === 0" size="small" type="danger">{{
$t('user.status0') $t('user.status0')
}}</el-tag> }}</el-tag>
<el-tag v-else size="small" type="success">{{ <el-tag v-else size="small" type="success">{{
$t('user.status1') $t('user.status1')
}}</el-tag> }}</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column prop="createDate" :label="$t('user.createDate')" sortable="custom" header-align="center"
prop="createDate" align="center" width="180"></el-table-column>
:label="$t('user.createDate')" <el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="150">
sortable="custom"
header-align="center"
align="center"
width="180"
></el-table-column>
<el-table-column
:label="$t('handle')"
fixed="right"
header-align="center"
align="center"
width="150"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button v-if="$hasPermission('sys:user:update')" type="text" size="small"
v-if="$hasPermission('sys:user:update')" @click="addOrUpdateHandle(scope.row.id)">{{ $t('update') }}</el-button>
type="text" <el-button v-if="$hasPermission('sys:user:delete')" type="text" size="small"
size="small" @click="deleteHandle(scope.row.id)">{{ $t('delete') }}</el-button>
@click="addOrUpdateHandle(scope.row.id)"
>{{ $t('update') }}</el-button
>
<el-button
v-if="$hasPermission('sys:user:delete')"
type="text"
size="small"
@click="deleteHandle(scope.row.id)"
>{{ $t('delete') }}</el-button
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination :current-page="page" :page-sizes="[10, 20, 50, 100]" :page-size="limit" :total="total"
:current-page="page" layout="total, sizes, prev, pager, next, jumper" @size-change="pageSizeChangeHandle"
:page-sizes="[10, 20, 50, 100]" @current-change="pageCurrentChangeHandle">
:page-size="limit"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="pageSizeChangeHandle"
@current-change="pageCurrentChangeHandle"
>
</el-pagination> </el-pagination>
<!-- 弹窗, 新增 / 修改 --> <!-- 弹窗, 新增 / 修改 -->
<add-or-update <add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList"></add-or-update>
v-if="addOrUpdateVisible"
ref="addOrUpdate"
@refreshDataList="getDataList"
></add-or-update>
</div> </div>
</el-card> </el-card>
</template> </template>
@ -214,7 +97,7 @@ import AddOrUpdate from './user-add-or-update'
import qs from 'qs' import qs from 'qs'
export default { export default {
mixins: [mixinViewModule], mixins: [mixinViewModule],
data () { data() {
return { return {
mixinViewModuleOptions: { mixinViewModuleOptions: {
getDataListURL: '/sys/user/page', getDataListURL: '/sys/user/page',
@ -235,30 +118,33 @@ export default {
components: { components: {
AddOrUpdate AddOrUpdate
}, },
created () { created() {
this.getPostList() this.getPostList()
}, },
methods: { methods: {
reset () { reset() {
this.dataForm.username = ''
this.dataForm.real_name = ''
this.dataForm.deptId = ''
this.dataForm.postId = ''
this.dataForm.gender = ''
if (this.$refs.renDeptTree) {
this.$refs.renDeptTree.showDeptName = '';
}
this.$http this.$http
.get( .get(
this.mixinViewModuleOptions.getDataListURL + this.mixinViewModuleOptions.getDataListURL +
'?' + '?' +
qs.stringify({ qs.stringify({
page: 1, page: 1,
limit: 10, limit: 10,
username: '', username: '',
deptId: '', deptId: '',
postId: '', postId: '',
gender: '' gender: ''
}) })
) )
.then(({ data: res }) => { .then(({ data: res }) => {
this.dataForm.username = ''
this.dataForm.real_name = ''
this.dataForm.deptId = ''
this.dataForm.postId = ''
this.dataForm.gender = ''
if (res.code !== 0) { if (res.code !== 0) {
this.dataList = [] this.dataList = []
this.total = 0 this.total = 0
@ -279,7 +165,7 @@ export default {
this.dataListLoading = false this.dataListLoading = false
}) })
}, },
getPostList () { getPostList() {
this.$http this.$http
.get('/sys/post/list') .get('/sys/post/list')
.then(({ data: res }) => { .then(({ data: res }) => {
@ -288,7 +174,7 @@ export default {
} }
this.postList = res.data this.postList = res.data
}) })
.catch(() => {}) .catch(() => { })
} }
} }
} }

View File

@ -9,7 +9,7 @@
> >
<div class="content"> <div class="content">
<img class="img" :src="dataInfo.imgSrc" /> <img class="img" :src="dataInfo.imgSrc" />
<div class="title">{{ title }}</div> <div class="title">{{ '我的'+title }}</div>
<div class="flex-row-bottom"> <div class="flex-row-bottom">
<span class="num" :style="{ color: dataInfo.textColor }">{{ <span class="num" :style="{ color: dataInfo.textColor }">{{
formatNum(dataInfo.num) formatNum(dataInfo.num)
@ -90,7 +90,7 @@
</div> </div>
<div class="more" @click="goPage(dataInfo.url)">查看更多 ></div> <div class="more" @click="goPage(dataInfo.url)">查看更多 ></div>
</div> </div>
<div class="list-box flex-row-center no-data" v-else>暂无数据</div> <div class="list-box flex-row-center no-data" v-else>暂无{{title}}任务</div>
</div> </div>
</template> </template>
<script> <script>

View File

@ -4,19 +4,19 @@
<div v-if="!noData" v-loading="loading"> <div v-if="!noData" v-loading="loading">
<div class="no-box"> <div class="no-box">
<div class="no no2"> <div class="no no2">
<el-tooltip effect="dark" :content="no2Obj.name" placement="top"> <el-tooltip effect="dark" :content="no2Obj.name" placement="top" v-if="no2Obj.name">
<div class="name ellipsis" :style="{ color: colorObj[2] }">{{ no2Obj.name || '--' }}</div> <div class="name ellipsis" :style="{ color: colorObj[2] }">{{ no2Obj.name || '--' }}</div>
</el-tooltip> </el-tooltip>
<div class="count">{{ formatCount(no2Obj.count) }}</div> <div class="count">{{ formatCount(no2Obj.count) }}</div>
</div> </div>
<div class="no no1"> <div class="no no1">
<el-tooltip effect="dark" :content="no1Obj.name" placement="top"> <el-tooltip effect="dark" :content="no1Obj.name" placement="top" v-if="no1Obj.name">
<div class="name ellipsis" :style="{ color: colorObj[1] }">{{ no1Obj.name || '--' }}</div> <div class="name ellipsis" :style="{ color: colorObj[1] }">{{ no1Obj.name || '--' }}</div>
</el-tooltip> </el-tooltip>
<div class="count">{{ formatCount(no1Obj.count) }}</div> <div class="count">{{ formatCount(no1Obj.count) }}</div>
</div> </div>
<div class="no no3"> <div class="no no3">
<el-tooltip effect="dark" :content="no3Obj.name" placement="top"> <el-tooltip effect="dark" :content="no3Obj.name" placement="top" v-if="no3Obj.name">
<div class="name ellipsis" :style="{ color: colorObj[3] }">{{ no3Obj.name || '--' }}</div> <div class="name ellipsis" :style="{ color: colorObj[3] }">{{ no3Obj.name || '--' }}</div>
</el-tooltip> </el-tooltip>
@ -26,7 +26,7 @@
<div class="flex-row-between row-name" v-for="(data, i) in listInfo" :key="i"> <div class="flex-row-between row-name" v-for="(data, i) in listInfo" :key="i">
<div class="left"> <div class="left">
<div class="row-index">{{ i + 4 }}</div> <div class="row-index">{{ i + 4 }}</div>
<el-tooltip effect="dark" :content="data.name" placement="top"> <el-tooltip effect="dark" :content="data.name" placement="top" v-if="data.name">
<div class="name-text ellipsis">{{ data.name || '--' }}</div> <div class="name-text ellipsis">{{ data.name || '--' }}</div>
</el-tooltip> </el-tooltip>
</div> </div>

View File

@ -3,8 +3,8 @@
<!-- --> <!-- -->
<div class="flex-row-start top"> <div class="flex-row-start top">
<div class="flex-row-start dept-left"> <div class="flex-row-start dept-left">
<dept-todo-view title="部门待办" v-loading="loadingToDo" :dataInfo="toToData"></dept-todo-view> <dept-todo-view title="待办" v-loading="loadingToDo" :dataInfo="toToData"></dept-todo-view>
<dept-todo-view title="部门已办" v-loading="loadingHasToDo" :dataInfo="hasToDodoData" <dept-todo-view title="已办" v-loading="loadingHasToDo" :dataInfo="hasToDodoData"
style="margin-left: 0"></dept-todo-view> style="margin-left: 0"></dept-todo-view>
</div> </div>
<div class="flex-row-start dept-chart-box"> <div class="flex-row-start dept-chart-box">
@ -56,7 +56,7 @@ export default {
list: [], list: [],
type: 'todo', type: 'todo',
// url: 'activiti-my-todo-task', // url: 'activiti-my-todo-task',
url: 'myAgent-CompetencyApplication', url: 'myAgent-CompetencyApplication'
}, },
// //
hasToDodoData: { hasToDodoData: {
@ -69,7 +69,7 @@ export default {
num: 0, num: 0,
list: [], list: [],
// url: 'activiti-my-join-task', // url: 'activiti-my-join-task',
url: 'hasToDoTasks-CompetencyApplication', url: 'hasToDoTasks-CompetencyApplication'
}, },
// //
resourceData: [], resourceData: [],
@ -103,43 +103,53 @@ export default {
// //
getToDo () { getToDo () {
this.loadingToDo = true this.loadingToDo = true
const data = { // const data = {
limit: 5, // limit: 5,
page: 1 // page: 1
} // }
Apis.getToDoTask(data, res => { this.$http.get('/act/task/myToDoTaskPage?page=1&limit=5').then(res => {
this.loadingToDo = false this.loadingToDo = false
if (res.data.code !== 0) { this.toToData.list = res.data.data.list || []
return this.$message.error(res.data.msg)
}
console.log('res----待办-------->', res.data)
this.toToData.list = res.data.data.records || []
this.toToData.num = res.data.data.total || 0 this.toToData.num = res.data.data.total || 0
}, err => {
this.$message.error(err)
this.loadingToDo = false
}) })
// Apis.getToDoTask(data, res => {
// this.loadingToDo = false
// if (res.data.code !== 0) {
// return this.$message.error(res.data.msg)
// }
// console.log('res------------>', res.data)
// this.toToData.list = res.data.data.records || []
// this.toToData.num = res.data.data.total || 0
// }, err => {
// this.$message.error(err)
// this.loadingToDo = false
// })
}, },
// //
getHasToDo () { getHasToDo () {
const data = { // const data = {
limit: 5, // limit: 5,
page: 1 // page: 1
} // }
this.loadingHasToDo = true this.loadingHasToDo = true
Apis.getHasToDoTask(data, res => { this.$http.get('/act/his/getMyHandledInstancePage?page=1&limit=5').then(res => {
this.loadingHasToDo = false this.loadingHasToDo = false
if (res.data.code !== 0) { this.hasToDodoData.list = res.data.data.list || []
return this.$message.error(res.data.msg)
}
console.log('res----已办-------->', res.data)
this.hasToDodoData.list = res.data.data.records || []
this.hasToDodoData.num = res.data.data.total || 0 this.hasToDodoData.num = res.data.data.total || 0
}, err => {
this.$message.error(err)
this.loadingHasToDo = false
console.log('err-----已办------->', err)
}) })
// Apis.getHasToDoTask(data, res => {
// this.loadingHasToDo = false
// if (res.data.code !== 0) {
// return this.$message.error(res.data.msg)
// }
// console.log('res------------>', res.data)
// this.hasToDodoData.list = res.data.data.records || []
// this.hasToDodoData.num = res.data.data.total || 0
// }, err => {
// this.$message.error(err)
// this.loadingHasToDo = false
// console.log('err------------>', err)
// })
}, },
// //
getShelvesTotal () { getShelvesTotal () {

View File

@ -2,18 +2,18 @@
* @Author: hisense.wuhongjian * @Author: hisense.wuhongjian
* @Date: 2020-07-07 16:03:23 * @Date: 2020-07-07 16:03:23
* @LastEditors: hisense.wuhongjian * @LastEditors: hisense.wuhongjian
* @LastEditTime: 2022-10-13 21:31:09 * @LastEditTime: 2022-10-24 11:50:52
* @Description: 系统静态参数配置 * @Description: 系统静态参数配置
*/ */
var _global = {} var _global = {}
var CONFIGITEM = { var CONFIGITEM = {
// version: 'qingdao', // // version: 'qingdao', //
version: 'xihaian', // 西 version: 'dev', // 西
// version: 'qingdao', // // version: 'qingdao', //
// version: 'zhanTingDev', // dev (2022-09-13:) // version: 'zhanTingDev', // dev (2022-09-13:)
// version: 'qingdao', // // version: 'qingdao', //
//version: 'frp', // 穿 //version: 'frp', // 穿
vNum: 'v0.8.7.2', vNum: 'v0.8.14.2',
configData: { configData: {
// //
qingdao: { qingdao: {
@ -27,8 +27,8 @@ var CONFIGITEM = {
backUrl: 'http://15.72.183.90:8001', backUrl: 'http://15.72.183.90:8001',
previewUrl: 'http://15.72.183.90:7008/', previewUrl: 'http://15.72.183.90:7008/',
//frontUrl: 'http://15.72.183.90:7008/document/#/devModelFile/', //frontUrl: 'http://15.72.183.90:7008/document/#/devModelFile/',
//apiURL: 'http://15.72.183.90:8000/renren-admin', apiURL: 'http://15.72.183.90:8000/renren-admin',
// websocketURL: '15.72.183.90:8000/renren-admin', websocketURL: '15.72.183.90:8000/renren-admin',
// websocketURL: '192.168.124.233:8888/renren-admin', // websocketURL: '192.168.124.233:8888/renren-admin',
POI_URL: POI_URL:
'http://15.72.178.129:8090/iserver/services/addressmatch-qingdaoPOI181015/restjsr/v1/address', 'http://15.72.178.129:8090/iserver/services/addressmatch-qingdaoPOI181015/restjsr/v1/address',
@ -86,8 +86,8 @@ var CONFIGITEM = {
userPwd: '', userPwd: '',
}, },
backUrl: 'http://localhost:8001', backUrl: 'http://localhost:8001',
previewUrl: 'http://192.168.124.236:9796/', previewUrl: 'http://192.168.124.243:9796/',
websocketURL: '192.168.124.233:8888/renren-admin', websocketURL: '192.168.124.243:8888/renren-admin',
// websocketURL: '10.18.1.99:8889/renren-admin', // websocketURL: '10.18.1.99:8889/renren-admin',
POI_URL: POI_URL:
'http://15.72.178.129:8090/iserver/services/addressmatch-qingdaoPOI181015/restjsr/v1/address', 'http://15.72.178.129:8090/iserver/services/addressmatch-qingdaoPOI181015/restjsr/v1/address',

View File

@ -103,4 +103,9 @@
@font-face { @font-face {
font-family: 'Alibaba PuHuiTi'; font-family: 'Alibaba PuHuiTi';
src: url('~@/assets/home/font/Alibaba-PuHuiTi-Light.otf'); src: url('~@/assets/home/font/Alibaba-PuHuiTi-Light.otf');
}
/* 气泡提示框按钮居中 */
.ant-popover-inner-content .ant-popover-buttons {
text-align: center;
} }

View File

@ -2,7 +2,7 @@
* @Author: hisense.wuhongjian * @Author: hisense.wuhongjian
* @Date: 2022-04-20 17:16:35 * @Date: 2022-04-20 17:16:35
* @LastEditors: hisense.wuhongjian * @LastEditors: hisense.wuhongjian
* @LastEditTime: 2022-08-25 14:13:30 * @LastEditTime: 2022-10-26 17:57:52
* @Description: 告诉大家这是什么 * @Description: 告诉大家这是什么
*/ */
import request from '@/utils/request' import request from '@/utils/request'
@ -99,14 +99,37 @@ export function getHls(params) {
} }
// 西-- (10.134.135.92:9537) // 西-- (10.134.135.92:9537)
let _cameraUrl = _global && _global.config && _global.config.camreaInfo && _global.config.camreaInfo.cameraUrl || '10.134.135.92:9537'; let _cameraUrl =
(_global &&
_global.config &&
_global.config.camreaInfo &&
_global.config.camreaInfo.cameraUrl) ||
'10.134.135.92:9537'
//- //-
export function getCameraInfoByAreaId(params) { export function getCameraInfoByAreaId(params) {
return axios.get(`http://${_cameraUrl}/data_service/getCamera/getCameraInfoByAreaId?areaId=${params.areaId}`, return axios.get(
`http://${_cameraUrl}/data_service/getCamera/getCameraInfoByAreaId?areaId=${params.areaId}`,
config2 config2
) )
} }
//- //-
export function getCameraByCondition(params) { export function getCameraByCondition(params) {
return axios.post(`http://${_cameraUrl}/data_service/getCamera/getCameraByCondition`, params, config2) return axios.post(
`http://${_cameraUrl}/data_service/getCamera/getCameraByCondition`,
params,
config2
)
}
export function initiateMeet(data) {
// return request({
// url: '/enke/initiateMeet',
// method: 'post',
// data: data,
// })
return axios.post(
'http://10.134.135.92:8888/renren-admin/enke/initiateMeet',
data,
config2
)
} }

View File

@ -1,8 +1,8 @@
/* /*
* @Author: hisense.wuhongjian * @Author: hisense.wuhongjian
* @Date: 2022-04-01 19:19:40 * @Date: 2022-04-01 19:19:40
* @LastEditors: hisense.liangjunhua * @LastEditors: Light
* @LastEditTime: 2022-08-23 09:37:58 * @LastEditTime: 2022-10-26 10:35:36
* @Description: 告诉大家这是什么 * @Description: 告诉大家这是什么
*/ */
import request from '@/utils/request' import request from '@/utils/request'
@ -103,6 +103,20 @@ export function getUserInfo(params) {
method: 'get', method: 'get',
}) })
} }
export function initiateMeet(data) {
return request({
url: '/enke/initiateMeet',
method: 'post',
data: data,
})
}
export function getEnkeUsers(params) {
return request({
url: '/enke/getEnkeUsers',
method: 'get',
params: params,
})
}
// //
export function ApplicationServe(data) { export function ApplicationServe(data) {
@ -405,11 +419,14 @@ export function updateIntegrationServices(data) {
} }
// //
export function getCountByFuzzyQuery(params) { export function getCountByFuzzyQuery(params, flag) {
return request({ return request({
url: '/resource/getCountByFuzzyQuery?keyWorld=' + params, url:
'/resource/getCountByFuzzyQuery?keyWorld=' +
params +
'&nonChinese=' +
flag,
method: 'get', method: 'get',
params,
}) })
} }
@ -492,4 +509,13 @@ export function getMaxApplyNum(number) {
url: '/processForm/tabilityapplication/canApply/' + number, url: '/processForm/tabilityapplication/canApply/' + number,
method: 'get', method: 'get',
}) })
} }
// -广-广GIS广
export function getGisByArea(data) {
return request({
url: '/resource/getSquareList',
method: 'post',
data,
})
}

View File

@ -308,4 +308,4 @@ export function getDeviceDetail(deviceId) {
url: `/device/${deviceId}`, url: `/device/${deviceId}`,
method: 'get', method: 'get',
}) })
} }

View File

@ -1,8 +1,8 @@
/* /*
* @Author: hisense.wuhongjian * @Author: hisense.wuhongjian
* @Date: 2022-03-29 17:48:03 * @Date: 2022-03-29 17:48:03
* @LastEditors: hisense.liangjunhua * @LastEditors: Light
* @LastEditTime: 2022-07-15 16:42:22 * @LastEditTime: 2022-10-25 09:37:05
* @Description: 告诉大家这是什么 * @Description: 告诉大家这是什么
*/ */
import request from '@/utils/request' import request from '@/utils/request'
@ -23,6 +23,13 @@ export async function socialLogin(data) {
}) })
} }
export function getRole(params) {
return request({
url: '/sys/role/' + params,
method: 'get',
params,
})
}
export function getUserInfo(redict) { export function getUserInfo(redict) {
//mock.js使dataaccessToken使mockheaders //mock.js使dataaccessToken使mockheaders
// debugger // debugger
@ -30,8 +37,8 @@ export function getUserInfo(redict) {
url: '/sys/user/info', url: '/sys/user/info',
method: 'get', method: 'get',
headers: { headers: {
REQUESTURI:redict REQUESTURI: redict,
} },
}) })
} }
export function getDeptAll() { export function getDeptAll() {

Binary file not shown.

After

Width:  |  Height:  |  Size: 757 KiB

View File

@ -16,6 +16,7 @@ const state = () => ({
username: '', username: '',
realName: '', realName: '',
deptName: '', deptName: '',
deptId: '',
userId: '', userId: '',
avatar: '', avatar: '',
role: 0, // role: 0, //
@ -28,6 +29,7 @@ const getters = {
role: (state) => state.role, role: (state) => state.role,
userId: (state) => state.userId, userId: (state) => state.userId,
deptName: (state) => state.deptName, deptName: (state) => state.deptName,
deptId: (state) => state.deptId,
} }
const mutations = { const mutations = {
/** /**
@ -70,6 +72,9 @@ const mutations = {
setDeptName(state, name) { setDeptName(state, name) {
state.deptName = name state.deptName = name
}, },
setDeptId(state, name) {
state.deptId = name
},
/** /**
* @author chuzhixin 1204505056@qq.com * @author chuzhixin 1204505056@qq.com
* @description 设置头像 * @description 设置头像
@ -143,6 +148,7 @@ const actions = {
commit('setRole', res.data.data.roleIdList.length) commit('setRole', res.data.data.roleIdList.length)
commit('setUserId', res.data.data.id) commit('setUserId', res.data.data.id)
commit('setDeptName', res.data.data.deptName) commit('setDeptName', res.data.data.deptName)
commit('setDeptId', res.data.data.deptId)
// TODO // TODO
// let { username, avatar, roles, ability } = data // let { username, avatar, roles, ability } = data
// if (username && roles && Array.isArray(roles)) { // if (username && roles && Array.isArray(roles)) {
@ -175,7 +181,7 @@ const actions = {
* @param {*} { commit, dispatch } * @param {*} { commit, dispatch }
*/ */
async resetAll({ dispatch }) { async resetAll({ dispatch }) {
debugger
await dispatch('setAccessToken', '') await dispatch('setAccessToken', '')
await dispatch('acl/setFull', false, { await dispatch('acl/setFull', false, {
root: true, root: true,

View File

@ -45,7 +45,6 @@ router.beforeEach(async (to, from, next) => {
}) })
console.log('验证白名单', routesWhiteList) console.log('验证白名单', routesWhiteList)
if (routesWhiteList.indexOf(to.path) !== -1) { if (routesWhiteList.indexOf(to.path) !== -1) {
debugger
next() next()
} else { } else {
// //

View File

@ -109,7 +109,7 @@
break break
case '资源申请量': case '资源申请量':
window.open( window.open(
window.SITE_CONFIG.backUrl + '/#/abilityStatistics-index', window.SITE_CONFIG.backUrl + '/#/abilityStatistics-index?type=use',
'_blank' '_blank'
) )
break break

View File

@ -262,6 +262,7 @@
center: ['50%', '40%'], center: ['50%', '40%'],
type: 'pie', type: 'pie',
selectedMode: 'single', selectedMode: 'single',
silent: true,
radius: ['50%', '30%'], radius: ['50%', '30%'],
color: ['#fe845e', '#6cc95a', '#02d1b0', '#1772ff', '#FAC858'], color: ['#fe845e', '#6cc95a', '#02d1b0', '#1772ff', '#FAC858'],
top: '0', top: '0',
@ -289,6 +290,7 @@
type: 'pie', type: 'pie',
center: ['50%', '40%'], center: ['50%', '40%'],
radius: ['58%', '50%'], radius: ['58%', '50%'],
silent: true,
itemStyle: { itemStyle: {
normal: { normal: {
color: '#c2c7d6', color: '#c2c7d6',

View File

@ -1,8 +1,8 @@
<!-- <!--
* @Author: hisense.liangjunhua * @Author: hisense.liangjunhua
* @Date: 2022-06-17 14:11:08 * @Date: 2022-06-17 14:11:08
* @LastEditors: hisense.wuhongjian * @LastEditors: Light
* @LastEditTime: 2022-08-25 19:52:03 * @LastEditTime: 2022-10-26 14:57:25
* @Description: 上架 * @Description: 上架
--> -->
<template> <template>
@ -95,7 +95,7 @@
disabled disabled
v-model:value="val[attr.field]" v-model:value="val[attr.field]"
:showCount="true" :showCount="true"
:maxlength="200" :maxlength="1000"
:placeholder="'请填写' + attr.name" :placeholder="'请填写' + attr.name"
v-else-if="attr.type == 'textArea'" v-else-if="attr.type == 'textArea'"
/> />
@ -166,7 +166,7 @@
<a-textarea <a-textarea
v-model:value="val.note1" v-model:value="val.note1"
:showCount="true" :showCount="true"
:maxlength="200" :maxlength="1000"
:placeholder="'请填写' + val.name" :placeholder="'请填写' + val.name"
v-else-if="val.type == 'textArea'" v-else-if="val.type == 'textArea'"
/> />
@ -203,7 +203,7 @@
</div> </div>
</div> </div>
</template> </template>
<template v-else> <template v-else>
<div class="bottom"> <div class="bottom">
<div <div
@ -270,7 +270,7 @@
v-else-if="item.type == 'textArea'" v-else-if="item.type == 'textArea'"
v-model:value="item.note1" v-model:value="item.note1"
:showCount="true" :showCount="true"
:maxlength="200" :maxlength="1000"
:placeholder="'请输入' + item.name" :placeholder="'请输入' + item.name"
@change="changeIiem(item.name, item.note1)" @change="changeIiem(item.name, item.note1)"
/> />
@ -703,7 +703,7 @@
data.value.list.push(item) data.value.list.push(item)
} }
}) })
} }
// else if (item.name === '') { // else if (item.name === '') {
// if (!item.note1) { // if (!item.note1) {
// getUserInfo().then(({ data: res1 }) => { // getUserInfo().then(({ data: res1 }) => {
@ -724,7 +724,7 @@
// } else { // } else {
// data.value.list.push(item) // data.value.list.push(item)
// } // }
// } // }
else if (item.name === '来源应用') { else if (item.name === '来源应用') {
queryApplicationRelByResourceId({ queryApplicationRelByResourceId({
referenceId: 0, referenceId: 0,
@ -1132,290 +1132,290 @@
</script> </script>
<style></style> <style></style>
<style lang="less" scoped> <style lang="less" scoped>
.put-on-the-shelf { .put-on-the-shelf {
height: 6.8rem; height: 6.8rem;
overflow: scroll; overflow: scroll;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
padding: 0.5rem 1rem 0.25rem; padding: 0.5rem 1rem 0.25rem;
.Technical-text { .Technical-text {
height: 0.3rem; height: 0.3rem;
width: 1rem; width: 1rem;
border: 0.01rem solid #bbd3ef; border: 0.01rem solid #bbd3ef;
border-radius: 0.06rem; border-radius: 0.06rem;
background: #edf4fc; background: #edf4fc;
color: #0087ff; color: #0087ff;
font-size: 0.14rem; font-size: 0.14rem;
text-align: center; text-align: center;
line-height: 0.3rem; line-height: 0.3rem;
} }
.Technical-text:hover { .Technical-text:hover {
cursor: pointer; cursor: pointer;
}
& > div {
width: 100%;
margin-top: 0.6rem;
.top {
color: #333333;
font-size: 0.22rem;
display: flex;
justify-content: center;
align-items: center;
margin-bottom: 0.25rem;
div:first-child,
div:last-child {
width: 2.45rem;
height: 0.01rem;
background: #f0f0f0;
}
div:nth-child(2) {
margin: 0 0.3rem;
}
} }
.bottom { & > div {
margin-top: 0.25rem; width: 100%;
margin-top: 0.6rem;
.items { .top {
background: #fafafa; color: #333333;
padding: 0.1rem; font-size: 0.22rem;
display: flex;
justify-content: center;
align-items: center;
margin-bottom: 0.25rem;
p { div:first-child,
display: flex; div:last-child {
justify-content: space-between; width: 2.45rem;
height: 0.01rem;
background: #f0f0f0;
}
span:nth-of-type(1) { div:nth-child(2) {
width: 2rem; margin: 0 0.3rem;
}
}
.bottom {
margin-top: 0.25rem;
.items {
background: #fafafa;
padding: 0.1rem;
p {
display: flex;
justify-content: space-between;
span:nth-of-type(1) {
width: 2rem;
}
span:nth-of-type(2) {
width: 100%;
font-weight: 600;
}
} }
span:nth-of-type(2) { p:nth-of-type(1) > span:nth-of-type(1) {
width: 100%; font-size: 0.18rem;
font-weight: 600; font-weight: 600;
} }
} }
p:nth-of-type(1) > span:nth-of-type(1) { .add {
font-size: 0.18rem; cursor: pointer;
font-weight: 600; margin-top: 0.1rem;
} font-size: 0.16rem;
} color: #007efb;
.add {
cursor: pointer;
margin-top: 0.1rem;
font-size: 0.16rem;
color: #007efb;
}
.form {
margin-top: 0.2rem;
display: flex;
justify-content: flex-start;
align-items: center;
span:first-child {
width: 1.2rem;
} }
:deep(.ant-input-textarea) { .form {
width: 5.2rem; margin-top: 0.2rem;
display: flex;
justify-content: flex-start;
align-items: center;
span:first-child {
width: 1.2rem;
}
:deep(.ant-input-textarea) {
width: 5.2rem;
}
:deep(.ant-radio-group) {
width: 5.2rem;
}
:deep(.ant-input-number) {
width: 2rem;
}
:deep(.ant-input) {
resize: none;
width: 5.2rem;
}
.ant-btn {
width: 1.6rem;
height: 0.32rem;
text-align: center;
background: #edf4fc;
color: #0087ff;
border: 0.01rem solid #bbd3ef;
border-radius: 0.06rem;
}
} }
:deep(.ant-radio-group) { .submit {
width: 5.2rem; margin-top: 0.4rem;
} font-size: 0.14rem;
display: flex;
justify-content: flex-end;
:deep(.ant-input-number) { .ant-btn {
width: 2rem; width: 1.8rem;
} height: 0.3rem;
text-align: center;
:deep(.ant-input) { background: #d9ebff;
resize: none; color: #0087ff;
width: 5.2rem; border: 0.01rem solid #0087ff;
} border-radius: 0.06rem;
}
.ant-btn {
width: 1.6rem;
height: 0.32rem;
text-align: center;
background: #edf4fc;
color: #0087ff;
border: 0.01rem solid #bbd3ef;
border-radius: 0.06rem;
}
}
.submit {
margin-top: 0.4rem;
font-size: 0.14rem;
display: flex;
justify-content: flex-end;
.ant-btn {
width: 1.8rem;
height: 0.3rem;
text-align: center;
background: #d9ebff;
color: #0087ff;
border: 0.01rem solid #0087ff;
border-radius: 0.06rem;
} }
} }
} }
}
& > div:nth-of-type(1) {
margin-top: 0;
}
}
.application-Area {
width: 5.2rem;
display: grid;
margin-top: -0.05rem;
grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr;
.application-Area-son {
cursor: pointer;
font-size: 0.14rem;
width: 0.9rem;
height: 0.26rem;
border-radius: 0.13rem;
color: #333333;
background: #f5f5f5;
border: 0.01rem #cccccc solid;
display: flex;
justify-content: center;
align-items: center;
margin-top: 0.1rem;
font-weight: 500;
}
.application-Area-down {
background: #0087ff;
color: #fff;
}
}
:deep(.ant-image-img) {
width: 100%;
height: 100%;
object-fit: contain;
}
:deep(.ant-modal) {
width: 9.6rem;
}
:deep(.ant-transfer-list) {
width: 39.5%;
height: 5.2rem;
}
:deep(.ant-transfer-operation) {
flex-direction: row-reverse;
margin: 0 0.3rem;
}
:deep(.ant-btn) {
width: 0.56rem;
height: 0.4rem;
border-radius: 0.04rem;
}
:deep(.ant-btn:first-child) {
margin-left: 0.04rem;
}
:deep(.ant-modal-footer) {
border: 0;
}
:deep(.ant-modal-header) {
border: 0;
}
:deep(.ant-modal-title) {
line-height: 0.24rem;
font-size: 0.18rem;
color: #303133;
}
:deep(.ant-transfer-list-header) {
background: #f5f7fa;
}
:deep(.ant-transfer-list-header-selected) {
display: flex;
width: 90%;
flex-direction: row-reverse;
justify-content: space-between;
align-items: center;
}
:deep(.ant-transfer-list-header-title) {
font-size: 0.16rem;
color: #303133;
font-weight: 400;
text-align: left;
}
:deep(.ant-transfer-list-header .ant-checkbox-wrapper) {
display: none !important;
}
:deep(.ant-upload-list-item-name) {
width: 1rem;
}
.del {
display: flex;
justify-content: flex-start;
align-items: center;
font-size: 0.14rem;
margin-left: 0.2rem;
.delImg {
cursor: pointer;
display: inline-block;
width: 0.16rem;
height: 0.18rem;
background: url(~@/assets/home/sf_del.png) no-repeat;
margin-right: 0.05rem;
}
div {
cursor: pointer;
}
}
.item {
position: relative;
span:first-child {
width: unset;
}
.box {
display: flex;
align-items: center;
// margin: 15px 0;
& > div:nth-of-type(1) { & > div:nth-of-type(1) {
width: 105px; margin-top: 0;
}
}
.application-Area {
width: 5.2rem;
display: grid;
margin-top: -0.05rem;
grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr;
.application-Area-son {
cursor: pointer;
font-size: 0.14rem;
width: 0.9rem;
height: 0.26rem;
border-radius: 0.13rem;
color: #333333;
background: #f5f5f5;
border: 0.01rem #cccccc solid;
display: flex;
justify-content: center;
align-items: center;
margin-top: 0.1rem;
font-weight: 500;
}
.application-Area-down {
background: #0087ff;
color: #fff;
}
}
:deep(.ant-image-img) {
width: 100%;
height: 100%;
object-fit: contain;
}
:deep(.ant-modal) {
width: 9.6rem;
}
:deep(.ant-transfer-list) {
width: 39.5%;
height: 5.2rem;
}
:deep(.ant-transfer-operation) {
flex-direction: row-reverse;
margin: 0 0.3rem;
}
:deep(.ant-btn) {
width: 0.56rem;
height: 0.4rem;
border-radius: 0.04rem;
}
:deep(.ant-btn:first-child) {
margin-left: 0.04rem;
}
:deep(.ant-modal-footer) {
border: 0;
}
:deep(.ant-modal-header) {
border: 0;
}
:deep(.ant-modal-title) {
line-height: 0.24rem;
font-size: 0.18rem;
color: #303133;
}
:deep(.ant-transfer-list-header) {
background: #f5f7fa;
}
:deep(.ant-transfer-list-header-selected) {
display: flex;
width: 90%;
flex-direction: row-reverse;
justify-content: space-between;
align-items: center;
}
:deep(.ant-transfer-list-header-title) {
font-size: 0.16rem;
color: #303133;
font-weight: 400;
text-align: left;
}
:deep(.ant-transfer-list-header .ant-checkbox-wrapper) {
display: none !important;
}
:deep(.ant-upload-list-item-name) {
width: 1rem;
}
.del {
display: flex;
justify-content: flex-start;
align-items: center;
font-size: 0.14rem;
margin-left: 0.2rem;
.delImg {
cursor: pointer;
display: inline-block;
width: 0.16rem;
height: 0.18rem;
background: url(~@/assets/home/sf_del.png) no-repeat;
margin-right: 0.05rem;
}
div {
cursor: pointer;
}
}
.item {
position: relative;
span:first-child {
width: unset;
}
.box {
display: flex; display: flex;
align-items: center; align-items: center;
// margin: 15px 0;
& > div:nth-of-type(1) {
width: 105px;
display: flex;
align-items: center;
}
.required {
color: #f56c6c;
margin-right: 3px;
}
} }
.required { .requiredTips {
font-size: 14px;
color: #f56c6c; color: #f56c6c;
margin-right: 3px; position: absolute;
bottom: -20px;
left: 110px;
} }
} }
.requiredTips {
font-size: 14px;
color: #f56c6c;
position: absolute;
bottom: -20px;
left: 110px;
}
}
</style> </style>

View File

@ -1,31 +1,38 @@
<!-- 智能算法 --> <!-- 智能算法 -->
<template> <template>
<div class="algorithm"> <div class="algorithm">
<div class="select"> <div style="display: flex">
<div class="top" @click="selectFlag2 = true"> <div class="select">
{{ typeName2 }} <div class="top" @click="selectFlag = !selectFlag">
<div class="light"></div> {{ typeName }}
<div class="light"></div>
</div>
<div class="bottom" v-show="selectFlag">
<span class="light"></span>
<div @click="changeDeptType('全市')">全市</div>
<div @click="changeDeptType('市级')">市级</div>
<div @click="changeDeptType('区级')">区级</div>
<div @click="changeDeptType('企业')">企业</div>
</div>
</div> </div>
<div class="bottom" v-show="selectFlag2"> <div class="select">
<span class="light"></span> <div class="top" @click="selectFlag2 = true">
<div v-for="val in dictList" :key="val" @click="getList2(val)"> {{ typeName2 }}
{{ val }} <div class="light"></div>
</div>
<div class="bottom" v-show="selectFlag2">
<span class="light"></span>
<div v-for="val in dictList" :key="val" @click="changeAreaFunction(val)">
{{ val }}
</div>
</div> </div>
</div> </div>
</div> </div>
<div class="algorithm-class"> <div class="algorithm-class">
<div <div v-for="(item, index) in dataList" :key="`algorithm-${index}`" class="algorithm-card">
v-for="(item, index) in dataList" <a-image :src="algorithmCardPhoto(item)" :width="525" :height="275" :fallback="imgSrc" :preview="false">
:key="`algorithm-${index}`" </a-image>
class="algorithm-card"
>
<a-image
:src="algorithmCardPhoto(item.infoList, item)"
:width="525"
:height="275"
:fallback="imgSrc"
:preview="false"
></a-image>
<a-tooltip> <a-tooltip>
<template #title>{{ item.name }}</template> <template #title>{{ item.name }}</template>
@ -39,248 +46,308 @@
</div> </div>
</template> </template>
<script setup> <script setup>
import { getCategoryTreePage } from '@/api/personalCenter' import { getCategoryTreePage } from '@/api/personalCenter'
import { pageWithAttrs } from '@/api/abilityStatistics' import { getGisByArea } from '@/api/home'
import { ref, onMounted, onBeforeUnmount } from 'vue' import { ref, onMounted, onBeforeUnmount, nextTick } from 'vue'
const typeName2 = ref('全部')
const dictList = ref([])
const dataList = ref([]) const deptType = ref(null)
const selectFlag2 = ref(false) const typeName = ref('全市')
getCategoryTreePage({ const typeName2 = ref('全部')
page: 1, const dictList = ref([])
limit: 99, const dataList = ref([])
dictTypeId: '1513712507692818433', const selectFlag2 = ref(false)
}).then((res) => { const selectFlag = ref(false)
dictList.value = ['全部'] getCategoryTreePage({
res.data.data.list.map((val) => { page: 1,
if (val.dictLabel !== '其他') { limit: 99,
dictList.value.push(val.dictLabel) dictTypeId: '1513712507692818433',
} }).then((res) => {
}) dictList.value = ['全部']
res.data.data.list.map((val) => {
// if (val.dictLabel !== '') {
dictList.value.push(val.dictLabel)
// }
}) })
const params = { })
deptIds: [], const params = {
districtId: '', pageNum: 1,
infoList: [{ attrType: '组件类型', attrValue: '智能算法' }], type: '智能算法',
orderField: 'pin_top', area: typeName2.value == '全部' ? '' : typeName2.value,
orderType: 'DESC', pageSize: 9 // 9
pageNum: 1, }
pageSize: 9,
type: '组件服务', //
} const changeAreaFunction = (val) => {
const getList2 = (val) => { params.pageNum = 1;
typeName2.value = val typeName2.value = val
if (val == '全部') { params.area = typeName2.value == '全部' ? '' : typeName2.value;
params.infoList = [{ attrType: '组件类型', attrValue: '智能算法' }] selectFlag2.value = false
} else { pageWithAttrsFunction()
params.infoList = [ }
{ attrType: '组件类型', attrValue: '智能算法' }, let algorithmclassDom = null
{ attrType: '应用领域', attrValue: val }, const imgSrc = ref(require('@/assets/capacitySquare/algorithm-photo.jpg'))
] const dataLength = ref(true)
const isNoMore = ref(false)
let url = ref('')
const pageWithAttrsFunction = () => {
getGisByArea(params).then((res) => {
dataList.value = res.data.data.list
if (res.data.data.list.length < 9) {
dataLength.value = false
} }
selectFlag2.value = false })
pageWithAttrsFunction() }
pageWithAttrsFunction()
//
const algorithmCardPhoto = (item) => {
let _arr = []
if(item.pic && typeof item.pic == 'string') {
_arr = JSON.parse(item.pic)
} }
let algorithmclass = null let _img = _arr[0] && _arr[0].img || imgSrc.value;
const imgSrc = ref(require('@/assets/capacitySquare/algorithm-photo.jpg')) console.log('_img------------>', _img);
const dataLength = ref(true) return _img
const isNoMore = ref(false) }
let url = ref('') //
const pageWithAttrsFunction = () => { const detailFunction = (id) => {
pageWithAttrs(params).then((res) => { window.open(window.SITE_CONFIG.previewUrl + `#/details?id=${id}`)
dataList.value = res.data.data.records }
if (res.data.data.records.length < 9) { const algorithmFunction = (e) => {
var scrollTop = e.currentTarget.scrollTop
var windowHeight = e.currentTarget.clientHeight
var scrollHeight = e.currentTarget.scrollHeight
console.log(scrollTop, windowHeight, scrollHeight, '123')
if (
scrollTop + windowHeight <= scrollHeight + 1 &&
scrollTop + windowHeight >= scrollHeight - 1
) {
//
isNoMore.value = true
params.pageNum++
getGisByArea(params).then((res) => {
dataList.value.push(...res.data.data.list)
if (res.data.data.list.length < 9) {
dataLength.value = false dataLength.value = false
} }
}) })
} else {
isNoMore.value = false
} }
pageWithAttrsFunction() }
//
const algorithmCardPhoto = (List, item) => {
let obj = List.filter((item) => item.attrType === '应用场景')[0]
if (obj && obj.attrValue != '') {
console.log(
item.name,
item.id,
obj.attrValue,
'----------------------------'
)
obj = JSON.parse(obj.attrValue)[0].img
}
return obj || ''
}
//
const detailFunction = (id) => {
window.open(window.SITE_CONFIG.previewUrl + `#/details?id=${id}`)
}
const algorithmFunction = (e) => {
var scrollTop = e.currentTarget.scrollTop
var windowHeight = e.currentTarget.clientHeight
var scrollHeight = e.currentTarget.scrollHeight
console.log(scrollTop, windowHeight, scrollHeight, '123')
if (
scrollTop + windowHeight <= scrollHeight + 1 &&
scrollTop + windowHeight >= scrollHeight - 1
) {
//
isNoMore.value = true
params.pageNum++
pageWithAttrs(params).then((res) => {
dataList.value.push(...res.data.data.records)
if (res.data.data.records.length < 9) {
dataLength.value = false
}
})
} else {
isNoMore.value = false
}
}
onMounted(() => { //
algorithmclass = document.querySelector('.algorithm-class') const changeDeptType = (str) => {
if (dataLength.value) { if (str) {
// if (algorithmclassDom) {
algorithmclass.addEventListener('scroll', algorithmFunction, true) algorithmclassDom.scrollTop = 0;
} }
switch (str) {
case '全市':
deptType.value = null
typeName.value = '全 市'
break
case '市级':
deptType.value = 2
typeName.value = '市 级'
break
case '区级':
deptType.value = 3
typeName.value = '区 级'
break
case '企业':
deptType.value = 4
typeName.value = '企 业'
break
}
params.pageNum = 1;
if(deptType.value !== null && deptType.value !== undefined) {
params.deptType = deptType.value;
}else {
if(Object.keys(params).includes('deptType')) {
delete params.deptType
}
}
}
selectFlag.value = false
getData(str)
}
const getData = (str) => {
getGisByArea(params).then((res) => {
const resData = res.data.data || {}
if (resData.list.length > 0 && resData.list.length < 9 && algorithmclassDom) {
algorithmclassDom.removeEventListener('scroll', algorithmFunction, true)
}
dataList.value = resData.list || []
nextTick(() => {
algorithmclassDom = document.querySelector('.algorithm-box')
if (str && algorithmclassDom) {
algorithmclassDom.removeEventListener('scroll', algorithmFunction, true)
algorithmclassDom.addEventListener('scroll', algorithmFunction, true)
}
})
}) })
onBeforeUnmount(() => { }
algorithmclass.removeEventListener('scroll', algorithmFunction, true)
}) onMounted(() => {
algorithmclassDom = document.querySelector('.algorithm-class')
if (dataLength.value) {
//
algorithmclassDom.addEventListener('scroll', algorithmFunction, true)
}
})
onBeforeUnmount(() => {
algorithmclassDom.removeEventListener('scroll', algorithmFunction, true)
})
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.algorithm { .algorithm {
.select { .select {
margin: 0.1rem 0 0.1rem 0.2rem; margin: 0.1rem 0 0.1rem 0.2rem;
color: #fff; color: #fff;
font-size: 0.2rem; font-size: 0.2rem;
font-family: webfont; font-family: webfont;
position: relative;
.top {
cursor: pointer;
width: 3.61rem;
height: 0.85rem;
font-weight: 600;
text-align: center;
padding-top: 0.1rem;
background: url('~@/assets/capacitySquare/select-bg.png') no-repeat;
background-size: 100%;
position: relative; position: relative;
.top {
cursor: pointer; .light {
width: 3.61rem; width: 0.56rem;
height: 0.85rem; height: 3px;
font-weight: 600;
text-align: center;
padding-top: 0.1rem;
background: url('~@/assets/capacitySquare/select-bg.png') no-repeat;
background-size: 100%;
position: relative;
.light {
width: 0.56rem;
height: 3px;
position: absolute;
top: 0.4rem;
left: 1.52rem;
background: url('~@/assets/capacitySquare/select-light1.png')
no-repeat;
background-size: 100%;
}
}
.bottom {
cursor: pointer;
position: absolute; position: absolute;
top: 0.5rem; top: 0.4rem;
left: 0.9rem; left: 1.52rem;
z-index: 1000; background: url('~@/assets/capacitySquare/select-light1.png') no-repeat;
background: rgba(57, 134, 239, 0.68); background-size: 100%;
border: 1px solid #aed5ff;
.light {
display: inline-block;
width: 2.39rem;
height: 5px;
position: absolute;
top: -0.08rem;
left: -0.3rem;
background: url('~@/assets/capacitySquare/select-light2.png')
no-repeat;
background-size: 100%;
}
& > div {
width: 1.8rem;
height: 0.4rem;
line-height: 0.4rem;
text-align: center;
border-top: 1px solid #aed5ff;
}
& > div:nth-of-type(1) {
border: none;
}
} }
} }
.algorithm-class {
// margin-top: 0.6rem; .bottom {
margin-bottom: 0.18rem; cursor: pointer;
display: grid; position: absolute;
grid-template-columns: repeat(3, 33%); top: 0.5rem;
height: 8.8rem; left: 0.9rem;
overflow: auto; z-index: 1000;
margin-left: 1.15rem; background: rgba(57, 134, 239, 0.68);
margin-right: 0.15rem; border: 1px solid #aed5ff;
.algorithm-card {
height: 2.75rem; .light {
width: 5.25rem; display: inline-block;
background: url('~@/assets/capacitySquare/algorithm-bg.png') no-repeat; width: 2.39rem;
background-size: 100% 100%; height: 5px;
margin-bottom: 0.4rem; position: absolute;
margin-right: 0.65rem; top: -0.08rem;
position: relative; left: -0.3rem;
:deep(.ant-image) { background: url('~@/assets/capacitySquare/select-light2.png') no-repeat;
img { background-size: 100%;
margin-top: 0.15rem; }
height: 2.45rem;
width: 5.05rem; &>div {
margin-left: 0.1rem; width: 1.8rem;
} height: 0.4rem;
} line-height: 0.4rem;
.algorithm-card-photo { text-align: center;
height: 100%; border-top: 1px solid #aed5ff;
width: 100%; }
background: url('~@/assets/capacitySquare/algorithm-photo.jpg')
no-repeat; &>div:nth-of-type(1) {
background-size: 100%; border: none;
}
.algorithm-card-title {
position: absolute;
height: 0.6rem;
margin-left: 0.08rem;
width: 97%;
color: #ffffff;
font-size: 0.22rem;
font-family: alibaba;
bottom: 0.15rem;
padding-left: 0.22rem;
background: url('~@/assets/capacitySquare/algorithm-title-bg.png')
no-repeat;
background-size: 100%;
display: flex;
flex-direction: column;
justify-content: center;
span {
line-height: 0.24rem;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
cursor: pointer;
}
span:last-child {
font-size: 0.14rem;
}
}
} }
}
.algorithm-class::-webkit-scrollbar-track-piece {
background: #a5bcdb;
border-radius: 0.08rem;
}
.algorithm-class::-webkit-scrollbar-thumb {
height: 3.2rem;
background: linear-gradient(to bottom, #47d7f5, #3dc6e3);
}
.algorithm-class::-webkit-scrollbar {
height: 8.8rem;
width: 0.08rem;
border-radius: 0.08rem;
} }
} }
.algorithm-class {
// margin-top: 0.6rem;
margin-bottom: 0.18rem;
display: grid;
grid-template-columns: repeat(3, 33%);
height: 8.8rem;
overflow: auto;
margin-left: 1.15rem;
margin-right: 0.15rem;
.algorithm-card {
height: 2.75rem;
width: 5.25rem;
background: url('~@/assets/capacitySquare/algorithm-bg.png') no-repeat;
background-size: 100% 100%;
margin-bottom: 0.4rem;
margin-right: 0.65rem;
position: relative;
:deep(.ant-image) {
img {
margin-top: 0.15rem;
height: 2.45rem;
width: 5.05rem;
margin-left: 0.1rem;
}
}
.algorithm-card-photo {
height: 100%;
width: 100%;
background: url('~@/assets/capacitySquare/algorithm-photo.jpg') no-repeat;
background-size: 100%;
}
.algorithm-card-title {
position: absolute;
height: 0.6rem;
margin-left: 0.08rem;
width: 97%;
color: #ffffff;
font-size: 0.22rem;
font-family: alibaba;
bottom: 0.15rem;
padding-left: 0.22rem;
background: url('~@/assets/capacitySquare/algorithm-title-bg.png') no-repeat;
background-size: 100%;
display: flex;
flex-direction: column;
justify-content: center;
span {
line-height: 0.24rem;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
cursor: pointer;
}
span:last-child {
font-size: 0.14rem;
}
}
}
}
.algorithm-class::-webkit-scrollbar-track-piece {
background: #a5bcdb;
border-radius: 0.08rem;
}
.algorithm-class::-webkit-scrollbar-thumb {
height: 3.2rem;
background: linear-gradient(to bottom, #47d7f5, #3dc6e3);
}
.algorithm-class::-webkit-scrollbar {
height: 8.8rem;
width: 0.08rem;
border-radius: 0.08rem;
}
}
</style> </style>

View File

@ -1,8 +1,8 @@
<!-- <!--
* @Author: hisense.liangjunhua * @Author: hisense.liangjunhua
* @Date: 2022-08-09 09:31:25 * @Date: 2022-08-09 09:31:25
* @LastEditors: hisense.liangjunhua * @LastEditors: hisense.wuhongjian
* @LastEditTime: 2022-09-19 10:19:02 * @LastEditTime: 2022-10-24 10:44:50
* @Description: 应用资源 * @Description: 应用资源
--> -->
<template> <template>
@ -74,9 +74,9 @@
}).then((res) => { }).then((res) => {
dictList.value = ['全部'] dictList.value = ['全部']
res.data.data.list.map((val) => { res.data.data.list.map((val) => {
if (val.dictLabel !== '其他') { // if (val.dictLabel !== '') {
dictList.value.push(val.dictLabel) dictList.value.push(val.dictLabel)
} // }
}) })
}) })
let dom = null let dom = null
@ -121,16 +121,19 @@
type: type.value, type: type.value,
area: area.value, area: area.value,
}).then((res) => { }).then((res) => {
if (res.data.data.length < 9) { console.log('res---应用广场--------->', res);
if (res.data.data.total.length < 9) {
dom.removeEventListener('scroll', viewMonitor, true) dom.removeEventListener('scroll', viewMonitor, true)
} }
res.data.data.map((val) => { // appList
res.data.data.appList.map((val) => {
if (!val.pic) { if (!val.pic) {
val.pic = require('@/assets/capacitySquare/yyzy.jpg') val.pic = require('@/assets/capacitySquare/yyzy.jpg')
} }
val.pic2 = require('@/assets/capacitySquare/yyzy.jpg') val.pic2 = require('@/assets/capacitySquare/yyzy.jpg')
}) })
data.list.push(...res.data.data) data.list.push(...res.data.data.appList)
selectFlag.value = false selectFlag.value = false
nextTick(() => { nextTick(() => {
dom = document.querySelector('.item-box') dom = document.querySelector('.item-box')

View File

@ -1,15 +1,34 @@
<!-- 图层服务 --> <!-- 图层服务 -->
<template> <template>
<div class="algorithm"> <div class="algorithm">
<div class="select"> <div style="display: flex">
<div class="top" @click="selectFlag2 = true"> <div class="select">
{{ typeName2 }} <div class="top" @click="selectFlag = !selectFlag">
<div class="light"></div> {{ typeName }}
<div class="light"></div>
</div>
<div class="bottom" v-show="selectFlag">
<span class="light"></span>
<div @click="changeDeptType('全市')">全市</div>
<div @click="changeDeptType('市级')">市级</div>
<div @click="changeDeptType('区级')">区级</div>
<div @click="changeDeptType('企业')">企业</div>
</div>
</div> </div>
<div class="bottom" v-show="selectFlag2"> <div class="select">
<span class="light"></span> <div class="top" @click="selectFlag2 = true">
<div v-for="val in dictList" :key="val" @click="getList2(val)"> {{ typeName2 }}
{{ val }} <div class="light"></div>
</div>
<div class="bottom" v-show="selectFlag2">
<span class="light"></span>
<div
v-for="val in dictList"
:key="val"
@click="changeAreaFunction(val)"
>
{{ val }}
</div>
</div> </div>
</div> </div>
</div> </div>
@ -20,13 +39,12 @@
class="algorithm-card" class="algorithm-card"
> >
<a-image <a-image
:src="algorithmCardPhoto(item.infoList)" :src="item.pic || imgSrc"
:width="525" :width="525"
:height="275" :height="275"
:fallback="imgSrc" :fallback="imgSrc"
:preview="false" :preview="false"
></a-image> ></a-image>
<a-tooltip> <a-tooltip>
<template #title>{{ item.name }}</template> <template #title>{{ item.name }}</template>
<div class="algorithm-card-title" @click="detailFunction(item.id)"> <div class="algorithm-card-title" @click="detailFunction(item.id)">
@ -40,12 +58,15 @@
</template> </template>
<script setup> <script setup>
import { getCategoryTreePage } from '@/api/personalCenter' import { getCategoryTreePage } from '@/api/personalCenter'
import { pageWithAttrs } from '@/api/abilityStatistics' import { getGisByArea } from '@/api/home'
import { ref, onMounted, onBeforeUnmount } from 'vue' import { ref, onMounted, onBeforeUnmount, nextTick } from 'vue'
const deptType = ref(null)
const typeName = ref('全市')
const typeName2 = ref('全部') const typeName2 = ref('全部')
const dictList = ref([]) const dictList = ref([])
const dataList = ref([]) const dataList = ref([])
const selectFlag2 = ref(false) const selectFlag2 = ref(false)
const selectFlag = ref(false)
getCategoryTreePage({ getCategoryTreePage({
page: 1, page: 1,
limit: 99, limit: 99,
@ -53,61 +74,101 @@
}).then((res) => { }).then((res) => {
dictList.value = ['全部'] dictList.value = ['全部']
res.data.data.list.map((val) => { res.data.data.list.map((val) => {
if (val.dictLabel !== '其他') { // if (val.dictLabel !== '') {
dictList.value.push(val.dictLabel) dictList.value.push(val.dictLabel)
} // }
}) })
}) })
const params = { const params = {
deptIds: [],
districtId: '',
infoList: [{ attrType: '组件类型', attrValue: '图层服务' }],
orderField: 'deptSort',
orderType: 'DESC',
pageNum: 1, pageNum: 1,
pageSize: 9, type: '图层服务',
type: '组件服务', area: typeName2.value == '全部' ? '' : typeName2.value,
pageSize: 9, // 9
} }
const getList2 = (val) => { //
const changeAreaFunction = (val) => {
params.pageNum = 1
typeName2.value = val typeName2.value = val
if (val == '全部') { params.area = typeName2.value == '全部' ? '' : typeName2.value
params.infoList = [{ attrType: '组件类型', attrValue: '图层服务' }]
} else {
params.infoList = [
{ attrType: '组件类型', attrValue: '图层服务' },
{ attrType: '应用领域', attrValue: val },
]
}
selectFlag2.value = false selectFlag2.value = false
pageWithAttrsFunction() pageWithAttrsFunction()
} }
let algorithmclass = null let algorithmclassDom = null
const imgSrc = ref(require('@/assets/capacitySquare/algorithm-photo2.jpg')) const imgSrc = ref(require('@/assets/capacitySquare/algorithm-photo2.jpg'))
const dataLength = ref(true) const dataLength = ref(true)
const isNoMore = ref(false) const isNoMore = ref(false)
const pageWithAttrsFunction = () => { const pageWithAttrsFunction = () => {
pageWithAttrs(params).then((res) => { getGisByArea(params).then((res) => {
dataList.value = res.data.data.records dataList.value = res.data.data.list
if (res.data.data.records.length < 9) { if (res.data.data.list.length < 9) {
dataLength.value = false dataLength.value = false
} }
}) })
} }
pageWithAttrsFunction() pageWithAttrsFunction()
//
const algorithmCardPhoto = (List) => {
let url = ''
List.map((item) => {
if (item.attrType === '图层缩略图') {
url = item.attrValue
}
})
return url
}
// //
const detailFunction = (id) => { const detailFunction = (id) => {
window.open(window.SITE_CONFIG.previewUrl + `#/details?id=${id}`) window.open(window.SITE_CONFIG.previewUrl + `#/details?id=${id}`)
} }
const changeDeptType = (str) => {
if (str) {
if (algorithmclassDom) {
algorithmclassDom.scrollTop = 0
}
switch (str) {
case '全市':
deptType.value = null
typeName.value = '全 市'
break
case '市级':
deptType.value = 2
typeName.value = '市 级'
break
case '区级':
deptType.value = 3
typeName.value = '区 级'
break
case '企业':
deptType.value = 4
typeName.value = '企 业'
break
}
params.pageNum = 1
if (deptType.value !== null && deptType.value !== undefined) {
params.deptType = deptType.value
} else {
if (Object.keys(params).includes('deptType')) {
delete params.deptType
}
}
}
selectFlag.value = false
getData(str)
}
const getData = (str) => {
getGisByArea(params).then((res) => {
const resData = res.data.data || {}
if (
resData.list.length > 0 &&
resData.list.length < 9 &&
algorithmclassDom
) {
algorithmclassDom.removeEventListener('scroll', algorithmFunction, true)
}
dataList.value = resData.list || []
nextTick(() => {
algorithmclassDom = document.querySelector('.algorithm-box')
if (str && algorithmclassDom) {
algorithmclassDom.removeEventListener(
'scroll',
algorithmFunction,
true
)
algorithmclassDom.addEventListener('scroll', algorithmFunction, true)
}
})
})
}
const layerFunction = (e) => { const layerFunction = (e) => {
var scrollTop = e.currentTarget.scrollTop var scrollTop = e.currentTarget.scrollTop
var windowHeight = e.currentTarget.clientHeight var windowHeight = e.currentTarget.clientHeight
@ -120,9 +181,9 @@
// //
isNoMore.value = true isNoMore.value = true
params.pageNum++ params.pageNum++
pageWithAttrs(params).then((res) => { getGisByArea(params).then((res) => {
dataList.value.push(...res.data.data.records) dataList.value.push(...res.data.data.list)
if (res.data.data.records.length < 9) { if (res.data.data.list.length < 9) {
dataLength.value = false dataLength.value = false
} }
}) })
@ -131,17 +192,16 @@
} }
} }
onMounted(() => { onMounted(() => {
algorithmclass = document.querySelector('.algorithm-class') algorithmclassDom = document.querySelector('.algorithm-class')
if (dataLength.value) { if (dataLength.value) {
// //
algorithmclass.addEventListener('scroll', layerFunction, true) algorithmclassDom.addEventListener('scroll', layerFunction, true)
} }
}) })
onBeforeUnmount(() => { onBeforeUnmount(() => {
algorithmclass.removeEventListener('scroll', layerFunction, true) algorithmclassDom.removeEventListener('scroll', layerFunction, true)
}) })
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.algorithm { .algorithm {
.select { .select {
@ -277,4 +337,4 @@
border-radius: 0.08rem; border-radius: 0.08rem;
} }
} }
</style> </style>

File diff suppressed because it is too large Load Diff

View File

@ -88,9 +88,9 @@
v-else v-else
placeholder="请选择归属部门" placeholder="请选择归属部门"
v-model:value="formName.unit" v-model:value="formName.unit"
:getPopupContainer="(triggerNode) => triggerNode.parentNode" :getPopupContainer="(triggerNode) => triggerNode.parentNode"
show-search show-search
:filterOption="true" :filterOption="true"
@change="deptIdChangeFunction" @change="deptIdChangeFunction"
> >
<a-select-option <a-select-option
@ -811,10 +811,10 @@
const handleBlur = () => { const handleBlur = () => {
console.log('blur') console.log('blur')
} }
const arrId = []
const handleFocus = () => { const handleFocus = () => {
console.log('focus') console.log('focus', systemOptions2.value, systemOptions.value)
let arrId = [] for (let valueIndex of systemOptions2.value) {
for (var valueIndex of systemOptions2.value) {
if (arrId.indexOf(valueIndex['value']) == -1) { if (arrId.indexOf(valueIndex['value']) == -1) {
arrId.push(valueIndex['value']) arrId.push(valueIndex['value'])
systemOptions.value.push(valueIndex) systemOptions.value.push(valueIndex)

File diff suppressed because it is too large Load Diff

View File

@ -230,13 +230,8 @@
</span> </span>
</template> </template>
</div> </div>
<div <div v-if="selectCardsname === '打包模式'" class="label-content1">
v-if=" 发布时间
selectCardsname === '打包模式'
"
class="label-content1"
>
发布时间
<template v-if="item.createDate"> <template v-if="item.createDate">
<span> <span>
{{ item.createDate.substring(0, 10) + ' ' }} {{ item.createDate.substring(0, 10) + ' ' }}
@ -300,11 +295,13 @@
> >
申请量{{ item.applyCount || 0 }} 申请量{{ item.applyCount || 0 }}
</div> </div>
<!-- 青岛不展示数据量 -->
<div <div
v-if=" v-if="
selectCardsname === '数据资源' && selectCardsname === '数据资源' &&
selectCardsname !== '融合服务' && selectCardsname !== '融合服务' &&
selectCardsname !== '赋能场景' selectCardsname !== '赋能场景' &&
whoShow1.itShowXiHaiAn
" "
> >
数据量{{ item.sjlCount || 0 }} 数据量{{ item.sjlCount || 0 }}
@ -1004,7 +1001,7 @@
margin: 0 10px 0 0; margin: 0 10px 0 0;
.header-right { .header-right {
// display: flex; // display: flex;
font-size: 14px; font-size: 14px;
color: #212121; color: #212121;

View File

@ -117,6 +117,7 @@
import mybus from '@/myplugins/mybus' import mybus from '@/myplugins/mybus'
import { useRouter } from 'vue-router' import { useRouter } from 'vue-router'
import { UpOutlined, DownOutlined } from '@ant-design/icons-vue' import { UpOutlined, DownOutlined } from '@ant-design/icons-vue'
import { useStore } from 'vuex'
export default defineComponent({ export default defineComponent({
setup() { setup() {
const selectedKeys = ref([]) const selectedKeys = ref([])
@ -126,6 +127,12 @@
children: 'children', children: 'children',
title: 'name', title: 'name',
} }
const store = useStore()
//
const user = ref({
deptName: store.getters['user/deptName'],
deptId: store.getters['user/deptId'],
})
const showKey = ref(0) const showKey = ref(0)
const treeData = ref([]) const treeData = ref([])
const init = () => { const init = () => {
@ -138,7 +145,7 @@
if (select === '123') { if (select === '123') {
select = '' select = ''
} }
// debugger
console.log( console.log(
'获取url中的select=====================>', '获取url中的select=====================>',
router.currentRoute.value.query.select router.currentRoute.value.query.select
@ -178,7 +185,33 @@
treeData.value.sort((a, b) => { treeData.value.sort((a, b) => {
return sortArr.indexOf(a.key) - sortArr.indexOf(b.key) return sortArr.indexOf(a.key) - sortArr.indexOf(b.key)
}) })
let deptId=user.value.deptId
treeData.value.forEach((child) => {
let childern=child.children
childern.forEach((childs) => {//
if(childs.key==deptId ){
childs.show=true
child.show=true
mybus.emit('paramsGetResources', [childs.key])
selectId.value =childs.key
}
if(childs.children && childs.children.length>0){//
let qu=childs.children
qu.forEach((qu) => {
if(qu.key==deptId ){
qu.show=true
childs.show=true
child.show=true
mybus.emit('paramsGetResources', [qu.key])
selectId.value = qu.key
}
})
}
})
})
console.log('左侧树结构数据======================>', treeData.value) console.log('左侧树结构数据======================>', treeData.value)
showKey.value++ showKey.value++
}) })
} }
@ -188,6 +221,7 @@
}) })
// children // children
const generateChildren = (val, obj) => { const generateChildren = (val, obj) => {
if (val.dataList.length > 0) { if (val.dataList.length > 0) {
val.dataList.forEach((child) => { val.dataList.forEach((child) => {
let children = { let children = {
@ -197,12 +231,14 @@
total: child.deptCount, total: child.deptCount,
key: child.deptId, key: child.deptId,
} }
obj.children.push(children) obj.children.push(children)
}) })
} }
} }
// //
const generateChildren2 = (val, obj) => { const generateChildren2 = (val, obj) => {
if (val.dataList.length > 0) { if (val.dataList.length > 0) {
val.dataList.forEach((dis) => { val.dataList.forEach((dis) => {
let children = { let children = {
@ -222,6 +258,7 @@
select: false, select: false,
key: child.deptId, key: child.deptId,
} }
children.children.push(children2) children.children.push(children2)
}) })
} }

File diff suppressed because it is too large Load Diff

View File

@ -66,7 +66,7 @@
></path> ></path>
</svg> </svg>
<img class="icon-poylon" @click="areaMode()" src="~@/supermap/image/icon-poylon.png"> <img class="icon-poylon" @click="areaMode()" src="~@/supermap/image/icon-poylon.png">
</div> </div>
<video-play <video-play
v-if="openVideo" v-if="openVideo"
@ -197,7 +197,7 @@
L.drawLocal.draw.handlers.polygon.tooltip.cont = '单击继续绘制形状' L.drawLocal.draw.handlers.polygon.tooltip.cont = '单击继续绘制形状'
L.drawLocal.draw.handlers.polygon.tooltip.end = L.drawLocal.draw.handlers.polygon.tooltip.end =
'单击继续绘制形状,双击结束绘制' '单击继续绘制形状,双击结束绘制'
this.hiMap.mapObj.map.off('draw:created') this.hiMap.mapObj.map.off('draw:created')
this.hiMap.mapObj.drawPolygon.enable() this.hiMap.mapObj.drawPolygon.enable()
this.hiMap.mapObj.map.once('draw:created', (e) => { this.hiMap.mapObj.map.once('draw:created', (e) => {

View File

@ -267,9 +267,12 @@
}) })
window.open(newpage.href, '_blank') window.open(newpage.href, '_blank')
} else if (data === '资源下架') { } else if (data === '资源下架') {
window.sessionStorage.setItem('type', JSON.stringify('PurchaseVehicle')) window.sessionStorage.setItem('type', JSON.stringify('apply'))
const newpage = router.resolve({ const newpage = router.resolve({
path: '/personalCenter', path: '/personalCenter',
query: {
tabTypeName: '能力上架'
}
}) })
window.location.href = newpage.href window.location.href = newpage.href
} }

View File

@ -8,40 +8,74 @@
<div class="bottom"> <div class="bottom">
<div class="item"> <div class="item">
<div class="zj">组件服务</div> <div class="zj">组件服务</div>
<div class="name" v-for="(item, index) in zjList.slice(0, 5)" :key="item.name" <div
:class="index == 4 ? 'name-last' : ''" @click="selectOne1(item.name)"> class="name"
v-for="(item, index) in zjList.slice(0, 5)"
:key="item.name"
:class="index == 4 ? 'name-last' : ''"
@click="selectOne1(item.name)"
>
{{ item.name + '-' + item.num + '项' }} {{ item.name + '-' + item.num + '项' }}
</div> </div>
<div class="btn" @click="jumpPage('组件服务')">查看更多</div> <div class="btn" @click="jumpPage('组件服务')">查看更多</div>
</div> </div>
<div class="item"> <div class="item">
<div class="yy">应用资源</div> <div class="yy">应用资源</div>
<div class="name" v-for="(item, index) in yyList.slice(0, 5)" :key="item.name" <div
:class="index == 4 ? 'name-last' : ''" @click="selectOne11(item.name)"> class="name"
v-for="(item, index) in yyList.slice(0, 5)"
:key="item.name"
:class="index == 4 ? 'name-last' : ''"
@click="selectOne11(item.name)"
>
{{ item.name + '-' + item.num + '项' }} {{ item.name + '-' + item.num + '项' }}
</div> </div>
<div class="btn" @click="jumpPage('应用资源')">查看更多</div> <div class="btn" @click="jumpPage('应用资源')">查看更多</div>
</div> </div>
<div class="item"> <div class="item">
<div class="jc">基础设施</div> <div class="jc">基础设施</div>
<div class="name" v-for="(item, index) in jcList.slice(0, 5)" :key="item.name" <div
:class="index == 2 ? 'name-last' : ''" @click="selectOne2(item.name)"> class="name"
{{ item.name + '-' + item.num + '项' }} v-for="(item, index) in jcList.slice(0, 5)"
:key="item.name"
:class="index == 2 ? 'name-last' : ''"
@click="selectOne2(item.name)"
>
{{
item.name +
'-' +
item.num +
(item.name == '会客厅'
? '间'
: item.name == '视频会议'
? '个'
: '项')
}}
</div> </div>
<div class="btn" @click="jumpPage('基础设施')">查看更多</div> <div class="btn" @click="jumpPage('基础设施')">查看更多</div>
</div> </div>
<div class="item"> <div class="item">
<div class="sj">数据资源</div> <div class="sj">数据资源</div>
<div class="name" v-for="(item, index) in sjList" :key="item.id" :class="index == 4 ? 'name-last' : ''" <div
@click="selectOne3(item.name)"> class="name"
v-for="(item, index) in sjList"
:key="item.id"
:class="index == 4 ? 'name-last' : ''"
@click="selectOne3(item.name)"
>
{{ index + 1 }}-{{ item.name }} {{ index + 1 }}-{{ item.name }}
</div> </div>
<div class="btn" @click="jumpPage('数据资源')">查看更多</div> <div class="btn" @click="jumpPage('数据资源')">查看更多</div>
</div> </div>
<div class="item"> <div class="item">
<div class="zs">知识库</div> <div class="zs">知识库</div>
<div class="name" v-for="(item, index) in zsList" :key="item.id" :class="index == 4 ? 'name-last' : ''" <div
@click="openHref(item)"> class="name"
v-for="(item, index) in zsList"
:key="item.id"
:class="index == 4 ? 'name-last' : ''"
@click="openHref(item)"
>
{{ index + 1 }}-{{ item.name }} {{ index + 1 }}-{{ item.name }}
</div> </div>
<div class="btn" @click="jumpPage('知识库')">查看更多</div> <div class="btn" @click="jumpPage('知识库')">查看更多</div>
@ -51,436 +85,432 @@
</div> </div>
</template> </template>
<script setup> <script setup>
import { import {
pageWithAttrs, pageWithAttrs,
getDataResource, getDataResource,
selectInfrastructureList, selectInfrastructureList,
selectCollectComponentList, selectCollectComponentList,
selectCollectResourceList selectCollectResourceList,
} from '@/api/home.js' } from '@/api/home.js'
import { ref, reactive } from 'vue' import { ref, reactive } from 'vue'
import { useRouter } from 'vue-router' import { useRouter } from 'vue-router'
import { useStore } from 'vuex' import { useStore } from 'vuex'
import { updateVisits, browsingInsert, getSoldierList } from '@/api/home' import { updateVisits, browsingInsert, getSoldierList } from '@/api/home'
import { message, Upload } from 'ant-design-vue' import { message, Upload } from 'ant-design-vue'
import mybus from '@/myplugins/mybus' import mybus from '@/myplugins/mybus'
const store = useStore() const store = useStore()
const router = useRouter() const router = useRouter()
const zjList = ref([]) const zjList = ref([])
const jcList = ref([]) const jcList = ref([])
const sjList = ref([]) const sjList = ref([])
const yyList = ref([]) const yyList = ref([])
// //
const zsList = ref([]) const zsList = ref([])
// const jcList = ref([]) // const jcList = ref([])
const paramsGetResources = { const paramsGetResources = {
districtId: '', districtId: '',
pageNum: 1, pageNum: 1,
pageSize: 5, pageSize: 5,
type: '', type: '',
name: '', name: '',
infoList: [], infoList: [],
orderField: 'total', // total visits 访 applyCount score collectCount orderField: 'total', // total visits 访 applyCount score collectCount
orderType: 'DESC', // ASC DESC orderType: 'DESC', // ASC DESC
} }
console.log('dataShowdev==========================>', whoShow) console.log('dataShowdev==========================>', whoShow)
// eslint-disable-next-line no-undef // eslint-disable-next-line no-undef
const whoShow1 = ref(whoShow) const whoShow1 = ref(whoShow)
const interfaceSuccess = ref(0) const interfaceSuccess = ref(0)
const object = reactive({ const object = reactive({
yyNum: '', yyNum: '',
zjNum: '', zjNum: '',
jcNum: '', jcNum: '',
sjNum: '', sjNum: '',
zsNum: '', zsNum: '',
}) })
const getAppResources = (type, obj) => { const getAppResources = (type, obj) => {
paramsGetResources.type = type paramsGetResources.type = type
if (type === '数据资源' && !whoShow1.value.itShowBaoTou) { if (type === '数据资源' && !whoShow1.value.itShowBaoTou) {
getDataResource({ getDataResource({
serviceName: paramsGetResources.name || '', // serviceName: paramsGetResources.name || '', //
orderField: whoShow1.value.itShowQingDao ? 'fbrq' : 'createTime', // orderField: whoShow1.value.itShowQingDao ? 'fbrq' : 'createTime', //
orderType: paramsGetResources.orderType.toLowerCase(), //descasc orderType: paramsGetResources.orderType.toLowerCase(), //descasc
pageNum: paramsGetResources.pageNum, // pageNum: paramsGetResources.pageNum, //
pageSize: paramsGetResources.pageSize, // pageSize: paramsGetResources.pageSize, //
}).then((res) => { }).then((res) => {
console.log('数据资源==================>', res.data.data) console.log('数据资源==================>', res.data.data)
if (whoShow1.value.itShowQingDao) { if (whoShow1.value.itShowQingDao) {
res.data.data.data.forEach((val) => { res.data.data.data.forEach((val) => {
val.id = val.guid // id val.id = val.guid // id
val.name = val.zyname // val.name = val.zyname //
val.sjlCount = val.sjcczl // val.sjlCount = val.sjcczl //
val.applyCount = val.syqk // val.applyCount = val.syqk //
val.deptName = val.TGBM // val.deptName = val.TGBM //
val.createDate = val.fbrq // val.createDate = val.fbrq //
val.description = val.xgxt // val.description = val.xgxt //
}) })
obj.value = res.data.data.data || [] obj.value = res.data.data.data || []
object.sjNum = res.data.data.rows object.sjNum = res.data.data.rows
} else if (whoShow1.value.itShowXiHaiAn) { } else if (whoShow1.value.itShowXiHaiAn) {
res.data.data.list.forEach((val) => { res.data.data.list.forEach((val) => {
val.id = val.serviceId // id val.id = val.serviceId // id
val.name = val.serviceName // val.name = val.serviceName //
val.sjlCount = val.requestQuantity // val.sjlCount = val.requestQuantity //
val.applyCount = val.requestCount // val.applyCount = val.requestCount //
val.deptName = val.departmentName // val.deptName = val.departmentName //
val.createTime = val.createTime.split('.')[0] val.createTime = val.createTime.split('.')[0]
val.createDate = val.createTime // val.createDate = val.createTime //
}) })
obj.value = res.data.data.list || [] obj.value = res.data.data.list || []
object.sjNum = res.data.data.total object.sjNum = res.data.data.total
} }
}) })
} else { } else {
let type = paramsGetResources.type let type = paramsGetResources.type
if (type == '基础设施') { if (type == '基础设施') {
jcList.value = [] jcList.value = []
selectInfrastructureList().then((res) => { selectInfrastructureList().then((res) => {
console.log('基础设施------res------>', res); console.log('基础设施------res------>', res)
for (const key in res.data.data) { for (const key in res.data.data) {
if (whoShow1.value.itShowXiHaiAn) { if (whoShow1.value.itShowXiHaiAn) {
if (key === '视频资源') { if (key === '视频资源') {
jcList.value.push({
name: key,
num: res.data.data[key],
})
}
} else {
jcList.value.push({ jcList.value.push({
name: key, name: key,
num: res.data.data[key], num: res.data.data[key],
}) })
} }
} }
else { // jcList.value.push({
jcList.value.push({ // name: '',
// num: 4,
// })
// 西-
if (whoShow1.value.itShowXiHaiAn) {
getSoldierData('无人机')
.then((res) => {
let { total = 0 } = res.data.data
jcList.value.push({
name: '无人机',
num: total,
})
})
.catch((err) => {
console.log('err--无人机---------->', err)
})
getSoldierData('单兵设备')
.then((res) => {
let { total = 0 } = res.data.data
jcList.value.push({
name: '单兵设备',
num: total,
})
})
.catch((err) => {
console.log('err--单兵设备---------->', err)
})
}
})
} else if (type == '组件服务') {
zjList.value = []
selectCollectComponentList().then((res) => {
console.log('组件服务----res-------->', res)
for (const key in res.data.data) {
console.log('key------------>', key)
zjList.value.push({
name: key, name: key,
num: res.data.data[key], num: res.data.data[key],
}) })
} }
} console.log('zjList------------>', zjList)
// jcList.value.push({ })
// name: '', } else if (type == '应用资源') {
// num: 4, yyList.value = []
// }) selectCollectResourceList().then((res) => {
// 西- console.log('应用资源---res--------->', res)
if (whoShow1.value.itShowXiHaiAn) { for (const key in res.data.data) {
getSoldierData('无人机') yyList.value.push({
.then((res) => { name: key,
let { total = 0 } = res.data.data num: res.data.data[key],
jcList.value.push({
name: '无人机',
num: total,
})
}) })
.catch((err) => { }
console.log('err--无人机---------->', err) })
}) } else {
getSoldierData('单兵设备') pageWithAttrs(paramsGetResources).then((res) => {
.then((res) => { console.log('object个数======>', type)
let { total = 0 } = res.data.data obj.value = res.data.data.records
jcList.value.push({ switch (type) {
name: '单兵设备', case '组件服务':
num: total, assignmentMethod('zjNum', res)
}) break
}) case '应用资源':
.catch((err) => { assignmentMethod('yyNum', res)
console.log('err--单兵设备---------->', err) break
}) case '基础设施':
} assignmentMethod('jcNum', res)
}) break
} case '知识库':
else if (type == '组件服务') { assignmentMethod('zsNum', res)
zjList.value = [] break
selectCollectComponentList().then((res) => { }
console.log('组件服务----res-------->', res); })
for (const key in res.data.data) { }
console.log('key------------>', key);
zjList.value.push({
name: key,
num: res.data.data[key],
})
}
console.log('zjList------------>', zjList);
})
}
else if (type == '应用资源') {
yyList.value = []
selectCollectResourceList().then((res) => {
console.log('应用资源---res--------->', res);
for (const key in res.data.data) {
yyList.value.push({
name: key,
num: res.data.data[key],
})
}
})
}
else {
pageWithAttrs(paramsGetResources).then((res) => {
console.log('object个数======>', type)
obj.value = res.data.data.records
switch (type) {
case '组件服务':
assignmentMethod('zjNum', res)
break
case '应用资源':
assignmentMethod('yyNum', res)
break
case '基础设施':
assignmentMethod('jcNum', res)
break
case '知识库':
assignmentMethod('zsNum', res)
break
}
})
} }
} }
}
// todo // todo
const getSoldierData = (name) => { const getSoldierData = (name) => {
let _params = { let _params = {
type: name, type: name,
page: 1, page: 1,
limit: 10, limit: 10,
} }
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
getSoldierList(_params) getSoldierList(_params)
.then((res) => { .then((res) => {
resolve(res) resolve(res)
console.log('res---获取无人机、单兵设备--------->', res) console.log('res---获取无人机、单兵设备--------->', res)
if (res.data.code !== 0) { if (res.data.code !== 0) {
return message.error(res.data.msg) return message.error(res.data.msg)
} }
}) })
.catch((err) => { .catch((err) => {
reject(err) reject(err)
}) })
})
}
const openHref = (item) => {
console.log(item.id, 'wowowo')
console.log(item.visits, 'wowowo')
browsingInsert({ resourceId: item.id }).then((res) => {
// console.log(res)
})
const arrList = ref([])
arrList.value = JSON.parse(window.sessionStorage.getItem('visits'))
if (arrList.value.indexOf(item.id) === -1) {
arrList.value.push(item.id)
updateVisits({
id: item.id,
visits: item.visits || '0',
}).then(() => {
window.sessionStorage.setItem('visits', JSON.stringify(arrList.value))
}) })
} }
window.open(item.link)
}
const assignmentMethod = (type, res) => {
object[type] = res.data.data.total
}
getAppResources('组件服务', zjList)
getAppResources('应用资源', yyList)
getAppResources('基础设施', jcList)
getAppResources('数据资源', sjList)
getAppResources('知识库', zsList)
function jumpPage(type) { const openHref = (item) => {
// store console.log(item.id, 'wowowo')
store.commit('home/selectCardsData', { console.log(item.visits, 'wowowo')
selectCardsnum: type, browsingInsert({ resourceId: item.id }).then((res) => {
}) // console.log(res)
console.log( })
'选中===================>', const arrList = ref([])
store.getters['home/selectCardsnum'] arrList.value = JSON.parse(window.sessionStorage.getItem('visits'))
) if (arrList.value.indexOf(item.id) === -1) {
// router.push({ path: '/DetailsPageconetent' }) arrList.value.push(item.id)
router.push({ updateVisits({
path: '/DetailsPageconetent', id: item.id,
query: { visits: item.visits || '0',
select: type, }).then(() => {
}, window.sessionStorage.setItem('visits', JSON.stringify(arrList.value))
}) })
} }
const selectOne = (id) => { window.open(item.link)
console.log('点击===============》', id) }
router.push({ const assignmentMethod = (type, res) => {
path: '/details', object[type] = res.data.data.total
query: { }
id: id, getAppResources('组件服务', zjList)
}, getAppResources('应用资源', yyList)
}) getAppResources('基础设施', jcList)
} getAppResources('数据资源', sjList)
const selectOne1 = (name) => { getAppResources('知识库', zsList)
router.push({
path: '/DetailsPageconetent', function jumpPage(type) {
query: { // store
type: name, store.commit('home/selectCardsData', {
select: '组件服务', selectCardsnum: type,
}, })
}) console.log(
} '选中===================>',
const selectOne11 = (name) => { store.getters['home/selectCardsnum']
router.push({ )
path: '/DetailsPageconetent', // router.push({ path: '/DetailsPageconetent' })
query: { router.push({
type: name, path: '/DetailsPageconetent',
select: '应用资源', query: {
}, select: type,
}) },
} })
const selectOne2 = (name) => { }
let names='' const selectOne = (id) => {
if(name ==='云资源'){ console.log('点击===============》', id)
names='政务云资源' router.push({
} else if(name ==='会客厅'){ path: '/details',
names='城市云脑会客厅' query: {
}else{ id: id,
names=name },
})
}
const selectOne1 = (name) => {
router.push({
path: '/DetailsPageconetent',
query: {
type: name,
select: '组件服务',
},
})
}
const selectOne11 = (name) => {
router.push({
path: '/DetailsPageconetent',
query: {
type: name,
select: '应用资源',
},
})
}
const selectOne2 = (name) => {
let names = ''
if (name === '云资源') {
names = '政务云资源'
} else if (name === '会客厅') {
names = '城市云脑会客厅'
} else {
names = name
}
router.push({
path: '/DetailsPageconetent',
query: {
type: names,
select: '基础设施',
},
})
}
const selectOne3 = (name) => {
console.log('点击===============》', name)
router.push({
path: '/DetailsPageconetent',
query: {
str: name,
select: '数据资源',
},
})
} }
router.push({
path: '/DetailsPageconetent',
query: {
type: names,
select: '基础设施',
},
})
}
const selectOne3 = (name) => {
console.log('点击===============》', name)
router.push({
path: '/DetailsPageconetent',
query: {
str: name,
select: '数据资源',
},
})
}
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.capability-convergence { .capability-convergence {
height: 7.2rem; height: 7.2rem;
background: url('~@/assets/newHome/Convergence-bg.png') no-repeat; background: url('~@/assets/newHome/Convergence-bg.png') no-repeat;
background-size: 100%; background-size: 100%;
display: flex;
justify-content: center;
.main {
width: 13rem;
margin-top: 1.8rem;
display: flex; display: flex;
flex-direction: column; justify-content: center;
flex-wrap: wrap;
.top { .main {
font-size: 0.3rem; width: 13rem;
color: #212121; margin-top: 1.8rem;
text-align: center;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: center;
align-items: center;
.line { .top {
width: 0.34rem; font-size: 0.3rem;
height: 0.03rem; color: #212121;
background-color: #0058e1; text-align: center;
margin-top: 0.08rem; display: flex;
flex-direction: column;
flex-wrap: wrap;
justify-content: center;
align-items: center;
.line {
width: 0.34rem;
height: 0.03rem;
background-color: #0058e1;
margin-top: 0.08rem;
}
} }
}
.bottom { .bottom {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
margin-top: 0.4rem; margin-top: 0.4rem;
.item { .item {
width: 2.44rem; width: 2.44rem;
height: 3.91rem; height: 3.91rem;
font-size: 0.16rem; font-size: 0.16rem;
background-color: #fff; background-color: #fff;
border-radius: 0.02rem;
box-shadow: 0 0.05rem 0.2rem #ccc;
position: relative;
div:nth-of-type(1) {
height: 1.02rem;
line-height: 1.02rem;
font-size: 0.2rem;
color: #fff;
padding-left: 0.15rem;
background-size: 100%;
}
.jc {
background: url('~@/assets/newHome/Convergence-jc.png') no-repeat;
}
.sj {
background: url('~@/assets/newHome/Convergence-sj.png') no-repeat;
}
.zj {
background: url('~@/assets/newHome/Convergence-zj.png') no-repeat;
}
.yy {
background: url('~@/assets/newHome/Convergence-yy.png') no-repeat;
}
.zs {
background: url('~@/assets/newHome/Convergence-zs.png') no-repeat;
}
.name {
height: 0.47rem;
line-height: 0.47rem;
margin: 0 0.16rem;
border-bottom: 0.01rem solid #e9e9e9;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
word-break: break-all;
}
.name:hover {
color: #0058e1;
cursor: pointer;
}
.name-last {
border-bottom: none;
}
.btn {
cursor: pointer;
width: 0.8rem;
height: 0.24rem;
border: 0.01rem solid #0058e1;
font-size: 0.14rem;
color: #0058e1;
border-radius: 0.02rem; border-radius: 0.02rem;
text-align: center; box-shadow: 0 0.05rem 0.2rem #ccc;
margin-top: 0.1rem; position: relative;
margin-left: 0.85rem;
position: absolute; div:nth-of-type(1) {
bottom: 0.2rem; height: 1.02rem;
line-height: 1.02rem;
font-size: 0.2rem;
color: #fff;
padding-left: 0.15rem;
background-size: 100%;
}
.jc {
background: url('~@/assets/newHome/Convergence-jc.png') no-repeat;
}
.sj {
background: url('~@/assets/newHome/Convergence-sj.png') no-repeat;
}
.zj {
background: url('~@/assets/newHome/Convergence-zj.png') no-repeat;
}
.yy {
background: url('~@/assets/newHome/Convergence-yy.png') no-repeat;
}
.zs {
background: url('~@/assets/newHome/Convergence-zs.png') no-repeat;
}
.name {
height: 0.47rem;
line-height: 0.47rem;
margin: 0 0.16rem;
border-bottom: 0.01rem solid #e9e9e9;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
word-break: break-all;
}
.name:hover {
color: #0058e1;
cursor: pointer;
}
.name-last {
border-bottom: none;
}
.btn {
cursor: pointer;
width: 0.8rem;
height: 0.24rem;
border: 0.01rem solid #0058e1;
font-size: 0.14rem;
color: #0058e1;
border-radius: 0.02rem;
text-align: center;
margin-top: 0.1rem;
margin-left: 0.85rem;
position: absolute;
bottom: 0.2rem;
}
.btn:hover {
background: rgba(0, 88, 225, 0.3);
color: #000;
}
} }
.btn:hover { .item:hover {
background: rgba(0, 88, 225, 0.3); border-radius: 0.02rem;
color: #000; border: 0.01rem solid #0058e1;
box-shadow: 0rem 0.08rem 0.2rem rgba(0, 88, 225, 0.3);
} }
} }
.item:hover {
border-radius: 0.02rem;
border: 0.01rem solid #0058e1;
box-shadow: 0rem 0.08rem 0.2rem rgba(0, 88, 225, 0.3);
}
} }
} }
}
</style> </style>

View File

@ -208,6 +208,7 @@
onBeforeUnmount, onBeforeUnmount,
h, h,
defineProps, defineProps,
nextTick,
} from 'vue' } from 'vue'
import { import {
getMyProcessInstancePage, getMyProcessInstancePage,
@ -252,16 +253,19 @@
typeList.value.push('设备申请') typeList.value.push('设备申请')
} }
const typeStrObj = { const typeStrObj = {
能力上架: 'resourcemountapply', '能力上架': 'resourcemountapply',
能力下架: 'resourcundercarriageapply', '能力下架': 'resourcundercarriageapply',
能力需求: 'abilitydemandapply', '能力需求': 'abilitydemandapply',
需求评论: 'comment_review', '需求评论': 'comment_review',
} }
let tabList = ref(['全部', '审核中', '审核完成']) let tabList = ref(['全部', '审核中', '审核完成'])
const contentList = reactive({ data: [] }) const contentList = reactive({ data: [] })
let tabIndex = ref(0) let tabIndex = ref(0)
let typeIndex = ref(0) let typeIndex = ref(0)
let typeName = ref(typeList.value[0]) let typeName = ref(typeList.value[0])
if(router.currentRoute.value.query.tabTypeName) {
typeName.value = router.currentRoute.value.query.tabTypeName
}
const videoVisible = ref(false) const videoVisible = ref(false)
const numFlag = ref(true) const numFlag = ref(true)
const columns = ref([ const columns = ref([
@ -306,7 +310,7 @@
ended.value = '' ended.value = ''
page.value = 1 page.value = 1
typeIndex.value = index typeIndex.value = index
typeName.value = item typeName.value = item;
getApplyList() getApplyList()
} }
@ -565,7 +569,6 @@
params.processDefinitionKey = processDefinitionKey.value params.processDefinitionKey = processDefinitionKey.value
getMyProcessInstancePage(params).then((res) => { getMyProcessInstancePage(params).then((res) => {
contentList.data = [] contentList.data = []
// initNum(name.value)
console.log(res.data.data.list) console.log(res.data.data.list)
contentList.data = res.data.data.list contentList.data = res.data.data.list
total.value = res.data.data.total total.value = res.data.data.total

View File

@ -9,83 +9,38 @@
<div class="form-container"> <div class="form-container">
<div v-if="applySuccess"> <div v-if="applySuccess">
<div class="title">申请人信息</div> <div class="title">申请人信息</div>
<a-form <a-form ref="formRef" :model="formName" name="basic" :label-col="{ style: { width: '106px' } }"
ref="formRef" :wrapper-col="{ style: { width: '230px' } }" labelAlign="left" autocomplete="off">
:model="formName"
name="basic"
:label-col="{ style: { width: '106px' } }"
:wrapper-col="{ style: { width: '230px' } }"
labelAlign="left"
autocomplete="off"
>
<div class="base-info"> <div class="base-info">
<a-form-item <a-form-item label="申请人" name="applyUserName" :rules="[{ required: true, message: '请输入申请人' }]">
label="申请人" <a-input placeholder="请输入申请人" v-model:value="formName.applyUserName" />
name="applyUserName"
:rules="[{ required: true, message: '请输入申请人' }]"
>
<a-input
placeholder="请输入申请人"
v-model:value="formName.applyUserName"
/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item style="margin: 0 22px" label="申请人电话" name="applyUserPhone" :rules="[
style="margin: 0 22px" {
label="申请人电话" required: true,
name="applyUserPhone" pattern: /^1[3456789]\d{9}$/,
:rules="[ message: '请输入正确的电话号码',
{ },
required: true, ]">
pattern: /^1[3456789]\d{9}$/, <a-input placeholder="请输入申请人电话" v-model:value="formName.applyUserPhone" />
message: '请输入正确的电话号码',
},
]"
>
<a-input
placeholder="请输入申请人电话"
v-model:value="formName.applyUserPhone"
/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item label="申请单位" name="applyUserDeptName" :rules="[{ required: true, message: '请输入申请单位' }]">
label="申请单位" <a-input placeholder="请输入申请单位" v-model:value="formName.applyUserDeptName" />
name="applyUserDeptName"
:rules="[{ required: true, message: '请输入申请单位' }]"
>
<a-input
placeholder="请输入申请单位"
v-model:value="formName.applyUserDeptName"
/>
</a-form-item> </a-form-item>
</div> </div>
<div class="title">需求信息</div> <div class="title">需求信息</div>
<a-form-item <a-form-item style="margin-bottom: 10px" label="需求标题" name="demandSubject"
style="margin-bottom: 10px" :rules="[{ required: true, message: '请输入需求标题' }]">
label="需求标题" <a-input style="width: 350px" v-model:value="formName.demandSubject" />
name="demandSubject"
:rules="[{ required: true, message: '请输入需求标题' }]"
>
<a-input
style="width: 350px"
v-model:value="formName.demandSubject"
/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item style="margin-bottom: 10px" label="需求类型" name="detailsType"
style="margin-bottom: 10px" :rules="[{ required: true, message: '请选择需求类型' }]">
label="需求类型" <a-select ref="select" v-model:value="formName.detailsType" @focus="focus" style="width: 200px">
name="detailsType"
:rules="[{ required: true, message: '请选择需求类型' }]"
>
<a-select
ref="select"
v-model:value="formName.detailsType"
@focus="focus"
style="width: 200px"
>
<a-select-option value="基础设施">基础设施</a-select-option> <a-select-option value="基础设施">基础设施</a-select-option>
<a-select-option value="数据资源">数据资源</a-select-option> <a-select-option value="数据资源">数据资源</a-select-option>
<a-select-option value="组件服务">组件服务</a-select-option> <a-select-option value="组件服务">组件服务</a-select-option>
@ -94,50 +49,24 @@
</a-select> </a-select>
</a-form-item> </a-form-item>
<a-form-item <a-form-item label="应用领域" v-if="formName.detailsType === '应用资源' ||
label="应用领域" formName.detailsType === '组件服务'" name="detailsField" style="width: 6.93rem" :rules="[
name="detailsField" {
style="width: 6.93rem" required: true,
:rules="[ message: '请选择应用领域',
{ },
required: ]">
formName.detailsType === '应用资源' || <a-select v-model:value="formName.detailsField" :options="applicationSceneOpthion" mode="tags"
formName.detailsType === '组件服务' :size="size" placeholder="请选择应用领域" :filterOption="false" :searchValue="false" style="width: 5.87rem">
? true </a-select>
: false,
message: '请选择应用领域',
},
]"
>
<a-select
:disabled="
formName.detailsType === '应用资源' ||
formName.detailsType === '组件服务'
? false
: true
"
v-model:value="formName.detailsField"
:options="applicationSceneOpthion"
mode="tags"
:size="size"
placeholder="请选择应用领域"
:filterOption="false"
:searchValue="false"
style="width: 5.87rem"
></a-select>
</a-form-item> </a-form-item>
<!-- <a-form-item label="应用领域" name="detailsField" style="width: 350px" <!-- <a-form-item label="应用领域" name="detailsField" style="width: 350px"
:rules="[{ required: true, message: '请输入应用领域' }]"> :rules="[{ required: true, message: '请输入应用领域' }]">
<a-input placeholder="请输入应用领域" v-model:value="formName.detailsField" /> <a-input placeholder="请输入应用领域" v-model:value="formName.detailsField" />
</a-form-item> --> </a-form-item> -->
<a-form-item <a-form-item style="margin-bottom: 10px" label="需求描述" name="demandDetails"
style="margin-bottom: 10px" :rules="[{ required: true, message: '请输入需求描述' }]">
label="需求描述" <a-textarea style="
name="demandDetails"
:rules="[{ required: true, message: '请输入需求描述' }]"
>
<a-textarea
style="
width: 500px; width: 500px;
height: 150px; height: 150px;
font-size: 16px; font-size: 16px;
@ -147,25 +76,12 @@
border-radius: 6px; border-radius: 6px;
padding: 10px; padding: 10px;
resize: none; resize: none;
" " v-model:value="formName.demandDetails" />
v-model:value="formName.demandDetails"
/>
</a-form-item> </a-form-item>
<a-form-item <a-form-item style="color: #666; font-size: 16px" label="附件上传" name="applyDoc">
style="color: #666; font-size: 16px" <a-upload v-model:file-list="fileList" name="file" :action="upLoadUrl" :headers="headers"
label="附件上传" @change="handleChange" :maxCount="1">
name="applyDoc" <a-button style="
>
<a-upload
v-model:file-list="fileList"
name="file"
:action="upLoadUrl"
:headers="headers"
@change="handleChange"
:maxCount="1"
>
<a-button
style="
width: 100px; width: 100px;
height: 30px; height: 30px;
margin-right: 10px; margin-right: 10px;
@ -176,8 +92,7 @@
border: 1px solid #bbd3ef; border: 1px solid #bbd3ef;
padding: 0; padding: 0;
text-align: center; text-align: center;
" ">
>
<upload-outlined></upload-outlined> <upload-outlined></upload-outlined>
文件上传 文件上传
</a-button> </a-button>
@ -188,8 +103,7 @@
</a-form-item> </a-form-item>
<a-form-item :wrapper-col="{ offset: 8, span: 16 }"> <a-form-item :wrapper-col="{ offset: 8, span: 16 }">
<a-button <a-button style="
style="
width: 80px; width: 80px;
height: 38px; height: 38px;
margin-right: 20px; margin-right: 20px;
@ -200,15 +114,10 @@
border: none; border: none;
padding: 0; padding: 0;
text-align: center; text-align: center;
" " type="primary" html-type="cancle" @click="signOut">
type="primary"
html-type="cancle"
@click="signOut"
>
退出申请 退出申请
</a-button> </a-button>
<a-button <a-button style="
style="
width: 80px; width: 80px;
height: 38px; height: 38px;
background: #0087ff; background: #0087ff;
@ -218,11 +127,7 @@
border: none; border: none;
padding: 0; padding: 0;
text-align: center; text-align: center;
" " type="primary" html-type="submit" @click="processStartHandle()">
type="primary"
html-type="submit"
@click="processStartHandle()"
>
提交申请 提交申请
</a-button> </a-button>
</a-form-item> </a-form-item>
@ -234,7 +139,7 @@
</div> </div>
<p> <p>
您已成功申请{{ 您已成功申请{{
formName.demandSubject || '' formName.demandSubject || ''
}},请耐心等待审批结果结果会第一时间通知您 }},请耐心等待审批结果结果会第一时间通知您
</p> </p>
</div> </div>
@ -245,250 +150,248 @@
</template> </template>
<script> <script>
import HomeHeader from '@/views/home/components/header' import HomeHeader from '@/views/home/components/header'
import { reactive, ref } from 'vue' import { reactive, ref } from 'vue'
import { message } from 'ant-design-vue' import { message } from 'ant-design-vue'
// import { UploadOutlined } from '@ant-design/icons-vue' // import { UploadOutlined } from '@ant-design/icons-vue'
import { getUser, getUserInfo, relaunch } from '@/api/home' import { getUser, getUserInfo, relaunch } from '@/api/home'
import { import {
demandApply, demandApply,
getDemandForm, getDemandForm,
updateDemandForm, updateDemandForm,
getCategoryTreePage, getCategoryTreePage,
} from '@/api/personalCenter' } from '@/api/personalCenter'
// import { baseURL } from '@/config' // import { baseURL } from '@/config'
import { useRouter } from 'vue-router' import { useRouter } from 'vue-router'
export default { export default {
name: '', name: '',
props: {}, props: {},
components: { components: {
HomeHeader, HomeHeader,
// UploadOutlined, // UploadOutlined,
}, },
setup() { setup() {
const disabled = ref(false) const disabled = ref(false)
const upLoadUrl = ref(window.SITE_CONFIG.apiURL + '/upload') const upLoadUrl = ref(window.SITE_CONFIG.apiURL + '/upload')
const formName = reactive({ const formName = reactive({
applyUserDeptId: '', applyUserDeptId: '',
applyUserDeptName: '', applyUserDeptName: '',
applyUserId: '', applyUserId: '',
applyUserName: '', applyUserName: '',
applyUserPhone: '', applyUserPhone: '',
demandDetails: '', demandDetails: '',
demandSubject: '', demandSubject: '',
detailsField: [], detailsField: [],
detailsType: '', detailsType: '',
enclosure: '', enclosure: '',
})
// console.log(formName.demandSubject)
const router = useRouter()
const id = ref(router.currentRoute.value.query.id)
const taskId = ref(router.currentRoute.value.query.taskId)
if (id.value) {
getDemandForm(id.value).then((res) => {
console.log('回填数据===============>', res)
formName.applyUserPhone = res.data.data.applyUserPhone
formName.demandSubject = res.data.data.demandSubject
formName.detailsType = res.data.data.detailsType
formName.detailsField = res.data.data.detailsField
formName.demandDetails = res.data.data.demandDetails
formName.enclosure = res.data.data.enclosure
}) })
// console.log(formName.demandSubject) }
const applicationSceneOpthion = ref([])
getCategoryTreePage({
page: 1,
limit: 20,
dictTypeId: '1513712507692818433',
deFlage: 0,
}).then((res) => {
res.data.data.list.map((val) => {
applicationSceneOpthion.value.push({
value: val.dictLabel,
label: val.dictLabel,
})
})
// console.log('========>', applicationSceneOpthion.value)
})
getUser().then((res) => {
formName.applyUserName = res.data.data.realName
formName.applyUserId = res.data.data.id
getUserInfo(formName.applyUserId).then((res) => {
if (res.data.data.mobile) {
formName.applyUserPhone = res.data.data.mobile
}
formName.applyUserDeptName = res.data.data.deptName
formName.applyUserDeptId = res.data.data.deptId
})
})
const formRef = ref()
const applySuccess = ref(true)
// 退
const signOut = () => {
window.close()
}
const handleChange = (info) => {
if (info.file.status !== 'uploading') {
console.log(info.file, info.fileList)
}
if (info.file.status === 'done') {
message.success(`${info.file.name} 文件上传成功`)
formName.enclosure = info.file.response.data
} else if (info.file.status === 'error') {
message.error(`${info.file.name} 文件上传失败`)
}
}
const fileList = ref([])
const processStartHandle = () => {
let detailsField = '';
if (formName.detailsField.length > 0) {
formName.detailsField.map((item) => {
detailsField += item + ';'
})
}
// copy
let _postData = JSON.parse(JSON.stringify(formName))
_postData.detailsField = detailsField;
const router = useRouter()
const id = ref(router.currentRoute.value.query.id)
const taskId = ref(router.currentRoute.value.query.taskId)
if (id.value) { if (id.value) {
getDemandForm(id.value).then((res) => { updateDemandForm(_postData).then((upres) => {
console.log('回填数据===============>', res) if (upres.data.code == 0) {
formName.applyUserPhone = res.data.data.applyUserPhone relaunch({ data: _postData, taskId: taskId.value }).then((res) => {
formName.demandSubject = res.data.data.demandSubject console.log('驳回================>', res)
formName.detailsType = res.data.data.detailsType if (res.data.code == 0) {
formName.detailsField = res.data.data.detailsField message.success('重新发起流程成功!')
formName.demandDetails = res.data.data.demandDetails window.setTimeout(() => {
formName.enclosure = res.data.data.enclosure window.close()
}) }, 1000)
} } else {
const applicationSceneOpthion = ref([]) message.error('重新发起流程失败!')
getCategoryTreePage({ }
page: 1,
limit: 20,
dictTypeId: '1513712507692818433',
deFlage: 0,
}).then((res) => {
res.data.data.list.map((val) => {
applicationSceneOpthion.value.push({
value: val.dictLabel,
label: val.dictLabel,
})
})
// console.log('========>', applicationSceneOpthion.value)
})
getUser().then((res) => {
formName.applyUserName = res.data.data.realName
formName.applyUserId = res.data.data.id
getUserInfo(formName.applyUserId).then((res) => {
if (res.data.data.mobile) {
formName.applyUserPhone = res.data.data.mobile
}
formName.applyUserDeptName = res.data.data.deptName
formName.applyUserDeptId = res.data.data.deptId
})
})
const formRef = ref()
const applySuccess = ref(true)
// 退
const signOut = () => {
window.close()
}
const handleChange = (info) => {
if (info.file.status !== 'uploading') {
console.log(info.file, info.fileList)
}
if (info.file.status === 'done') {
message.success(`${info.file.name} 文件上传成功`)
formName.enclosure = info.file.response.data
} else if (info.file.status === 'error') {
message.error(`${info.file.name} 文件上传失败`)
}
}
const fileList = ref([])
const subimtFlag = ref(true)
const processStartHandle = () => {
if (formName.detailsField.length > 0) {
let detailsField = ''
formName.detailsField.map((item) => {
detailsField += item + ';'
})
formName.detailsField = detailsField
}
if (id.value) {
updateDemandForm(formName).then((upres) => {
if (upres.data.code == 0) {
relaunch({ data: formName, taskId: taskId.value }).then((res) => {
console.log('驳回================>', res)
if (res.data.code == 0) {
message.success('重新发起流程成功!')
window.setTimeout(() => {
window.close()
}, 1000)
} else {
message.error('重新发起流程失败!')
}
})
} else {
message.error('数据更新失败!')
}
})
} else {
if (subimtFlag.value) {
subimtFlag.value = false
formRef.value.validate().then(() => {
const detString = String(formName.detailsField)
formName.detailsField = detString
console.log(detString, formName.detailsField, 'detString')
demandApply(formName).then((res) => {
applySuccess.value = false
message.success('操作成功!')
console.log('能力申请================>', res)
subimtFlag.value = true
})
}) })
} else {
message.error('数据更新失败!')
} }
} })
} else {
formRef.value.validate().then((valid) => {
const detString = String(_postData.detailsField)
_postData.detailsField = detString
console.log(detString, _postData.detailsField, 'detString')
demandApply(_postData).then((res) => {
applySuccess.value = false
message.success('操作成功!')
console.log('能力申请================>', res)
})
})
} }
}
return { return {
formRef, formRef,
formName, formName,
fileList, fileList,
headers: { headers: {
authorization: 'authorization-text', authorization: 'authorization-text',
}, },
handleChange, handleChange,
applySuccess, applySuccess,
disabled, disabled,
signOut, signOut,
processStartHandle, processStartHandle,
upLoadUrl, upLoadUrl,
// baseURL, // baseURL,
applicationSceneOpthion, applicationSceneOpthion,
} }
}, },
} }
</script> </script>
<style scoped lang="less"> <style scoped lang="less">
#apply-container { #apply-container {
background-color: #f5f8fc; background-color: #f5f8fc;
height: 100%; height: 100%;
width: 100%; width: 100%;
margin: 90px auto 0; margin: 90px auto 0;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
aside { aside {
width: 282px; width: 282px;
height: 96%; height: 96%;
overflow-y: auto; overflow-y: auto;
background-color: #fff; background-color: #fff;
margin: 1% 0 3%; margin: 1% 0 3%;
} }
article { article {
width: 1090px; width: 1090px;
height: 99%; height: 99%;
overflow-y: auto; overflow-y: auto;
background-color: #fff; background-color: #fff;
margin: 5% auto; margin: 5% auto;
} }
.form-container { .form-container {
padding: 20px 20px 30px 20px; padding: 20px 20px 30px 20px;
.title { .title {
font-size: 20px;
color: #000;
font-weight: bold;
margin-bottom: 20px;
}
}
.base-info {
display: flex;
}
:deep(.ant-form-item-label) {
label {
color: #666;
font-size: 16px;
&::after {
content: '';
}
}
}
:deep(.ant-form-item-required) {
&::before {
font-size: 8px;
margin-right: 10px;
}
}
:deep(.ant-input) {
border: 1px solid #e0e0e0;
border-radius: 6px;
}
.success {
div {
width: 100px;
margin: 80px auto 40px;
}
text-align: center;
font-size: 20px; font-size: 20px;
font-weight: bold;
color: #000; color: #000;
font-weight: bold;
margin-bottom: 20px;
} }
} }
.base-info {
display: flex;
}
:deep(.ant-form-item-label) {
label {
color: #666;
font-size: 16px;
&::after {
content: '';
}
}
}
:deep(.ant-form-item-required) {
&::before {
font-size: 8px;
margin-right: 10px;
}
}
:deep(.ant-input) {
border: 1px solid #e0e0e0;
border-radius: 6px;
}
.success {
div {
width: 100px;
margin: 80px auto 40px;
}
text-align: center;
font-size: 20px;
font-weight: bold;
color: #000;
}
}
</style> </style>
<style> <style>
body, body,
html { html {
height: unset; height: unset;
} }
</style> </style>

View File

@ -33,15 +33,16 @@ export default defineComponent({
imgActive: require('@/assets/personalCenter/applyactive.png'), imgActive: require('@/assets/personalCenter/applyactive.png'),
key: 'apply', key: 'apply',
} }
const push = {
title: '我的发布',
img: require('@/assets/personalCenter/push.png'),
imgActive: require('@/assets/personalCenter/pushactive.png'),
key: 'push',
}
let menuList = [ let menuList = [
car, car,
{
title: '我的发布',
img: require('@/assets/personalCenter/push.png'),
imgActive: require('@/assets/personalCenter/pushactive.png'),
key: 'push',
},
apply, apply,
push,
{ {
title: '我的收藏', title: '我的收藏',
img: require('@/assets/personalCenter/collect.png'), img: require('@/assets/personalCenter/collect.png'),
@ -69,7 +70,7 @@ export default defineComponent({
] ]
// 西 // 西
if (itShowXiHaiAn) { if (itShowXiHaiAn) {
menuList = [car, apply] menuList = [car, apply, push]
} }
const selectedKeys = ref(['apply']) const selectedKeys = ref(['apply'])

View File

@ -29,8 +29,8 @@ const productionGzipExtensions = [
'ico', 'ico',
] ]
// gzip // gzip
const isPro = process.env.NODE_ENV === 'production' // const isPro = process.env.NODE_ENV === 'production'
// const isPro = false const isPro = false
if (donation) donationConsole() if (donation) donationConsole()
const { version, author } = require('./package.json') const { version, author } = require('./package.json')
const Webpack = require('webpack') const Webpack = require('webpack')