Commit 98fcf58a authored by 沈翠玲's avatar 沈翠玲

客户报告临时提交

parent 4a4db135
...@@ -26,4 +26,12 @@ export const saveContract = (data) => { ...@@ -26,4 +26,12 @@ export const saveContract = (data) => {
// 合同批量审核 // 合同批量审核
export const flowStatusByIds = (data) => { export const flowStatusByIds = (data) => {
return request.get('/Contract/flowStatusByIds', data); return request.get('/Contract/flowStatusByIds', data);
};
// 发起客户报告
export const sendReport = (id) => {
return request.get('/customerReport/sendReport?customerId=' + id);
};
// 根据id获取客户详情
export const getByIdcustomerReport = (id) => {
return request.get('/customerReport/getById?id=' + id);
}; };
\ No newline at end of file
import * as echarts from "echarts/core"; import * as echarts from "echarts/core";
import { BarChart, LineChart, LinesChart, PieChart, ScatterChart, RadarChart, GaugeChart } from "echarts/charts"; import { BarChart, LineChart, LinesChart, PieChart, ScatterChart, RadarChart, GaugeChart, MapChart } from "echarts/charts";
import { import {
TitleComponent, TitleComponent,
TooltipComponent, TooltipComponent,
...@@ -8,6 +8,7 @@ import { ...@@ -8,6 +8,7 @@ import {
TransformComponent, TransformComponent,
LegendComponent, LegendComponent,
PolarComponent, PolarComponent,
VisualMapComponent,
GeoComponent, GeoComponent,
ToolboxComponent, ToolboxComponent,
DataZoomComponent DataZoomComponent
...@@ -53,6 +54,7 @@ echarts.use([ ...@@ -53,6 +54,7 @@ echarts.use([
EffectScatterChart, EffectScatterChart,
TitleComponent, TitleComponent,
TooltipComponent, TooltipComponent,
VisualMapComponent,
GridComponent, GridComponent,
DatasetComponent, DatasetComponent,
TransformComponent, TransformComponent,
...@@ -63,6 +65,7 @@ echarts.use([ ...@@ -63,6 +65,7 @@ echarts.use([
DataZoomComponent, DataZoomComponent,
BarChart, BarChart,
LineChart, LineChart,
MapChart,
LinesChart, LinesChart,
PieChart, PieChart,
ScatterChart, ScatterChart,
......
...@@ -11,169 +11,424 @@ import echarts, { ECOption } from "@/components/ECharts/config"; ...@@ -11,169 +11,424 @@ import echarts, { ECOption } from "@/components/ECharts/config";
import ECharts from "@/components/ECharts/index.vue"; import ECharts from "@/components/ECharts/index.vue";
import mapJson from "../assets/china.json"; import mapJson from "../assets/china.json";
echarts.registerMap("china", mapJson as Parameters<typeof echarts.registerMap>[1]); // echarts.registerMap("china", mapJson as Parameters<typeof echarts.registerMap>[1]);
var geoCoordMap = { // var geoCoordMap = {
台湾: [121.5135, 25.0308], // 台湾: [121.5135, 25.0308],
哈尔滨: [127.9688, 45.368], // 哈尔滨: [127.9688, 45.368],
内蒙古: [110.3467, 41.4899], // 内蒙古: [110.3467, 41.4899],
吉林: [125.8154, 44.2584], // 吉林: [125.8154, 44.2584],
北京市: [116.4551, 40.2539], // 北京市: [116.4551, 40.2539],
沈阳: [123.1238, 42.1216], // 沈阳: [123.1238, 42.1216],
石家庄: [114.4995, 38.1006], // 石家庄: [114.4995, 38.1006],
天津: [117.4219, 39.4189], // 天津: [117.4219, 39.4189],
山西: [112.3352, 37.9413], // 山西: [112.3352, 37.9413],
西安: [109.1162, 34.2004], // 西安: [109.1162, 34.2004],
甘肃: [103.5901, 36.3043], // 甘肃: [103.5901, 36.3043],
宁夏: [106.3586, 38.1775], // 宁夏: [106.3586, 38.1775],
青海: [101.4038, 36.8207], // 青海: [101.4038, 36.8207],
新疆: [87.9236, 43.5883], // 新疆: [87.9236, 43.5883],
西藏: [91.11, 29.97], // 西藏: [91.11, 29.97],
成都: [103.9526, 30.7617], // 成都: [103.9526, 30.7617],
重庆: [108.384366, 30.439702], // 重庆: [108.384366, 30.439702],
青岛: [117.1582, 36.8701], // 青岛: [117.1582, 36.8701],
河南: [113.4668, 34.6234], // 河南: [113.4668, 34.6234],
江苏: [118.8062, 31.9208], // 江苏: [118.8062, 31.9208],
安徽: [117.29, 32.0581], // 安徽: [117.29, 32.0581],
武汉: [114.3896, 30.6628], // 武汉: [114.3896, 30.6628],
浙江: [119.5313, 29.8773], // 浙江: [119.5313, 29.8773],
福州: [119.4543, 25.9222], // 福州: [119.4543, 25.9222],
江西: [116.0046, 28.6633], // 江西: [116.0046, 28.6633],
湖南: [113.0823, 28.2568], // 湖南: [113.0823, 28.2568],
贵州: [106.6992, 26.7682], // 贵州: [106.6992, 26.7682],
云南: [102.9199, 25.4663], // 云南: [102.9199, 25.4663],
广州: [113.12244, 23.009505], // 广州: [113.12244, 23.009505],
广西: [108.479, 23.1152], // 广西: [108.479, 23.1152],
海南: [110.3893, 19.8516], // 海南: [110.3893, 19.8516],
上海: [121.4648, 31.2891], // 上海: [121.4648, 31.2891],
}; // };
var convertData = function(data) { // var convertData = function(data) {
var res = []; // var res = [];
for (var i = 0; i < data.length; i++) { // for (var i = 0; i < data.length; i++) {
var geoCoord = geoCoordMap[data[i].name]; // var geoCoord = geoCoordMap[data[i].name];
if (geoCoord) { // if (geoCoord) {
res.push({ // res.push({
name: data[i].name, // name: data[i].name,
value: geoCoord.concat(data[i].value), // value: geoCoord.concat(data[i].value),
}); // });
} // }
} // }
return res; // return res;
}; // };
var data = [ var mapData = [{
{name:"北京市",value:300}, name: "北京",
{name:"石家庄",value:300}, devicesCount: 100, //总数
{name:"沈阳",value:300}, feiyue1: 40, //肺悦1个数
{name:"哈尔滨",value:300}, feiyue2: 60, //肺悦2个数
{name:"青岛",value:100}, value: 10, //使用个数
{name:"成都",value:200}, devicesUseLv: '40%', //使用率
{name:"武汉",value:250}, },
{name:"西安",value:270}, {
{name:"广州",value:300}, name: "天津",
{name:"福州",value:300} devicesCount: 50,
]; feiyue1: 40,
const option: ECOption = { feiyue2: 60,
tooltip: { value: 20,
trigger: "item", devicesUseLv: '20%',
formatter: function (params, ticket, callback) { },
if (params.seriesType == "effectScatter") { {
console.log('params', params) name: "上海",
return params.data.name + ":" devicesCount: 80,
+ params.data.name + '调解中心' + '<br />' feiyue1: 40,
+ '案件总数:' + params.data.value[2] + '<br />' feiyue2: 60,
+ '案件总金额:' + params.data.value[2]; value: 30,
} else { devicesUseLv: '20%',
return params.name; },
} {
} name: "重庆",
}, devicesCount: 90,
grid: { feiyue1: 40,
left: "0px", feiyue2: 60,
right: "80px", value: 40,
top: "10px", devicesUseLv: '20%',
bottom: "10px" },
}, {
geo: { name: "河北",
map: "china", devicesCount: 130,
label: { feiyue1: 40,
emphasis: { feiyue2: 60,
show: false, value: 50,
color: "#fff" devicesUseLv: '20%',
},
{
name: "河南",
devicesCount: 160,
feiyue1: 40,
feiyue2: 60,
value: 80,
devicesUseLv: '20%',
},
{
name: "云南",
devicesCount: 110,
feiyue1: 40,
feiyue2: 60,
value: 40,
devicesUseLv: '20%',
},
{
name: "辽宁",
devicesCount: 320,
feiyue1: 40,
feiyue2: 60,
value: 120,
devicesUseLv: '20%',
},
{
name: "黑龙江",
devicesCount: 80,
feiyue1: 40,
feiyue2: 60,
value: 40,
devicesUseLv: '20%',
},
{
name: "湖南",
devicesCount: 60,
feiyue1: 40,
feiyue2: 60,
value: 10,
devicesUseLv: '20%',
},
{
name: "安徽",
devicesCount: 300,
feiyue1: 40,
feiyue2: 60,
value: 270,
devicesUseLv: '20%',
},
{
name: "山东",
devicesCount: 50,
feiyue1: 40,
feiyue2: 60,
value: 9,
devicesUseLv: '20%',
},
{
name: "新疆",
devicesCount: 40,
feiyue1: 40,
feiyue2: 60,
value: 0,
devicesUseLv: '20%',
},
{
name: "江苏",
devicesCount: 240,
feiyue1: 40,
feiyue2: 60,
value: 40,
devicesUseLv: '20%',
},
{
name: "浙江",
devicesCount: 450,
feiyue1: 40,
feiyue2: 60,
value: 300,
devicesUseLv: '20%',
},
{
name: "江西",
devicesCount: 20,
feiyue1: 40,
feiyue2: 60,
value: 4,
devicesUseLv: '20%',
},
{
name: "湖北",
devicesCount: 50,
feiyue1: 40,
feiyue2: 60,
value: 40,
devicesUseLv: '20%',
},
{
name: "广西",
devicesCount: 10,
feiyue1: 40,
feiyue2: 60,
value: 0,
devicesUseLv: '20%',
},
{
name: "甘肃",
devicesCount: 20,
feiyue1: 40,
feiyue2: 60,
value: 1,
devicesUseLv: '20%',
},
{
name: "山西",
devicesCount: 230,
feiyue1: 40,
feiyue2: 60,
value: 140,
devicesUseLv: '20%',
},
{
name: "内蒙古",
devicesCount: 200,
feiyue1: 40,
feiyue2: 60,
value: 0,
devicesUseLv: '20%',
},
{
name: "陕西",
devicesCount: 30,
feiyue1: 40,
feiyue2: 60,
value: 40,
devicesUseLv: '20%',
},
{
name: "吉林",
devicesCount: 77,
feiyue1: 40,
feiyue2: 60,
value: 40,
devicesUseLv: '20%',
},
{
name: "福建",
devicesCount: 55,
feiyue1: 40,
feiyue2: 60,
value: 8,
devicesUseLv: '20%',
},
{
name: "贵州",
devicesCount: 55,
feiyue1: 40,
feiyue2: 60,
value: 7,
devicesUseLv: '20%',
},
{
name: "广东省",
devicesCount: 44,
feiyue1: 40,
feiyue2: 60,
value: 6,
devicesUseLv: '20%',
},
{
name: "青海",
devicesCount: 33,
feiyue1: 40,
feiyue2: 60,
value: 5,
devicesUseLv: '20%',
},
{
name: "西藏",
devicesCount: 10,
feiyue1: 40,
feiyue2: 60,
value: 4,
devicesUseLv: '20%',
},
{
name: "四川",
devicesCount: 99,
feiyue1: 40,
feiyue2: 60,
value: 20,
devicesUseLv: '20%',
},
{
name: "宁夏",
devicesCount: 145,
feiyue1: 40,
feiyue2: 60,
value: 40,
devicesUseLv: '20%',
}, },
normal: { {
show: false, name: "海南",
color: "#fff" devicesCount: 122,
feiyue1: 40,
feiyue2: 60,
value: 90,
devicesUseLv: '20%',
}, },
{
name: "台湾",
devicesCount: 10,
feiyue1: 4,
feiyue2: 6,
value: 0,
devicesUseLv: '20%',
},
{
name: "香港",
devicesCount: 0,
feiyue1: 0,
feiyue2: 0,
value: 0,
devicesUseLv: '0%',
},
{
name: "澳门",
devicesCount: 0,
feiyue1: 0,
feiyue2: 0,
value: 0,
devicesUseLv: '0%',
}
];
const option: ECOption = {
tooltip: {
show: true,
formatter: function(params) {
if(params.value){
return '&nbsp;&nbsp;' + params.name + '&nbsp;&nbsp;&nbsp;' + params.value + '个&nbsp;&nbsp;';
}else{
return '&nbsp;&nbsp;' + params.name + '&nbsp;&nbsp;&nbsp;0个&nbsp;&nbsp;';
}
}
},
visualMap: {
min: 0,
left: 26,
bottom: 40,
showLabel: !0,
text: ["高", "低"],
pieces: [{
gt: 200,
label: "1 - 9 人",
color: "#8616fe"
}, {
gt: 100,
lt: 200,
label: "疑似",
color: "#6b1dfd"
}, {
value: 0,
color: "rbga(255, 255, 255, 0.5)"
}],
show: !0
}, },
// 放大我们的地图 geo: {
zoom: 1.2, map: 'china',
itemStyle: { show: true,
normal: { roam: false,
areaColor: "rgba(43, 196, 243, 0.42)", label: {
borderColor: "rgba(43, 196, 243, 1)", emphasis: {
borderWidth: 1 show: false
}, },
emphasis: { normal: {
areaColor: "#2B91B7" show: false
}
},
itemStyle: {
normal: {
show: false
}
} }
}
}, },
series: [ series: [
{ {
name: '散点', name: "确诊病例",
type: 'scatter', type: "map",
coordinateSystem: 'geo', map: 'china',
data: convertData(data), aspectScale: 0.75,
zoom:1.3,
label: { label: {
normal: { normal: {
formatter: '{b}', formatter: function(para) {
position: 'right', return '{name|' + para.name + '}'
show: true, },
fontSize: 16, rich: {
color: '#fff' cnNum: {
fontSize: 11,
color: '#333333',
align: 'center',
},
name: {
fontSize: 11,
color: '#333333',
align: 'center',
lineHeight: 20,
},
},
//formatter: '{b}',
color: '#333333',
show: true
}, },
emphasis: { emphasis: {
show: true show: true,
} }
}, },
itemStyle: { itemStyle: {
normal: { normal: {
color: '#fff' areaColor: '#D9EEFF',
borderColor: '#fff',
borderWidth: 1,
},
emphasis: {
areaColor: '#FFAE00',
} }
} },
}, data: mapData
{
name: 'Top 5',
type: 'effectScatter',
coordinateSystem: 'geo',
data: convertData(data.sort(function(a, b) {
return b.value - a.value;
})),
symbolSize: function(val) {
return val[2] / 10;
},
showEffectOn: 'render',
rippleEffect: {
brushType: 'stroke'
},
hoverAnimation: true,
label: {
normal: {
formatter: '{b}',
position: 'left',
show: false
}
},
itemStyle: {
normal: {
color: '#fff',
shadowBlur: 10,
shadowColor: '#fff'
}
},
zlevel: 1
} }
] ]
}; };
......
.dataScreen-container { .dataScreen-container {
width: 100%; width: 100%;
height: 100%; height: 100%;
background: #00204b; background: #140f59;
.dataScreen-content { .dataScreen-content {
position: fixed; position: fixed;
top: 50%; top: 50%;
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
>新建网贷&信用贷</el-button >新建网贷&信用贷</el-button
> --> > -->
<el-button type="primary" @click="pushCustomer()">新建客户</el-button> <el-button type="primary" @click="pushCustomer()">新建客户</el-button>
<el-button type="primary">发起风控审核</el-button> <!-- <el-button type="primary">发起风控审核</el-button> -->
</template> </template>
</ProTable> </ProTable>
</div> </div>
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
<script setup lang="jsx" name="platformManage"> <script setup lang="jsx" name="platformManage">
import { ref, reactive, onMounted } from 'vue'; import { ref, reactive, onMounted } from 'vue';
import { Plus, Delete, Edit, Setting } from '@element-plus/icons-vue'; import { Plus, Delete, Edit, Setting } from '@element-plus/icons-vue';
import { getCustomerPage } from '@/api/customer'; import { getCustomerPage, sendReport } from '@/api/customer';
import { ElMessageBox, ElMessage, ElButton, ElTag } from 'element-plus'; import { ElMessageBox, ElMessage, ElButton, ElTag } from 'element-plus';
import { useRouter } from 'vue-router'; import { useRouter } from 'vue-router';
...@@ -59,6 +59,22 @@ ...@@ -59,6 +59,22 @@
query: { id: 44 }, //这里不能直接写成 query: JSON.stringify(item) query: { id: 44 }, //这里不能直接写成 query: JSON.stringify(item)
}); });
}; };
const send = async (e, row) => {
e.stopPropagation()
await ElMessageBox.confirm(`是否分起客户名称为${row.name},身份证号为${row.idCard},创建时间为${row.createTime}的风控审核?`, '提示', {
confirmButtonText: '确认',
cancelButtonText: '取消',
type: 'warning',
});
sendReport(row.id).then(res => {
if (res.success) {
router.push({
path: '/infoGather/dangerReport/dangerReportDetail',
query: res.result ? { id: res.result.id }: {}, //这里不能直接写成 query: JSON.stringify(item)
});
}
})
}
const onCellClick = ({ row, rowIndex }) => { const onCellClick = ({ row, rowIndex }) => {
pushCustomer(row) pushCustomer(row)
} }
...@@ -67,7 +83,7 @@ ...@@ -67,7 +83,7 @@
onCheckboxAll: onCheckboxAll, onCheckboxAll: onCheckboxAll,
onCellClick: onCellClick, onCellClick: onCellClick,
columns: [ columns: [
{ type: 'checkbox', width: 60,fixed: 'left' }, // { type: 'checkbox', width: 60,fixed: 'left' },
{ field: 'name', title: '客户名称', search: { labelWidth: 85, el: 'input' } }, { field: 'name', title: '客户名称', search: { labelWidth: 85, el: 'input' } },
{ {
field: 'createTime', field: 'createTime',
...@@ -89,6 +105,22 @@ ...@@ -89,6 +105,22 @@
{ field: 'reserveWorkUnit', title: '预留工作单位', search: { labelWidth: 85, el: 'input' } }, { field: 'reserveWorkUnit', title: '预留工作单位', search: { labelWidth: 85, el: 'input' } },
{ field: 'reserveAddress', title: '预留家庭地址', search: { labelWidth: 85, el: 'input' } }, { field: 'reserveAddress', title: '预留家庭地址', search: { labelWidth: 85, el: 'input' } },
{ field: 'remark', title: '备注', search: { labelWidth: 85, el: 'input' } }, { field: 'remark', title: '备注', search: { labelWidth: 85, el: 'input' } },
{
field: 'code',
title: '操作',
width: 100,
slots: {
default: ({ row, rowIndex }) => {
return (
<>
<ElButton type="primary" onClick={(e) => send(e, row)}>
发起风控审核
</ElButton>
</>
);
},
},
},
], ],
}); });
......
...@@ -266,6 +266,7 @@ ...@@ -266,6 +266,7 @@
import { ElButton, ElTag, ElMessage } from 'element-plus'; import { ElButton, ElTag, ElMessage } from 'element-plus';
import { useRoute } from 'vue-router'; import { useRoute } from 'vue-router';
import { useRouter } from 'vue-router'; import { useRouter } from 'vue-router';
import { getByIdcustomerReport } from '@/api/customer';
import { ref, reactive, onBeforeMount } from 'vue'; import { ref, reactive, onBeforeMount } from 'vue';
const form = ref({ const form = ref({
status: '' status: ''
...@@ -313,10 +314,16 @@ const cancel = () => { ...@@ -313,10 +314,16 @@ const cancel = () => {
}); });
} }
const query = async (type) => { const query = async (type) => {
const id = JSON.parse(route.query.id); getByIdcustomerReport(route.query.id).then(res => {
if(res.success) {
form.value = res.result
}
})
} }
onBeforeMount(async () => { onBeforeMount(async () => {
query() if (route.query.id) {
query()
}
}) })
const cardConfig = reactive({ const cardConfig = reactive({
minHeight: 200, minHeight: 200,
......
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 to comment