Compare commits

..

No commits in common. "37675c31adfb6d3d447b5df2695a0ae277110287" and "e1867c94fdc1d129291725da346c10179de020ed" have entirely different histories.

5 changed files with 1491 additions and 2112 deletions

BIN
dist.zip Normal file

Binary file not shown.

View File

@ -1366,11 +1366,3 @@ export async function fetchReviewAuthCateList(params?: any) {
export async function fetchmoduleStatExternalPage(params?: any) {
return http.get(`/moduleStat/externalPage`, { params })
}
// 内部统计列表
export async function fetchmoduleStatInternalPage(params?: any) {
return http.get(`/moduleStat/internalPage`, { params })
}
// 获取岗位
export async function fetchPostList(params?: any) {
return http.get(`/common/getPostList`, { params })
}

File diff suppressed because it is too large Load Diff

View File

@ -22,7 +22,6 @@ const store = noticeld()
const store2 = useUserStore()
const user: any = store2.user
const header = { token: user.token }
console.log('🚀 ~ file: Process.vue:25 ~ user:', user)
const { push } = useRouter()
const database = databaseld()
const route = useRoute()

View File

@ -1,18 +1,14 @@
<script setup lang="ts">
import HomeHead from '@/views/home/components/HomeHead.vue'
import UserList from '@/views/home/intelligence/process/UserPages.vue'
import {
timeStat,
externalTimeStat,
fetchmoduleStatExternalPage,
fetchPostList,
fetchmoduleStatInternalPage
fetchmoduleStatExternalPage
} from '@/api/daikin/base'
import { formatDate } from '@/utils/format'
import { Chart1 } from './indexData'
import zhCn from 'element-plus/lib/locale/lang/zh-cn'
import { Search } from '@element-plus/icons-vue'
import { NModal } from 'naive-ui'
const currentDate = new Date()
const currentDates = new Date()
const value1 = ref<[Date, Date]>([
@ -37,27 +33,17 @@ const pageInfo = reactive({
total: 10
})
const moduleCode = ref()
const imoduleCode = ref()
const visitDay = ref()
const waibuKd = ref()
const inseideDetail = ref([])
const outDetail = ref([])
const postId = ref<any>([])
const nickName = ref()
const postList = ref<any>([])
const getPostList = async () => {
const res: any = await fetchPostList()
postList.value = res.data || []
}
const getInsideListPage = async () => {
const res: any = await fetchmoduleStatInternalPage({
postId: postId.value,
nickName: nickName.value,
moduleCode: imoduleCode.value,
const res: any = await fetchmoduleStatExternalPage({
waibuKd: waibuKd.value,
visitDay: visitDay.value,
moduleCode: moduleCode.value,
pageNum: pageInfo.currentPage,
pageSize: pageInfo.pageSize,
...states
pageSize: pageInfo.pageSize
})
inseideDetail.value = res?.rows || []
pageInfo.total = res?.total || 0
@ -74,9 +60,8 @@ const getListPage = async () => {
pageInfo.total = res?.total || 0
}
getPostList()
getListPage()
getInsideListPage()
// getInsideListPage()
const clickButton = (id) => {
primary.value = id
@ -130,10 +115,6 @@ const getExternalTimeStat = async () => {
}
)
chartOption2.value = Chart1(xAxisData, siomesData)
console.log(
'🚀 ~ file: index.vue:131 ~ Chart1(xAxisData, siomesData):',
Chart1(xAxisData, siomesData)
)
// chartOption2.value.height=3000
// chartOption2.value.width=1000
}
@ -236,105 +217,6 @@ const handleClick = ({ paneName }: any) => {
}
const selValue = ref('')
const echartsItemColor = [
'#2ec7c9',
'#b6a2de',
'#5ab1ef',
'#ffb980',
'#d87a80',
'#8d98b3',
'#e5cf0d',
'#97b552',
'#95706d',
'#dc69aa',
'#07a2a4',
'#9a7fd1',
'#588dd5',
'#f5994e',
'#c05050',
'#59678c',
'#c9ab00',
'#7eb00a',
'#6f5553',
'#c14089'
]
const barOption = {
width: '100%',
height: '100%',
grid: {
top: 0,
left: 10,
right: 5,
bottom: 10,
containLabel: true
},
yAxis: {
data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun','hour','month','year'],
axisLabel: {
show: false, // x
interval: 0,
}
},
xAxis: {
type: 'value'
},
label: {
show: true,
position: 'inside',
align: 'center',
color: '#333', //
fontSize: 14, //
formatter: function (value: any) {
// console.log(value);
return value.name + ' ' + value.value
},
rotate: 0
},
tooltip: {
trigger: 'axis',
axisPointer: {
type: 'shadow'
},
formatter: function ([params]: any) {
const title = `<p>${params.name}</p>`
const colorDot =
'<span style="display:inline-block;margin-right:5px;border-radius:50%;width:10px;height:10px;background-color:' +
params.color +
'"></span>'
return title + colorDot + params.value
}
},
series: [
{
data: [120, 200, 150, 80, 70, 110, 130,123,50,80],
type: 'bar',
itemStyle: {
color: function (params: any) {
return echartsItemColor[params.dataIndex]
}
}
}
]
}
const showModal = ref(false)
const setUserList = ref<any>([])
const handleChild = async (data: any) => {
const { showModal: show, multipleSelection } = data
showModal.value = unref(show) || false
let userIdList: any[] = []
multipleSelection.value.forEach((i: { userId: any }) => {
userIdList.push(i.userId)
})
console.log("🚀 ~ file: index.vue:328 ~ userIdList:", userIdList)
}
const CloseThiss = (data?: boolean) => {
showModal.value = data || false
// setUserList.value = []
}
const isDev = false
</script>
<template>
@ -344,7 +226,7 @@ const isDev = false
<span class="text-#000 mr-10px">日期: </span>
<div class="max-w-350px flex items-center">
<el-date-picker
v-if="['inside', 'out', 'inside-detail'].includes(activeName)"
v-if="['inside', 'out'].includes(activeName)"
v-model="value1"
type="daterange"
range-separator="到"
@ -352,7 +234,6 @@ const isDev = false
end-placeholder="结束时间"
@change="timenFirst"
:shortcuts="shortcuts"
clearable
/>
<el-date-picker
v-else
@ -360,19 +241,14 @@ const isDev = false
type="date"
value-format="YYYY-MM-DD"
placeholder="选择日期"
clearable
/>
</div>
<div
class="mx-4 flex items-center"
v-if="['inside-detail', 'out-detail'].includes(activeName)"
>
<div class="mx-4 flex items-center">
<span class="text-#000 mr-10px">模块: </span>
<el-select
v-if="'out-detail' === activeName"
v-model="moduleCode"
placeholder="选择模块"
clearable
>
<el-option
v-for="item in externalList"
@ -381,39 +257,14 @@ const isDev = false
:value="item.moduleCode"
/>
</el-select>
<template v-if="'inside-detail' === activeName">
<el-select v-model="imoduleCode" placeholder="选择模块" clearable>
<el-option
v-for="item in dataList"
:key="item.id"
:label="item.moduleName"
:value="item.moduleCode"
/>
</el-select>
<span class="text-#000 mr-10px ml-4">职位: </span>
<el-select v-model="postId" placeholder="选择职位" clearable>
<el-option
v-for="item in postList"
:key="item.id"
:label="item.name"
:value="item.id"
/>
</el-select>
</template>
</div>
<div class="flex items-center" v-if="activeName === 'out-detail'">
>
<div class="flex items-center">
<span class="text-#000 mr-10px w-50px">供方: </span>
<el-input
v-model="waibuKd"
placeholder="请输入供方昵称或代码"
></el-input>
</div>
<div class="flex items-center" v-if="activeName === 'inside-detail'">
>
<span class="text-#000 mr-10px w-50px">昵称: </span>
<el-input v-model="nickName" placeholder="请输入用户昵称"></el-input>
</div>
<el-button
type="primary"
:icon="Search"
@ -446,7 +297,6 @@ const isDev = false
</div>
<el-tabs class="mt-20px" v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="本部足迹" name="inside">
<div class="overflow-auto h-720px">
<div class="mt20px w-full">
<span
class="cardfoot text-#000 p30px mx10px my10px text-center text-18px font-bold"
@ -460,7 +310,7 @@ const isDev = false
</span>
</div>
<!-- <div class="mt10px w-full"> -->
<div class="mt10px w-full">
<!-- <div class="relative w-full h-50px flex">
<el-button :type="primarys == 2 ? 'primary' : ''" :icon="Search" class="!ml30px mt--5px"
@click="clickButtons(2)">本周</el-button>
@ -473,75 +323,13 @@ const isDev = false
</el-config-provider>
</div>
</div> -->
<div class="w-full h-400px mt-10px">
<div class="w-full h-400px">
<VChart key="yyy" ref="chartRef1" :option="chartOption1" />
</div>
<div class="mt-30px">
<div class="flex items-center" v-if="isDev">
<span class="text-#000 mr-10px">模块: </span>
<el-select
v-model="moduleCode"
placeholder="选择模块"
clearable
>
<el-option
v-for="item in externalList"
:key="item.id"
:label="item.moduleName"
:value="item.moduleCode"
/>
</el-select>
<el-button
type="primary"
:icon="Search"
size="small"
class="ml20px"
@click="handleClick({ paneName: activeName })"
>搜索</el-button
>
<el-button
type="primary"
:icon="Search"
size="small"
class="ml20px"
@click="showModal = true"
>部长以上人员足迹</el-button
>
</div>
<div class="pb-14px" v-if="isDev">
<div class=" flex flex-wrap mb-30px" >
<div
class=" m-4 flex items-center justify-between w-45% h-full"
v-for="i in 10"
:key="i"
>
<div class="flex items-center text-#000 text-22px">
<p class="text-bold text-40px">{{ i }}TH</p>
<div class="mx-10px flex-col items-center">
<img src="@/views/extermal/images/zanwly2.png" alt="" />
<p class="text-center mt-10">测试 {{ i }}</p>
</div>
</div>
<VChart class="h-300px w-65% pb-10px ml-auto" key="yyy1" :option="barOption" />
</div>
</div>
<div class="absolute bottom-2px right-30px z-20 bg-#fff">
<el-pagination
v-model:current-page="pageInfo.currentPage"
v-model:page-size="pageInfo.pageSize"
layout="prev, pager, next, jumper"
:total="pageInfo.total"
@size-change="getInsideListPage"
@current-change="getInsideListPage"
/>
</div>
</div>
</div>
<!-- </div> -->
</div>
</el-tab-pane>
<el-tab-pane label="本部足迹-明细" name="inside-detail">
<div v-show="activeName === 'inside-detail'" class="h-720px">
<el-tab-pane v-if="false" label="本部足迹-明细" name="inside-detail">
<div v-if="activeName === 'inside-detail'" class="h-720px">
<div class="w100% h-full overflow-auto">
<el-table
:data="inseideDetail"
@ -559,28 +347,34 @@ const isDev = false
}"
:cell-style="{ 'text-align': 'center', 'overflow-y': 'auto' }"
>
<el-table-column prop="moduleName" label="模块名称" />
<el-table-column prop="deptName" label="排序" />
<el-table-column
prop="postName"
label="职位名称"
prop="cateName"
label="所属分类"
show-overflow-tooltip
>
<template #default="scope">
<span v-if="scope"></span>
</template>
</el-table-column>
<el-table-column
prop="nickName"
label="用户昵称"
prop="title"
label="标题名称"
show-overflow-tooltip
/>
<el-table-column
label="访问次数"
prop="visitCount"
show-overflow-tooltip
/>
<el-table-column
label="访问日期"
prop="visitTime"
label="文件列表"
prop="filePath"
show-overflow-tooltip
/>
<el-table-column label="排序" prop="sort" show-overflow-tooltip />
<el-table-column label="查看范围" prop="userIdList">
<template #default="scope">
<el-button type="primary" class="button" @click=""
>查看范围</el-button
>
</template>
</el-table-column>
</el-table>
</div>
<div class="absolute bottom-2px right-30px z-20 bg-#fff">
@ -615,6 +409,13 @@ const isDev = false
}"
:cell-style="{ 'text-align': 'center', 'overflow-y': 'auto' }"
>
<el-table-column prop="userId" label="供方ID" />
<el-table-column
prop="nickName"
label="供方昵称"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
prop="title"
label="访问模块"
@ -624,20 +425,13 @@ const isDev = false
<span>{{ externalObj[row.moduleCode] || '' }}</span>
</template>
</el-table-column>
<el-table-column prop="userId" label="供方ID" />
<el-table-column
prop="nickName"
label="供方昵称"
show-overflow-tooltip
>
</el-table-column>
<el-table-column
label="访问计数"
prop="visitCount"
show-overflow-tooltip
/>
<el-table-column
label="访问日期"
label="访问时间"
prop="visitDay"
show-overflow-tooltip
/>
@ -677,13 +471,6 @@ const isDev = false
</div>
</div>
</div>
<n-modal v-model:show="showModal">
<UserList
:userDataList="setUserList"
@clickChild="handleChild"
@CloseThis="CloseThiss"
/>
</n-modal>
</template>
<style lang="less" scoped>