Commit 47c7d35a by 杨铁龙

init

parents
Showing with 9595 additions and 0 deletions
> 1%
last 2 versions
not dead
NODE_ENV = development
# just a flag
ENV = 'development'
# base api 全局常量,定义接口的前缀
VUE_APP_CC_API = ''
VUE_APP_CC_MOCK = '/mocker'
# vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable,
# to control whether the babel-plugin-dynamic-import-node plugin is enabled.
# It only does one thing by converting all import() to require().
# This configuration can significantly increase the speed of hot updates,
# when you have a large number of pages.
# Detail: https://github.com/vuejs/vue-cli/blob/dev/packages/@vue/babel-preset-app/index.js
VUE_CLI_BABEL_TRANSPILE_MODULES = true
NODE_ENV = production
# just a flag
ENV = 'production'
# base api 全局常量,定义接口的前缀
VUE_APP_CC_API = ''
VUE_APP_CC_MOCK = '/mocker'
module.exports = {
root: true,
parserOptions: {
parser: 'babel-eslint',
extend: 'standard',
sourceType: 'module'
},
env: {
browser: true,
node: true,
es6: true,
},
extends: ['plugin:vue/recommended', 'eslint:recommended'],
// add your custom rules here
// it is base on https://github.com/vuejs/eslint-config-vue
rules: {
'vue/max-attributes-per-line': [2, {
'singleline': 10,
'multiline': {
'max': 1,
'allowFirstLine': false
}
}],
'vue/singleline-html-element-content-newline': 'off',
'vue/multiline-html-element-content-newline': 'off',
'vue/name-property-casing': ['error', 'PascalCase'],
'vue/no-v-html': 'off',
'accessor-pairs': 2,
'arrow-spacing': [2, {
'before': true,
'after': true
}],
'block-spacing': [2, 'always'],
'brace-style': [2, '1tbs', {
'allowSingleLine': true
}],
'camelcase': [0, {
'properties': 'always'
}],
'comma-dangle': [0, 'never'],
'comma-spacing': [2, {
'before': false,
'after': true
}],
'comma-style': [2, 'last'],
'constructor-super': 2,
'curly': [2, 'multi-line'],
'dot-location': [2, 'property'],
'eol-last': 2,
'eqeqeq': 'off',
'generator-star-spacing': [2, {
'before': true,
'after': true
}],
'handle-callback-err': [2, '^(err|error)$'],
'indent': [2, 2, {
'SwitchCase': 1
}],
'jsx-quotes': [2, 'prefer-single'],
'key-spacing': [2, {
'beforeColon': false,
'afterColon': true
}],
'keyword-spacing': [2, {
'before': true,
'after': true
}],
'new-cap': [2, {
'newIsCap': true,
'capIsNew': false
}],
'new-parens': 2,
'no-array-constructor': 2,
'no-caller': 2,
'no-console': 'off',
'no-class-assign': 2,
'no-cond-assign': 2,
'no-const-assign': 2,
'no-control-regex': 0,
'no-delete-var': 2,
'no-dupe-args': 2,
'no-dupe-class-members': 2,
'no-dupe-keys': 2,
'no-duplicate-case': 2,
'no-empty-character-class': 2,
'no-empty-pattern': 2,
'no-eval': 2,
'no-ex-assign': 2,
'no-extend-native': 2,
'no-extra-bind': 2,
'no-extra-boolean-cast': 2,
'no-extra-parens': [2, 'functions'],
'no-fallthrough': 2,
'no-floating-decimal': 2,
'no-func-assign': 2,
'no-implied-eval': 2,
'no-inner-declarations': [2, 'functions'],
'no-invalid-regexp': 2,
'no-irregular-whitespace': 2,
'no-iterator': 2,
'no-label-var': 2,
'no-labels': [2, {
'allowLoop': false,
'allowSwitch': false
}],
'no-lone-blocks': 2,
'no-mixed-spaces-and-tabs': 2,
'no-multi-spaces': 2,
'no-multi-str': 2,
'no-multiple-empty-lines': [2, {
'max': 1
}],
'no-native-reassign': 2,
'no-negated-in-lhs': 2,
'no-new-object': 2,
'no-new-require': 2,
'no-new-symbol': 2,
'no-new-wrappers': 2,
'no-obj-calls': 2,
'no-octal': 2,
'no-octal-escape': 2,
'no-path-concat': 2,
'no-proto': 2,
'no-redeclare': 2,
'no-regex-spaces': 2,
'no-return-assign': [2, 'except-parens'],
'no-self-assign': 2,
'no-self-compare': 2,
'no-sequences': 2,
'no-shadow-restricted-names': 2,
'no-spaced-func': 2,
'no-sparse-arrays': 2,
'no-this-before-super': 2,
'no-throw-literal': 2,
'no-trailing-spaces': 2,
'no-undef': 2,
'no-undef-init': 2,
'no-unexpected-multiline': 2,
'no-unmodified-loop-condition': 2,
'no-unneeded-ternary': [2, {
'defaultAssignment': false
}],
'no-unreachable': 2,
'no-unsafe-finally': 2,
'no-unused-vars': [2, {
'vars': 'all',
'args': 'none'
}],
'no-useless-call': 2,
'no-useless-computed-key': 2,
'no-useless-constructor': 2,
'no-useless-escape': 0,
'no-whitespace-before-property': 2,
'no-with': 2,
'one-var': [2, {
'initialized': 'never'
}],
'operator-linebreak': [2, 'after', {
'overrides': {
'?': 'before',
':': 'before'
}
}],
'padded-blocks': [2, 'never'],
'quotes': [2, 'single', {
'avoidEscape': true,
'allowTemplateLiterals': true
}],
'semi': [2, 'never'],
'semi-spacing': [2, {
'before': false,
'after': true
}],
'space-before-blocks': [2, 'always'],
'space-before-function-paren': [2, 'never'],
'space-in-parens': [2, 'never'],
'space-infix-ops': 2,
'space-unary-ops': [2, {
'words': true,
'nonwords': false
}],
'spaced-comment': [2, 'always', {
'markers': ['global', 'globals', 'eslint', 'eslint-disable', '*package', '!', ',']
}],
'template-curly-spacing': [2, 'never'],
'use-isnan': 2,
'valid-typeof': 2,
'wrap-iife': [2, 'any'],
'yield-star-spacing': [2, 'both'],
'yoda': [2, 'never'],
'prefer-const': 2,
'no-debugger': process.env.NODE_ENV === 'production' ? 2 : 0,
'object-curly-spacing': [2, 'always', {
objectsInObjects: false
}],
'array-bracket-spacing': [2, 'never']
}
}
.DS_Store
node_modules
/dist
# local env files
.env.local
.env.*.local
# Log files
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
# webapp
## Project setup
```
npm install
```
### Compiles and hot-reloads for development
```
npm run serve
```
### Compiles and minifies for production
```
npm run build
```
### Lints and fixes files
```
npm run lint
```
### Customize configuration
See [Configuration Reference](https://cli.vuejs.org/config/).
module.exports = {
presets: ['@vue/cli-plugin-babel/preset']
}
This diff could not be displayed because it is too large.
{
"name": "webapp",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "vue-cli-service serve",
"build": "vue-cli-service build --mode production",
"lint": "vue-cli-service lint"
},
"dependencies": {
"axios": "^0.21.0",
"core-js": "^3.6.5",
"crypto-js": "^4.0.0",
"dayjs": "^1.9.6",
"echarts": "^4.9.0",
"element-ui": "^2.15.6",
"fastclick": "^1.0.6",
"file-saver": "^2.0.5",
"good-storage": "^1.1.1",
"js-cookie": "^2.2.0",
"lodash.omit": "^4.5.0",
"moment": "^2.29.1",
"normalize-css": "^2.3.1",
"sass-loader": "^10.0.4",
"vant": "2.12.29",
"vue": "^2.6.11",
"vue-count-to": "^1.0.13",
"vue-router": "^3.2.0",
"vue-seamless-scroll": "^1.1.23",
"vuex": "^3.4.0",
"wangeditor": "^4.5.1"
},
"devDependencies": {
"@vue/cli-plugin-babel": "~4.5.0",
"@vue/cli-plugin-eslint": "~4.5.0",
"@vue/cli-plugin-router": "~4.5.0",
"@vue/cli-plugin-vuex": "~4.5.0",
"@vue/cli-service": "~4.5.0",
"@vue/eslint-config-prettier": "^6.0.0",
"babel-eslint": "^10.1.0",
"compression-webpack-plugin": "^3.1.0",
"eslint": "^6.7.2",
"eslint-plugin-prettier": "^3.1.3",
"eslint-plugin-vue": "^6.2.2",
"image-webpack-loader": "^7.0.1",
"less": "^3.0.4",
"less-loader": "^5.0.0",
"postcss-pxtorem": "^5.1.1",
"prettier": "^1.19.1",
"script-ext-html-webpack-plugin": "2.1.3",
"uglifyjs-webpack-plugin": "^1.0.0-rc.0",
"vue-skeleton-webpack-plugin": "^1.2.2",
"vue-template-compiler": "^2.6.11",
"webpack-cli": "^4.1.0"
}
}
No preview for this file type
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<meta http-equiv="cache-control" content="no-cache, must-revalidate" />
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="expires" content="Fri, 26 Nov 2021 23:22:26 GMT" />
<meta http-equiv="expires" content="0" />
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
<title><%= webpackConfig.name %></title>
<!-- 引入样式 -->
<% for(var i in htmlWebpackPlugin.options.cdn && htmlWebpackPlugin.options.cdn.css) { %>
<link rel="stylesheet" href="<%= htmlWebpackPlugin.options.cdn.css[i] %>">
<% } %>
</head>
<body>
<noscript>
<strong>We're sorry but <%= webpackConfig.name %> doesn't work properly without JavaScript enabled. Please enable it
to continue.</strong>
</noscript>
<!-- 引入JS -->
<% for(var i in htmlWebpackPlugin.options.cdn && htmlWebpackPlugin.options.cdn.js) { %>
<script src="<%= htmlWebpackPlugin.options.cdn.js[i] %>"></script>
<% } %>
<div id="app"></div>
<!-- built files will be auto injected -->
</body>
</html>
\ No newline at end of file
<template>
<div id="app">
<TopBar />
<keep-alive>
<router-view />
</keep-alive>
</div>
</template>
<script>
import TopBar from '@/components/TopBar'
export default {
name: 'App',
components: {
TopBar
},
data() {
return {}
}
}
</script>
<style lang="less">
// @designWidth: 1920px; // 设计稿宽度
// @rootFontSize: 80px; // 根文字字号
@rem: 20rem;
html{
// 关于2.666vw计算,用的是100VW * @size / designWidth, 这里用的是100*20/750 = 2.666,其中,100vw就是设备宽度
font-size: 80px;
}
body {
background: #F5F5F5;
}
#app {
font-family: Avenir, Helvetica, Arial, sans-serif;
background: url('~@/assets/images/system_bg.png') no-repeat;
background-size: 100% 100%;
}
p {
margin: 0;
padding: 0;
}
</style>
import request from '@/utils/request'
import common from '@/common/common'
// 获取报告列表
export function getReportList(params) {
return request({
url: common.CC_API + `/dashboard/api/v2/analysisReport/getReportList`,
method: 'GET',
params
})
}
// 删除报告
export function deleteReport(id) {
return request({
url: common.CC_API + `/dashboard/api/v2/analysisReport/deleteReport?id=${id}`,
method: 'GET'
})
}
// 下载文件
export function downloadFile(id) {
return request({
url: common.CC_API + `/dashboard/api/v2/analysisReport/downloadFile?id=${id}`,
method: 'GET'
})
}
// 获取报告下载历史
export function getReportUploadHistory(params) {
return request({
url: common.CC_API + `/dashboard/api/v2/analysisReport/getReportUploadHistory`,
method: 'GET',
params
})
}
// 生成报告
export function autoGenerateFile(data) {
return request({
url: common.CC_API + `/dashboard/api/v2/analysisReport/autoGenerateFile`,
method: 'POST',
data
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 标题统计-今日采集情况
*/
export function getToday(params) {
return request({
url: common.CC_API + `/bigdata/api/collectionStatistics/today`,
method: 'GET',
params
})
}
/**
* 近七天更新已采集数据
*/
export function getRecent7(params) {
return request({
url: common.CC_API + `/bigdata/api/collectionStatistics/recent`,
method: 'GET',
params
})
}
/**
* 近7天采集趋势-本月
*/
export function getTrendMonth(params) {
return request({
url: common.CC_API + `/bigdata/api/collectionStatistics/trendMonth`,
method: 'GET',
params
})
}
/**
* 近7天采集趋势-今日
*/
export function getTrendToday(params) {
return request({
url: common.CC_API + `/bigdata/api/collectionStatistics/trendToday`,
method: 'GET',
params
})
}
/**
* 近7天采集趋势-今日
*/
export function getTrendWeek(params) {
return request({
url: common.CC_API + `/bigdata/api/collectionStatistics/trendWeek`,
method: 'GET',
params
})
}
/**
* 地图分布
*/
export function getArea(params) {
return request({
url: common.CC_API + `/bigdata/api/collectionStatistics/area`,
method: 'GET',
params
})
}
// 采集调度表
import request from '@/utils/request'
import common from '@/common/common'
/**
* 调度表列表
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
*/
export function getBrokerDispatchList(params) {
return request({
url: common.CC_API + `/bigdata/api/pc/collection/getBrokerDispatchList`,
method: 'get',
params
})
}
// 导出调度表报表
export function exportBrokerDispatch(params) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/exportBrokerDispatch',
method: 'get',
params,
responseType: 'blob'
})
}
/**
* 进度调度表列表
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
*/
export function getAllBrokerDispatchList(params) {
return request({
url: common.CC_API + `/bigdata/api/pc/collection/getAllBrokerDispatchList`,
method: 'get',
params
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 获取导入数据信息列表
* @param {Object} data
*/
export function getLoborCollectList(data) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/getLaborCollectionImportList',
method: 'get',
params: data
})
}
/**
* 获取统计图数据
* @param {Object} data
*/
export function laborCountryOrVillageCount() {
return request({
url: common.CC_API + '/dashboard/api/pc/collection/laborCountryOrVillageCount',
method: 'get'
})
}
/**
* 获取统计图数据
* @param {Object} data
*/
export function getLaborVillageCount(params) {
return request({
url: common.CC_API + '/dashboard/api/pc/collection/laborVillageCount',
method: 'get',
params
})
}
/**
* 获取统计图数据
* @param {Object} data
*/
export function getLaborCountryCount(params) {
return request({
url: common.CC_API + '/dashboard/api/pc/collection/laborCountryCount',
method: 'get',
params
})
}
/**
* 获取劳动力采集信息详情
* @param {String} id 采集信息id
*/
export function getLoborCollectByid(id, status) {
return request({
url: common.CC_API + `/dashboard/api/pc/collection/getCollectionImportDetail?id=${id}`,
method: 'get'
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 线上采集区/乡/村统计-PC 列表
* @param {Object} data
*/
export function getLaborCountList(data) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/getLaborCountList',
method: 'GET',
params: data
})
}
/**
* 线上采集统计标题-PC
*/
export function getCollectionTitle(curAreaID, curAreaGrade, source) {
return request({
url: common.CC_API + `/bigdata/api/pc/collection/getCollectionTitle?areaCode=${curAreaID}&areaCodeLevel=${curAreaGrade}&source=${source}`,
method: 'GET'
})
}
/**
* 线上采集统计标题-PC
* 获取头部采集更新目标数和待采集更新人数统计
*/
export function getTotalCount(curAreaID, curAreaGrade, source) {
return request({
url: common.CC_API + `/bigdata/api/pc/collection/getToCollectionTitle?areaCode=${curAreaID}&areaCodeLevel=${curAreaGrade}&source=${source}`,
method: 'GET'
})
}
/**
* 线上采集统计近七天新增更新-PC
*/
export function getCollectionRecent(curAreaID, curAreaGrade, source) {
return request({
url: common.CC_API + `/dashboard/api/pc/collection/getCollectionRecent?areaCode=${curAreaID}&areaCodeLevel=${curAreaGrade}&source=${source}`,
method: 'GET'
})
}
/**
* 线上采集统计地区分布-PC
*/
export function getCollectionArea(curAreaID, curAreaGrade, source) {
return request({
url: common.CC_API + `/dashboard/api/pc/collection/getCollectionArea?areaCode=${curAreaID}&areaCodeLevel=${curAreaGrade}&source=${source}`,
method: 'GET'
})
}
import request from '@/utils/request'
import common from '@/common/common'
// 发布新消息
export function addTask(data) {
return request({
url: common.CC_API + `/dashboard/api/v2/createTaskRecord/addTask`,
method: 'POST',
data
})
}
// 我发布的消息
export function getSendMsg(data) {
return request({
url: common.CC_API + `/dashboard/api/v2/createTaskRecord/list`,
method: 'POST',
data
})
}
// 消息详情
export function getMsgDetails(id) {
return request({
url: common.CC_API + `/dashboard/api/v2/createTaskRecord/task/${id}`,
method: 'GET'
})
}
import request from '@/utils/request'
import common from '@/common/common'
// 获取统计信息
export function getServiceStatistics() {
return request({
url: common.CC_RESULT + `/api/admin/api/task/serviceStatistics`,
method: 'get'
})
}
// 数据核验服务
export function getVerificationService() {
return request({
url: common.CC_RESULT + `/api/admin/api/task/verificationService`,
method: 'GET'
})
}
// 线下招聘会
export function getJobFairOffline() {
return request({
url: common.CC_RESULT + `/api/admin/api/task/jobFairOffline`,
method: 'GET'
})
}
import request from '@/utils/request'
import common from '@/common/common'
// 根据区域等级取区域数据
export function getSysRegion(page, size, regionName, regionCode, regionGrade, pid) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion?page=${page}&size=${size}&regionName=${regionName}&regionCode=${regionCode}&regionGrade=${regionGrade}&pid=${pid}`,
method: 'GET'
})
}
// 根据区域等级取区域数据
export function getRegionLevel(regionGrade, pid) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion/getRegionLevel?regionGrade=${regionGrade}&pid=${pid}`,
method: 'GET'
})
}
// 系统区域数据删除
export function delAreaCode(id) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion/${id}`,
method: 'DELETE'
})
}
// 系统区域数据修改
export function editAreaCode(form, id) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion/${id}`,
method: 'PUT',
data: form
})
}
// 区域保存
export function newAreaCode(data) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion`,
method: 'post',
data
})
}
// 区域列表导出
export function exportArea(params) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion/export`,
headers: { 'content-type': 'application/x-www-form-urlencoded' },
responseType: 'blob',
method: 'get',
params
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 电话回访名单列表导出
*/
export function dataSamplingByPhone() {
return request({
url: common.CC_API + '/dashboard/api/bigdata/acceptanceSurvey/telephoneVisit',
method: 'get',
responseType: 'blob'
})
}
/**
* 培训信息名单列表导出
*/
export function dataSamplingOfTrain() {
return request({
url: common.CC_API + '/dashboard/api/bigdata/acceptanceSurvey/trainVisit',
method: 'get',
responseType: 'blob'
})
}
/**
* 社保信息名单列表导出
*/
export function dataSamplingOfSocialSecurity() {
return request({
url: common.CC_API + '/dashboard/api/bigdata/acceptanceSurvey/SocialInsuranceVisit',
method: 'get',
responseType: 'blob'
})
}
/**
* 获取所有村信息
*/
export function getAllVillages() {
return request({
url: common.CC_API + '/dashboard/api/v2/rasicRegion/allVillages',
method: 'get'
})
}
/**
* 获取所有村信息
*/
export function dataSamplingByVisit(params) {
return request({
url: common.CC_API + '/dashboard/api/bigdata/acceptanceSurvey/villageVisit',
method: 'get',
params,
responseType: 'blob'
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 残疾人总数
* @param data
*/
export function deformedManAll(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/deformedManAll`,
method: 'POST',
data
})
}
/**
* 残疾类型分布
* @param data
*/
export function getDeformedType(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/deformedType`,
method: 'POST',
data
})
}
/**
* 就业渠道分布
* @param data
*/
export function getEmploymentChannel(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/employmentChannel`,
method: 'POST',
data
})
}
/**
* 参保险种分布
* @param data
*/
export function getInsuranceType(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/insuranceType`,
method: 'POST',
data
})
}
/**
* 就业行业分布TOP10
* @param data
*/
export function employmentIndustryDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/employmentIndustryDistr`,
method: 'POST',
data
})
}
/**
* 就业状态分布
* @param data
*/
export function getEmploymentStatus(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/employmentStatusDistr`,
method: 'POST',
data
})
}
/**
* 伤残等级分布
* @param data
*/
export function getDeformedLevel(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/deformedLevel`,
method: 'POST',
data
})
}
/**
* 年龄及性别分布
* @param data
*/
export function getAgeDistribution(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/ageGroupAndSex`,
method: 'POST',
data
})
}
/**
* 户籍性质分布
* @param data
*/
export function getEmploymentHope(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/registeredNature`,
method: 'POST',
data
})
}
/**
* 技能培训类型
* @param data
*/
export function getTrainIntention(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/skillTrainType`,
method: 'POST',
data
})
}
/**
* 残疾地图分布
* @param data
*/
export function deformedManDistribute(data) {
return request({
url: common.CC_API + `/dashboard/api/deformedManAnalysis/deformedManDistribute`,
method: 'POST',
data
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 年龄段分布
*/
export function ageStructure(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart7`,
method: 'GET',
params
})
}
/**
* 文化程度
*/
export function degreeOfEducation(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bdjyry/chart2`,
method: 'GET',
params
})
}
/**
* 工作年限
*/
export function workExperience(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bdjyry/chart3`,
method: 'GET',
params
})
}
/**
* 就业方式
*/
export function backPersonEmploymentWay(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart2`,
method: 'GET',
params
})
}
/**
* 薪资分布
*/
export function salaryDistribution(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart3`,
method: 'GET',
params
})
}
/**
* 本地就业创业人数
*/
export function personnelCount(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart1`,
method: 'GET',
params
})
}
/**
* 各村户籍明细
*/
export function getVillageDetailed(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bdjyry/listVillagesDetail`,
method: 'GET',
params
})
}
/**
* 就业行业分布TOP10
*/
export function outsideManSalary(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart4`,
method: 'GET',
params
})
}
/**
* 就业工种top10
*/
export function getOutsideManSalary(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart6`,
method: 'GET',
params
})
}
/**
* 文化程度分布
*/
export function getCultureSpread(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart8`,
method: 'GET',
params
})
}
/**
* 就业地分布
*/
export function getPersonnelDistribution(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart5`,
method: 'GET',
params
})
}
/**
* 参保险种分布
*/
export function getOperationMode(params) {
return request({
url: common.CC_API + `/dashboard/api/residence/chart9`,
method: 'GET',
params
})
}
// 高校毕业生大屏
import request from '@/utils/request'
import common from '@/common/common'
/**
* 顶部各项独立指标
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function itemCount(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/itemCount`,
method: 'POST',
data: params
})
}
/**
* 学校类型
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function schoolType(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/schoolType`,
method: 'POST',
data: params
})
}
/**
* 学历就业分布
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function educationEmploymentDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/educationEmploymentDistr`,
method: 'POST',
data: params
})
}
/**
* 薪资分布
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function salaryDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/salaryDistr`,
method: 'POST',
data: params
})
}
/**
* 就业工种TOP10
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function employmentWorkTypeDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/employmentWorkTypeDistr`,
method: 'POST',
data: params
})
}
/**
* 所学专业TOP10
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function majorDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/majorDistr`,
method: 'POST',
data: params
})
}
/**
* 未就业原因分布
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function unemploymentReasonDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/unemploymentReasonDistr`,
method: 'POST',
data: params
})
}
/**
* 就业意向工种
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function intentWorkTypeDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/intentWorkTypeDistr`,
method: 'POST',
data: params
})
}
/**
* 参加培训情况
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function trainDetailDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/trainDetailDistr`,
method: 'POST',
data: params
})
}
/**
* 学校类型明细(把类似'985高校'名称传给name参数)
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function schoolTypeList(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/schoolTypeList`,
method: 'POST',
data: params
})
}
/**
* 就业地区(省)分布
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
* areaCodeLevel
* name
* pageNum
* pageSize
*/
export function employmentAreaDistr(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjgx/employmentAreaDistr`,
method: 'POST',
data: params
})
}
// 整体概览大屏
import request from '@/utils/request'
import common from '@/common/common'
/**
* 毕节市总劳动力
*/
export function getTotalLabor(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart1`,
method: 'GET',
params
})
}
/**
* 就业创业人数
*/
export function getDoPioneeringWork(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart2`,
method: 'GET',
params
})
}
/**
* 暂未就业人数
*/
export function getNoDoWork(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart3`,
method: 'GET',
params
})
}
/**
* 学历分布
*/
export function getEducationECharts(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart5`,
method: 'GET',
params
})
}
/**
* 年龄段性别分布
*/
export function getAgeECharts(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart4`,
method: 'GET',
params
})
}
/**
* 获取劳动力类型
*/
export function getlaborType(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart7`,
method: 'GET',
params
})
}
/**
* 毕节工匠系列
*/
export function getCraftsmanList(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart10`,
method: 'GET',
params
})
}
/**
* 已参保人数
*/
export function getInsuredPersons(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart8`,
method: 'GET',
params
})
}
/**
* 毕节区域地图数据
*/
export function getregionMap(params, url, type) {
let obj = {}
if (type === 'get') {
obj = {
url: common.CC_API + url,
method: type,
params
}
} else {
obj = {
url: common.CC_API + url,
method: type,
data: params
}
}
return request(obj)
}
// 社区列表
export function getTableList(params, url, type) {
if (type === 'post') {
return request({
url: common.CC_API + url,
method: 'POST',
data: params
})
} else {
return request({
url: common.CC_API + url,
method: 'GET',
params
})
}
}
// 退出劳动力原因
export function getWithoutLaborReason(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/withoutLaborReason`,
method: 'GET',
params
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 获取当前就业数
*/
export function getAlljiuye() {
return request({
url: common.CC_API + `/dashboard/api/personData/dangqianjiuye`,
method: 'get'
})
}
/**
* 获取就业数
*/
export function getjiuye() {
return request({
url: common.CC_API + `/dashboard/api/personData/jiuye`,
method: 'get'
})
}
/**
* 各年龄段人数分布
*/
export function getnianlin() {
return request({
url: common.CC_API + `/dashboard/api/personData/nianlin`,
method: 'get'
})
}
/**
* 各工作就业年限人数
*/
export function getnianxian() {
return request({
url: common.CC_API + `/dashboard/api/personData/nianxian`,
method: 'get'
})
}
/**
* 各月份人才量
*/
export function getrencailiang() {
return request({
url: common.CC_API + `/dashboard/api/personData/rencailiang`,
method: 'get'
})
}
/**
* 各性别人数分布
*/
export function getxinbie() {
return request({
url: common.CC_API + `/dashboard/api/personData/xinbie`,
method: 'get'
})
}
/**
* 各学历人数分布
*/
export function getxueli() {
return request({
url: common.CC_API + `/dashboard/api/personData/xueli`,
method: 'get'
})
}
/**
* 各职业类别人数
*/
export function getzhiye() {
return request({
url: common.CC_API + `/dashboard/api/personData/zhiye`,
method: 'get'
})
}
/**
* 个人画像列表
*/
export function getUserList(data) {
return request({
// url: common.CC_API + `/dashboard/api/darwnew/esDarwList`,(暂时不上)
url: common.CC_API + `/dashboard/api/darwnew/darwList`,
method: 'POST',
data
})
}
/**
* 参保信息查询列表
*/
export function getInsureList(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/insure/insureList`,
method: 'GET',
params
})
}
/**
* 个人画像图表数据
*/
export function getPersonaechart() {
return request({
url: common.CC_API + `/dashboard/api/bigdata/darw/talentDashBoard`,
method: 'GET'
})
}
/**
* 获取画像用户详情
*/
// export function getUserDetail(data) {
// return request({
// url: common.CC_API + `/dashboard/api/darwnew/esDarwByIdcard`,
// method: 'POST',
// data
// })
// }
export function getUserDetail(guid) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/darwList/${guid}`,
method: 'get'
})
}
/**
* 获取画像用户详情2
*/
export function getDetail(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/darw/supplementData`,
method: 'post',
params
})
}
/**
* 获取画像用户工作经历
*/
export function getworkExp(personId, pageNum, pageSize) {
return request({
url: common.CC_API + `/dashboard/api/portrait/personal/workExperience?personId=${personId}&pageNum=${pageNum}&pageSize=${pageSize}`,
method: 'get'
})
}
/**
* 获取画像简历投递记录
*/
export function getresumes(personId, pageNum, pageSize) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/darw/resumes?personId=${personId}&pageNum=${pageNum}&pageSize=${pageSize}`,
method: 'get'
})
}
/**
* 获取画像岗位推荐
*/
export function getJobRecommendation(personId, pageNum, pageSize) {
return request({
url: common.CC_API + `/dashboard/api/portrait/personal/getJobRecommendation?personId=${personId}&pageNum=${pageNum}&pageSize=${pageSize}`,
method: 'get'
})
}
/**
* 获取画像意向产业分析
*/
export function getwillIndustryAnalysis(personId) {
return request({
url: common.CC_API + `/dashboard/api/portrait/personal/willIndustryAnalysis?personId=${personId}`,
method: 'get'
})
}
/**
* 劳动力动态查询即可欧
*/
// 学历分布
export function geteducation(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/educationList`,
method: 'post',
data
})
}
// 特殊人群类型
export function getlaborType(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/personTypeDistr`,
method: 'post',
data
})
}
// 性别统计
export function getsexCount(data) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/darw/sexCount`,
method: 'post',
data
})
}
// 劳动力总数
export function getdataCount(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/employmentAreaList`,
method: 'post',
data
})
}
// 就业创业劳动力
export function getregionMap(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/employmentAreaDistr`,
method: 'post',
data
})
}
// 毕节补充地图: 1 百里杜鹃 ,2 金海湖
export function getMap(data) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/darw/trainType`,
method: 'post',
data
})
}
// 就业方式统计
export function getdoPioneeringWork(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/employmentTypeDistr`,
method: 'post',
data
})
}
// 区域就业人数统计
export function getldlLabelCount(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/laborList`,
method: 'post',
data
})
}
// 新的毕节数据分析接口
// 毕节市总劳动力
export function gettotalLabor() {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bigdp/totalLabor`,
method: 'get'
})
}
// 适龄劳动力
export function getTotalLabor() {
return request({
url: common.CC_API + `/dashboard/api/bigdata/darw/darwTotalLabor`,
method: 'get'
})
}
// 人才竞争力情况
export function personCompetitiveness(personId) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/darw/personCompetitive?personId=${personId}`,
method: 'get'
})
}
// 劳动力个人画像
export function getDarwList(params) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/darwList`,
method: 'GET',
params
})
}
// 动态标签查询-报表统计-人员明细列表
export function getSpecialCrowdList(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/specialCrowdList`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-返乡原因
export function getReturnReason(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/returnReasonDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-返乡农名工数量前十
export function getReturnAreaDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/beforeReturnAreaDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-返乡农名工学历
export function getEducationDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/returnEducationDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-返乡农名工年龄段
export function getAgeDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/returnAgeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-返乡农名工就业情况
export function getEmploymentStatusDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/employmentStatusDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-返乡农名工务工地点分布
export function getReturnEmploymentAreaDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/afterReturnEmploymentAreaDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-返乡农名工就业方式
export function getReturnEmploymentTypeDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/returnEmploymentTypeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-特殊人群求职意向地
export function getTrainEmploymentWishAreatDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/applyEmploymentWishAreaDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-特殊人群求职意向月薪
export function getTrainSalaryDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/applySalaryDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-特殊人群有求职意向
export function getTrainApplyWillingDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/applyWillingDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-特殊人群有求职意向
export function getTrainApplyWorkTypeDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/applyWorkTypeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-特殊人群类型统计
export function getTrainPpersonTypeDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/personTypeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-特殊人群培训意向工种
export function getTrainIntentWorkTypeDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/trainIntentWorkTypeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-特殊人群培训意愿
export function getTrainWillingDistr(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/trainWillingDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-技能培训-性别分布
export function getSkillTrainSex(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/skillTrainSexDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-技能培训-户口性质分布
export function getSkillTrainRegisteredNature(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/skillTrainRegisteredNatureDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-技能培训-参加技能培训分布
export function getSkillTrain(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/skillTrainDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-技能培训-就业状态分布
export function getSkillTrainEmploymentStatus(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/skillTrainEmploymentStatusDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-技能培训-就业方式分布
export function getSkillTrainEmploymentType(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/skillTrainEmploymentTypeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-脱贫外出务工-外出务工地分布
export function getMigrantWork(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/migrantWorkDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-脱贫外出务工-就业方式分布
export function getMigrantEmploymentType(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/migrantWorkEmploymentTypeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-脱贫外出务工-薪资分布
export function getMigrantSalary(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/migrantWorkSalaryDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-脱贫外出务工-从事行业分布
export function getMigrantIndustry(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/migrantWorkIndustryDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-脱贫外出务工-从事工种分布
export function getMigrantWorkType(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/migrantWorkWorkTypeDistr`,
method: 'post',
data
})
}
// 动态标签查询-报表统计-脱贫外出务工-参保情况
export function getMigrantInsured(data) {
return request({
url: common.CC_API + `/dashboard/api/darwnew/migrantWorkInsuredDistr`,
method: 'post',
data
})
}
/**
* 动态标签页导出
*/
export function laborListExport(data) {
return request({
url: common.CC_API + '/dashboard/api/darwnew/laborListExport',
method: 'POST',
responseType: 'blob',
data
})
}
/**
* 导出统计明细
*/
export function exportCountDetail(data) {
return request({
url: common.CC_API + '/dashboard/api/darwnew/exportCountDetail',
method: 'POST',
responseType: 'blob',
data
})
}
/**
* 特殊人群就业培训统计报告
* @param data
*
*/
export function applyCountReport(params) {
delete params.trainSituation
return request({
url: common.CC_API + `/dashboard/api/darwnew/applyCountReport`,
method: 'POST',
responseType: 'blob',
data: params
})
}
/**
* 脱贫人口统计报告
* @param data
*
*/
export function migrantWorkCountReport(params) {
delete params.trainSituation
return request({
url: common.CC_API + `/dashboard/api/darwnew/migrantWorkCountReport`,
method: 'POST',
responseType: 'blob',
data: params
})
}
/**
* 返乡农民工统计报告
* @param data
*
*/
export function returnCountReport(params) {
delete params.trainSituation
return request({
url: common.CC_API + `/dashboard/api/darwnew/returnCountReport`,
method: 'POST',
responseType: 'blob',
data: params
})
}
/**
* 职业技能培训统计报告
* @param data
*
*/
export function skillTrainCountReport(params) {
// delete params.trainSituation
return request({
url: common.CC_API + `/dashboard/api/darwnew/skillTrainCountReport`,
method: 'POST',
responseType: 'blob',
data: params
})
}
/**
* 获取劳动力采集信息详情
* @param {String} id 采集信息id
*/
export function getLoborCollectByid(id, status) {
return request({
url: common.CC_API + `/dashboard/api/pc/collection/getCollectionDetail?id=${id}&status=${status}`,
method: 'get'
})
}
import request from '@/utils/request'
import common from '@/common/common'
// 获取
export function getLogList(data) {
return request({
url: common.CC_API + `/user/api/v2/sysOperationLog/list`,
method: 'POST',
data
})
}
// 高校毕业生大屏
import request from '@/utils/request'
import common from '@/common/common'
/**
* 返乡年龄
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function ageAndSex(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/age`,
method: 'get',
params
})
}
/**
* 返乡原因
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function returnReason(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/returnReason`,
method: 'get',
params
})
}
/**
* 返岗外出方式
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function migrantType(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/migrantType`,
method: 'get',
params
})
}
/**
* 未返岗原因
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function noReturnReason(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/noReturnReason`,
method: 'get',
params
})
}
/**
* 返乡返岗人员变化趋势
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function returnTrend(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/trend`,
method: 'get',
params
})
}
/**
* 人员类型
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function peopleType(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/peopleType`,
method: 'get',
params
})
}
/**
* 文化程度
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function education(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/education`,
method: 'get',
params
})
}
/**
* 返乡流动
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function returnHomeArea(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/returnDistribution`,
method: 'get',
params
})
}
/**
* 返岗流动
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function returnWorkDistribution(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/returnWorkDistribution`,
method: 'get',
params
})
}
/**
* 标题统计
* @param data
* areaCode 控制账号区域编码(区县、乡镇、村社区)
*/
export function numStatistics(params) {
return request({
url: common.CC_API + `/bigdata/api/returnStatistics/title`,
method: 'get',
params
})
}
import request from '@/utils/request'
import common from '@/common/common'
// import Qs from 'qs'
/**
* 机构列表
* @param pageNo
* @param pageSize
* @param data
*/
export function getOrganList(params) {
return request({
url: common.CC_API + '/user/api/v2/sysDept',
method: 'GET',
params
})
}
/**
* 获取下架机构列表
* @param pageNo
* @param pageSize
* @param data
*/
export function getNextGrade(deptCode) {
return request({
url: common.CC_API + `/user/api/v2/sysDept/nextGrade/${deptCode}`,
method: 'GET'
})
}
/**
* 机构列表
* @param pageNo
* @param pageSize
* @param data
*/
export function getOrganDetail(id) {
return request({
url: common.CC_API + `/user/api/v2/sysDept/${id}`,
method: 'GET'
})
}
/**
* 新增机构
* @param data
* */
export function addOrg(data) {
return request({
url: common.CC_API + '/user/api/v2/sysDept',
method: 'POST',
data
})
}
/**
* 修改机构
* @param data
* */
export function updateOrg(id, data) {
return request({
url: common.CC_API + `/user/api/v2/sysDept/${id}`,
method: 'PUT',
data
})
}
/**
* 删除机构
* @param id
* */
export function deleteOrg(id, data) {
return request({
url: common.CC_API + `/user/api/v2/sysDept/${id}`,
method: 'DELETE',
// headers: {
// 'Content-Type': 'application/x-www-form-urlencoded'
// },
// data: Qs.stringify({ id })
data
})
}
/**
* 机构列表导出
* @param data
* */
export function exportOrganList(data) {
return request({
url: common.CC_API + `/user/api/v2/sysDept/export`,
method: 'GET',
params: data,
responseType: 'blob'
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 年龄段性别分布
*/
export function getAgeSex(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/ageSexDistr`,
method: 'POST',
data: params
})
}
/**
* 文化程度分布
*/
export function getEducation(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/educationDistr`,
method: 'POST',
data: params
})
}
/**
* 薪资分布
*/
export function getSalary(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/salaryDistr`,
method: 'POST',
data: params
})
}
/**
* 地区分布
*/
export function getArea(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/areaDistr`,
method: 'POST',
data: params
})
}
/**
* 就业方式分布
*/
export function getEmploymentType(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/employmentTypeDistr`,
method: 'POST',
data: params
})
}
/**
* 顶部各项独立指标
*/
export function getItemCount(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/itemCount`,
method: 'POST',
data: params
})
}
/**
* 参保险种分布
*/
export function getInsuranceType(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/insuranceTypeDistr`,
method: 'POST',
data: params
})
}
/**
* 求职意向岗位top10
*/
export function getAapplyIntentPosition(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/applyIntentPositionDistr`,
method: 'POST',
data: params
})
}
/**
* 就业意向分布
*/
export function getEmploymentIntent(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/employmentIntentDistr`,
method: 'POST',
data: params
})
}
/**
* 培训意向分布
*/
export function getTrainIntent(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/trainIntentDistr`,
method: 'POST',
data: params
})
}
/**
* 未就业原因
*/
export function getUnemploymentReason(params) {
return request({
url: common.CC_API + `/dashboard/api/poorHouseholds/unemploymentReasonDistr`,
method: 'POST',
data: params
})
}
// 整体概览大屏
import request from '@/utils/request'
import common from '@/common/common'
/**
* 获取劳动力类型
*/
export function getlaborType(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart7`,
method: 'GET',
params
})
}
/**
* 已参保人数
*/
export function getInsuredPersons(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart8`,
method: 'GET',
params
})
}
/**
* 行业分布TOP10
*/
export function getindustry(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart12`,
method: 'GET',
params
})
}
/**
* 三产业
*/
export function getThreeIndustry(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart13`,
method: 'GET',
params
})
}
/**
* 毕节区域地图数据
*/
export function getregionMap(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart6`,
method: 'get',
params
})
}
/**
* 毕节补充地图: 1 百里杜鹃 ,2 金海湖
*/
export function getMap() {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bigdp/trainType`,
method: 'get'
})
}
/**
* 外出务工
*/
export function getoutWork() {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bigdp/outWork`,
method: 'get'
})
}
/**
* 返乡回流
*/
export function getbackWork() {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bigdp/backWork`,
method: 'get'
})
}
/**
* 学历分布
*/
export function getEducationECharts(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart5`,
method: 'GET',
params
})
}
/**
* 年龄、性别分布
*/
export function getAgeECharts(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart4`,
method: 'GET',
params
})
}
/**
* 毕节市总劳动力
*/
export function getTotalLabor(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart1`,
method: 'GET',
params
})
}
/**
* 就业创业人数
*/
export function getDoPioneeringWork(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart2`,
method: 'GET',
params
})
}
/**
* 暂未就业人数
*/
export function getNoDoWork(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart3`,
method: 'GET',
params
})
}
/**
* 技能类型
*/
export function getSkillType(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart9`,
method: 'GET',
params
})
}
/**
* 毕节工匠系列
*/
export function getCraftsmanList(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart10`,
method: 'GET',
params
})
}
/**
* 获取评级时间
*/
export function gettrainClass(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart11`,
method: 'GET',
params
})
}
/**
* 地图汇总数据
*/
export function getMapSumData() {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart14`,
method: 'get'
})
}
/**
* 地图汇总数据
*/
export function getMapListData(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart14`,
method: 'get',
params
})
}
/**
* 技能工种Top10
*/
export function getSkillTop5(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/chart15`,
method: 'GET',
params
})
}
/**
* 地图列表数据
*/
export function getListLaborResource(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/ldlzy/listLaborResource`,
method: 'get',
params
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 获取区域
* @param id
* */
export function getArea(id) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion/findRegionTree/${id}`,
method: 'get'
})
}
/**
* 获取区域树
* @param id
* */
export function getAreaTree(id) {
return request({
url: common.CC_API + `/person/api/v2/rasicRegion/findRegionTree/${id}`,
method: 'get'
})
}
/**
* 新增区域
* *@param data
* */
export function addRegion(data) {
return request({
url: common.CC_API + '/person/api/v2/rasicRegion/addRegion',
method: 'post',
data
})
}
/**
* 编辑区域
* *@param data
* */
export function updateRegion(data) {
return request({
url: common.CC_API + '/person/api/v2/rasicRegion/updateRegion',
method: 'put',
data
})
}
/**
* 删除区域
* @param id
* */
export function delRegion(id) {
return request({
url: common.CC_API + '/person/api/v2/rasicRegion/delRegion',
method: 'delete',
params: { id }
})
}
/**
* 区域查询,根据登录用户类型及所属区域返回,默认返回国家,根据父级code查询下级
* @param id
* */
export function findUserRegionByCode(id) {
return request({
url: common.CC_API + `/dashboard/api/v2/rasicRegion/findUserRegionByCode/${id}`,
method: 'get'
})
}
/**
* 区域查询,根据登录用户类型及所属区域返回,默认返回国家,根据父级code查询下级
* @param id
* */
export function findByCode(id) {
return request({
url: common.CC_API + `/person/api/v2/rasicRegion/findByCode/${id}`,
method: 'get'
})
}
// 获取区域数据
export function getTreeGionCode(regionCode) {
return request({
url: common.CC_API + `/user/api/v2/sysRegion/findRegionTreeOrSelf/${regionCode}`,
method: 'GET'
})
}
import request from '@/utils/request'
import common from '@/common/common'
// 统计数量
export function itemCount(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/itemCount',
method: 'post',
data
})
}
// 性别分布
export function ageSexDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/ageSexDistr',
method: 'post',
data
})
}
// 文化程度分布
export function educationDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/educationDistr',
method: 'post',
data
})
}
// 参保险种分布
export function insuranceTypeDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/insuranceTypeDistr',
method: 'post',
data
})
}
// 就业方式
export function employmentTypeDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/employmentTypeDistr',
method: 'post',
data
})
}
// 培训意愿
export function trainIntentDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/trainIntentDistr',
method: 'post',
data
})
}
// 未就业原因
export function unemploymentReasonDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/unemploymentReasonDistr',
method: 'post',
data
})
}
// 就业意向
export function employmentIntentDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/employmentIntentDistr',
method: 'post',
data
})
}
// 求职意向岗位top10
export function applyIntentPositionDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/applyIntentPositionDistr',
method: 'post',
data
})
}
// 劳动力人员分布
export function areaDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/areaDistr',
method: 'post',
data
})
}
// 薪资分布
export function salaryDistr(data) {
return request({
url: common.CC_API + '/dashboard/api/relocatedFamilies/salaryDistr',
method: 'post',
data
})
}
import request from '@/utils/request'
import common from '@/common/common'
// import Qs from 'qs'
/**
* 获取高校毕业生列表
* */
export function getcollegeGraduatesList(data) {
return request({
url: common.CC_API + '/person/api/v2/collection/collegeGraduatesList',
method: 'get',
params: data
})
}
/**
* 获取就业见习列表
* */
export function getemploymentTraineeList(data) {
return request({
url: common.CC_API + '/person/api/v2/collection/employmentTraineeList',
method: 'get',
params: data
})
}
/**
* 获取创业登记列表
* */
export function getentrepreneurshipList(data) {
return request({
url: common.CC_API + '/person/api/v2/collection/entrepreneurshipList',
method: 'get',
params: data
})
}
/**
* 获取培训申请列表
* */
export function gettrainingApplyList(data) {
return request({
url: common.CC_API + '/person/api/v2/collection/trainingApplyList',
method: 'get',
params: data
})
}
/**
* 获取公益岗位列表
* */
export function getPublicJobsList(data) {
return request({
url: common.CC_API + '/person/api/v2/welfarepost/list',
method: 'post',
data
})
}
/**
* 根据id获取高校毕业生详情
* @param id
* */
export function getcollegeGraduatesByid(id) {
return request({
url: common.CC_API + `/person/api/v2/collection/collegeGraduates/${id}`,
method: 'get'
})
}
/**
* 根据id获取就业见习详情
* @param id
* */
export function getemploymentTraineeByid(id) {
return request({
url: common.CC_API + `/person/api/v2/collection/employmentTrainee/${id}`,
method: 'get'
})
}
/**
* 根据id获取创业登记详情
* @param id
* */
export function getentrepreneurshipByid(id) {
return request({
url: common.CC_API + `/person/api/v2/collection/entrepreneurship/${id}`,
method: 'get'
})
}
/**
* 根据id获取培训申请详情
* @param id
* */
export function gettrainingApplyByid(id) {
return request({
url: common.CC_API + `/person/api/v2/collection/trainingApply/${id}`,
method: 'get'
})
}
/**
* 根据id获取公益岗位详情
* @param id
* */
export function getPublicJobByid(id) {
return request({
url: common.CC_API + `/person/api/v2/welfarepost/detail/${id}`,
method: 'get'
})
}
/**
* 根据id删除毕业生档案
* @param id
* */
export function deletecollegeGraduates(id) {
return request({
url: common.CC_API + `/person/api/v2/collection/collegeGraduates/${id}`,
method: 'DELETE'
})
}
/**
* 根据id删除一条公益岗位采集
* @param id
* */
export function delPublicJob(id) {
return request({
url: common.CC_API + `/person/api/v2/welfarepost/delete/${id}`,
method: 'get'
})
}
/**
* 就业见习登记信息导出
* @param data
* */
export function exportEmploymentTrainee(data) {
return request({
url: common.CC_API + `/person/api/v2/collection/exportEmploymentTrainee`,
method: 'get',
params: data,
responseType: 'blob'
})
}
/**
* 创业登记信息导出
* @param data
* */
export function exportEntrepreneurship(data) {
return request({
url: common.CC_API + `/person/api/v2/collection/exportEntrepreneurship/`,
method: 'get',
params: data,
responseType: 'blob'
})
}
/**
* 培训申请信息导出
* @param data
* */
export function exportTrainingApply(data) {
return request({
url: common.CC_API + `/person/api/v2/collection/exportTrainingApply/`,
method: 'get',
params: data,
responseType: 'blob'
})
}
/**
* 获取劳动力采集信息列表
* @param {Object} data
*/
export function getLoborCollectList(data) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/getLaborCollectionList',
method: 'get',
params: data
})
}
/**
* 获取劳动力信息历史列表-PC
* @param {Object} data
*/
export function getHistoryCollectList(data) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/getLaborCollectionAllList',
method: 'get',
params: data
})
}
/**
* 调查员信息列表-PC
* @param {Object} data
*/
export function getInvestigatorList(data) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/getInvestigatorList',
method: 'get',
params: data
})
}
/**
* 删除劳动力采集信息
* @param {String} id
*/
export function deleteLoborCollectList(id) {
return request({
url: common.CC_API + ``,
method: 'DELETE'
})
}
/**
* 获取劳动力采集信息详情
* @param {String} id 采集信息id
*/
export function getLoborCollectByid(id, status) {
return request({
url: common.CC_API + `/bigdata/api/pc/collection/getCollectionDetail?id=${id}&status=${status}`,
method: 'get'
})
}
/**
* 模板下载
* 劳动力采集
* */
export function excelCollectTemplate() {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/excelTemplate',
method: 'get',
responseType: 'blob'
})
}
/**
* 获取劳动力采集信息列表-演示版本
* @param {Object} params
*/
export function getLoborDataList(params) {
return request({
url: common.CC_API + '/collection/api/collection/listCollectionDemo',
method: 'get',
params
})
}
/**
* 获取劳动力采集信息详情-演示版本
* @param {Object} params 采集信息id
*/
export function getCollectionDetailDemo(params) {
return request({
url: common.CC_API + `/collection/api/collection/getCollectionDetailDemo`,
method: 'get',
params
})
}
// 导出报表
export function exportLaborList(params) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/exportLaborList',
method: 'get',
params,
responseType: 'blob'
})
}
// 导出统计报表
export function exportLaborCount(params) {
return request({
url: common.CC_API + '/bigdata/api/pc/collection/exportLaborCount',
method: 'get',
params,
responseType: 'blob'
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 获取资源列表
* @param id
*/
export function getRes(page, size, code, name) {
return request({
url: common.CC_API + `/user/api/v2/resources?page=${page}&size=${size}&code=${code}&name=${name}`,
method: 'get'
})
}
/**
* 获取资源列表
* @param id
*/
export function getResAll() {
return request({
url: common.CC_API + `/user/api/v2/resources/allResourceTrees`,
method: 'get'
})
}
/**
* 根据用户id获取资源信息
* @param id
*/
export function findResById(id) {
return request({
url: common.CC_API + `/user/api/v2/resources/${id}`,
method: 'get'
})
}
/**
* 接口描述 根据用户id获取资源树
* @param id yong
*/
export function findResTreeById(id) {
return request({
url: common.CC_API + `/user/api/v2/resources/userResourceTree/${id}`,
method: 'get'
})
}
/**
* 接口描述 根据用户id修改资源
* @param id yong
*/
export function modifyRes(id, data) {
return request({
url: common.CC_API + `/user/api/v2/resources/${id}`,
method: 'PUT',
data
})
}
/**
* 接口描述 保存资源,新增资源
* @param id yong
*/
export function addRes(data) {
return request({
url: common.CC_API + `/user/api/v2/resources`,
method: 'POST',
data
})
}
/**
* 接口描述 根据用户ids删除资源
* @param id yong
*/
export function deleteRes(id) {
return request({
url: common.CC_API + `/user/api/v2/resources/${id}`,
method: 'DELETE'
})
}
import request from '@/utils/request'
import common from '@/common/common'
const path = `${common.CC_API}/dashboard/api/returnBigscreen/`
const api = {
numStatistics: `${path}numStatistics`, // 数量统计
returnHomeUnemploymentNum: `${path}returnHomeUnemploymentNum`, // 返乡未就业人数
returnUnEmployment: `${path}returnUnEmployment`, // 返乡未就业人员所在地分布
ageAndSex: `${path}ageAndSex`, // 返乡未就业人员年龄及性别分布
unemploymentReason: `${path}unemploymentReason`, // 返乡未就业原因分布
trainIntention: `${path}trainIntention`, // 培训意愿
returnReason: `${path}returnReason`, // 返乡原因分布
returnTrend: `${path}returnTrend`, // 返乡返岗人员变化趋势
returnHomeDetailStatistics: `${path}returnHomeDetailStatistics`, // 返乡返岗人员统计
returnHomeArea: `${path}returnHomeArea`, // 返乡地区地图分布
returnHgeAndSex: `${path}returnHgeAndSex`, // 返乡详情年龄性别分布
returnHomeDetailEducation: `${path}returnHomeDetailEducation` // 返乡详情教育统计
}
const handlePost = (url) => {
return data => request({
url,
method: 'post',
data
})
}
const numStatistics = handlePost(api.numStatistics)
const returnHomeUnemploymentNum = handlePost(api.returnHomeUnemploymentNum)
const returnUnEmployment = handlePost(api.returnUnEmployment)
const ageAndSex = handlePost(api.ageAndSex)
const unemploymentReason = handlePost(api.unemploymentReason)
const trainIntention = handlePost(api.trainIntention)
const returnReason = handlePost(api.returnReason)
const returnTrend = handlePost(api.returnTrend)
const returnHomeDetailStatistics = handlePost(api.returnHomeDetailStatistics)
const returnHomeArea = handlePost(api.returnHomeArea)
const returnHgeAndSex = handlePost(api.returnHgeAndSex)
const returnHomeDetailEducation = handlePost(api.returnHomeDetailEducation)
export {
numStatistics,
returnHomeUnemploymentNum,
returnUnEmployment,
ageAndSex,
unemploymentReason,
trainIntention,
returnReason,
returnTrend,
returnHomeDetailStatistics,
returnHomeArea,
returnHgeAndSex,
returnHomeDetailEducation
}
import request from '@/utils/request'
import common from '@/common/common'
export function getRoutes() {
return request({
url: '/user',
method: 'get'
})
}
/**
* 获取用户列表
* @param page
* @param size
*/
export function getRoles(page, size) {
return request({
url: common.CC_API + `/user/api/v2/roles?page=${page}&size=${size}`,
method: 'get'
})
}
/**
* 保存用户/添加用户
*
* */
export function addRole(data) {
return request({
url: common.CC_API + '/user/api/v2/roles',
method: 'post',
data
})
}
/**
* 修改用户
* @param id
* @param data
*/
export function updateRole(id, data) {
return request({
url: common.CC_API + `/user/api/v2/roles/${id}`,
method: 'put',
data
})
}
/**
* 删除用户id获取用户
* @param id 用户id
*/
export function deleteRole(id) {
return request({
url: common.CC_API + `/user/api/v2/roles/${id}`,
method: 'delete'
})
}
/**
* 根据id获取角色,包含资源树
* @param id 用户id
*/
export function getRoleResTree(id) {
return request({
url: common.CC_API + `/user/api/v2/roles/resourceTree/${id}`,
method: 'GET'
})
}
import request from '@/utils/request'
import common from '@/common/common'
// 总数统计
export function gettimelyCalulate() {
return request({
url: common.CC_API + '/dashboard/api/bigdata/bijie/chart5',
method: 'GET'
})
}
// 热门技能培训课程
export function gettrainLesson() {
return request({
url: common.CC_API + '/dashboard/api/bigdata/bijie/chart2',
method: 'GET'
})
}
// 参与培训人群分布
export function gettrainPeople() {
return request({
url: common.CC_API + '/dashboard/api/bigdata/bijie/chart3',
method: 'GET'
})
}
// 热门培训工种人数
export function gettrainSubsidy(params) {
return request({
url: common.CC_API + '/dashboard/api/bigdata/bijie/chart4',
method: 'GET',
params
})
}
// 累计技能证书+培训人次
export function getStatisticsOne(areaCode) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart1?areaCode=${areaCode}`,
method: 'GET'
})
}
// 培训意愿+培训次数+技能证书+培训再就业
export function getStatisticsTwo(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart2`,
method: 'GET',
params
})
}
// 热门培训课程top10
export function getPopularCourses(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart4`,
method: 'GET',
params
})
}
// 年龄段分布
export function getAgeDistribution(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart7`,
method: 'GET',
params
})
}
// 已培训人群分布
export function getPersonDistribution(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart5`,
method: 'GET',
params
})
}
// 培训类型分布
export function getTrainDistribution(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart6`,
method: 'GET',
params
})
}
// 参与培训人群区域分布
export function getAreaDistribution(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart3`,
method: 'GET',
params
})
}
// 培训意向工种top10
export function getWishTrainTop10(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bijie/chart9`,
method: 'GET',
params
})
}
import request from '@/utils/request'
import API from '@/common/business/baseUrl'
/**
* 消息详情
* @param taskId
*/
export function getTaskDetail(taskId) {
return request({
url: API.CC_API + `/dashboard/api/v2/createTaskRecord/task/${taskId}`,
method: 'get'
})
}
/**
* 回复列表
* @param taskId
*/
export function getReplyList(taskId) {
return request({
url: API.CC_API + `/dashboard/api/v2/taskMessageReply/replyList/${taskId}`,
method: 'get'
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 未就业原因
*/
export function getEmploymentReason(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart8`,
method: 'get',
params
})
}
/**
* 就业意向分布
*/
export function getEmploymentTrain(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart6`,
method: 'get',
params
})
}
/**
* 培训意向分布
*/
export function getWillingnessTrain(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart5`,
method: 'get',
params
})
}
/**
* 求职意向岗位
*/
export function getJobIntention(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart9`,
method: 'get',
params
})
}
/**
* 求职意向省份
*/
export function getWorkExperience(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart3`,
method: 'get',
params
})
}
/**
* 未就业人员人数
*/
export function getPersonnelAnalysis(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart10`,
method: 'get',
params
})
}
/**
* 年龄段分布
*/
export function getTimeStatistics(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart7`,
method: 'get',
params
})
}
/**
* 文化程度分布
*/
export function employmentDirection(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart1`,
method: 'get',
params
})
}
/**
* 人员性别
*/
export function getxinbie(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart2`,
method: 'get',
params
})
}
/**
* 未就业人员分布
*/
export function getPersonnelDistribution(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/bjwjy/chart4`,
method: 'get',
params
})
}
import request from '@/utils/request'
import common from '@/common/common'
const qs = require('qs')
// 登陆
export function login(data) {
return request({
url: common.CC_API + '/user/api/v2/login',
method: 'post',
// headers: { 'content-type': 'application/x-www-form-urlencoded' },
data
})
}
// 跳转登录
export function skipLogin(data) {
return request({
url: common.CC_API + '/user/api/v2/sso/login',
method: 'post',
headers: { 'content-type': 'application/x-www-form-urlencoded' },
data: qs.stringify(data)
})
}
// 用token换取ticket
export function getTicket() {
return request({
url: common.CC_API + '/user/api/v2/ticket/current',
method: 'get'
})
}
// 跳转登录 -- 权限配置
export function skipAuth(data) {
return request({
url: common.CC_API + '/user/api/v2/sso/login',
method: 'post',
headers: { 'content-type': 'application/x-www-form-urlencoded' },
data: qs.stringify(data)
})
}
export function getInfo() {
return request({
url: common.CC_API + '/user/api/v2/users/info/authority',
method: 'get'
})
}
export function logout(from) {
return request({
url: common.CC_API + `/user/api/v2/logout?from=${from}`,
method: 'POST'
})
}
export function refresh() {
return request({
url: common.CC_API + '/api-auth/authToken/refresh',
method: 'post'
})
}
/**
* 获取用户列表
* @param page
* @param size
*/
export function getUserList(page, size, userType, name) {
return request({
url: common.CC_API + `/user/api/v2/users?page=${page}&size=${size}&userType=${userType}&name=${name}`,
method: 'get'
})
}
/**
* 保存用户/添加用户
*
* */
export function addUser(data) {
return request({
url: common.CC_API + '/user/api/v2/users',
method: 'post',
data
})
}
/**
* 修改用户
* @param id
* @param data
*/
export function uploadUser(id, data) {
return request({
url: common.CC_API + `/user/api/v2/users/${id}`,
method: 'put',
data
})
}
/**
* 删除用户id获取用户
* @param id 用户id
*/
export function deleteUser(id) {
return request({
url: common.CC_API + `/user/api/v2/users/${id}`,
method: 'delete'
})
}
/**
* 删除用户id获取用户
* @param id 用户id
*/
export function getUserResById(id) {
return request({
url: common.CC_API + `/user/api/v2/users/${id}`,
method: 'GET'
})
}
/**
* 重置密码
* @param id 用户id
*/
export function handleReset(id) {
return request({
url: common.CC_API + `/user/api/v2/users/password/reset/${id}`,
method: 'put'
})
}
/**
* 修改密码
* @param id 用户id
*/
export function handleChange(id, data) {
return request({
url: common.CC_API + `/user/api/v2/users/password/${id}`,
method: 'put',
data
})
}
/**
* 获取字典
*/
export function getDictionaryCollect(type) {
return request({
url: common.CC_API + `/dashboard/api/v2/dictionary?type=${type}`,
method: 'GET'
})
}
/**
* 获取区域字典
*/
export function getAreaDictionary(id) {
return request({
url: common.CC_API + `/dashboard/api/v2/rasicRegion/findUserRegionBigData/${id}`,
method: 'GET'
})
}
/**
* 根据id查询所有父级区域
*/
export function getParentRegionById(id) {
return request({
url: common.CC_API + `/dashboard/api/v2/rasicRegion/findParentRegionById?id=${id}`,
method: 'GET'
})
}
/**
* 查询当前用户区域信息
*/
export function getMyArea() {
return request({
url: common.CC_API + `/dashboard/api/v2/rasicRegion/findRegionByCode`,
method: 'GET'
})
}
/**
* 获取地图JSON
*/
export function getMapJSON(areaCode) {
return request({
url: common.CC_API + `/dashboard/api/pc/collection/getGeoJson?areaCode=${areaCode}`,
method: 'GET'
})
}
import request from '@/utils/request'
import common from '@/common/common'
// 退役军人-人数总数
export function getVeteransCount(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/demobilizedVeteransAll`,
method: 'post',
data
})
}
// 退役军人-未就业原因
export function getUnemploymentReason(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/unemploymentReason`,
method: 'post',
data
})
}
// 退役军人-文化程度分布
export function getEducation(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/educationDistr`,
method: 'post',
data
})
}
// 退役军人-技能培训类型
export function getSkillTrainType(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/skillTrainTypeDistr`,
method: 'post',
data
})
}
// 退役军人-就业方式分布
export function getEmploymentType(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/employmentTypeDistr`,
method: 'post',
data
})
}
// 退役军人-就业状态分布
export function getEmploymentStatus(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/employmentStatusDistr`,
method: 'post',
data
})
}
// 退役军人-就业行业分析
export function getEmploymentIndustry(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/employmentIndustryDistr`,
method: 'post',
data
})
}
// 地图数据
export function getPersonnelDistribution(data) {
return request({
url: common.CC_API + `/dashboard/api/demobilizedVeterans/demobilizedVeteransAreaDistr`,
method: 'post',
data
})
}
import request from '@/utils/request'
import common from '@/common/common'
/**
* 文化程度分布
*/
export function employmentDirection(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart1`,
method: 'get',
params
})
}
/**
* 人员性别
*/
export function getxinbie(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart2`,
method: 'get',
params
})
}
/**
* 外出务工省份top10(单位:人)
*/
export function humanResourceSurvey(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart7`,
method: 'get',
params
})
}
/**
* 外出人员就业创业省分top10(单位:人)
*/
export function getPaySpread(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart8`,
method: 'get',
params
})
}
/**
* 毕节外出务工人员分析
*/
export function outsideManAnalysis(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart3`,
method: 'get',
params
})
}
/**
* 近6个月外出务工人数
*/
export function sixMonthoutsideMan(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart4`,
method: 'get',
params
})
}
/**
* 外出务工人员就业行业
*/
export function outsideManSalary(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart9`,
method: 'get',
params
})
}
/**
* 就业工种
*/
export function outsideManJobs(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart10`,
method: 'get',
params
})
}
/**
* 年龄分布
*/
export function getAgeFenbu(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart6`,
method: 'get',
params
})
}
/**
* 就业方式
*/
export function getOperationMode(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart5`,
method: 'get',
params
})
}
/**
* 获取明细列表数据
*/
export function getTabelListData(data) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/chart4/detail`,
method: 'post',
data
})
}
/**
* 新增外出务工人员人数
*/
export function addMigrantWorkerTwoyear(params) {
return request({
url: common.CC_API + `/dashboard/api/bigdata/worker/addMigrantWorkerTwoyear`,
method: 'get',
params
})
}
const CC_API = '/api'
const CC_MOCK = '/mocker'
export default {
CC_API: CC_API,
CC_MOCK: CC_MOCK
}
/**
* 编码 = 服务编号 + 渠道编号 + 模块编号 + 序列号
* 示例:11010001 = 11 + 01 + 00 + 01
*
* 服务编号
* edas-auth 11
* edas-gateway 12
* edas-user 13
* edas-base 14
* edas-search 15
* edas-kafka 16
* edas-info 17
* edas-enterprise 18
* edas-personal 19
*
* 渠道编码
* PC端 01
* 小程序端 02
* APP 03
* 自助终端 04
* pad设备 05
*/
export const responseCode = {
// 成功
'0': '成功',
// 失败
'-1': '失败',
// 认证服务
'11010001': '未认证',
'11010002': '请求出错',
'11010003': '没有访问权限',
'11010004': '未认证(签名错误)',
'11010005': '权限不足,无法访问该资源',
'11010006': '无效请求',
'11010007': '无效client_id',
'11010008': '无效授权',
'11010009': '无效scope',
'11010010': '无效token',
'11010011': '授权不足',
'11010012': '拒绝访问',
'11010013': '权限服务错误',
'11010014': '未授权客户端',
// 网关服务
'12010001': '服务未找到',
'12010002': '网关异常',
'12010003': '网关超时',
// 用户服务
'13010001': '系统繁忙,请稍候再试',
'13010002': '请求参数校验不通过',
'13010003': '用户不存在',
'13010004': '旧密码错误',
'13010005': '角色已存在',
'13010006': '角色已管理用户',
'13010007': '角色不存在',
'13010008': '用户已存在',
'13010009': '用户被锁定',
'13010010': '手机号应为11位数',
'13010011': '验证码错误',
'13010012': '密码不一致',
'13010013': '手机验证码1分钟内不能重发',
'13010014': '帐号或密码错误',
'13010015': '验证码已过期',
'13010016': '发送验证码次数已满',
'13010017': '密码错误',
'13010018': '手机号不是注册的手机号',
'13010019': '用户名必须是英文字母',
'13010020': '该微信号已绑定企业',
'13010021': '该微信号未绑定',
'13010022': '该微信号已绑定其他手机号',
'13010023': '该微信号已绑定其他手机号',
'13010024': '企业全称重复不能进行注册',
// 政策服务
'17010001': '政策不存在',
'17010002': '招聘会不存在',
'17010003': '未登记',
'17010004': '已登记',
'17010005': '已报名',
'17010006': '展位已满',
'17010007': '分配失败,请重试',
'17010008': '展位已分配',
'17010009': 'MAC已存在',
'17010010': 'MAC不存在',
'17010011': '展位名称已存在',
'17010012': 'pad设备号已存在',
'17010013': 'pad设备号已绑定',
'17010014': '招聘会报名已结束',
'17010015': '无此公告内容',
// 企业服务
'18010001': '已收藏',
'18010002': '已投递',
'18010003': '还没注册任何企业',
'18010004': '已邀约',
'18010005': '不能取消',
'18010006': 'userId不是个人用户id',
// 个人服务
'19010001': '简历不存在',
'19010002': '已报到'
}
const CC_ROUTER = 'routers'
const CC_API = '/data'
const CC_RESULT = '/result'
const CC_MOCK = '/mocker'
export default {
CC_ROUTER: CC_ROUTER,
CC_API: CC_API,
CC_RESULT: CC_RESULT,
CC_MOCK: CC_MOCK
}
export const NAVBARTITLE = '__navbarTitle__'
module.exports = {
title: '消息详情', // 主页名字设置
/**
* vue.config配置
*/
buildFile: 'dist', // 打包后生产的文件目录名
StaticFile: 'static', // 打包后用于放置静态资源的文件名
isSourceMap: false, // 是否在打包时生成 sourceMap 文件
port: 9000, // 端口设置
// proxy代理,可设置多个
proxy: {
'/api': {
/* 目标代理服务器地址,这个就是你要连接的接口地址,可以使用域名,代理解决跨域问题 */
target: 'http://192.168.67.104:34001', // 请求地址
// target: 'https://bijieysp.e-tecsun.com/labor', // 正式请求地址
/* 允许跨域 */
changeOrigin: true,
/* 如果是http接口,需要配置该参数 */
secure: false,
/* 代理 websockets 支持*/
ws: true,
/* path 重写url*/
pathRewrite: {
'^/api': ''
}
}
},
isUseGzip: false, // 是否在生产环境使用gzip压缩,启动后需要后台配置nginx才能在生产环境生效
gzipFile: ['js', 'css'], // 需要gzip压缩的文件
isDelOriFile: true, // 是否在生产环境删除压缩后的原文件
isCdn: false, // 是否使用cdn加载文件
isSkeleton: true, // 是否使用骨架屏
CssCdn: [
'https://cdn.jsdelivr.net/npm/vant@2.10/lib/index.css',
'https://cdn.bootcdn.net/ajax/libs/animate.css/4.1.1/animate.compat.min.css'
], // css CND路径
jsCdn: [
'https://cdn.bootcdn.net/ajax/libs/vue/2.6.11/vue.js', // vue.js CND路径
'https://cdn.jsdelivr.net/npm/vant@2.10/lib/vant.min.js', // element-ui.js CND路径
'https://cdn.jsdelivr.net/npm/vue-router@3.0.1/dist/vue-router.min.js', // vue-router.js CND路径
'https://cdn.jsdelivr.net/npm/vuex@3.0.1/dist/vuex.min.js', // vuex.js CND路径
'https://cdn.jsdelivr.net/npm/axios@0.18.0/dist/axios.min.js', // axios.js CND路径
// 'http://api.map.baidu.com/api?v=2.0&ak='
],
externalsBuild: {
// 打包时不包含哪些文件(不包含的文件想要cdn引入)
'vue': 'Vue',
'vue-router': 'VueRouter',
'vuex': 'Vuex',
'vant': 'vant',
'axios': 'axios'
},
/**
* @type {string | array} 'production' | ['production', 'development']
* @description Need show err logs component.
* The default is only used in the production env
* If you want to also use it in dev, you can pass ['production', 'development']
*/
errorLog: 'production'
}
module.exports = {
/**
* axios 自定义配置
* 暂定以下几个,需要更多的可以自行根据 axios 文档添加配置项
* baseURL 将自动加在 `url` 前面,除非 `url` 是一个绝对 URL
* timeout 如果请求话费了超过 `timeout` 的时间,请求将被中断
* headers 即将被发送的自定义请求头
*/
configObj: {
baseURL: '',
timeout: 60 * 1000,
headers: {
'Content-Type': 'application/json;charset=UTF-8'
}
}
}
/* .van-cell {
padding: 0 16px;
height: 44px;
line-height: 44px;
} */
.van-field__label {
width: 12rem;
margin-left: 1.5rem;
}
.van-picker__title {
color: #3e7dff;
font-size: 1.6rem;
}
.van-arrow-down {
position: relative;
}
.arrow-down {
position: absolute;
right: 3rem;
top: 1.4rem;
}
.arrow-down.van-icon {
font-size: 1.4rem;
color: #B7B7B7 ;
}
.van-field__body {
width: 15rem;
}
.van-picker-column__item--selected {
color: #3e7dff;
}
.van-dialog {
width: 24rem;
min-height: 15rem;
}
<template>
<div class="empty-content">
<img v-if="image" :src="image" alt="" class="image">
<div>
{{ description }}
</div>
</div>
</template>
<script>
export default {
props: {
image: {
type: String,
// default: require('../../assets/images/old/Empty.png')
default: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAALQAAAC0CAMAAAAKE/YAAAADAFBMVEVMaXFmrv/P4f/A5//U5f/o8f/R4//a6f/X5//e6//////S6P/////j7//////////////K3v////////////////////////////9Jof/////e7P9Jnv////////86l/9Upv////8vk//h7P/L4P/I3v////////9Jmf/////U5v9trf/////////r8v9AnP93tP9osP9fp//0+f////////////////9NlP3L4f////////////9qq/9go/9mp//+///////////S5P////////8MgP86m/9cnf1srP5spf6fxf+oyv/j7v/B2/8Ogv9krv9grP9qqP58sP6RvP+Rvf8/lf+rzf9ipv9Rnf+uzv7///////8Ae/8pkP+DtP5aqf88mv+uz/9hn/1kpv9fnv7p8v+exP/y+P+00v/Z6P/N4f8Be/82l/8Jfv9bov4Zh/9Lkf1Kmf6u0/9Hmf621P+y0f+81v+91/+rzP/W5v8ZiP8Ae/9Kkfzu9f9Clv/G2P9frP9hrf9Oo/9Zqf9aqf82lv9Fnv9grP8wk/8Aev9IoP84mP8qkP9Kof9Nov9mr/9Gn/////9BnP89mv9QpP9Dnf9cqv8ukv8Rg/9Enf9Spf9RpP8rkf9eq/9Vpv88mf8dif9jrv81lf8LgP9bqv87mf9Tpf9krv8tkv86mP8ylP8kjf9Tpv9Wp/9qr/+60/+Zxf+10f+x0P4Xhv9cnP2Wwv+py/4/m/8EfP8Fff8oj/8ijP+kyP5jrf8eiv9gnv2uzv5In/8Yhv+41P6hxv610v6Owf9jrP8xlP8xk/+Xxv9oo/1YqP95rv2exf5lof1Mov+Uxf++2P9Ymv1+sf282P+XwP6gzP+Bs/6KuP6SxP+Ou/671v52rP1rpf1joP3M4f+cyf+Htv5up/2Uvv5zqv2bwv7C2v8Yh/9xqf2Etf2ZyP+RvP3R5P7V5v4Lf//H3f5Ul/3g7v+o0P+v1P+HvP/y+P8Ngf+11/9+uP95tf9ytP9eqf9OnP9So/9qyF2zAAAAgHRSTlMAUaMDo6Ojo6Oj4QdEo4OuS6PIlKIdt+tT7vOjDz+/7+547qOko84kUJytHxcRC+4sjK0OXdsu1v6sqn8qF0M3/Ipt3dIzyBnI0vNB8Kusa/TK3+nV7ypdXdneZTj4tqnrxn2WfvayxMLRxPB+3KVwlO+6H4v55ce3p+rt7WGWsEO686cAAAudSURBVHja7ZoJVFTXGccfndi0DEXCzDBkCqS0CQQFY9iMggiIRqNJXBI1aps2a7M0SZM0adL2HBURCLK5YUgEIyjigtpRxwRHRRkSF5aETSwDAoLIZjAu0Szt/973eG/mDITRnnnv5OT9zuf7vvu98Zyf99yZuXd8jIyMjIyMjIyMjIyMjIyMjIyMjIyMzE8XpVPw9FlbQcbWDISQBfgeX2fMmh7spJDM2WnO1k3UBWnTpkObDiH4jJbQ33qI1gKzx0qjrAhexrNp2SYEzYCtDy0j8rZ9gDQrSiLn4UlaloQY9NYsKeb6mSQAISpmW1tK02zDbPHX9aSkpUlLEUkEvs5JykFY96xrgaULRJcOXkrIWZpDQYGwzoCrbTNlttjOo3NuEkFaYLTI0q/m8GTlZBGQhDEu1gh9XA8UHyyMR+dNsVdHFocgjItdpL//HmFDVtbrIkvPzsranLWZkrA5AbEZQ9LjM+1nJbCiKBA0r/36E5bUrD+JLP1HVhQXG7j+UBTn53+d/zUif+MTYksvX16+vLw8odzWCk0g3FuesBxB+4i17/NckEYaQbMNfN+mt/LYhQt7L+zde2zvsWNiL4/flJcXlRchIDMcVvInPhL4g9jSRRzf7l4yLNVX8Y9DFIHCgzt2HNxxkCKBdG5RLkK/xB4S6GupdLGA6NK5gIiU2OPcuRzCeDHYnryeR/Q1vZMjw7B7WPTf5O7MRezcWbBzxfa8vO152xF5eX+RRBoSBQg2A6Qf7IE1K1m2rdy2TXTpDygFHxQgbGqrsXV/9QGB+8SX/vCDDxHUhKutModVHyQmZmcnZidSMsWWZoXWfriWggLwPYRNzY3TLFGKLB0fvzZ+LYJmwNdDZg7L0UTJpAWE3tDszC3iyRX5FHBnfHx6fDoFBQUFwioDqx6w3P9tHiuF9LDYyi+1PKNPEln6c46Cq3uG5dPvPuc5lGFBlMjSaRyVS+xgd3oay+dpVtJOEknbt2EqSBtggZMFo0WXTklLATfsca7EaxHk7zzISMedKZSjKUcTdg3LZymAe73E0pkpmZlHM49SYIOwzMJ961pS6UwbEjMTEXweAomlYcZhI4s0RF9a6cRbRFLpbEA3mQiaAa2B5Zh/DYeU0vdlZ6/LXkdAEmrbsVW/IGfXU0/Nn/GGQiJpVmT1utUUFAirDKx6iRmf6s2lpWVlen3JzHfmK6WQXj1AwWfDkrB6deKN0jqzmSjDucRgMMx8aox00t8ssYP93+qrzZxzCXU2Gk0z5yvElj7AYdfeo7O6uo4sDb2Fs6ny/PMTJZLeY5ez2WztbCLO5+sfGyuu9Jo1B9YcQCRe3T8MlXXsNJeVVbf0Xbx4sa9lSZmxkjjXtz8+Q1zpIdm4ZiMFBSGxpNpMnfsh3NI/efLkd/v6WsyVxLm993Exd6d3UTkEm7ds3ILYyCH0UfWwzp0wrrty5fpzI0aMePjFd1ta9PXtvb29jY8pRZTesmXblm2ILcNwgzpjmvvqrl+8tmrVKt2fR4AXX2opbe9tbDxz5kkRpakwQsgCFr20UjiTpdFy/atVLNGYbMz2S/1m4tzWNlZMafyGyIMBgs8CV+ly7uzrv45Z5sBUEyb364lz95PiSa+0i/RS4mzua7kCZ2tpzHWnqa27u6FhkojSK1au4MEAQTMQ6qv0S7Cl78pXgrPu4V+xPNxpbutuqK19UjTpFXZhIM7mvs46Xjna+Tn4skyuNsK5dq5SbOl0078Hwfhf9ib9EuxvucxN9Fd1l0f9TmBUtbm2tqKiKUo86bwVeQjjkkEx5BG+Jc76ls7L0azz6dOnR/3agsnmxgpI3y+WdB6HYXBpPb15Fc4lpS3XO9mVcZlI/1Lg9hfNpoqmpo7pIkn/djtH+e7BnHd/R2/uJ9uj6v7LffxEQ9qCUaUGOHfNEVka5AlgubDLhrtVCWdIn2aXdF8rGHW7JaV6OHc9JJb08eMnjp+gbD/BGqJAi/T5bADGzv7Wi1S6zlb6b/qurnPnmr1Ek04+nmwFGrR3IvkEgrbodr+zs/UKcb52urW1p3X8LyyBNJxFk16/Pnl9MsIqc/DjPUYcUcydrT1111Zdu9JDsJbWG+B8SrTlsZ7HWt6q30hOVWXVp0/2nGztwQUx/jYLRulNzc2nTs0RX7pwfSEFBYLNHDfIqaqk+vJJHmvpt0vq4Vw1TSzpwsINhRsQhT/ELnKqMpn1ltI/F7jtrZLaU1VVZ58WS3rDsKRuSM2mJ8FSc88XPJbS40sMzXA+4iSeNKQQfOaw6m9or8dJ0Fhq+A/P+J8JvGBohPKRZ73Ekk61i11wbm/Xl53kpR8RnMcbjM1nzx7ZF+xg17H3c6Sn2UUCOb02ni8rEaTv5nnL2I153rfvXgdLO2XcJG295PRq0hs+5XjkjgEWGnvPQnnfNMbR0sJj0QBpuGe8d0EZJ0FjiXFA+h5wxz133L3QWF9FnGuiHC7NP5UJhAcdUSBItul9A2ecBLF12s9Lg7/PNPYS55qaYMbh0gPPWxUhbGthzOeihrY2HF4b2g0G0xesNJQXGk1tUD7SXPOE4z867uWfjEASatuxQG5Ddzc5CTbUY/dUueeFt19YONNkamzGW/BIQ/epeYxS6WjplJsnvRbO5FRV0VZvBCZTewOUsZxrGyo6nlG88/wYB0sP9T8UQ+d1B/KaqHNHB7ah5zo6zlXhw5ku57MVHc1V042Vz3s5VnqwH0dtxgjLfnFqc0UT64w9XRWcoQznS08seKhqX80Z/E490aHSK26B4wd3fN/V0WXlXAPe9GImPXup6Xw9fjsd7UDpecl2IBxiOHYcPlz8fRdRhjO3NC4FE8/59XBubzzTPdeB1l6plOLUYgSfgWXftj54GNoba3jnfdNepZJvGE2sc0Pt3LGOs55KnyPGxQY0CUj8GMFlWBPvvG13Pf30Mwui+CU8gzq3NdRWdDw0yWHSjx7+6PBHiMMk2yD0hVrI5M9rjDUzHmedm7qaHWft9Q88Gw/o8/EINl84dgHBj2nGQ/QIfgzQOzaPsbHmnE+dfTbKYVP9/v/Da4PsdueyztiJ1Dhsk/pK/pdf5n+ZPyS4ibCpKVMVzGDWdJ7hfOkBR1krXvmE5+NPPiYg2VVPHfybb/Scc5hn4vzXeY57M/7zvVvh9y8rmMGZOJ1znsQ4Dq9Hp358s8ZTX36QGZKJ04jzA1HMjwqvaXDGgv6RWb/+wL+YHx3KexkZGRkZGRkZGRmZnyYKXyVbaDRsFhij8PdmghhcKFPCaZIejXqkTq1W+8eq3X1CGSZw5AABuBkT6hkQ6cPEoia4+jKhzpRx0kqHuGlDPV1cgpxdlHRu3dzcQrVuwAWjQJVnQEQ4E6DGWEmlY1UhIFDHSIvKz1fn6xukdY2IiGDXh3/YwOpQqZ3DVKpAP99FYa4hGnWcn2tsXABBK7F0kEaj1WiCwvw93f3Zxe3tzp/9PGLCJkT6r1rMaIMYdqZjGGaCJyM1vjGqaA8/T1dmig8WizsYp3OnjAl0j/UMWKxydXbFemClfSd4e/tEeHsHSSwdG6qbEugRSaWVLmBkQIQ7yYoxoYwnZtVnsZ9LHJX2mRAT5uOjjfPxWcxIS4jGVaPx1mgWx3KNceFuHrRQenrq8C4NYnxUMVjqAVqfSHUoXR6S46r1oziPZMf+zgwnHYK3ntoDkxyrwyd1eESAL2Z90SJ31SIXyaVj2BzKSis8YlhpBWKcP53XKdEh3Jp2DopWqVQjJ0gurXOmaFnpiLgQVtonkgl3DnAlpUecipWe4szoULhILx2joNCZDlRr/RnGzU/BKMmnnLez1t0br1DGkXUc4xsTw+jCw8MXSS+tDaOQmQ7SqgMZJN04dyzxyDgPF8x6hJp84bgo1TpPv0gm2sPDw11y6SmL2ezvQi5srYwM12BJR9JBoJJcxjDe4QyaoRhoXBgZGRkZGRkZGRkZGRkZGRkZGRkZGZmfNv8DNanBPn+6VIgAAAAASUVORK5CYII='
},
description: {
type: String,
default: ''
}
}
}
</script>
<style lang="less" scoped>
.empty-content{
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
color:darkgrey;
.image{
width: 1.8rem;
height: 1.8rem;
}
}
</style>
<template>
<div :class="{'hidden':hidden}" class="pagination-container">
<el-pagination
:background="background"
:current-page.sync="currentPage"
:page-size.sync="pageSize"
:layout="layout"
:page-sizes="pageSizes"
:total="total"
v-bind="$attrs"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
</div>
</template>
<script>
import { scrollTo } from '@/utils/scroll-to'
export default {
name: 'Pagination',
props: {
total: {
required: true,
type: Number
},
page: {
type: Number,
default: 1
},
limit: {
type: Number,
default: 20
},
pageSizes: {
type: Array,
default() {
return [10, 20, 30, 50]
}
},
layout: {
type: String,
default: 'total, sizes, prev, pager, next, jumper'
},
background: {
type: Boolean,
default: true
},
autoScroll: {
type: Boolean,
default: true
},
hidden: {
type: Boolean,
default: false
}
},
computed: {
currentPage: {
get() {
return this.page
},
set(val) {
this.$emit('update:page', val)
}
},
pageSize: {
get() {
return this.limit
},
set(val) {
this.$emit('update:limit', val)
}
}
},
methods: {
handleSizeChange(val) {
this.$emit('pagination', { page: this.currentPage, limit: val })
if (this.autoScroll) {
scrollTo(0, 800)
}
},
handleCurrentChange(val) {
this.$emit('pagination', { page: val, limit: this.pageSize })
// if (this.autoScroll && this.$route.path.indexOf('personaPorDetails') === -1) {
// scrollTo(0, 800)
// }
}
}
}
</script>
<style scoped>
.pagination-container {
padding: 32px 16px;
}
.pagination-container.hidden {
display: none;
}
</style>
<template>
<div class="topbar">
<!-- Top -->
<section class="m-top">
<p class="m-title f-flex">
<img :src="logoUrl">
<span>全口径劳动力大数据分析应用平台</span>
</p>
<p class="m-clock">{{ timeDisplay }}</p>
</section>
<!-- Bottom -->
<section class="m-bottom f-flex">
<!-- Left -->
<section class="bottom-l f-flex">
<el-dropdown
v-for="item in routerList"
:key="item.path"
class="active menuItem"
>
<span v-if="item.children && item.dropdown" class="el-dropdown-link" @click="goPath(item)">{{ item.name }}</span>
<el-dropdown-menu v-if="item.children&&item.dropdown" slot="dropdown">
<app-link v-for="sub in item.children" :key="sub.path" :to="resolvePath(sub.path,index)">
<el-dropdown-item v-if="!sub.hidden" :command="index">{{ sub.name }}</el-dropdown-item>
</app-link>
</el-dropdown-menu>
<el-dropdown-menu v-else style="visibility: hidden" />
</el-dropdown>
</section>
<!-- Right -->
<section class="bottom-r f-flex">
<!-- 消息提醒 -->
<div class="m-message new" @click="jumpToMsgPage" />
<!-- 返回上级 -->
<!-- <div v-if="curAreaGrade !== userAreaGrade" class="m-back f-flex" @click="backLastGrade">
<img src="@/assets/images/layout/topbar_return.png">
<span>返回上级</span>
</div> -->
<!-- 用户中心 -->
<!-- <el-dropdown class="m-user">
<span class="userName">{{ username }}</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item @click.native="toChangePW">修改密码</el-dropdown-item>
<el-dropdown-item @click.native="logout">退出</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown> -->
</section>
</section>
</div>
</template>
<script>
export default {
name: 'Tobar',
data() {
return {
logoUrl: require('@/assets/images/layout/topbar_logo.jpg'),
routerList: [
{ name: '劳动力总况', path: '/', dropdown: true, children: [] }
],
updateTimer: null, // 更新时钟的timer
currTime: new Date(), // 当前日期对象
weekList: {
0: '星期日',
1: '星期一',
2: '星期二',
3: '星期三',
4: '星期四',
5: '星期五',
6: '星期六'
},
timeDisplay: ''
}
},
created() {
this.initClock()
},
beforeDestroy() {
clearInterval(this.updateTimer)
},
methods: {
// 初始化时钟
initClock() {
this.currTime = new Date()
clearInterval(this.updateTimer)
this.updateTimer = setInterval(() => {
this.currTime = new Date()
}, 1000)
},
// 跳转菜单路由
goPath(route) {
if (route.path) {
this.$router.push(route.path)
}
},
// 去修改密码
toChangePW() {
this.$router.push({ path: '/changePW' })
},
// 查看消息列表
jumpToMsgPage() {
this.$router.push({ path: '/permission/MsgCenter' })
}
}
}
</script>
<style lang="less" scoped>
.f-flex {
display: flex;
display: -webkit-flex;
flex-flow: row nowrap;
justify-content: space-between;
align-items: center;
}
.topbar {
width: 100%;
.m-top {
position: relative;
width: 100%;
height: .9rem;
background: url('~@/assets/images/layout/topbar_bg.png') no-repeat;
background-size: contain;
.m-title {
width: 100%;
height: .9rem;
justify-content: center;
line-height: .9rem;
text-align: center;
img {
width: .4rem;
height: .4rem;
}
span {
display: inline-block;
margin-left: 0.08rem;
font-size: .36rem;
font-weight: 500;
color: #FFFFFF;
}
}
.m-clock {
position: absolute;
top: .54rem;
right: 7%;
height: .25rem;
line-height: .25rem;
font-size: .18rem;
color: #FFFFFF;
}
}
.m-bottom {
width: 100%;
height: .6rem;
padding: 0 .15rem;
}
}
.m-bottom {
.bottom-l {
width: calc(100% - 2.4rem);
height: 100%;
justify-content: flex-start;
}
.bottom-r {
width: 2.4rem;
height: 100%;
}
}
/deep/.bottom-l {
.menuItem {
margin: 0 .15rem;
height: .4rem;
width: 2.02rem;
background: url('~@/assets/images/layout/topbar_menu_bg.png') no-repeat;
background-size: contain;
text-align: center;
line-height: .4rem;
font-weight: 500;
font-size: .2rem;
color: #BBDBFF;
&.active {
background: url('~@/assets/images/layout/topbar_menu_active_bg.png') no-repeat;
background-size: contain;
color: #004E4F;
}
.el-dropdown-link {
display: inline-block;
width: 100%;
cursor: pointer;
}
}
}
/deep/.bottom-r {
.m-message {
position: relative;
margin-right: 0.1rem;
width: .16rem;
height: .2rem;
background: url('~@/assets/images/layout/topbar_msg.png') no-repeat;
background-size: 100% 100%;
cursor: pointer;
user-select: none;
&::after {
position: absolute;
top: -0.03rem;
right: -0.03rem;
width: 0.1rem;
height: 0.1rem;
content: '';
border-radius: 50%;
background-color: #FF0200;
opacity: 0;
}
&.new::after { opacity: 1 }
}
.m-back {
height: .4rem;
padding: 0 0.1rem;
line-height: .4rem;
user-select: none;
cursor: pointer;
img {
width: 0.16rem;
height: 0.14rem
}
span {
display: inline-block;
margin-left: 0.06rem;
font-size: .14rem;
color: #E8F4FF;
}
}
.m-user {
height: 0.4rem;
padding: 0 0.1rem;
line-height: .4rem;
text-align: center;
cursor: pointer;
.userName {
font-size: .14rem;
color: #FFFFFF;
}
}
}
</style>
<template>
<div class="vessel_box" :style="{backgroundImage:'url('+vesselBoximg+')',paddingLeft:vesselPaddimg,paddingRight:vesselPaddimg}">
<div v-if="showTitle" class="vessel_head">
<div v-for="(item,index) in vesselList" :key="index" class="vessel_title" :style="{minWidth:minWidth,fontSize:fontSize}">
{{ item }}
</div>
</div>
<div class="vessel_content" :style="{height:contentHeight}">
<slot v-show="!showEmpty" name="chart" />
<Empty v-if="showEmpty" class="empty" />
</div>
</div>
</template>
<script>
export default {
props: {
vesselTitle: {
type: String,
default: ''
},
size: {
type: String,
default: 'small'
},
showTitle: {
type: Boolean,
default: true
},
usePadding: {
type: Boolean,
default: true
},
showEmpty: {
type: Boolean,
default: false
},
fontSize: {
type: String,
default: '.24rem'
}
},
computed: {
vesselBoximg() {
let vesselBoder = ''
switch (this.size) {
case 'small':
vesselBoder = require('@/assets/images/vessel_box.png')
break
case 'middle':
vesselBoder = require('@/assets/images/vessel_middleBox.png')
break
case 'large':
vesselBoder = require('@/assets/images/vessel_mapBox.png')
break
case 'long':
vesselBoder = require('@/assets/images/vessel_boxMiddle.png')
break
}
return vesselBoder
},
vesselList() {
const vesselList = this.vesselTitle.split(',')
return vesselList
},
vesselPaddimg() {
const paddingNum = this.usePadding ? '.25rem' : '0rem'
return paddingNum
},
contentHeight() {
const paddingNum = this.showTitle ? 'calc(100% - .5rem)' : '100%'
return paddingNum
},
minWidth() {
const vesselList = this.vesselTitle.split(',')
const minWidth = vesselList.length === 2 ? '1.94rem' : '2.64rem'
return minWidth
}
}
}
</script>
<style lang="less" scoped>
.vessel_box{
width: 100%;
height: 100%;
padding-top: .05rem;
padding-bottom: .1rem;
// padding: .05rem .25rem .1rem;
background-repeat: no-repeat;
background-size: 100% 100%;
}
.vessel_head{
height: .4rem;
display: flex;
justify-content: center;
.vessel_title{
height: .4rem;
line-height: .4rem;
text-align: center;
margin: 0 .15rem;
// font-size: .24rem;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #FFFFFF;
box-sizing: border-box;
padding: 0 .25rem;
background: url('../../assets/images/vessel_title.png') no-repeat;
background-size: 100% 100%;
}
}
.vessel_content{
position: relative;
width: 100%;
margin-top: .1rem;
// overflow: hidden;
.empty {
position: absolute;
top: 0;
left: 0;
}
}
</style>
import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import fastclick from 'fastclick'
import 'normalize-css'
import './common/style/reset.css'
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import Empty from './components/Empty'
fastclick.attach(document.body)
Vue.config.productionTip = false
var bus = new Vue()
Vue.prototype.bus = bus
Vue.use(ElementUI)
Vue.component('Empty', Empty)
new Vue({
router,
store,
render: h => h(App)
}).$mount('#app')
import Vue from 'vue'
import VueRouter from 'vue-router'
Vue.use(VueRouter)
const routes = [
{
path: '/',
name: 'Home',
component: () => import('../views/Home')
},
{
path: '/permission/MsgCenter',
component: () => import('../views/message'),
hidden: true,
name: '消息中心',
meta: { title: '消息中心' }
}
]
const router = new VueRouter({
routes
})
export default router
<template>
<div class="skeleton page">
<div class="skeleton-nav" />
<div class="skeleton-swiper" />
<ul class="skeleton-tabs">
<li v-for="i in 8" :key="i" class="skeleton-tabs-item"><span /></li>
</ul>
<div class="skeleton-banner" />
<div v-for="i in 5" :key="i" class="skeleton-productions" />
</div>
</template>
<style>
.skeleton {
position: relative;
height: 100%;
overflow: hidden;
padding: 15px;
box-sizing: border-box;
background: #fff;
}
.skeleton-nav {
height: 45px;
background: #eee;
margin-bottom: 15px;
}
.skeleton-swiper {
height: 160px;
background: #eee;
margin-bottom: 15px;
}
.skeleton-tabs {
list-style: none;
padding: 0;
margin: 0 -15px;
display: flex;
flex-wrap: wrap;
}
.skeleton-tabs-item {
width: 25%;
height: 55px;
box-sizing: border-box;
text-align: center;
margin-bottom: 15px;
}
.skeleton-tabs-item span {
display: inline-block;
width: 55px;
height: 55px;
border-radius: 55px;
background: #eee;
}
.skeleton-banner {
height: 60px;
background: #eee;
margin-bottom: 15px;
}
.skeleton-productions {
height: 20px;
margin-bottom: 15px;
background: #eee;
}
.skeleton {
padding: 10px;
}
.skeleton .skeleton-head,
.skeleton .skeleton-title,
.skeleton .skeleton-content {
background: rgb(194, 207, 214);
}
.skeleton-head {
width: 100px;
height: 100px;
float: left;
}
.skeleton-body {
margin-left: 110px;
}
.skeleton-title {
width: 500px;
height: 60px;
transform-origin: left;
animation: skeleton-stretch .5s linear infinite alternate;
}
.skeleton-content {
width: 260px;
height: 30px;
margin-top: 10px;
transform-origin: left;
animation: skeleton-stretch .5s -.3s linear infinite alternate;
}
@keyframes skeleton-stretch {
from {
transform: scalex(1);
}
to {
transform: scalex(.3);
}
}
</style>
import Vue from 'vue'
import SkeletonIndex from './SkeletonIndex.vue'
/**
* id[skeletonIndex] 与 routes-skeleton.js 里的 skeletonId 想对应
* import 引入的 SkeletonIndex.vue 文件就是骨架屏文件
* 骨架屏文件根据配置打包到 index.html里 通过路由path与skeletonId 来匹配展示
*/
export default new Vue({
components: {
SkeletonIndex
},
template: `
<div>
<SkeletonIndex id="skeletonIndex" style="display:none"/>
</div>
`
})
module.exports = {
router: {
mode: 'hash', // router 模式
routes: [
{
path: '/',
skeletonId: 'skeletonIndex'
}
]
}
}
File mode changed
File mode changed
import Vue from 'vue'
import Vuex from 'vuex'
// import * as actions from "./actions";
// import * as getters from "./getters";
import state from './state'
import mutations from './mutations'
import createLogger from 'vuex/dist/logger' // 用于观察vuex状态日志
Vue.use(Vuex)
const debug = process.env.NODE_ENV !== 'production'
export default new Vuex.Store({
state,
mutations,
// actions,
// getters,
strict: debug,
plugins: debug ? [createLogger()] : []
})
const mutations = {}
export default mutations
const state = {}
export default state
html {
margin: 0;
height: 100%;
scrollbar-width: none;
box-sizing: border-box;
font-size: 100px;
}
body {
margin: 0;
height: 100%;
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
text-rendering: optimizeLegibility;
font-family: Helvetica Neue, Helvetica, PingFang SC, Hiragino Sans GB, Microsoft YaHei, Arial, sans-serif;
font-size: 14px;
}
#app {
height: 100%;
}
*,
*:before,
*:after {
box-sizing: inherit;
}
a:focus,
a:active {
outline: none;
}
a,
a:focus,
a:hover {
cursor: pointer;
color: inherit;
text-decoration: none;
}
p { margin: 0 }
div:focus {
outline: none;
}
.fr {
float: right;
}
.fl {
float: left;
}
.clearfix {
&:after {
visibility: hidden;
display: block;
font-size: 0;
content: " ";
clear: both;
height: 0;
}
}
.unknow-tip {
position: absolute;
right: 0;
bottom: 2%;
cursor: pointer;
color: #aaa;
z-index: 99;
}
.unknow-tip-chart {
position: absolute;
right: -.16rem;
bottom: 2%;
cursor: pointer;
color: #aaa;
z-index: 99;
}
.unknow-tip-home {
position: absolute;
right: .1rem;
bottom: .1rem;
cursor: pointer;
color: #aaa;
z-index: 99;
}
::-webkit-scrollbar-track-piece {
border-radius: 0
}
::-webkit-scrollbar {
width: 5px;
height: 10px
}
::-webkit-scrollbar-thumb {
height: 50px;
background-color: #b8b8b8;
border-radius: 6px;
outline-offset: -2px;
filter: alpha(opacity = 50);
-moz-opacity: 0.5;
-khtml-opacity: 0.5;
opacity: 0.5
}
::-webkit-scrollbar-thumb:hover {
height: 50px;
background-color: #878987;
border-radius: 6px
}
import CryptoJS from 'crypto-js/crypto-js'
import Vue from 'vue'
const KEY = CryptoJS.enc.Utf8.parse('tecsuntecsun1234') // 'retedfgd' 与后台一致
const IV = CryptoJS.enc.Utf8.parse('o-kJW4_3AVXz5s96JgUkcBE4M3LA') // 'asdqwe' 与后台一致
/**
* 加密 没IV
* @param str
* @returns {string}
*/
export function EncryptNoIV(str) {
if (str) {
var srcs = CryptoJS.enc.Utf8.parse(str)
var encrypted = CryptoJS.AES.encrypt(srcs, KEY, {
mode: CryptoJS.mode.ECB,
padding: CryptoJS.pad.Pkcs7 })
return encrypted.toString()
} else {
return ''
}
}
/**
* 解密 没IV
* @param str
* @returns {*}
*/
export function DecryptNoIV(str) {
if (str) {
var decrypt = CryptoJS.AES.decrypt(str, KEY, {
mode: CryptoJS.mode.ECB,
padding: CryptoJS.pad.Pkcs7
})
return CryptoJS.enc.Utf8.stringify(decrypt).toString()
} else {
return ''
}
}
// AES加密 :字符串 key iv 返回base64
export function Encrypt(str) {
const key = KEY
const iv = IV
const srcs = CryptoJS.enc.Utf8.parse(str)
var encrypted = CryptoJS.AES.encrypt(srcs, key, {
iv: iv,
// mode: CryptoJS.mode.ECB,
mode: CryptoJS.mode.CBC, // mode 与后台一致
padding: CryptoJS.pad.Pkcs7
})
return CryptoJS.enc.Base64.stringify(encrypted.ciphertext)
}
// AES 解密 :字符串 key iv 返回base64
export function Decrypt(str) {
const key = KEY
const iv = IV
const base64 = CryptoJS.enc.Base64.parse(str)
const src = CryptoJS.enc.Base64.stringify(base64)
var decrypt = CryptoJS.AES.decrypt(src, key, {
iv: iv,
// mode: CryptoJS.mode.ECB,
mode: CryptoJS.mode.CBC, // 保持一致
padding: CryptoJS.pad.Pkcs7
})
var decryptedStr = decrypt.toString(CryptoJS.enc.Utf8)
return decryptedStr.toString()
}
Vue.use(CryptoJS)
import Cookies from 'js-cookie'
const TokenKey = 'Admin-Token'
const userName = 'userName'
const userType = 'userType'
export function getToken() {
// return Cookies.get(TokenKey)
return sessionStorage.getItem('token')
}
export function removeToken() {
return Cookies.remove(TokenKey)
}
export function getUserName() {
return Cookies.get(userName)
}
export function getUserType() {
return Cookies.get(userType)
}
export function setUserName(token) {
return Cookies.set(userName, token)
}
export function setUserType(userType) {
return Cookies.set(userType, userType)
}
export function removeUserName() {
return Cookies.remove(userName)
}
export function removeUserType() {
return Cookies.remove(userType)
}
// 本地缓存的方法统一写在这里
import storage from 'good-storage'
export function setSession(name, query) {
storage.session.set(name, query)
}
export function getSession(name) {
storage.session.get(name)
}
export function getImgUrl(type, imgUrl = 'https://bijieyspim.e-tecsun.com/images') {
const icons = {
person: '/ic_workman_20210624_04.png',
work: '/ic_workman_20210624_05.png',
skill: '/ic_workman_20210624_06.png',
labor: '/ic_workman_20210624_07.png',
insurance: '/ic_workman_20210624_02.png',
addtion: '/ic_workman_20210624_01.png',
investigator: '/ic_workman_20210624_03.png',
arrow_up: '/ic_workman_arrow_up.png',
arrow_down: '/ic_workman_arrow_down.png'
}
return imgUrl + icons[type]
}
export function tree(sourceArr, targetArr, num) {
sourceArr.forEach((item, index) => {
const children = item.children
if (children && children.length > 0 && num > 1) {
targetArr.push({
text: item.name,
id: item.id,
leaf: '',
children: []
})
tree(children, targetArr[index].children, num - 1)
} else {
targetArr.push({
text: item.name,
id: item.id,
leaf: 'leaf',
children: ''
})
}
})
return targetArr
}
// 递归树取得省市区回显index数组
export function findDeepIndex(sourceArr, targetArr, result, i) {
let indexVal; let source
if (sourceArr instanceof Array) {
sourceArr.forEach((item, index) => {
if (item.id == targetArr[i]) {
indexVal = index
source = item
return
}
})
}
if (indexVal !== -1) {
result.push(indexVal)
i++
}
if (i < targetArr.length) {
if (source.children && source.children.length) {
findDeepIndex(source.children, targetArr, result, i)
}
} else {
return result
}
return result
}
// 删除对象某些属性
export function omit(obj, uselessKeys) {
return uselessKeys.reduce((acc, key) => {
return { ...acc, [key]: undefined }
}, obj)
}
// 选择对象某些属性
export function pick(obj, arr) {
// eslint-disable-next-line no-sequences
return arr.reduce((iter, val) => (val in obj && (iter[val] = obj[val]), iter), {})
}
// 防抖
export function debounce(callback, delay) {
let timer = null
var that = this
return function() {
var args = Array.prototype.slice.call(arguments)
if (timer !== null) {
clearTimeout(timer)
}
timer = setTimeout(() => {
callback.apply(that, args)
}, delay)
}
}
/**
* 去除字符串空格
*/
function removeEmpty(str) {
return str.replace(/\s/g, '')
}
// 检验姓名输入的方法
export function checkName(name) {
// 少数民族名字验证,中间点为粗点
const reg1 = /^[\u4e00-\u9fa5]{1,6}([\u4e00-\u9fa5]{1,6}){0,2}$/
// 中间点为细点
const reg2 = /^[\u4e00-\u9fa5]{1,6}(·[\u4e00-\u9fa5]{1,6}){0,2}$/
// 正常人名字验证
const reg3 = /^[\u4E00-\u9FA5]{2,4}$/
// 先去除空格
name = removeEmpty(name)
if (name.indexOf('•') != -1) {
console.log('粗点')
if (reg1.test(name)) {
return true
} else {
return false
}
} else if (name.indexOf('·') != -1) {
console.log('细点')
if (reg2.test(name)) {
return true
} else {
return false
}
} else {
console.log('正常')
if (name.length == 4) {
console.log('4')
const s1 = name.substring(0, 2)
const s2 = name.substring(2, name.length)
console.log('s1', s1)
console.log('s2', s2)
if (s1 == s2) {
return false
} else {
return true
}
} else {
if (reg3.test(name)) {
return true
} else {
return false
}
}
}
}
/**
* 检测电话号码合法性
*/
export function checkPhone(content) {
var reg = /^1[3-9][0-9]{9}$/
if (!reg.test(content)) {
return false
}
// 记录出现的数字
var flag = 1
// 记录连续出现的次数
var count = 1
for (var i = 0; i < content.length; i++) {
if (content[i] == flag) {
count = count + 1
} else {
count = 1
flag = content[i]
}
if (count >= 6) {
return false
}
}
return true
}
/**
* 根据身份证获取年龄
*/
function getAgeByIdcard(idCard) {
if (!idCard) {
return 0
}
if (idCard.length === 20) { // 残疾人证件
idCard = idCard.substring(0, 18)
}
try {
var myDate = new Date()
var month = myDate.getMonth() + 1
var day = myDate.getDate()
var age = myDate.getFullYear() - idCard.substring(6, 10) - 1
if (idCard.substring(10, 12) < month || idCard.substring(10, 12) == month && idCard.substring(12, 14) <= day) {
age++
}
return age
} catch (e) {
return 0
}
}
/**
* 检测身份证合法性
*/
export function checkIdCard(content, checkAge) {
// //验证前两位城市编码是否正确
var aCity = { 11: '北京', 12: '天津', 13: '河北', 14: '山西', 15: '内蒙古', 21: '辽宁', 22: '吉林', 23: '黑龙江 ', 31: '上海', 32: '江苏', 33: '浙江', 34: '安徽', 35: '福建', 36: '江西', 37: '山东', 41: '河南', 42: '湖北', 43: '湖南', 44: '广东', 45: '广西', 46: '海南', 50: '重庆', 51: '四川', 52: '贵州', 53: '云南', 54: '西藏', 61: '陕西', 62: '甘肃', 63: '青海', 64: '宁夏', 65: '新疆', 71: '台湾', 81: '香港', 82: '澳门', 91: '国外' }
if (aCity[parseInt(content.substr(0, 2))] == null) {
return false
}
var reg = /(^\d{15}$)|(^\d{17}(\d|X|x)$)/
if (!reg.test(content)) {
return false
}
// 身份证15位转18位
var a18 = content
if (content.length == '15') {
// eslint-disable-next-line no-array-constructor
var arrInt = new Array(7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2)
// eslint-disable-next-line no-array-constructor
var arrCh = new Array('1', '0', 'X', '9', '8', '7', '6', '5', '4', '3', '2')
var cardTemp = 0; var i
a18 = ''
a18 = content.substr(0, 6) + '19' + content.substr(6, content.length - 6)
for (i = 0; i < 17; i++) {
cardTemp += a18.substr(i, 1) * arrInt[i]
}
a18 += arrCh[cardTemp % 11]
}
// 获取身份证中的年月进行校验
var re_eighteen = /^(\d{6})(\d{4})(\d{2})(\d{2})(\d{3})([0-9]|X|x)$/
var arr_data = a18.match(re_eighteen)
var year = arr_data[2]
var month = arr_data[3]
var day = arr_data[4]
var birthday = new Date(year + '/' + month + '/' + day)
var now = new Date()
var time = now.getFullYear - year
// 检测年月日是否合理
if (birthday.getFullYear() == year && (birthday.getMonth() + 1) == month && birthday.getDate() == day) {
if (time >= 0 || time <= 130) {
return true
}
} else {
return false
}
if (checkAge) {
// 限制年龄16到60岁
var age = getAgeByIdcard(a18)
if (age >= 16 && age <= 60) {
console.log(age)
} else {
return false
}
}
return true
}
import dayjs from 'dayjs'
import 'dayjs/locale/zh-cn'
dayjs.locale('zh-cn')
export default {
/**
* 获取格式化之后的日期,默认当前
*/
dateFormat(date, format = 'YYYY-MM-DD') {
return dayjs(date).format(format)
},
/**
* 返回星期几
* @param {Stirng} val
*/
getWeekDate(val) {
if (!val) return ''
var date = dayjs(val)
var week = ['星期日', '星期一', '星期二', '星期三', '星期四', '星期五', '星期六']
return `${week[date.day()]}`
},
/**
* 获取本周周一
*/
monday() {
return this.dateFormat(dayjs().startOf('week'))
},
/**
* 获取上周周一
*/
lastMonday() {
return this.dateFormat(
dayjs()
.subtract(1, 'week')
.startOf('week')
)
},
/**
* 获取本周周日
*/
sunday() {
return this.dateFormat(dayjs().endOf('week'))
},
/**
* 获取上周周日
*/
lastSunday() {
return this.dateFormat(
dayjs()
.subtract(1, 'week')
.endOf('week')
)
},
/**
* 根据日期获取本周或上周字符串
* @param {String} date
*/
weekDiff(date) {
const diff = dayjs()
.startOf('week')
.diff(dayjs(date), 'day')
if (diff === 0) return '本周'
if (diff > 0 && diff <= 7) return '上周'
return false
},
/**
* 获取本月第一天
*/
getLastDayOfMonth() {
const date = dayjs().startOf('month')
return this.dateFormat(date)
},
/**
* 获取本月最后一天
*/
getFirstDayOfMonth() {
const date = dayjs().endOf('month')
return this.dateFormat(date)
},
/**
* 返回日期范围的值
* @param {String} data 日期范围字符串 '2019-4-11 - 2019-4-30'
*/
dateRange2json(data) {
if (data === '') return {}
data = data.split(' - ')
return {
startTime: data[0],
endTime: data[1]
}
},
/**
* 返回日期相差年数
* @param {String} date1 YYYY-MM-DD
* @param {String} date2 YYYY-MM-DD
*/
getDiffByYear(date1, date2) {
return dayjs(date1).diff(dayjs(date2), 'year')
},
/**
* 返回日期相差月数
* @param {String} date1 YYYY-MM-DD
* @param {String} date2 YYYY-MM-DD
*/
getDiffByMonth(date1, date2) {
return dayjs(date1).diff(dayjs(date2), 'month')
},
/**
* 返回日期相差天数
* @param {String} date1 YYYY-MM-DD
* @param {String} date2 YYYY-MM-DD
*/
getDiffByDate(date1, date2) {
return dayjs(date1).diff(dayjs(date2), 'day')
},
/**
* 返回日期相差小时
* @param {String} date1 YYYY-MM-DD
* @param {String} date2 YYYY-MM-DD
*/
getDiffByHour(date1, date2) {
return (dayjs(date1).diff(dayjs(date2))) / (24 * 60 * 60 * 1000)
},
/**
* 计算时间差(天、小时、分钟、秒)
* @param {String} date1 YYYY-MM-DD HH:mm:ss
* @param {String} date2 YYYY-MM-DD HH:mm:ss
*/
getDiffByTime(date1, date2) {
var getDiff = (dayjs(date1).diff(dayjs(date2)))
// 计算出相差天数
var days = Math.floor(getDiff / (24 * 3600 * 1000))
// 计算天数后剩余的毫秒数
var leave1 = getDiff % (24 * 3600 * 1000)
// 计算出小时数
var hours = Math.floor(leave1 / (3600 * 1000))
// 计算小时数后剩余的毫秒数
var leave2 = leave1 % (3600 * 1000)
// 计算相差分钟数
var minutes = Math.floor(leave2 / (60 * 1000))
// 计算分钟数后剩余的毫秒数
var leave3 = leave2 % (60 * 1000)
// 计算相差秒数
var seconds = Math.round(leave3 / 1000)
return `相差 ${days}${hours} 小时 ${minutes} 分钟 ${seconds} 秒`
},
/**
* 某个时间在当前时间的多久前
* @param {*} date 要对比的时间 YYYY-MM-DD HH:mm:ss
*/
getDateDiff(date) {
var minute = 1000 * 60
var hour = minute * 60
var day = hour * 24
var month = day * 30
var year = day * 365
var now = dayjs(new Date()).format('YYYY-MM-DD HH:mm:ss')
var diffValue = dayjs(now).diff(dayjs(date))
if (diffValue < 0) { return '未来' }
var yearC = diffValue / year
var monthC = diffValue / month
var weekC = diffValue / (7 * day)
var dayC = diffValue / day
var hourC = diffValue / hour
var minC = diffValue / minute
var result
if (yearC >= 1) {
result = '' + parseInt(yearC) + '年前'
} else if (monthC >= 1) {
result = '' + parseInt(monthC) + '月前'
} else if (weekC >= 1) {
result = '' + parseInt(weekC) + '周前'
} else if (dayC >= 1) {
result = '' + parseInt(dayC) + '天前'
} else if (hourC >= 1) {
result = '' + parseInt(hourC) + '小时前'
} else if (minC >= 1) {
result = '' + parseInt(minC) + '分钟前'
} else {
result = '刚刚'
}
return result
}
}
/**
* @param {blob} res
* @param {String} name
* 下载方法
*/
import { saveAs } from 'file-saver'
import date from './date'
export function downLoad(res, name) {
saveAs(new Blob([res], { type: 'application/json' }), date.dateFormat(new Date(), 'YYYY-MM-DD HH:mm:ss') + '-' + name)
}
import defaultSettings from '@/settings'
const title = defaultSettings.title || 'Vue Element Admin'
export default function getPageTitle(pageTitle) {
if (pageTitle) {
return `${pageTitle} - ${title}`
}
return `${title}`
}
import store from '@/store'
/**
* @param {Array} value
* @returns {Boolean}
* @example see @/views/permission/directive.vue
*/
export default function checkPermission(value) {
if (value && value instanceof Array && value.length > 0) {
const roles = store.getters && store.getters.roles
const permissionRoles = value
const hasPermission = roles.some(role => {
return permissionRoles.includes(role)
})
if (!hasPermission) {
return false
}
return true
} else {
console.error(`need roles! Like v-permission="['admin','editor']"`)
return false
}
}
// rem.js
const baseSize = 32
// 设置 rem 函数
function setRem() {
// 当前页面宽度相对于 750 宽的缩放比例,可根据自己需要修改。
const scale = document.documentElement.clientWidth / 750
// 设置页面根节点字体大小
document.documentElement.style.fontSize = (baseSize * Math.min(scale, 2)) + 'px'
}
// 初始化
setRem()
// 改变窗口大小时重新设置 rem
window.onresize = function() {
setRem()
}
import axios from 'axios'
import { Notify } from 'vant'
import { Toast } from 'vant'
import router from '@/router/index.js'
import { responseCode } from '@/common/business/responseCode'
import { getToken } from '@/utils/auth.js'
import { configObj } from '@/common/settings/xhr.config'
const service = axios.create(configObj)
const CancelToken = axios.CancelToken // 取消重复的请求
const cancelSource = CancelToken.source()
// http request 拦截器
// ajax 发送之前拦截 比如对所有请求统一添加 header token
service.interceptors.request.use(
config => {
// 不传递默认开启loading
if (!config.hideloading) {
Toast.loading({
message: config.loadingText ? config.loadingText : '加载中...',
forbidClick: true
})
}
config.cancelToken = cancelSource.token // 全局添加cancelToken
config.headers.Authorization = 'bearer ' + getToken()
return config
},
error => {
return Promise.reject(error)
}
)
// http response 拦截器
// ajax 请求回调之前拦截 对请求返回的信息做统一处理 比如 未认证则跳转到登陆界面
service.interceptors.response.use(
response => {
Toast.clear()
const res = response.data
if (res.code && res.code !== 200) {
if (res.code === 11010001) {
Notify({
message: '已超时未认证,请重新登录',
type: 'danger',
duration: 2 * 1000
})
cancelSource.cancel() // 取消其他正在进行的请求
sessionStorage.clear()
// Notify.closeAll()
router.replace({ path: '/login' })
return Promise.reject(res)
}
Notify({
message: res.msg || responseCode[res.code] || '返回未知异常',
type: 'danger',
duration: 2 * 1000
})
return Promise.reject(res)
}
return res
},
error => {
Toast.clear()
const { response } = error
if (response && (response.data || response.code)) {
let { msg } = response.data
const { code } = response.data
if (response.data instanceof Blob) {
msg = response.code === 500 ? '服务器出差了' : '网络异常,请稍候再试'
}
Notify({
message: msg || responseCode[code] || '接口未知异常',
type: 'danger',
duration: 2 * 1000
})
if (code === 11010001) {
cancelSource.cancel() // 取消其他正在进行的请求
sessionStorage.clear()
// Notify.closeAll()
router.replace({ path: '/login' })
}
return Promise.reject(error)
} else {
let { message } = error
const code = error.response.status
if (message.includes('timeout')) {
message = '请求超时'
} else {
switch (code) {
case 400:
message = '请求错误'
break
case 401:
message = '未认证,请重新登录'
cancelSource.cancel() // 取消其他正在进行的请求
sessionStorage.clear()
// Notify.closeAll()
router.replace({ path: '/login' })
break
case 403:
message = '拒绝访问'
break
case 404:
message = '资源未找到~'
break
case 500:
message = '服务器出差了~'
break
}
}
Notify({
message: message || `接口未知异常`,
type: 'danger',
duration: 2 * 1000
})
return Promise.reject(error)
}
}
)
export default service
/** 重置message,防止重复点击重复弹出message弹框 */
import { Message } from 'element-ui'
let messageInstance = null
const resetMessage = (options) => {
if (messageInstance) {
messageInstance.close()
}
messageInstance = Message(options)
};
['error', 'success', 'info', 'warning'].forEach(type => {
resetMessage[type] = options => {
if (typeof options === 'string') {
options = {
message: options
}
}
options.type = type
return resetMessage(options)
}
})
resetMessage.closeAll = () => {
Message.closeAll()
}
export const message = resetMessage
Math.easeInOutQuad = function(t, b, c, d) {
t /= d / 2
if (t < 1) {
return c / 2 * t * t + b
}
t--
return -c / 2 * (t * (t - 2) - 1) + b
}
// requestAnimationFrame for Smart Animating http://goo.gl/sx5sts
var requestAnimFrame = (function() {
return window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || function(callback) { window.setTimeout(callback, 1000 / 60) }
})()
/**
* Because it's so fucking difficult to detect the scrolling element, just move them all
* @param {number} amount
*/
function move(amount) {
document.documentElement.scrollTop = amount
document.body.parentNode.scrollTop = amount
document.body.scrollTop = amount
}
function position() {
return document.documentElement.scrollTop || document.body.parentNode.scrollTop || document.body.scrollTop
}
/**
* @param {number} to
* @param {number} duration
* @param {Function} callback
*/
export function scrollTo(to, duration, callback) {
const start = position()
const change = to - start
const increment = 20
let currentTime = 0
duration = (typeof (duration) === 'undefined') ? 500 : duration
var animateScroll = function() {
// increment the time
currentTime += increment
// find the value with the quadratic in-out easing function
var val = Math.easeInOutQuad(currentTime, start, change, duration)
// move the document.body
move(val)
// do the animation unless its over
if (currentTime < duration) {
requestAnimFrame(animateScroll)
} else {
if (callback && typeof (callback) === 'function') {
// the animation is done so lets callback
callback()
}
}
}
animateScroll()
}
// 时间格式化处理
export function dateFtt(fmt, date) {
var o = {
'M+': date.getMonth() + 1, // 月份
'd+': date.getDate(), // 日
'h+': date.getHours(), // 小时
'm+': date.getMinutes(), // 分
's+': date.getSeconds(), // 秒
'q+': Math.floor((date.getMonth() + 3) / 3), // 季度
'S': date.getMilliseconds() // 毫秒
}
if (/(y+)/.test(fmt)) { fmt = fmt.replace(RegExp.$1, (date.getFullYear() + '').substr(4 - RegExp.$1.length)) }
for (var k in o) {
if (new RegExp('(' + k + ')').test(fmt)) { fmt = fmt.replace(RegExp.$1, (RegExp.$1.length === 1) ? (o[k]) : (('00' + o[k]).substr(('' + o[k]).length))) }
}
return fmt
}
// Echarts图表像素大小自适应
export function PXTransformation(res) {
const docEl = document.documentElement
const clientWidth = window.innerWidth || docEl.clientWidth || document.body.clientWidth
if (!clientWidth) return
const fontSize = 100 * (clientWidth / 1920)
return parseInt(res * fontSize)
}
export function getPageTitle(pageTitle) {
if (pageTitle) {
return `${pageTitle}-` + localStorage.getItem('title')
}
return localStorage.getItem('title') || '社保银行服务包业务后台管理系统'
}
// 一维数组转为树形结构)
/**
* @param {string} id // 子索引
* @param {string} pid // 父索引
*/
export function convertTree(list, id, pid) {
list.forEach(item => {
delete item.children
})
const root = []
const idMapping = list.reduce((acc, el, i) => {
acc[el[id]] = i
return acc
}, {})
list.forEach(el => {
if (!el[pid]) {
root.push(el)
return
}
const parentEl = list[idMapping[el[pid]]]
if (parentEl === undefined) {
root.push(el)
return
}
parentEl.children = [...(parentEl.children || []), el]
})
return root
}
/**
* This is just a simple version of deep copy
* Has a lot of edge cases bug
* If you want to use a perfect deep copy, use lodash's _.cloneDeep
* @param {Object} source
* @returns {Object}
*/
export function deepClone(source) {
if (!source && typeof source !== 'object') {
throw new Error('error arguments', 'deepClone')
}
const targetObj = source.constructor === Array ? [] : {}
Object.keys(source).forEach(keys => {
if (source[keys] && typeof source[keys] === 'object') {
targetObj[keys] = deepClone(source[keys])
} else {
targetObj[keys] = source[keys]
}
})
return targetObj
}
/**
* Parse the time to string
* @param {(Object|string|number)} time
* @param {string} cFormat
* @returns {string | null}
*/
export function parseTime(time, cFormat) {
if (arguments.length === 0) {
return null
}
const format = cFormat || '{y}-{m}-{d} {h}:{i}:{s}'
let date
if (typeof time === 'object') {
date = time
} else {
if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) {
time = parseInt(time)
}
if ((typeof time === 'number') && (time.toString().length === 10)) {
time = time * 1000
}
date = new Date(time)
}
const formatObj = {
y: date.getFullYear(),
m: date.getMonth() + 1,
d: date.getDate(),
h: date.getHours(),
i: date.getMinutes(),
s: date.getSeconds(),
a: date.getDay()
}
const time_str = format.replace(/{([ymdhisa])+}/g, (result, key) => {
const value = formatObj[key]
// Note: getDay() returns 0 on Sunday
if (key === 'a') { return ['日', '一', '二', '三', '四', '五', '六'][value ] }
return value.toString().padStart(2, '0')
})
return time_str
}
/**
* 防抖
* @param { Function } func: 执行函数
* @param { Number } wait:间隔时长
* @param { Boolean } immediate: 是否立即执行
* @returns { Function }
*/
export function debounce(func, wait, immediate = true) {
let timeout, result
const debounced = function () {
const _this = this
const args = arguments
if (timeout) clearTimeout(timeout)
if (immediate) {
const callNow = !timeout
timeout = setTimeout(function() {
timeout = null
}, wait)
if (callNow) result = func.apply(_this, args)
} else {
timeout = setTimeout(function() {
func.apply(_this, args)
}, wait)
}
return result
}
debounced.cancel = function() {
clearTimeout(timeout)
timeout = null
}
return debounced
}
/**
* 节流
* @param { Function } func: 执行函数
* @param { Number } wait:间隔时长
* @returns { Function }
*/
export function throttle(func, wait) {
let _this, timeout, args
let previous = 0
const later = function() {
previous = +new Date()
timeout = null
func.apply(_this, args)
}
const throttled = function() {
const now = +new Date()
const remaining = wait - (now - previous)
_this = this
args = arguments
if (remaining <= 0 || remaining > wait) {
if (timeout) {
clearTimeout(timeout)
timeout = null
}
previous = now
func.apply(_this, args)
} else if (!timeout) {
timeout = setTimeout(later, remaining)
}
}
return throttled
}
/**
* Created by PanJiaChen on 16/11/18.
*/
/**
* @param {string} path
* @returns {Boolean}
*/
export function isExternal(path) {
return /^(https?:|mailto:|tel:)/.test(path)
}
/**
* @param {string} str
* @returns {Boolean}
*/
export function validUsername(str) {
const valid_map = ['admin', 'editor']
return valid_map.indexOf(str.trim()) >= 0
}
/**
* @param {string} url
* @returns {Boolean}
*/
export function validURL(url) {
const reg = /^(https?|ftp):\/\/([a-zA-Z0-9.-]+(:[a-zA-Z0-9.&%$-]+)*@)*((25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]?)(\.(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9]?[0-9])){3}|([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+\.(com|edu|gov|int|mil|net|org|biz|arpa|info|name|pro|aero|coop|museum|[a-zA-Z]{2}))(:[0-9]+)*(\/($|[a-zA-Z0-9.,?'\\+&%$#=~_-]+))*$/
return reg.test(url)
}
/**
* @param {string} str
* @returns {Boolean}
*/
export function validLowerCase(str) {
const reg = /^[a-z]+$/
return reg.test(str)
}
/**
* @param {string} str
* @returns {Boolean}
*/
export function validUpperCase(str) {
const reg = /^[A-Z]+$/
return reg.test(str)
}
/**
* @param {string} str
* @returns {Boolean}
*/
export function validAlphabets(str) {
const reg = /^[A-Za-z]+$/
return reg.test(str)
}
/**
* @param {string} email
* @returns {Boolean}
*/
export function validEmail(email) {
const reg = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/
return reg.test(email)
}
/**
* @param {string} str
* @returns {Boolean}
*/
export function isString(str) {
if (typeof str === 'string' || str instanceof String) {
return true
}
return false
}
/**
* @param {Array} arg
* @returns {Boolean}
*/
export function isArray(arg) {
if (typeof Array.isArray === 'undefined') {
return Object.prototype.toString.call(arg) === '[object Array]'
}
return Array.isArray(arg)
}
/**
* 账号密码校验规则(大小写字母+数字,至少8位)
* @param value
*/
export function passwordVerifiers(rule, value, callback) {
const reg = /^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9]).{8,}$/
if (!value) callback(new Error('密码不能为空'))
if (!reg.test(value)) {
if (value && value.length < 8) {
callback(new Error('密码不能少于8位'))
} else {
callback(new Error('密码应至少含有一个大写字母、小写字母和数字'))
}
} else {
callback()
}
}
/**
* 检测邮箱
* @param rule
* @param value
* @param callback
*/
export function validateEmail(rule, value, callback) {
if (!value || value === '') {
callback()
} else {
if (value !== '') {
var reg = /^[A-Za-z0-9\u4e00-\u9fa5]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
if (!reg.test(value)) {
callback(new Error('请输入有效的邮箱'))
}
}
callback()
}
}
/**
* 检测手机号
* @param rule
* @param value
* @param callback
*/
export function validateMobile(rule, value, callback) {
if (!value || value === '') {
callback()
} else {
if (value !== '') {
var reg = /^1[3456789]\d{9}$/
if (!reg.test(value)) {
callback(new Error('请输入正确的手机号'))
}
}
callback()
}
}
/**
* 检测手机号
* @param rule
* @param value
* @param callback
*/
export function validateChinese(rule, value, callback) {
if (value !== '') {
var reg = /[\u4E00-\u9FA5]/g
if (reg.test(value)) {
callback(new Error('请不要输入中文'))
} else {
callback()
}
} else {
callback()
}
}
/**
* 检测手机号
* @param rule
* @param value
* @param callback
*/
export function validatelng(rule, value, callback) {
if (!value) {
callback()
} else
if (value !== '') {
var reg = /^[0-9]+\.[0-9]+$/
if (!reg.test(value)) {
callback(new Error('请输入正确的经纬度'))
}
callback()
} else {
callback()
}
}
<template>
<div class="home_bottomCenter">
<Vessel vessel-title="劳动力人员户籍地分布" size="large" :use-padding="false">
<template v-slot:chart>
<div v-if="showMap" class="map-chart">
<Empty v-if="!hasMap" :image="emptyImgUrl" />
<div
v-else
ref="map"
v-loading="mapLoading"
element-loading-text="拼命加载中"
element-loading-spinner="el-icon-loading"
element-loading-background="rgba(0, 0, 0, 0.4)"
class="map-box"
/>
</div>
<div v-else class="svg-chart">
<Plot title="劳动力人数" query-url="/dashboard/api/bigdata/ldlzy/chart6" @showSecondaryData="showSecondaryData" />
</div>
<div class="select-box">
<el-cascader
ref="address"
v-model="curSelectArea"
:options="areaOptions"
:disabled="curAreaGrade === 5"
placeholder="查看下级区域"
@change="changeSelectArea"
/>
</div>
</template>
</Vessel>
<!-- 该图是乡镇级地图背景组成材料 -->
<img v-show="false" ref="townImg" :src="townBgImg" style="width: 8px;height: 8px;">
</div>
</template>
<script>
const echarts = require('echarts/lib/echarts')
require('echarts/lib/chart/map')
require('echarts/lib/chart/effectScatter')
require('echarts/lib/chart/scatter')
require('echarts/lib/component/tooltip')
require('echarts/lib/component/geo')
require('echarts/lib/component/legend')
require('echarts/lib/component/visualMap')
import Vessel from '@/components/Vessel'
import Plot from '@/components/Plot'
import { PXTransformation } from '@/utils/util'
import { getregionMap } from '@/api/home'
import { getAreaDictionary } from '@/api/user'
export default {
name: 'BottomCenter',
components: {
Vessel,
Plot
},
data () {
return {
showMap: true,
hasMap: true,
emptyImgUrl: require('@/assets/images/map/icon_nomap.png'),
townBgImg: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAIAAAAmKNuZAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyNpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTQ4IDc5LjE2NDAzNiwgMjAxOS8wOC8xMy0wMTowNjo1NyAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIDIxLjAgKFdpbmRvd3MpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOkFDQ0Q2RjYyQTdDRDExRUI4ODUxRDIxRjkzMEExNzg2IiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOkFDQ0Q2RjYzQTdDRDExRUI4ODUxRDIxRjkzMEExNzg2Ij4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6QUNDRDZGNjBBN0NEMTFFQjg4NTFEMjFGOTMwQTE3ODYiIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6QUNDRDZGNjFBN0NEMTFFQjg4NTFEMjFGOTMwQTE3ODYiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz6FboimAAAASklEQVR42mIUnL9XtHsDAzXA69IARjWtXJYX7+FCfyQEKeEyMVAVDG7jWCB+RhaihAsybjQqRqNiNCpGo2I0KoZZVDBSt9oGCDAAhYNrvRu3DWEAAAAASUVORK5CYII=',
symbolImgUrl: require('@/assets/images/map/icon_symbol.png'),
symbolLabelBgUrl: require('@/assets/images/map/symbol_label_bg.png'),
mapLoading: true,
mapEchart: null,
curSelectArea: [], // 当前下拉地区
areaOptions: [], // 区域选择列表
coordinateList: [], // 社区 | 村庄列表
timer: null // 地图定时器
}
},
computed: {
curAreaID() { // 当前区域ID
return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
},
curAreaName() { // 当前区域名称
return this.$store.getters.curAreaName || localStorage.getItem('areaName')
},
curAreaGrade() { // 当前区域等级
return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
},
mapZoom() { // 地图缩放比
let zoom = 1
const curAreaID = this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
switch (curAreaID) {
case 520500: // 毕节市
zoom = 1.4
break
case 520526: // 威宁县
case 520527: // 赫章县
case 520521: // 大方县
case 520525: // 纳雍县
case 520522: // 黔西市
case 520529: // 金海湖
zoom = 1
break
case 520524: // 织金县
case 520528: // 百里杜鹃
zoom = 1.1
break
case 520502: // 七星关
case 520523: // 金沙县
zoom = 1.2
break
default:
zoom = 1
}
return zoom
}
},
watch: {
async curAreaGrade(newV, oldV) {
const curAreaName = this.curAreaName
const curAreaID = this.curAreaID
if (newV < 5) this.initPage(curAreaID, curAreaName, newV)
if (newV === 5) this.curSelectArea = [curAreaID]
},
curAreaID(newV, oldV) {
let lastAreaCode = ''
if (localStorage.getItem('areaInfoHistoryList')) {
const areaInfoHistoryList = JSON.parse(localStorage.getItem('areaInfoHistoryList'))
lastAreaCode = areaInfoHistoryList.areaCodeList.pop()
}
this.showMap = lastAreaCode !== 50211 && newV !== 50211
}
},
created() {
const curAreaID = this.curAreaID
const curAreaName = this.curAreaName
const curAreaGrade = this.curAreaGrade
this.showMap = curAreaID !== 50211
this.initPage(curAreaID, curAreaName, curAreaGrade)
},
beforeDestory() {
clearInterval(this.timer)
this.timer = null
},
methods: {
// 初始化
initPage(curAreaID, curAreaName, curAreaGrade) {
this.getregionMap(curAreaID, curAreaName, curAreaGrade)
this.getAreaDictionary(curAreaID)
},
// 获取地图数据
async getregionMap(curAreaID, curAreaName, curAreaGrade) {
this.mapLoading = true
this.hasMap = true
const params = { areaCode: curAreaID }
const { data } = await getregionMap(params)
const { map, mapName, option } = this.handleDataBeforDrawMap(curAreaID, curAreaName, curAreaGrade, data)
this.$nextTick(() => {
this.mapLoading = false
if (map) {
this.hasMap = true
this.drawMap(map, mapName, option)
} else {
if (this.mapEchart !== null) this.mapEchart.dispose()
this.hasMap = false
}
})
},
// 处理区域字典
async getAreaDictionary(areaCode) {
let list = []
this.curSelectArea = []
const { data } = await getAreaDictionary(areaCode)
if (data) {
list = data.map((item) => ({
label: item.name,
value: item.id
}))
}
this.areaOptions = list
},
// 绘制地图前逻辑处理
handleDataBeforDrawMap(curAreaID, curAreaName, curAreaGrade, data) {
let map = ''
let mapName = ''
let curAreaNameFilter = curAreaName
if (curAreaName === '黔西县') curAreaNameFilter = '黔西市'
if (curAreaName === '威宁彝族回族苗族自治县') curAreaNameFilter = '威宁县'
if (curAreaGrade === 2) {
const mapList = ['bijie']
const mapNameList = ['毕节市']
const mapIndex = mapNameList.indexOf(curAreaNameFilter)
mapName = mapList[mapIndex]
}
if (curAreaGrade === 3) {
const mapList = ['bailidujuan', 'dafang', 'hezhang', 'jinhaihu', 'jinsha', 'nayong', 'qianxi', 'qixingguan', 'weining', 'zhijin']
const mapNameList = ['百里杜鹃管理区', '大方县', '赫章县', '金海湖新区', '金沙县', '纳雍县', '黔西市', '七星关区', '威宁县', '织金县']
const mapIndex = mapNameList.indexOf(curAreaNameFilter)
mapName = mapList[mapIndex]
}
if (curAreaGrade === 4) {
const mapList = [50243, 52803, 52117, 52717, 52309, 52503, 52213, 52632, 52419, 52904]
const mapNameList = ['鸭池镇', '普底彝族苗族白族乡', '凤山乡', '双坪乡', '禹谟镇', '居仁街道', '新仁乡', '雪山镇', '官寨乡', '双山镇']
const coordinateJson = require(`@/assets/geojson/coordinate.json`)
const mapIndex = mapNameList.indexOf(curAreaNameFilter)
mapName = mapList[mapIndex]
if (mapName) this.coordinateList = coordinateJson.area.find(item => item.areaCode === mapName).coordinateList
}
if (mapName) map = require(`@/assets/geojson/${mapName}.json`)
const mapData = []
const totalNum = []
const townBgImg = this.$refs.townImg
const townData = [{ name: curAreaName, value: 0 }]
const symbolImgUrl = this.symbolImgUrl
const symbolLabelBgUrl = this.symbolLabelBgUrl
const cityEmphasis = { // 高亮状态(市级)
show: false,
itemStyle: { areaColor: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
{ offset: 0, color: '#FFEC00' },
{ offset: 1, color: '#FF8D01' }
], false) },
label: {
show: true,
position: 'top',
backgroundColor: 'rgba(3, 16, 41, 0.72)',
padding: [8, 16],
borderRadius: 3,
formatter: ['{area|{b}}', '{num|{c}人}', '{pic|}'].join('\n'),
rich: {
area: {
align: 'left',
lineHeight: PXTransformation(0.26),
fontSize: PXTransformation(0.14),
color: '#fff'
},
num: {
align: 'left',
lineHeight: PXTransformation(0.26),
fontSize: PXTransformation(0.18),
color: '#FFBC00'
},
pic: {
height: 68,
width: 120,
backgroundColor: ''
}
}
}
}
const areaEmphasis = { // 高亮状态(区级)
show: false,
itemStyle: { areaColor: 'rgb(255,255,0,1)' },
label: {
show: true,
position: 'top',
backgroundColor: 'rgba(3, 16, 41, 0.72)',
padding: [8, 16],
borderRadius: 3,
formatter: ['{area|{b}}', '{num|{c}人}'].join('\n'),
rich: {
area: {
align: 'left',
lineHeight: PXTransformation(0.26),
fontSize: PXTransformation(0.14),
color: '#fff'
},
num: {
align: 'left',
lineHeight: PXTransformation(0.26),
fontSize: PXTransformation(0.18),
color: '#FFBC00'
}
}
}
}
data.forEach(item => {
let mapColor = 'rgba(0, 133, 255, 0.15)'
const emphasis = curAreaGrade === 2 ? JSON.parse(JSON.stringify(cityEmphasis)) : JSON.parse(JSON.stringify(areaEmphasis))
const mapColorList = ['#F1EA81', '#FBB4B7', '#8FDAFC', '#8DAAFF', '#CCBDFF', '#FFCE68']
if (curAreaGrade === 2) { // 市级
const picName = 'area_' + item.migrantCode + '.jpeg'
emphasis.label.rich.pic.backgroundColor = { image: require(`@/assets/images/map/${picName}`) }
if (item.migrantCode === 520526 || item.migrantCode === 520521) mapColor = mapColorList[0]
if (item.migrantCode === 520527 || item.migrantCode === 520523) mapColor = mapColorList[1]
if (item.migrantCode === 520502 || item.migrantCode === 520522) mapColor = mapColorList[2]
if (item.migrantCode === 520528 || item.migrantCode === 520529) mapColor = mapColorList[3]
if (item.migrantCode === 520525) mapColor = mapColorList[4]
if (item.migrantCode === 520524) mapColor = mapColorList[5]
mapData.push(
{
name: item.content,
value: item.num,
areaCode: item.migrantCode,
selected: false,
itemStyle: { areaColor: mapColor },
label: { show: true, color: '#606266' },
emphasis: emphasis
}
)
}
if (curAreaGrade === 3) { // 区级
totalNum.push(parseInt(item.num))
mapData.push(
{
name: item.content,
value: item.num,
areaCode: item.migrantCode,
selected: false,
itemStyle: { areaColor: mapColor },
label: { show: true, color: '#303133' },
emphasis: emphasis
}
)
}
if (curAreaGrade === 4) { // 乡镇、街道级
const coordinateValue = this.coordinateList.find(son => son.name === item.content) ? this.coordinateList.find(son => son.name === item.content).value : []
mapData.push(
{
name: item.content,
value: coordinateValue,
laborNum: item.num,
areaCode: item.migrantCode,
selected: false
}
)
}
})
const newTotalNum = Array.from(new Set(totalNum))
const minNum = Math.min(...newTotalNum)
const maxNum = Math.max(...newTotalNum)
const cityOption = { // 市级配置
geo: {
map: mapName,
aspectScale: 0.85,
zoom: this.mapZoom, // 当前视角的缩放比例
layoutCenter: ['50%', '50%'], // 地图位置
layoutSize: '100%',
roam: true, // 是否开启平游或缩放
itemStyle: {
normal: {
shadowColor: 'rgba(0, 133, 255, 1)',
areaColor: 'rgba(0, 133, 255, 0.15)',
borderColor: 'rgba(0, 133, 255, 0.5)',
shadowOffsetX: 0,
shadowOffsetY: 15,
opacity: 1
},
emphasis: {
areaColor: 'rgba(0, 133, 255, 0.6)'
}
}
},
series: [
{
type: 'map',
mapType: mapName,
aspectScale: 0.85,
layoutCenter: ['50%', '50%'], // 地图位置
layoutSize: '100%',
zoom: this.mapZoom, // 当前视角的缩放比例
roam: true, // 是否开启平游或缩放
itemStyle: {
areaColor: 'gray',
borderColor: '#BEDBFF',
borderWidth: 1,
emphasis: {
label: { show: false }
}
},
label: {
show: true,
fontSize: this.curAreaGrade === 2 ? PXTransformation(0.16) : PXTransformation(0.12)
},
data: mapData
}
]
}
const areaOption = { // 区级配置
geo: {
map: mapName,
aspectScale: 0.85,
zoom: this.mapZoom, // 当前视角的缩放比例
layoutCenter: ['50%', '50%'], // 地图位置
layoutSize: '100%',
roam: true, // 是否开启平游或缩放
itemStyle: {
normal: {
shadowColor: 'rgba(0, 133, 255, 1)',
areaColor: 'rgba(0, 133, 255, 0.15)',
borderColor: 'rgba(0, 133, 255, 0.5)',
shadowOffsetX: 0,
shadowOffsetY: 15,
opacity: 1
},
emphasis: {
areaColor: 'rgba(0, 133, 255, 0.6)'
}
}
},
visualMap: {
show: true,
bottom: 10,
right: 30,
itemHeight: 90,
min: minNum,
max: maxNum,
text: ['多', '少'],
realtime: false,
calculable: true, // 是否显示拖曳手柄
inRange: { color: ['#00DCFA', '#0B9AFF', '#003FFF'] },
textStyle: {
fontSize: PXTransformation(0.14),
color: '#FFFFFF'
}
},
series: [
{
type: 'map',
mapType: mapName,
aspectScale: 0.85,
layoutCenter: ['50%', '50%'], // 地图位置
layoutSize: '100%',
zoom: this.mapZoom, // 当前视角的缩放比例
roam: true, // 是否开启平游或缩放
itemStyle: {
areaColor: 'gray',
borderColor: '#BEDBFF',
borderWidth: 1,
emphasis: {
label: { show: false }
}
},
label: {
show: true,
fontSize: this.curAreaGrade === 2 ? PXTransformation(0.16) : PXTransformation(0.14)
},
data: mapData
}
]
}
const townOption = { // 乡镇 | 街道级配置
geo: {
map: mapName,
aspectScale: 1.3,
zoom: 1.1, // 当前视角的缩放比例
roam: true, // 是否开启平游或缩放
layoutCenter: ['50%', '50%'], // 地图位置
layoutSize: '100%',
itemStyle: {
normal: {
shadowColor: 'rgba(0, 133, 255, 1)',
areaColor: 'rgba(0, 133, 255, 0.15)',
borderColor: 'rgba(0, 133, 255, 0.5)',
shadowOffsetX: 0,
shadowOffsetY: 15,
opacity: 1
},
emphasis: {
areaColor: 'rgba(0, 133, 255, 0.6)'
}
}
},
series: [
{
type: 'map',
mapType: mapName,
aspectScale: 1.3,
layoutCenter: ['50%', '50%'], // 地图位置
layoutSize: '100%',
zoom: 1.1, // 当前视角的缩放比例
roam: true, // 是否开启平游或缩放
itemStyle: {
borderColor: '#BEDBFF',
borderWidth: 1,
areaColor: {
image: townBgImg,
repeat: 'repeat'
},
emphasis: {
label: { show: false },
areaColor: {
image: townBgImg,
repeat: 'repeat'
}
}
},
label: {
show: false,
fontSize: this.curAreaGrade === 2 ? PXTransformation(0.16) : PXTransformation(0.12)
},
data: townData
},
{
type: 'scatter',
coordinateSystem: 'geo',
itemStyle: { color: '#f00' },
symbol: `image://${symbolImgUrl}`,
symbolSize: [32, 41],
symbolOffset: [0, -20],
z: 9999,
data: mapData
},
{
type: 'scatter',
coordinateSystem: 'geo',
label: {
normal: {
show: true,
formatter: function (params) {
const name = params.name
const value = params.data.laborNum + '人'
const text = `{fline|${value}}\n{tline|${name}}`
return text
},
color: '#fff',
rich: {
fline: {
align: 'center',
lineHeight: PXTransformation(0.2),
fontSize: PXTransformation(0.14),
color: '#fff'
},
tline: {
align: 'center',
padding: [0, 20],
lineHeight: PXTransformation(0.2),
fontSize: PXTransformation(0.16),
color: '#fff'
}
}
},
emphasis: { show: true }
},
itemStyle: { color: '#00FFF6' },
symbol: `image://${symbolLabelBgUrl}`,
symbolSize: [100, 50],
symbolOffset: [0, -60],
z: 999,
data: mapData
},
{
tooltip: { show: false },
type: 'effectScatter',
coordinateSystem: 'geo',
rippleEffect: {
scale: 10,
brushType: 'stroke'
},
showEffectOn: 'render',
itemStyle: {
normal: {
shadowColor: '#0ff',
shadowBlur: 10,
shadowOffsetX: 0,
shadowOffsetY: 0,
color: new echarts.graphic.LinearGradient(1, 0, 0, 0, [
{ offset: 0, color: '#64fbc5' },
{ offset: 1, color: '#018ace' }
])
}
},
label: {
normal: { color: '#fff' }
},
symbol: 'circle',
symbolSize: [10, 5],
data: mapData,
zlevel: 1
}
]
}
let option = {}
if (curAreaGrade === 2) option = cityOption
if (curAreaGrade === 3) option = areaOption
if (curAreaGrade === 4 || curAreaGrade === 5) option = townOption
return { map, mapName, option }
},
// 绘制地图
drawMap(map, mapName, option) {
if (this.mapEchart !== null) this.mapEchart.dispose()
let hourIndex = 0
const mapBox = this.$refs.map
echarts.registerMap(mapName, map)
this.mapEchart = echarts.init(mapBox)
// 捕捉georoam事件,使下层的geo随着上层的geo一起缩放拖曳
this.mapEchart.on('georoam', (params) => {
var option = this.mapEchart.getOption() // 获得option对象
if (params.zoom !== null && params.zoom !== undefined) { // 捕捉到缩放时
option.geo[0].zoom = option.series[0].zoom // 下层geo的缩放等级跟着上层的geo一起改变
option.geo[0].center = option.series[0].center // 下层的geo的中心位置随着上层geo一起改变
} else { // 捕捉到拖曳时
option.geo[0].center = option.series[0].center // 下层的geo的中心位置随着上层geo一起改变
}
this.mapEchart.setOption(option)
})
this.mapEchart.setOption(option)
clearInterval(this.timer)
this.timer = null
if (this.curAreaGrade < 4) {
// 轮播展示下级区域
this.timer = setInterval(() => {
this.mapEchart.dispatchAction({
type: 'downplay',
seriesIndex: 0
})
this.mapEchart.dispatchAction({
type: 'highlight',
seriesIndex: 0,
dataIndex: hourIndex
})
this.mapEchart.dispatchAction({
type: 'showTip',
seriesIndex: 0,
dataIndex: hourIndex
})
hourIndex++
if (hourIndex > option.series[0].data.length) {
hourIndex = 0
}
}, 4000)
// 鼠标移入停止轮播
this.mapEchart.on('mousemove', (e) => {
clearInterval(this.timer)
this.timer = null
this.mapEchart.dispatchAction({
type: 'downplay',
seriesIndex: 0
})
this.mapEchart.dispatchAction({
type: 'highlight',
seriesIndex: 0,
dataIndex: e.dataIndex
})
this.mapEchart.dispatchAction({
type: 'showTip',
seriesIndex: 0,
dataIndex: e.dataIndex
})
})
// 鼠标移出恢复轮播
this.mapEchart.on('mouseout', (e) => {
clearInterval(this.timer)
this.timer = null
this.mapEchart.dispatchAction({
type: 'downplay',
seriesIndex: 0
})
this.timer = setInterval(() => {
this.mapEchart.dispatchAction({
type: 'downplay',
seriesIndex: 0
})
this.mapEchart.dispatchAction({
type: 'highlight',
seriesIndex: 0,
dataIndex: hourIndex
})
this.mapEchart.dispatchAction({
type: 'showTip',
seriesIndex: 0,
dataIndex: hourIndex
})
hourIndex++
if (hourIndex > option.series[0].data.length) {
hourIndex = 0
}
}, 5000)
})
}
// 点击查看详情
this.mapEchart.on('click', (e) => {
if (e.data && e.data.name !== this.curAreaName) {
this.showSecondaryData(e.data)
}
})
},
// 查看次级数据
showSecondaryData(value) {
const { name, areaCode } = value
const grade = this.curAreaGrade === 5 ? this.curAreaGrade : this.curAreaGrade + 1
const lastAreaName = this.curAreaName
const lastAreaCode = this.curAreaID
if (this.curAreaGrade === 5) this.curSelectArea = [areaCode]
if (localStorage.getItem('areaInfoHistoryList')) {
const areaInfoHistoryList = JSON.parse(localStorage.getItem('areaInfoHistoryList'))
if (this.curAreaGrade < 5) areaInfoHistoryList.areaNameList.push(lastAreaName)
if (this.curAreaGrade < 5) areaInfoHistoryList.areaCodeList.push(lastAreaCode)
localStorage.setItem('areaInfoHistoryList', JSON.stringify(areaInfoHistoryList))
} else {
const areaInfoHistoryList = { areaNameList: [lastAreaName], areaCodeList: [lastAreaCode] }
localStorage.setItem('areaInfoHistoryList', JSON.stringify(areaInfoHistoryList))
}
this.$store.commit('user/SET_AREA_ID', areaCode)
this.$store.commit('user/SET_AREA_GRADE', grade)
this.$store.commit('user/SET_AREA_NAME', name)
localStorage.setItem('areaId', areaCode)
localStorage.setItem('areaGrade', grade)
localStorage.setItem('areaName', name)
},
// 区域选择
changeSelectArea() {
const { label, value } = this.$refs.address.getCheckedNodes()[0]
const form = { name: label, areaCode: value }
if (label === '黔西县') form.name = '黔西市'
this.showSecondaryData(form)
}
}
}
</script>
<style lang="less" scoped>
.home_bottomCenter{
position: relative;
width: 100%;
height: 100%;
.map-chart{
width: 100%;
height: 100%;
}
.map-box {
width: 100%;
height: 100%;
}
.select-box {
position: absolute;
top: -0.45rem;
right: 0.05rem;
width: 1.8rem;
>>>.el-input__inner {
border: 1px solid #0570FB;
color: #fff;
background-color: rgba(3, 38, 99, 0.5);
}
}
.svg-chart {
padding: .8rem .03rem 0;
width: 100%;
height: 100%;
}
}
</style>
<template>
<div class="home_leftBottom">
<Vessel vessel-title="文化程度分布" :show-empty="showEmpty">
<template v-slot:chart>
<div ref="pie" class="home_leftBottom_pie" />
</template>
</Vessel>
</div>
</template>
<script>
import Vessel from '@/components/Vessel'
import echarts from 'echarts'
import { getEducationECharts } from '@/api/home'
import { PXTransformation } from '@/utils/util'
export default {
name: 'LeftBottom',
components: {
Vessel
},
data () {
return {
pieChart: null,
showEmpty: false
}
},
computed: {
curAreaID() { // 当前区域ID
return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
},
curAreaGrade() { // 当前区域等级
return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
}
},
watch: {
curAreaID(newV, oldV) {
const params = { areaCode: this.curAreaID }
if (!isNaN(newV)) this.initPage(params)
}
},
created() {
const params = { areaCode: this.curAreaID }
this.initPage(params)
},
methods: {
// 初始化
initPage(params) {
this.getEducation(params)
},
// 获取文化程度数据
async getEducation(params) {
const { data } = await getEducationECharts(params)
const valueData = []
if (data) {
data.forEach(item => {
const name = item.content
const value = parseInt(item.num)
valueData.push({ name, value })
})
this.$nextTick(() => {
this.drawPie(valueData)
})
}
this.showEmpty = data.length === 0
},
drawPie(valueData) {
if (this.pieChart !== null) this.pieChart.dispose()
const mapBox = this.$refs.pie
this.pieChart = echarts.init(mapBox)
const option = {
tooltip: {
confine: true,
formatter: '{a} <br/>{b}: {c}人({d}%'
},
legend: {
type: 'scroll',
itemWidth: PXTransformation(0.16),
textStyle: {
color: '#FFFFFF',
fontSize: PXTransformation(0.16)
},
orient: 'vertical',
right: 10,
top: 40,
bottom: 20
},
color: ['#FFAF09', '#007AFF', '#FFEF00', '#FF9DA0', '#01FEFF', '#9E87FF', '#00C801'],
series: [
{
name: '文化程度',
type: 'pie',
radius: ['40%', '70%'],
center: ['35%', '50%'],
label: { // 饼图图形上的文本标签
normal: {
show: false,
position: 'inner', // 标签的位置
textStyle: {
fontWeight: 400,
fontSize: PXTransformation(0.14) // 文字的字体大小
},
formatter: '{d}%'
}
},
data: valueData
}
]
}
// 构建echarts前先清除原先数据,释放内存
this.pieChart.clear()
if (valueData.length) {
this.pieChart.setOption(option)
}
}
}
}
</script>
<style lang="less" scoped>
.home_leftBottom{
width: 100%;
height: 100%;
.home_leftBottom_pie{
width: 100%;
height: 100%;
}
}
</style>
<template>
<div class="home_leftTop">
<Vessel vessel-title="年龄及性别分布">
<template v-slot:chart>
<div v-if="!showEmpty">
<div class="sexAge_top">
<div>
<div>男性人数:{{ manTotal }}{{ manPercent }})</div>
<div style="marginTop:.04rem">女性人数:{{ womanTotal }}{{ womanPercent }})</div>
</div>
</div>
<div ref="sexAge_bottom" class="sexAge_bottom_chart" />
</div>
<Empty v-if="showEmpty" />
</template>
</Vessel>
</div>
</template>
<script>
import Vessel from '@/components/Vessel'
import echarts from 'echarts'
import { PXTransformation } from '@/utils/util'
import { getAgeECharts } from '@/api/home'
export default {
name: 'LeftTop',
components: {
Vessel
},
data () {
return {
barChart: null,
manTotal: 0,
manPercent: '',
womanTotal: 0,
womanPercent: '',
list: [],
showEmpty: false
}
},
computed: {
curAreaID() { // 当前区域id
return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
},
curAreaGrade() { // 当前区域等级
return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
}
},
watch: {
curAreaID(newV, oldV) {
const params = { areaCode: this.curAreaID }
if (!isNaN(newV)) this.initPage(params)
}
},
created() {
const params = { areaCode: this.curAreaID }
this.initPage(params)
},
methods: {
// 初始化
initPage(params) {
this.getGender(params)
},
// 加载年龄段分布数据
async getGender(params) {
const resData = (await getAgeECharts(params)).data
const labelData = []
const manData = []
const womanData = []
const totalData = []
let manTotal = 0
let womanTotal = 0
let totalNum = 0
resData.forEach((item) => {
const total = parseInt(item.man) + parseInt(item.woman)
manTotal += parseInt(item.man)
womanTotal += parseInt(item.woman)
labelData.push(item.content)
manData.push(parseInt(item.man))
womanData.push(parseInt(item.woman))
totalData.push(total)
})
totalNum = manTotal + womanTotal
this.manTotal = manTotal
this.womanTotal = womanTotal
this.manPercent = (manTotal / totalNum * 100).toFixed(2) + '%'
this.womanPercent = (womanTotal / totalNum * 100).toFixed(2) + '%'
this.$nextTick(() => {
this.drawBar(labelData, manData, womanData, totalData)
})
this.showEmpty = resData.length === 0
},
drawBar(labelData, manData, womanData, totalData) {
if (this.barChart !== null) this.barChart.dispose()
const mapBox = this.$refs.sexAge_bottom
this.barChart = echarts.init(mapBox)
// 指定图表的配置项和数据
const option = {
tooltip: {
trigger: 'axis',
show: true,
axisPointer: {
type: 'shadow'
}
},
legend: {
itemWidth: 10,
itemHeight: 10,
right: '5%',
textStyle: {
color: '#fff',
fontSize: PXTransformation(0.14)
},
data: ['男', '女']
},
grid: {
top: '16%',
left: '1%',
right: '1%',
bottom: '0%',
containLabel: true
},
xAxis: {
type: 'category',
axisTick: {
show: false
},
axisLine: {
lineStyle: {
color: '#54A6FF' // 改变X轴颜色
}
},
axisLabel: {
interval: 0,
rotate: 0,
textStyle: {
color: '#fff', // 这里是改变字体颜色
fontSize: PXTransformation(0.14)
}
},
data: labelData
},
yAxis: {
type: 'value',
axisLine: {
show: false
},
axisTick: {
show: false
},
axisLabel: {
show: false
},
// 网格样式
splitLine: {
lineStyle: {
color: '#02458E'
}
}
},
series: [
{
name: '男',
type: 'bar',
color: '#007FFF',
barWidth: PXTransformation(0.16),
data: manData,
stack: 'total'
},
{
name: '女',
type: 'bar',
color: '#FDEE01',
barWidth: PXTransformation(0.16),
data: womanData,
stack: 'total'
},
{
name: '总数',
type: 'bar',
barGap: '-100%',
barMaxWidth: PXTransformation(0.16),
label: {
normal: {
show: true,
position: 'top',
formatter: '{c}人',
textStyle: {
fontSize: PXTransformation(0.14),
color: '#FFFFFF'
}
}
},
itemStyle: {
normal: {
color: 'rgba(128, 128, 128, 0)'
}
},
data: totalData
}
]
}
// 构建echarts前先清除原先数据,释放内存
this.barChart.clear()
if (manData.length || womanData.length) {
this.barChart.setOption(option)
}
}
}
}
</script>
<style lang="less" scoped>
.home_leftTop{
width: 100%;
height: 100%;
}
.sexAge_top{
width: 100%;
height: .72rem;
background: rgba(5, 19, 76, 0.1);
border: .01rem solid #5BA9FF;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
font-size: .16rem;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #FFFFFF;
}
.sexAge_bottom_chart{
width: 100%;
height: 2.15rem;
}
</style>
<template>
<Vessel vessel-title="参保险种分布" :show-empty="!list.length">
<template v-slot:chart>
<div class="percentage">
<vue-seamless-scroll v-if="list.length" ref="list1" class="scroll" :data="list" :class-option="optionSetting">
<div v-for="(pro, index) in list" :key="index" class="percentage-item">
<div class="label">{{ pro.content }}</div>
<div class="progress" :class="'progress' + index">
<div class="progress_in" :style="'width:' + percent(pro.num) + '%'" />
</div>
<span class="num">{{ pro.num }}</span>
</div>
</vue-seamless-scroll>
</div>
</template>
</Vessel>
</template>
<script>
import Vessel from '@/components/Vessel'
import vueSeamlessScroll from 'vue-seamless-scroll'
import { getOperationMode } from '@/api/employed'
export default {
name: 'LeftBottom',
components: {
Vessel,
vueSeamlessScroll
},
data () {
return {
total: 0,
list: [],
optionSetting: {
step: 0.4, // 滚动速度
openWatch: true
}
}
},
computed: {
curAreaID() { // 当前区域ID
return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
},
curAreaGrade() { // 当前区域等级
return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
}
},
watch: {
curAreaID(newV, oldV) {
if (!isNaN(newV)) {
const params = { areaCode: this.curAreaID }
this.getOperationMode(params)
}
}
},
mounted () {
const params = { areaCode: this.curAreaID }
this.getOperationMode(params)
},
methods: {
// 参保险种分布
async getOperationMode(params) {
this.total = 0
const { data } = await getOperationMode(params)
if (data) {
data.forEach(e => {
this.total += parseInt(e.num)
})
this.list = data
} else {
this.list = []
this.total = 0
}
},
// 百分比计算
percent(value) {
if (parseInt(value) !== 0) {
return (parseInt(value) / this.total * 100).toFixed(2)
} else {
return 0
}
}
}
}
</script>
<style lang="less" scoped>
.percentage {
width: 100%;
height: 100%;
overflow: hidden;
.percentage-item {
display: flex;
.label {
width: 1.5rem;
color: #fff;
font-size: 0.16rem;
line-height: .32rem;
overflow: hidden;
}
.progress {
width: 1.8rem;
height: 0.2rem;
margin-top: .06rem;
position: relative;
background: #62522D;
border-radius: 0.15rem;
border: 1px solid #FF7F02;
.progress_in {
width: 0%;
transition: all 1s ease 0.5s;
height: 100%;
background: linear-gradient(270deg, #FF7F02 0%, #FDC501 100%);
border-radius: 0.15rem;
}
}
.num {
line-height: .36rem;
margin-left: .05rem;
font-size: .16rem;
color: #fff;
}
}
}
</style>
<template>
<div class="home_rightTop">
<Vessel vessel-title="特殊人群类型分布">
<template v-slot:chart>
<div v-if="!showEmpty">
<percentage :list="specialCrowd" />
</div>
<Empty v-if="showEmpty" />
</template>
</Vessel>
</div>
</template>
<script>
import Vessel from '@/components/Vessel'
import percentage from './percentage'
import { getlaborType } from '@/api/home'
export default {
name: 'RightTop',
components: {
Vessel,
percentage
},
data () {
return {
specialCrowd: [],
showEmpty: false
}
},
computed: {
curAreaID() { // 当前区域ID
return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
},
curAreaGrade() { // 当前区域等级
return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
}
},
watch: {
curAreaID(newV, oldV) {
const params = { areaCode: this.curAreaID }
if (!isNaN(newV)) this.initPage(params)
}
},
created() {
const params = { areaCode: this.curAreaID }
this.initPage(params)
},
methods: {
// 初始化
initPage(params) {
this.getlaborType(params)
},
// 特殊人群类型分布
async getlaborType(params) {
const { data } = await getlaborType(params)
const arr = []
let allnum = 0
if (data) {
let arrList = JSON.parse(JSON.stringify(data))
arrList = arrList.filter(item => item.content !== '城镇困难人员' && item.content !== '边缘户劳动力')
arrList.forEach((e, index) => {
if (this.curAreaID === 50211 && e.content === '贫困劳动力') e.content = '脱贫劳动力'
allnum += +e.num
arr.push({ name: e.content, value: e.num })
})
this.specialCrowd = arr
// 计算每个值所占的百分比
this.specialCrowd.forEach(e => {
e.percentage = (e.value / allnum) * 100
})
}
this.showEmpty = this.specialCrowd.length === 0
}
}
}
</script>
<style lang="less" scoped>
.home_rightTop{
width: 100%;
height: 100%;
}
</style>
<template>
<div class="box">
<div class="box-item left">
<div class="bottom-line" />
<div class="labor-force">
<div class="labor-force-num">{{ getTotalLaborNum.totalLaborNum }}</div>
<span class="labor-force-describe">总劳动力人数</span>
</div>
<div class="register-num">
<div>农村户籍人数:</div>
<div>{{ getTotalLaborNum.villageLaborNum }}{{ getTotalLaborNum.villageLaborNum | percent(getTotalLaborNum.totalLaborNum) }}</div>
<div>城镇户籍人数:</div>
<div>{{ getTotalLaborNum.townLaborNum }}{{ getTotalLaborNum.townLaborNum | percent(getTotalLaborNum.totalLaborNum) }}</div>
</div>
<el-tooltip effect="dark" :content="`未知户籍性质人数:${getTotalLaborNum.unknowNaturn}`" placement="top">
<i class="unknow-tip-home el-icon-info" />
</el-tooltip>
</div>
<div class="box-item center">
<div class="bottom-line" />
<div class="center-left">
<div class="center-left-title cursor" @click="pageJump('/first/EmploymentBigData')">已就业人数</div>
<div class="center-left-num cursor" @click="pageJump('/first/EmploymentBigData')">
<countTo class="countTo" :start-val="0" separator="" :end-val="doPioneeringWorkNum.totalWorkNum" :duration="3000" />
</div>
<div>少数民族:{{ doPioneeringWorkNum.ethnicMinorityNum }}%</div>
<div class="count-txt">
<span>男性:{{ doPioneeringWorkNum.manNum | percent(doPioneeringWorkNum.totalWorkNum) }}</span>
<span>女性:{{ doPioneeringWorkNum.womanNum | percent(doPioneeringWorkNum.totalWorkNum) }}</span>
</div>
</div>
<div class="center-center">
<div class="center-center-item">
<div class="item-num">{{ doPioneeringWorkNum.xiannei }}</div>
<div v-show="curAreaGrade === 2" class="item-name">
<div>市内</div>
就业人数
</div>
<div v-show="curAreaGrade >= 3" class="item-name">
<div>县内</div>
就业人数
</div>
</div>
<div class="center-center-item">
<div class="item-num cursor" @click="pageJump('/first/EmploymentAnalysis', { showType: 2 })">{{ doPioneeringWorkNum.xianwai }}</div>
<div v-show="curAreaGrade === 2" class="item-name cursor" @click="pageJump('/first/EmploymentAnalysis', { showType: 2 })">
<div>市外省内</div>
就业人数
</div>
<div v-show="curAreaGrade >= 3" class="item-name cursor" @click="pageJump('/first/EmploymentAnalysis', { showType: 2 })">
<div>县外省内</div>
就业人数
</div>
</div>
<div class="center-center-item">
<div class="item-num cursor" @click="pageJump('/first/EmploymentAnalysis', { showType: 1 })">{{ doPioneeringWorkNum.shengwai }}</div>
<div class="item-name cursor" @click="pageJump('/first/EmploymentAnalysis', { showType: 1 })">
<div>省外</div>
就业人数
</div>
</div>
<el-tooltip effect="dark" :content="`未知就业地人数:${doPioneeringWorkNum.unknowWorkArea}`" placement="top">
<i class="unknow-tip-home el-icon-info" />
</el-tooltip>
</div>
<div class="center-right">
<div class="farm-title">在家务农人数</div>
<div class="farm-num">
<countTo class="countTo" :start-val="0" separator="" :end-val="getNoDoWorkNum.farmerNum" :duration="3000" />
</div>
</div>
</div>
<div class="box-item right">
<div class="bottom-line" />
<div class="right-top">
<div class="unemployed">
<div class="count-title cursor" @click="pageJump('/first/StaffAnalysis')">未就业人数</div>
<div class="unemployed-num cursor" @click="pageJump('/first/StaffAnalysis')">
<countTo class="countTo" :start-val="0" separator="" :end-val="getNoDoWorkNum.onWorkNum" :duration="3000" />
</div>
</div>
<div class="exit">
<div class="count-title">未进入或退出劳动力市场人数</div>
<div class="unemployed-num">
<countTo class="countTo" :start-val="0" separator="" :end-val="getNoDoWorkNum.exitMarketNum" :duration="3000" />
</div>
<el-tooltip effect="dark" placement="left">
<div slot="content">
<p v-for="(item, index) in exitUnknowState" :key="index">
{{ item }}
</p>
</div>
<i class="unknow-tip-home el-icon-info" />
</el-tooltip>
</div>
</div>
<div class="count-txt">未知就业状态人数:{{ getNoDoWorkNum.unknownEmploymentNum }}</div>
</div>
</div>
</template>
<script>
import countTo from 'vue-count-to'
import { getTotalLabor, getDoPioneeringWork, getNoDoWork, getWithoutLaborReason } from '@/api/home'
export default {
name: 'HomeTop',
components: {
countTo
},
filters: {
percent(value, total) {
if (!isNaN((value / total * 100).toFixed(2))) {
return (value / total * 100).toFixed(2) + '%'
}
return '--%'
}
},
data() {
return {
// 就业创业
doPioneeringWorkNum: {
xiannei: 0, // 县内
xianwai: 0, // 县外省内
shengwai: 0, // 省外
womanNum: 0, // 男
manNum: 0, // 女
welfareNum: 0, // 公益性岗位
ethnicMinorityNum: 0, // 少数民族
totalWorkNum: 0, // 就业创业人数
unknowWorkArea: 0 // 未知就业地人数
},
// 毕节市总劳动力
getTotalLaborNum: {
cityLaborNum: 0, // 城市劳动力
totalLaborNum: 0, // 总劳动力
villageLaborNum: 0, // 农村劳动力
townLaborNum: 0, // 城镇劳动力
unknowNaturn: 0 // 户籍性质未知的人数
},
// 暂未就业
getNoDoWorkNum: {
intenNum: 0, // 就业
intenRate: 0, // 有就业人数百分比
onIntenNum: 0, // 未就业
onIntenRate: 0, // 无就业意向人数百分比
onWorkNum: 0, // 暂未就业
wishWorkNum: 0, // 有就业意向
farmerNum: 0, // 在家务农人数
unemploymentNum: 0, // 失业人员人数
exitMarketNum: 0, // 未进入或退出劳动力市场人数
unknownEmploymentNum: 0 // 未知就业状态人数
},
exitUnknowState: [] // 未进入或退出劳动力市场人数未知状态
}
},
computed: {
curAreaID() { // 当前区域ID
return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
},
curAreaGrade() { // 当前区域等级
return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
}
},
watch: {
curAreaID(newV, oldV) {
const params = { areaCode: this.curAreaID }
if (!isNaN(newV)) this.initPage(params)
}
},
mounted() {
const params = { areaCode: this.curAreaID }
this.initPage(params)
},
methods: {
// 初始化
initPage(params) {
this.getNoDoWorkData(params) // 暂未就业人数
this.doPioneeringWorkData(params) // 就业创业人数
this.getTotalLaborData(params) // 毕节市总劳动力
this.getWithoutLaborReason(params) // 退出劳动力原因
},
// 退出劳动力原因
async getWithoutLaborReason(params) {
this.exitUnknowState = []
const { data } = await getWithoutLaborReason(params)
if (data) {
data.forEach(item => {
this.exitUnknowState.push(`${item.content}: ${item.num}`)
})
}
},
// 就业创业人数
async doPioneeringWorkData(params) {
this.doPioneeringWorkNum = {
xiannei: 0, // 县内
xianwai: 0, // 县外省内
shengwai: 0, // 省外
womanNum: '--', // 男
manNum: '--', // 女
welfareNum: 0, // 公益性岗位
ethnicMinorityNum: '--', // 少数民族
totalWorkNum: 0, // 就业创业人数
unknowWorkArea: 0 // 未知就业地人数
}
const { data } = await getDoPioneeringWork(params)
if (data) {
data.forEach(item => {
if (item.content === '市内' || item.content === '县内' || item.content === '乡内') this.doPioneeringWorkNum.xiannei = item.num
if (item.content === '市外省内' || item.content === '县外省内' || item.content === '乡外省内') this.doPioneeringWorkNum.xianwai = item.num
if (item.content === '省外') this.doPioneeringWorkNum.shengwai = item.num
if (item.content === '少数民族') this.doPioneeringWorkNum.ethnicMinorityNum = item.percent
if (item.content === '已就业人数') this.doPioneeringWorkNum.totalWorkNum = item.num
if (item.content === '男') this.doPioneeringWorkNum.manNum = item.num
if (item.content === '女') this.doPioneeringWorkNum.womanNum = item.num
if (item.content === '未知就业地人数') this.doPioneeringWorkNum.unknowWorkArea = item.num || 0
})
const totalNum = parseInt(this.doPioneeringWorkNum.manNum) + parseInt(this.doPioneeringWorkNum.womanNum)
this.doPioneeringWorkNum.manPercent = (parseInt(this.doPioneeringWorkNum.manNum) / totalNum * 100).toFixed(2)
this.doPioneeringWorkNum.womanPercent = (parseInt(this.doPioneeringWorkNum.womanNum) / totalNum * 100).toFixed(2)
}
},
// 就业意向
async getNoDoWorkData(params) {
try {
this.getNoDoWorkNum = {
intenNum: 0, // 就业
intenRate: 0, // 有就业人数百分比
onIntenNum: 0, // 未就业
onIntenRate: 0, // 无就业意向人数百分比
onWorkNum: 0, // 暂未就业
wishWorkNum: 0, // 有就业意向
farmerNum: 0, // 在家务农人数
unemploymentNum: 0, // 失业人员人数
exitMarketNum: 0, // 未进入或退出劳动力市场人数
unknownEmploymentNum: 0 // 未知就业状态人数
}
const resData = (await getNoDoWork(params)).data
if (resData) {
resData.forEach(item => {
if (item.content === '未就业人数') this.getNoDoWorkNum.onWorkNum = parseInt(item.num) || 0
if (item.content === '有就业意向') this.getNoDoWorkNum.wishWorkNum = item.num
if (item.content === '无就业意向') this.getNoDoWorkNum.onIntenNum = item.num
if (item.content === '在家务农人数') this.getNoDoWorkNum.farmerNum = parseInt(item.num) || 0
if (item.content === '失业人员人数') this.getNoDoWorkNum.unemploymentNum = item.num
if (item.content === '未进入或已退出劳动力市场') this.getNoDoWorkNum.exitMarketNum = parseInt(item.num) || 0
if (item.content === '未知就业状态人数') this.getNoDoWorkNum.unknownEmploymentNum = item.num
})
}
} catch (error) {
console.log('error', error)
}
},
// 毕节市总劳动力
async getTotalLaborData(params) {
this.getTotalLaborNum = {
cityLaborNum: 0, // 城市劳动力
totalLaborNum: 0, // 总劳动力
villageLaborNum: 0, // 农村劳动力
unknowNaturn: 0,
townLaborNum: 0 // 城镇劳动力
}
const resData = (await getTotalLabor(params)).data
if (resData) {
resData.forEach(item => {
if (item.content === '毕节市总劳动力') this.getTotalLaborNum.totalLaborNum = item.num
if (item.content === '城市劳动力') this.getTotalLaborNum.cityLaborNum = item.num || 0
if (item.content === '农村劳动力') this.getTotalLaborNum.villageLaborNum = item.num || 0
if (item.content === '城镇劳动力') this.getTotalLaborNum.townLaborNum = item.num || 0
if (item.content === '未知户籍性质人数') this.getTotalLaborNum.unknowNaturn = item.num || 0
})
}
},
// 页面跳转
pageJump(route, query) {
this.$router.push({ path: `${route}`, query })
}
}
}
</script>
<style lang="less" scoped>
.box {
display: flex;
justify-content: space-between;
font-size: .18rem;
.cursor { cursor: pointer }
.count-txt {
position: absolute;
left: 0;
bottom: .23rem;
width: 100%;
text-align: center;
}
.box-item {
position: relative;
height: 2rem;
background: linear-gradient(180deg, #0043BB 0%, rgba(0, 67, 187, 0.8) 100%);
&::after {
content: '';
position: absolute;
left: 0;
top: 0;
width: .62rem;
height: .03rem;
background: #5BA9FF;
}
&::before {
content: '';
position: absolute;
right: 0;
top: 0;
width: .62rem;
height: .03rem;
background: #5BA9FF;
}
.bottom-line {
&::after {
content: '';
position: absolute;
left: 0;
bottom: 0;
width: .62rem;
height: .03rem;
background: #5BA9FF;
}
&::before {
content: '';
position: absolute;
right: 0;
bottom: 0;
width: .62rem;
height: .03rem;
background: #5BA9FF;
}
}
}
.left {
width: 4.26rem;
display: flex;
justify-content: space-around;
align-items: center;
.labor-force {
width: 1.7rem;
height: 1.7rem;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background: url('~@/assets/images/home/home_count_bg.png') no-repeat;
background-size: 100% 100%;
.labor-force-num {
margin-bottom: .1rem;
line-height: .46rem;
font-size: .36rem;
color: #FDEE01;
}
}
.register-num {
width: 2rem;
line-height: .3rem;
div {
&:nth-child(2) {
margin-bottom: .1rem;
}
}
}
}
.right {
position: relative;
width: 4.56rem;
.right-top {
position: relative;
display: flex;
height: 1.5rem;
&::after {
content: '';
position: absolute;
left: 50%;
top: 50%;;
transform: translateX(-50%);
transform: translateY(-50%);
width: .02rem;
height: .75rem;
background: #5BA9FF;
}
.unemployed {
display: flex;
flex-direction: column;
align-items: center;
width: 50%;
margin-top: .12rem;
text-align: center;
.unemployed-num {
height: .6rem;
line-height: .6rem;
font-size: .4rem;
color: #FDEE01;
}
.count-title {
width: 1.5rem;
height: .5rem;
line-height: .5rem;
text-align: center;
}
}
.exit {
width: 50%;
display: flex;
flex-direction: column;
align-items: center;
margin-top: .12rem;
.unemployed-num {
height: .6rem;
line-height: .6rem;
font-size: .4rem;
color: #FDEE01;
}
.count-title {
width: 1.5rem;
height: .5rem;
line-height: .25rem;
text-align: center;
}
}
}
}
.center {
width: 9.6rem;
display: flex;
justify-content: space-between;
.center-left {
position: relative;
width: 3.2rem;
display: flex;
flex-direction: column;
align-items: center;
margin-top: .12rem;
.center-left-title {
height: .5rem;
line-height: .5rem;
}
.center-left-num {
line-height: .6rem;
font-size: .4rem;
color: #FDEE01;
}
}
.center-center {
position: relative;
width: 4.5rem;
padding: .24rem .15rem 0;
display: flex;
justify-content: space-around;
align-items: flex-start;
&::after {
content: '';
position: absolute;
left: 0;
top: 50%;
transform: translateY(-50%);
width: .02rem;
height: 1.62rem;
background: #5BA9FF;
}
&::before {
content: '';
position: absolute;
right: 0;
top: 50%;
transform: translateY(-50%);
width: .02rem;
height: 1.62rem;
background: #5BA9FF;
}
.center-center-item {
position: relative;
width: .97rem;
height: 1.04rem;
background: url('~@/assets/images/home/home_light.png') no-repeat;
background-size: 100% 100%;
text-align: center;
.item-num {
font-size: .24rem;
}
.item-name {
position: absolute;
top: 100%;
left: 50%;
transform: translateX(-50%);
width: 1.5rem;
}
}
}
.center-right {
width: 1.87rem;
display: flex;
flex-direction: column;
align-items: center;
margin-top: .12rem;
.farm-title {
height: .5rem;
line-height: .5rem;
}
.farm-num {
line-height: .6rem;
font-size: .4rem;
color: #FDEE01;
}
}
}
}
</style>
<template>
<div class="percentage">
<div
v-for="(pro,index) in list"
:key="index"
>
<div :class="{ 'progress': true, 'cursor': pro.name !== '低保家庭' }" @click="pageJump(pro.name)">
<span class="index">{{ index+1 }}</span>
<span class="label">{{ pro.name }}</span>
<div
class="progress_in"
:style="'width:'+(pro.percentage)+'%'"
/>
<span class="num">{{ pro.value }}</span>
</div>
</div>
</div>
</template>
<script>
export default {
props: {
list: {
type: Array,
default: () => { [] }
}
},
data() {
return {
}
},
methods: {
// 页面跳转
pageJump(type) {
let route = ''
if (type === '脱贫劳动力') route = '/outPoverty'
if (type === '易地扶贫搬迁人员') route = '/relocating'
if (type === '残疾人') route = '/disabilities'
if (type === '退伍军人') route = '/Veterans'
if (type === '高校毕业生') route = '/graduates'
if (route) this.$router.push({ path: `${route}` })
}
}
}
</script>
<style lang="less" scoped>
.percentage {
width: 100%;
padding-top: 0.16rem;
.progress {
width: 78%;
height: 0.32rem;
background: url('../../../assets/images/home/home_progress.png') no-repeat center center;
background-size: 100% 100%;
position: relative;
margin-left: 0.2rem;
margin-bottom: 0.24rem;
&.cursor { cursor: pointer }
.progress_in {
width: 0%;
transition: all 1s ease 0.5s;
height: 100%;
background-color: rgba(253, 238, 1, 0.4);
// margin-left: .13rem;
}
.index {
position: absolute;
left: -0.15rem;
top: -0.03rem;
width: .35rem;
height: .35rem;
background: url('../../../assets/images/home/home_progressicon.png') no-repeat center center;
background-size: 100% 100%;
text-align: center;
line-height: .35rem;
font-size: .18rem;
}
.label {
position: absolute;
left: .4rem;
top: 0.05rem;
max-width: 2rem;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
color: #fff;
font-size: .16rem;
}
.num {
position: absolute;
left: 105%;
top: 0.05rem;
font-size: .16rem;
color: #fff;
}
}
}
</style>
<template>
<div class="home">
<!-- 顶部统计 -->
<div class="top">
<top />
</div>
<!-- 图表统计 -->
<div class="chart">
<div class="chart-left">
<div class="chart-left-top">
<Left-top />
</div>
<div class="chart-left-bottom">
<Left-bottom />
</div>
</div>
<div class="chart-center" />
<div class="chart-right">
<div class="chart-right-top">
<Right-top />
</div>
<div class="chart-right-bottom">
<Right-bottom />
</div>
</div>
</div>
</div>
</template>
<script>
import Top from './components/Top'
import LeftTop from './components/LeftTop'
import LeftBottom from './components/LeftBottom'
import RightTop from './components/RightTop'
import RightBottom from './components/RightBottom'
export default {
name: 'Home',
components: {
Top,
LeftTop,
LeftBottom,
RightTop,
RightBottom
},
data() {
return {}
}
}
</script>
<style lang="less" scoped>
.home {
width: 100%;
height: 9.3rem;
padding: 0 .18rem;
color: #fff;
.top {
height: 2rem;
margin-bottom: .16rem;
}
.chart {
height: 7rem;
display: flex;
justify-content: space-between;
&>div { // 临时标记,开发时去掉
box-sizing: border-box;
}
.chart-left {
width: 4.5rem;
.chart-left-top {
width: 4.5rem;
height: 3.55rem;
}
.chart-left-bottom {
width: 4.5rem;
height: 3.25rem;
margin-top: .16rem;
}
}
.chart-center {
width: 9.56rem;
}
.chart-right {
width: 4.5rem;
.chart-right-top {
width: 4.5rem;
height: 4.15rem;
}
.chart-right-bottom {
width: 4.5rem;
height: 2.655rem;
margin-top: .16rem;
}
}
}
}
</style>
<template>
<div>
<div class="message-list">
<!-- tab -->
<section class="m-tab">
<div :class="{ 'tab-btn': true, 'active': curActiveTab === 'send' }" @click="changeActiveTab('send')">我发布的消息</div>
<div :class="{ 'tab-btn': true, 'active': curActiveTab === 'receive' }" @click="changeActiveTab('receive')">我收到的消息</div>
</section>
<!-- search -->
<section class="m-search">
<el-form ref="searchForm" :model="searchForm" label-width="120px">
<el-row>
<el-col :span="5">
<el-form-item label="任务类型">
<el-select v-model="searchForm.taskType" placeholder="请选择任务类型" clearable style="width: 100%">
<el-option v-for="item in taskList" :key="item.type" :label="item.name" :value="item.type" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="5">
<el-form-item label="任务标题">
<el-input v-model.trim="searchForm.taskTitle" placeholder="请输入任务标题" />
</el-form-item>
</el-col>
<el-col :span="7">
<el-form-item label="发布日期">
<el-date-picker
v-model="releaseTime"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd"
style="width:100%"
suffix-icon="el-icon-date"
clearable
/>
</el-form-item>
</el-col>
<el-col :span="7">
<el-form-item class="m-btns" label-width="0">
<el-button type="primary" :loading="tableLoading" @click="searchVisitorRecord">查询</el-button>
<el-button type="primary" @click="addMsgDrawer = true">发布新消息</el-button>
<el-button type="primary" plain @click="reVisitor">重置</el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
</section>
<!-- table -->
<section class="m-table">
<el-table
v-loading="tableLoading"
border
stripe
:data="lsitData"
:header-cell-style="tableHeadStyle"
:cell-style="tableCellStyle"
>
<el-table-column
align="center"
label="序号"
width="70"
type="index"
:index="(index)=>{return (index+1) + (curPage-1)*pageSize}"
/>
<el-table-column align="center" prop="taskType" label="任务类型" width="100" show-overflow-tooltip />
<el-table-column align="center" prop="publisher" label="发布人" show-overflow-tooltip />
<el-table-column align="center" prop="taskTitle" label="任务标题" show-overflow-tooltip />
<el-table-column align="center" prop="messageContent" label="任务内容" show-overflow-tooltip />
<el-table-column align="center" prop="sendTargetNum" label="发送对象数" show-overflow-tooltip />
<!-- <el-table-column align="center" label="状态" show-overflow-tooltip>
<template slot-scope="scope">
<span v-if="scope.row.telephone === 1">{{ scope.row.telephone }}</span>
<span v-else>{{ scope.row.telephone }}</span>
</template>
</el-table-column> -->
<el-table-column align="center" prop="residenceAddressDetail" label="发布时间" show-overflow-tooltip />
<el-table-column align="center" label="操作">
<template slot-scope="scope">
<el-button type="primary" size="small" @click="showMsgDetails(scope.row)">详情</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="curPage"
:limit.sync="pageSize"
layout="total, sizes, prev, pager, next, jumper"
@pagination="pageChange"
/>
</section>
</div>
<!-- 新增消息 -->
<el-drawer custom-class="drawer-add" title="新增消息" size="40%" :wrapper-closable="false" :visible.sync="addMsgDrawer">
<!-- 任务列表 -->
<section class="task-list">
<div
v-for="item of taskList"
:key="item.type"
:class="{ 'task-item': true, 'chosed': addMsgForm.taskType === item.type }"
@click="choseTaskType(item.type)"
>{{ item.name }}</div>
</section>
<!-- 表单 -->
<el-form ref="addMsgForm" :model="addMsgForm" label-width="0" class="form_addmsg">
<el-form-item prop="taskTitle">
<el-input
v-model="addMsgForm.taskTitle"
maxlength="40"
show-word-limit
clearable
placeholder="请输入任务标题"
/>
</el-form-item>
<el-form-item prop="taskTitle">
<!-- <el-cascader
ref="address"
v-model="addMsgForm.areaCodes"
clearable
:props="dynamicProps"
placeholder="请选择接收人"
style="width: 100%"
@change="handleAddress"
/> -->
</el-form-item>
<el-form-item prop="messageContent">
<el-input
v-model="addMsgForm.messageContent"
type="textarea"
maxlength="1000"
show-word-limit
clearable
placeholder="请输入消息内容"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="sendNewMessage('ruleForm')">发送</el-button>
</el-form-item>
</el-form>
</el-drawer>
<!-- 消息详情 -->
<el-drawer custom-class="drawer-details" title="消息详情" size="40%" :wrapper-closable="false" :visible.sync="showMsgDrawer">
<span>消息详情</span>
</el-drawer>
</div>
</template>
<script>
import Pagination from '@/components/Pagination'
import { getAreaDictionary } from '@/api/user'
import { getSendMsg, getMsgDetails } from '@/api/Message'
export default {
name: 'PersonaPortrait',
components: { Pagination },
data() {
return {
tableLoading: false,
pageSize: 10,
curPage: 1, // 底部标签当前页码
total: 4,
curActiveTab: 'receive', // 当前激活tab
releaseTime: [], // 发布时间
searchForm: {
startDate: '', // 发布开始时间
endDate: '', // 发布结束时间
taskTitle: '', // 任务标题
taskType: '' // 任务类型
},
addMsgForm: {
taskTitle: '', // 任务标题
taskType: '1', // 任务类型
messageContent: '', // 消息内容
areaCodes: [],
publisher: '', // 发布人(区域名称)
publisherAccount: '', // 发布人账号(登录账号)
publisherAreaCode: '', // 发布人所属区域编码
publisherAreaLevel: '' // 发布人所属区域等级
},
lsitData: [
{
'ifReaded': '0',
'messageContent': '新功能内测中,感谢您的配合,敬请期待。',
'publishTime': '2022-02-28 09:26:47',
'publisher': '毕节市',
'publisherAccount': 'analysis',
'taskId': '22',
'taskTitle': 'news ',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '测试内容',
'publishTime': '2022-02-28 01:58:59',
'publisher': '毕节市',
'publisherAccount': 'analysis',
'taskId': '21',
'taskTitle': '任务3',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '测试内容',
'publishTime': '2022-02-28 01:54:16',
'publisher': '毕节市',
'publisherAccount': 'analysis',
'taskId': '20',
'taskTitle': '任务2',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '新功能内测中,感谢您的配合,敬请期待。',
'publishTime': '2022-02-26 18:31:56',
'publisher': '管理员',
'publisherAccount': 'analysis',
'taskId': '19',
'taskTitle': '新消息',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '新功能内测中,感谢您的配合,敬请期待。',
'publishTime': '2022-02-25 09:55:41',
'publisher': '管理员',
'publisherAccount': 'analysis',
'taskId': '18',
'taskTitle': '新消息',
'taskType': '1'
}
],
tableHeadStyle: { // 表头样式
padding: '.12rem 0',
textAlign: 'center',
fontSize: 14,
color: '#393d41',
backgroundColor: '#e3ebf7'
},
tableCellStyle: { // 列表单元格样式
color: '#525963',
padding: '.12rem 0 .11rem'
},
addMsgDrawer: false, // 抽屉:新增消息
showMsgDrawer: false, // 抽屉:消息详情
taskList: [ // 任务列表
]
}
},
computed: {
// curAreaID() { // 当前区域code
// return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
// },
// curAreaGrade() { // 当前区域等级
// return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
// },
// dynamicProps() { // 接收人所属区域
// return {
// lazy: true,
// lazyLoad: async(node, resolve) => {
// let nodes = []
// const curAreaCode = this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
// const searchCode = node.value ? node.value : curAreaCode
// nodes = await this.getAreaDictionary(searchCode)
// resolve(nodes)
// },
// checkStrictly: true,
// emitPath: false
// }
// }
},
created() {
// this.initPage()
},
methods: {
// 初始化
initPage() {
this.searchForm.areaCode = this.curAreaID
this.searchForm.areaCodeLevel = this.curAreaGrade
this.getSendMsgList()
},
// 获取“我发布的消息”列表
async getSendMsgList() {
this.tableLoading = true
const page = this.curPage
const size = this.pageSize
const form = Object.assign(this.searchForm, { page, size })
const { data } = await getSendMsg(form)
if (data) {
this.lsitData = data.list
this.total = data.total
}
this.tableLoading = false
},
// 获取消息详情
async getMsgDetails(id) {
const { data } = await getMsgDetails(id)
if (data) {
console.log(data, '消息详情')
}
},
// 处理区域字典
async getAreaDictionary(areaCode) {
let result = []
const { data } = await getAreaDictionary(areaCode)
result = data.map((item) => ({
label: item.name,
value: item.id,
leaf: item.level > 4
}))
return result
},
// 查询
searchVisitorRecord() {
this.getSendMsgList()
},
// 重置
reVisitor() {
this.$refs.searchForm.resetFields()
this.curPage = 1
this.total = 0
this.searchForm = {
startDate: '',
endDate: '',
taskTitle: '',
taskType: ''
}
this.getSendMsgList()
},
// 查看消息详情
showMsgDetails(row) {
this.showMsgDrawer = true
const id = row.id
this.getMsgDetails(id)
},
// 改变当前页
pageChange(e) {
const page = e.page
const size = e.limit
this.curPage = page
this.pageSize = size
this.getUserList()
},
// 切换当前查看列表
changeActiveTab(type) {
this.curActiveTab = type
},
// 选择任务类型
choseTaskType(type) {
this.addMsgForm.taskType = type
},
handleAddress(value) {
console.log(value)
},
// 发送新消息
sendNewMessage() {}
}
}
</script>
<style lang="less" scoped>
.message-list {
width: 100%;
height: 100%;
padding: 0 0.2rem;
overflow: auto;
.m-tab {
display: flex;
margin-bottom: 0.16rem;
height: 0.36rem;
line-height: 0.36rem;
text-align: center;
font-size: 0.16rem;
font-weight: 400;
color: #525963;
cursor: pointer;
user-select: none;
.tab-btn {
width: 1.4rem;
background-color: #FFFFFF;
&:first-of-type { border-radius: 0.06rem 0 0 0 }
&:last-of-type { border-radius: 0 0.06rem 0 0 }
&.active {
color: #fff;
background-color: #4191ff;
}
}
}
.m-search {
margin-bottom: 0.16rem;
padding: 0.16rem 0.2rem 0.16rem 0;
background-color: #eef2f8;
.el-row {
.el-form-item {
margin-bottom: 0.12rem;
&.m-btns {
text-align: right;
.el-button {
padding: 0.1rem 0.25rem;
}
}
}
&:last-of-type {
.el-form-item { margin-bottom: 0 }
}
}
}
}
/deep/.pagination-container {
text-align: right;
.el-pagination__total { color: #fff }
.el-pagination__jump { color: #fff }
}
/deep/.el-drawer {
&.drawer-add,
&.drawer-details {
background-color: #F6FAFF;
background: url('~@/assets/images/message/drawer_msg_bg.png') no-repeat;
background-size: 100% 100%;
.el-drawer__header {
position: relative;
margin-bottom: .3rem;
height: 1rem;
padding: 0;
span {
display: block;
position: absolute;
left: .6rem;
bottom: 0;
line-height: .33rem;
font-size: .24rem;
font-weight: 500;
color: #0065FF;
user-select: none;
}
.el-drawer__close-btn {
position: absolute;
top: .3rem;
right: .31rem;
font-weight: 700;
font-size: .32rem;
color: #333;
}
}
.el-drawer__body {
padding: 0 .6rem;
.task-list {
display: flex;
flex-flow: row wrap;
justify-content: space-between;
align-items: center;
margin-bottom: .3rem;
.task-item {
position: relative;
width: 2rem;
height: .8rem;
padding: 0.45rem 0.2rem 0.15rem;
box-sizing: border-box;
border-radius: .08rem;
background: #FFFFFF;
border: 1px solid #C1C1C1;
line-height: .2rem;
font-size: .14rem;
font-weight: 500;
color: #666;
cursor: pointer;
user-select: none;
&::after {
position: absolute;
left: .2rem;
top: .15rem;
content: url('~@/assets/images/message/icon_msg_task_g.png');
width: .15rem;
height: .2rem;
}
&:hover {
border-color: #0065FF;
color: #0065FF;
}
&.chosed {
background: #0065FF;
border-color: #0065FF;
color: #fff;
&::after { content: url('~@/assets/images/message/icon_msg_task_w.png') }
}
}
}
.el-form {
&.form_addmsg {
.el-form-item {
margin-bottom: .2rem;
.el-input__inner,
.el-textarea__inner {
border-radius: 4px;
border: 1px solid #C1C1C1;
line-height: .36rem;
font-size: .14rem;
color: #333;
}
&:nth-of-type(1) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(2) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(3) {
margin-bottom: .4rem;
.el-textarea__inner {
height: 4.42rem;
resize: none;
}
}
&:last-of-type {
margin-bottom: 0;
.el-button {
width: 1.4rem;
padding: 0.1rem 0.2rem;
background-color: #0065FF;
border-color: #0065FF;
}
}
}
}
}
}
}
&.drawer-add {
.el-drawer__body {
padding: 0 .6rem;
.task-list {
display: flex;
flex-flow: row wrap;
justify-content: space-between;
align-items: center;
margin-bottom: .3rem;
.task-item {
position: relative;
width: 2rem;
height: .8rem;
padding: 0.45rem 0.2rem 0.15rem;
box-sizing: border-box;
border-radius: .08rem;
background: #FFFFFF;
border: 1px solid #C1C1C1;
line-height: .2rem;
font-size: .14rem;
font-weight: 500;
color: #666;
cursor: pointer;
user-select: none;
&::after {
position: absolute;
left: .2rem;
top: .15rem;
content: url('~@/assets/images/message/icon_msg_task_g.png');
width: .15rem;
height: .2rem;
}
&:hover {
border-color: #0065FF;
color: #0065FF;
}
&.chosed {
background: #0065FF;
border-color: #0065FF;
color: #fff;
&::after { content: url('~@/assets/images/message/icon_msg_task_w.png') }
}
}
}
.el-form {
&.form_addmsg {
.el-form-item {
margin-bottom: .2rem;
.el-input__inner,
.el-textarea__inner {
border-radius: 4px;
border: 1px solid #C1C1C1;
line-height: .36rem;
font-size: .14rem;
color: #333;
}
&:nth-of-type(1) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(2) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(3) {
margin-bottom: .4rem;
.el-textarea__inner {
height: 4.42rem;
resize: none;
}
}
&:last-of-type {
margin-bottom: 0;
.el-button {
width: 1.4rem;
padding: 0.1rem 0.2rem;
background-color: #0065FF;
border-color: #0065FF;
}
}
}
}
}
}
}
&.drawer-details {
.el-drawer__body {
padding: 0 .6rem;
}
}
}
</style>
<template>
<div>
<div class="message-list">
<!-- tab -->
<section class="m-tab">
<div :class="{ 'tab-btn': true, 'active': curActiveTab === 'send' }" @click="changeActiveTab('send')">我发布的消息</div>
<div :class="{ 'tab-btn': true, 'active': curActiveTab === 'receive' }" @click="changeActiveTab('receive')">我收到的消息</div>
</section>
<!-- search -->
<section class="m-search">
<el-form ref="searchForm" :model="searchForm" label-width="120px">
<el-row>
<el-col :span="5">
<el-form-item label="任务类型">
<el-select v-model="searchForm.taskType" placeholder="请选择任务类型" clearable style="width: 100%">
<el-option v-for="item in taskList" :key="item.type" :label="item.name" :value="item.type" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="5">
<el-form-item label="任务标题">
<el-input v-model.trim="searchForm.taskTitle" placeholder="请输入任务标题" />
</el-form-item>
</el-col>
<el-col :span="7">
<el-form-item label="发布日期">
<el-date-picker
v-model="releaseTime"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd"
style="width:100%"
suffix-icon="el-icon-date"
clearable
/>
</el-form-item>
</el-col>
<el-col :span="7">
<el-form-item class="m-btns" label-width="0">
<el-button type="primary" :loading="tableLoading" disabled @click="searchVisitorRecord">查询</el-button>
<el-button type="primary" @click="addMsgDrawer = true">发布新消息</el-button>
<el-button type="primary" plain @click="reVisitor">重置</el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
</section>
<!-- table -->
<section class="m-table">
<el-table
v-loading="tableLoading"
border
stripe
:data="lsitData"
:header-cell-style="tableHeadStyle"
:cell-style="tableCellStyle"
>
<el-table-column
align="center"
label="序号"
width="70"
type="index"
:index="(index)=>{return (index+1) + (curPage-1)*pageSize}"
/>
<el-table-column align="center" prop="taskType" label="任务类型" width="100" show-overflow-tooltip />
<el-table-column align="center" prop="publisher" label="发布人" show-overflow-tooltip />
<el-table-column align="center" prop="taskTitle" label="任务标题" show-overflow-tooltip />
<el-table-column align="center" prop="messageContent" label="任务内容" show-overflow-tooltip />
<el-table-column align="center" prop="sendTargetNum" label="发送对象数" show-overflow-tooltip />
<!-- <el-table-column align="center" label="状态" show-overflow-tooltip>
<template slot-scope="scope">
<span v-if="scope.row.telephone === 1">{{ scope.row.telephone }}</span>
<span v-else>{{ scope.row.telephone }}</span>
</template>
</el-table-column> -->
<el-table-column align="center" prop="residenceAddressDetail" label="发布时间" show-overflow-tooltip />
<el-table-column align="center" label="操作">
<template slot-scope="scope">
<el-button type="primary" size="small" @click="showMsgDetails(scope.row)">详情</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="curPage"
:limit.sync="pageSize"
layout="total, sizes, prev, pager, next, jumper"
@pagination="pageChange"
/>
</section>
</div>
<!-- 新增消息 -->
<el-drawer custom-class="drawer-add" title="新增消息" size="40%" :wrapper-closable="false" :visible.sync="addMsgDrawer">
<!-- 任务列表 -->
<section class="task-list">
<div
v-for="item of taskList"
:key="item.type"
:class="{ 'task-item': true, 'chosed': addMsgForm.taskType === item.type }"
@click="choseTaskType(item.type)"
>{{ item.name }}</div>
</section>
<!-- 表单 -->
<el-form ref="addMsgForm" :model="addMsgForm" label-width="0" class="form_addmsg">
<el-form-item prop="taskTitle">
<el-input
v-model="addMsgForm.taskTitle"
maxlength="40"
show-word-limit
clearable
placeholder="请输入任务标题"
/>
</el-form-item>
<el-form-item prop="taskTitle">
<!-- <el-cascader
ref="address"
v-model="addMsgForm.areaCodes"
clearable
:props="dynamicProps"
placeholder="请选择接收人"
style="width: 100%"
@change="handleAddress"
/> -->
</el-form-item>
<el-form-item prop="messageContent">
<el-input
v-model="addMsgForm.messageContent"
type="textarea"
maxlength="1000"
show-word-limit
clearable
placeholder="请输入消息内容"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="sendNewMessage('ruleForm')">发送</el-button>
</el-form-item>
</el-form>
</el-drawer>
<!-- 消息详情 -->
<el-drawer custom-class="drawer-details" title="消息详情" size="40%" :wrapper-closable="false" :visible.sync="showMsgDrawer">
<span>消息详情</span>
</el-drawer>
</div>
</template>
<script>
import Pagination from '@/components/Pagination'
import { getAreaDictionary } from '@/api/user'
import { getSendMsg, getMsgDetails } from '@/api/Message'
export default {
name: 'PersonaPortrait',
components: { Pagination },
data() {
return {
tableLoading: false,
pageSize: 10,
curPage: 1, // 底部标签当前页码
total: 4,
curActiveTab: 'receive', // 当前激活tab
releaseTime: [], // 发布时间
searchForm: {
startDate: '', // 发布开始时间
endDate: '', // 发布结束时间
taskTitle: '', // 任务标题
taskType: '' // 任务类型
},
addMsgForm: {
taskTitle: '', // 任务标题
taskType: '1', // 任务类型
messageContent: '', // 消息内容
areaCodes: [],
publisher: '', // 发布人(区域名称)
publisherAccount: '', // 发布人账号(登录账号)
publisherAreaCode: '', // 发布人所属区域编码
publisherAreaLevel: '' // 发布人所属区域等级
},
lsitData: [
{
'ifReaded': '0',
'messageContent': '新功能内测中,感谢您的配合,敬请期待。',
'publishTime': '2022-02-28 09:26:47',
'publisher': '毕节市',
'publisherAccount': 'analysis',
'taskId': '22',
'taskTitle': 'news ',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '测试内容',
'publishTime': '2022-02-28 01:58:59',
'publisher': '毕节市',
'publisherAccount': 'analysis',
'taskId': '21',
'taskTitle': '任务3',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '测试内容',
'publishTime': '2022-02-28 01:54:16',
'publisher': '毕节市',
'publisherAccount': 'analysis',
'taskId': '20',
'taskTitle': '任务2',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '新功能内测中,感谢您的配合,敬请期待。',
'publishTime': '2022-02-26 18:31:56',
'publisher': '管理员',
'publisherAccount': 'analysis',
'taskId': '19',
'taskTitle': '新消息',
'taskType': '1'
}, {
'ifReaded': '1',
'messageContent': '新功能内测中,感谢您的配合,敬请期待。',
'publishTime': '2022-02-25 09:55:41',
'publisher': '管理员',
'publisherAccount': 'analysis',
'taskId': '18',
'taskTitle': '新消息',
'taskType': '1'
}
],
tableHeadStyle: { // 表头样式
padding: '.12rem 0',
textAlign: 'center',
fontSize: 14,
color: '#393d41',
backgroundColor: '#e3ebf7'
},
tableCellStyle: { // 列表单元格样式
color: '#525963',
padding: '.12rem 0 .11rem'
},
addMsgDrawer: false, // 抽屉:新增消息
showMsgDrawer: false, // 抽屉:消息详情
taskList: [ // 任务列表
]
}
},
computed: {
// curAreaID() { // 当前区域code
// return this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
// },
// curAreaGrade() { // 当前区域等级
// return this.$store.getters.curAreaGrade || parseInt(localStorage.getItem('areaGrade'))
// },
// dynamicProps() { // 接收人所属区域
// return {
// lazy: true,
// lazyLoad: async(node, resolve) => {
// let nodes = []
// const curAreaCode = this.$store.getters.curAreaID || parseInt(localStorage.getItem('areaId'))
// const searchCode = node.value ? node.value : curAreaCode
// nodes = await this.getAreaDictionary(searchCode)
// resolve(nodes)
// },
// checkStrictly: true,
// emitPath: false
// }
// }
},
created() {
// this.initPage()
},
methods: {
// 初始化
initPage() {
this.searchForm.areaCode = this.curAreaID
this.searchForm.areaCodeLevel = this.curAreaGrade
this.getSendMsgList()
},
// 获取“我发布的消息”列表
async getSendMsgList() {
this.tableLoading = true
const page = this.curPage
const size = this.pageSize
const form = Object.assign(this.searchForm, { page, size })
const { data } = await getSendMsg(form)
if (data) {
this.lsitData = data.list
this.total = data.total
}
this.tableLoading = false
},
// 获取消息详情
async getMsgDetails(id) {
const { data } = await getMsgDetails(id)
if (data) {
console.log(data, '消息详情')
}
},
// 处理区域字典
async getAreaDictionary(areaCode) {
let result = []
const { data } = await getAreaDictionary(areaCode)
result = data.map((item) => ({
label: item.name,
value: item.id,
leaf: item.level > 4
}))
return result
},
// 查询
searchVisitorRecord() {
this.getSendMsgList()
},
// 重置
reVisitor() {
this.$refs.searchForm.resetFields()
this.curPage = 1
this.total = 0
this.searchForm = {
startDate: '',
endDate: '',
taskTitle: '',
taskType: ''
}
this.getSendMsgList()
},
// 查看消息详情
showMsgDetails(row) {
this.showMsgDrawer = true
const id = row.id
this.getMsgDetails(id)
},
// 改变当前页
pageChange(e) {
const page = e.page
const size = e.limit
this.curPage = page
this.pageSize = size
this.getUserList()
},
// 切换当前查看列表
changeActiveTab(type) {
this.curActiveTab = type
},
// 选择任务类型
choseTaskType(type) {
this.addMsgForm.taskType = type
},
handleAddress(value) {
console.log(value)
},
// 发送新消息
sendNewMessage() {}
}
}
</script>
<style lang="less" scoped>
.message-list {
width: 100%;
height: 100%;
padding: 0 0.2rem;
overflow: auto;
.m-tab {
display: flex;
margin-bottom: 0.16rem;
height: 0.36rem;
line-height: 0.36rem;
text-align: center;
font-size: 0.16rem;
font-weight: 400;
color: #525963;
cursor: pointer;
user-select: none;
.tab-btn {
width: 1.4rem;
background-color: #FFFFFF;
&:first-of-type { border-radius: 0.06rem 0 0 0 }
&:last-of-type { border-radius: 0 0.06rem 0 0 }
&.active {
color: #fff;
background-color: #4191ff;
}
}
}
.m-search {
margin-bottom: 0.16rem;
padding: 0.16rem 0.2rem 0.16rem 0;
background-color: #eef2f8;
.el-row {
.el-form-item {
margin-bottom: 0.12rem;
&.m-btns {
text-align: right;
.el-button {
padding: 0.1rem 0.25rem;
}
}
}
&:last-of-type {
.el-form-item { margin-bottom: 0 }
}
}
}
}
/deep/.pagination-container {
text-align: right;
.el-pagination__total { color: #fff }
.el-pagination__jump { color: #fff }
}
/deep/.el-drawer {
&.drawer-add,
&.drawer-details {
background-color: #F6FAFF;
background: url('~@/assets/images/message/drawer_msg_bg.png') no-repeat;
background-size: 100% 100%;
.el-drawer__header {
position: relative;
margin-bottom: .3rem;
height: 1rem;
padding: 0;
span {
display: block;
position: absolute;
left: .6rem;
bottom: 0;
line-height: .33rem;
font-size: .24rem;
font-weight: 500;
color: #0065FF;
user-select: none;
}
.el-drawer__close-btn {
position: absolute;
top: .3rem;
right: .31rem;
font-weight: 700;
font-size: .32rem;
color: #333;
}
}
.el-drawer__body {
padding: 0 .6rem;
.task-list {
display: flex;
flex-flow: row wrap;
justify-content: space-between;
align-items: center;
margin-bottom: .3rem;
.task-item {
position: relative;
width: 2rem;
height: .8rem;
padding: 0.45rem 0.2rem 0.15rem;
box-sizing: border-box;
border-radius: .08rem;
background: #FFFFFF;
border: 1px solid #C1C1C1;
line-height: .2rem;
font-size: .14rem;
font-weight: 500;
color: #666;
cursor: pointer;
user-select: none;
&::after {
position: absolute;
left: .2rem;
top: .15rem;
content: url('~@/assets/images/message/icon_msg_task_g.png');
width: .15rem;
height: .2rem;
}
&:hover {
border-color: #0065FF;
color: #0065FF;
}
&.chosed {
background: #0065FF;
border-color: #0065FF;
color: #fff;
&::after { content: url('~@/assets/images/message/icon_msg_task_w.png') }
}
}
}
.el-form {
&.form_addmsg {
.el-form-item {
margin-bottom: .2rem;
.el-input__inner,
.el-textarea__inner {
border-radius: 4px;
border: 1px solid #C1C1C1;
line-height: .36rem;
font-size: .14rem;
color: #333;
}
&:nth-of-type(1) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(2) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(3) {
margin-bottom: .4rem;
.el-textarea__inner {
height: 4.42rem;
resize: none;
}
}
&:last-of-type {
margin-bottom: 0;
.el-button {
width: 1.4rem;
padding: 0.1rem 0.2rem;
background-color: #0065FF;
border-color: #0065FF;
}
}
}
}
}
}
}
&.drawer-add {
.el-drawer__body {
padding: 0 .6rem;
.task-list {
display: flex;
flex-flow: row wrap;
justify-content: space-between;
align-items: center;
margin-bottom: .3rem;
.task-item {
position: relative;
width: 2rem;
height: .8rem;
padding: 0.45rem 0.2rem 0.15rem;
box-sizing: border-box;
border-radius: .08rem;
background: #FFFFFF;
border: 1px solid #C1C1C1;
line-height: .2rem;
font-size: .14rem;
font-weight: 500;
color: #666;
cursor: pointer;
user-select: none;
&::after {
position: absolute;
left: .2rem;
top: .15rem;
content: url('~@/assets/images/message/icon_msg_task_g.png');
width: .15rem;
height: .2rem;
}
&:hover {
border-color: #0065FF;
color: #0065FF;
}
&.chosed {
background: #0065FF;
border-color: #0065FF;
color: #fff;
&::after { content: url('~@/assets/images/message/icon_msg_task_w.png') }
}
}
}
.el-form {
&.form_addmsg {
.el-form-item {
margin-bottom: .2rem;
.el-input__inner,
.el-textarea__inner {
border-radius: 4px;
border: 1px solid #C1C1C1;
line-height: .36rem;
font-size: .14rem;
color: #333;
}
&:nth-of-type(1) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(2) {
.el-input__inner { height: .36rem }
}
&:nth-of-type(3) {
margin-bottom: .4rem;
.el-textarea__inner {
height: 4.42rem;
resize: none;
}
}
&:last-of-type {
margin-bottom: 0;
.el-button {
width: 1.4rem;
padding: 0.1rem 0.2rem;
background-color: #0065FF;
border-color: #0065FF;
}
}
}
}
}
}
}
&.drawer-details {
.el-drawer__body {
padding: 0 .6rem;
}
}
}
</style>
const path = require('path')
const resolve = dir => path.join(__dirname, dir)
const isProduction = process.env.NODE_ENV === 'production'
const defaultSettings = require('./src/common/networkConfig.js')
const productionGzip = defaultSettings.isUseGzip // 是否使用gzip
// const UglifyJsPlugin = require("uglifyjs-webpack-plugin");
const port =
process.env.port || process.env.npm_config_port || defaultSettings.port // dev port
const name = defaultSettings.title || '' // page title
// gzip压缩
const CompressionWebpackPlugin = require('compression-webpack-plugin')
// const productionGzipExtensions = /\.(js|css|json|txt|html|ico|svg)(\?.*)?$/i
const SkeletonWebpackPlugin = require('vue-skeleton-webpack-plugin')
const skeletonRroutes = require('./src/skeleton/routes-skeleton')
module.exports = {
/* 部署生产环境和开发环境下的URL:*/
publicPath: '/',
/* 输出文件目录:在npm run build时,生成文件的目录名称 */
outputDir: defaultSettings.buildFile,
/* 放置生成的静态资源 (js、css、img、fonts) 的 (相对于 outputDir 的) 目录 */
assetsDir: defaultSettings.StaticFile,
/* 代码保存时进行eslint检测 */
lintOnSave: process.env.NODE_ENV === 'development',
/* 是否在构建生产包时生成 sourceMap 文件,false将提高构建速度 */
productionSourceMap: defaultSettings.isSourceMap,
/* webpack-dev-server 相关配置*/
devServer: {
/* 端口设置 */
port: port,
/* 自动打开浏览器 */
open: true,
/* 在浏览器上全屏显示编译的errors或warnings 默认是关闭的*/
overlay: {
warnings: false,
errors: true
},
/* 使用代理 */
proxy: defaultSettings.proxy
},
css: {
loaderOptions: {
postcss: {
plugins: [
// require('postcss-pxtorem')({
// rootValue: 20, // 换算的基数
// // 忽略转换正则匹配项。插件会转化所有的样式的px。比如引入了三方UI,也会被转化。目前我使用 selectorBlackList字段,来过滤
// // 如果个别地方不想转化px。可以简单的使用大写的 PX 或 Px 。
// selectorBlackList: ['ig'],
// propList: ['*'],
// exclude: /node_modules/
// })
]
}
},
// 使用 css 分离插件 mini-css-extract-plugin,不然骨架屏组件里的 <style> 不起作用,
extract: defaultSettings.isSkeleton
},
/* webpack打包配置 */
configureWebpack: config => {
/* 主页名字设置 */
config.name = name
/* 忽略打包配置 */
// config.externals = defaultSettings.externalsBuild
// 打包gzip压缩
if (isProduction && productionGzip) {
config.plugins.push(
new CompressionWebpackPlugin({
test: /\.(js|css|json|txt|html|ico|svg)(\?.*)?$/i,
threshold: 8192, // 只有大小大于该值的资源会被处理
minRatio: 0.8, // 只有压缩率小于这个值的资源才会被处理
deleteOriginalAssets: defaultSettings.isDelOriFile // 删除原文件
})
)
}
},
/* 对内部的 webpack 配置进行更细粒度的修改 */
chainWebpack: config => {
config.resolve.alias.set('@', resolve('src'))
/* 对内部的 webpack 配置进行更细粒度的修改 */
if (defaultSettings.isSkeleton) {
config.plugin('SkeletonWebpackPlugin').use(SkeletonWebpackPlugin, [
{
webpackConfig: {
entry: {
app: path.resolve(__dirname, './src/skeleton/entry-skeleton.js')
}
},
// 服务端渲染时是否需要输出信息到控制台
quiet: true,
// SPA 下是压缩注入 HTML 的 JS 代码
minimize: true,
// 根据路由显示骨架屏
router: skeletonRroutes.router
}
])
}
// /* 添加CND 使用*/
// const cdn = {
// /* css CND路径*/
// css: defaultSettings.CssCdn,
// js: defaultSettings.jsCdn
// }
// /* 设置 主页index.html 的参数配置,例如注入CND */
// if (defaultSettings.isCdn) {
// config.plugin('html').tap(args => {
// args[0].cdn = cdn
// return args
// })
// }
// 打包优化,去除console.log
config.when(isProduction, config => {
config.optimization.minimizer('terser').tap(args => {
// 注释console.*
args[0].terserOptions.compress.drop_console = true
// remove debugger
args[0].terserOptions.compress.drop_debugger = true
// 移除 console.log
args[0].terserOptions.compress.pure_funcs = ['console.log']
return args
})
})
config.output.filename('assets/js/[name].[hash].js').chunkFilename('assets/js/[name].[hash].js').end()
if (isProduction) {
// 作用:压缩图片
// PS:建议cnpm安装, npm因为墙的原因可能安装不上一些依赖
config.module
.rule('images')
.use('image-webpack-loader')
.loader('image-webpack-loader')
.options({ bypassOnDebug: true })
.end()
}
/* 设置代码分割插件的配置对引入库代码进行代码的分割进行优化 代码分割后的每一个js文件即为Chunk */
if (isProduction) {
config
.plugin('ScriptExtHtmlWebpackPlugin')
.after('html')
.use('script-ext-html-webpack-plugin', [{
// `runtime` must same as runtimeChunk name. default is `runtime`
inline: /runtime\..*\.js$/
}])
.end()
config.optimization.splitChunks = {
cacheGroups: {
common: {
name: 'common',
chunks: 'initial',
minChunks: 2,
maxInitialRequests: 5,
minSize: 0,
priority: 1,
reuseExistingChunk: true,
enforce: true
},
vendors: {
name: 'chunk-libs',
test: /[\\/]node_modules[\\/]/,
chunks: 'initial',
priority: 2,
reuseExistingChunk: true,
enforce: true
}
}
}
config.optimization.runtimeChunk('single')
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment