diff --git a/jsite-core/src/main/resources/views/modules/sys/sysIndex.html b/jsite-core/src/main/resources/views/modules/sys/sysIndex.html index 5e57debde598ae5fa6e4cd5f595bb7083638e3dc..af58c69519893a07bf7533ab6a2a79f07766667b 100644 --- a/jsite-core/src/main/resources/views/modules/sys/sysIndex.html +++ b/jsite-core/src/main/resources/views/modules/sys/sysIndex.html @@ -19,7 +19,7 @@ var bodyClass = 'fixed sidebar-mini ' + skinName;
-
+
diff --git a/jsite-framework/src/main/resources/views/modules/sys/sysIndex/sysDesktop.html b/jsite-framework/src/main/resources/views/modules/sys/sysIndex/sysDesktop.html index 9e781466b744434242928eaae8dae0f5a574a4c4..a793021fd380b01a724eb23749bcf3ce00346068 100644 --- a/jsite-framework/src/main/resources/views/modules/sys/sysIndex/sysDesktop.html +++ b/jsite-framework/src/main/resources/views/modules/sys/sysIndex/sysDesktop.html @@ -144,27 +144,27 @@ 部门 -
+
-
+
    -
  • 项目中心
  • -
  • 质量监察部
  • -
  • 集成服务事业部
  • -
  • 营销部
  • -
  • 东郊机房运维项目
  • -
  • 配电室运维项目
  • -
  • 电科院机房运维项目
  • +
  • +
  • +
  • +
  • +
  • +
  • +
@@ -306,90 +306,106 @@ // console.log(json.officeName + "=====" + json.wagesRealTotal); var PieData = [ { - value : result["总经办"] ? result["总经办"].wagesRealTotal : "0", + value : result["总经办"] ? changeMoney(result["总经办"].wagesRealTotal) : 0, color : '#f56954',//red highlight: '#f56954', label : result["总经办"] ? result["总经办"].officeName : "总经办" }, { - value : result["财务部"] ? result["财务部"].wagesRealTotal : "0", + value : result["财务部"] ? changeMoney(result["财务部"].wagesRealTotal) : 0, color : '#00a65a',//green highlight: '#00a65a', label : result["财务部"] ? result["财务部"].officeName : "财务部" }, { - value : result["东郊机房运维项目"] ? result["东郊机房运维项目"].wagesRealTotal : "0", + value : result["东郊机房运维项目"] ? changeMoney(result["东郊机房运维项目"].wagesRealTotal) : 0, color : '#f39c12',//yellow highlight: '#f39c12', label : result["东郊机房运维项目"] ? result["东郊机房运维项目"].officeName : "东郊机房运维项目" }, { - value : result["配电室运维项目"] ? result["配电室运维项目"].wagesRealTotal : "0", + value : result["配电室运维项目"] ? changeMoney(result["配电室运维项目"].wagesRealTotal) : 0, color : '#00c0ef',//aqua highlight: '#00c0ef', label : result["配电室运维项目"] ? result["配电室运维项目"].officeName : "配电室运维项目" }, { - value : result["电科院机房运维项目"] ? result["电科院机房运维项目"].wagesRealTotal : "0", + value : result["电科院机房运维项目"] ? changeMoney(result["电科院机房运维项目"].wagesRealTotal) : 0, color : '#72bdef',//aqua highlight: '#72bdef', label : result["电科院机房运维项目"] ? result["电科院机房运维项目"].officeName : "电科院机房运维项目" }, { - value : result["行政部"] ? result["行政部"].wagesRealTotal : "0", + value : result["行政部"] ? changeMoney(result["行政部"].wagesRealTotal) : 0, color : '#3c8dbc',//light bule highlight: '#3c8dbc', label : result["行政部"] ? result["行政部"].officeName : "行政部" }, { - value : result["商务部"] ? result["商务部"].wagesRealTotal : "0", + value : result["商务部"] ? changeMoney(result["商务部"].wagesRealTotal) : 0, color : '#6F00D2',//purple highlight: '#6F00D2', label : result["商务部"] ? result["商务部"].officeName : "商务部" }, { - value : result["人力资源部"] ? result["人力资源部"].wagesRealTotal : "0", + value : result["人力资源部"] ? changeMoney(result["人力资源部"].wagesRealTotal) : 0, color : '#d2d6de',//gray highlight: '#d2d6de', label : result["人力资源部"] ? result["人力资源部"].officeName : "人力资源部" }, { - value : result["事业部"] ? result["事业部"].wagesRealTotal : "0", + value : result["事业部"] ? changeMoney(result["事业部"].wagesRealTotal) : 0, color : '#f012be', highlight: '#f012be', label : result["事业部"] ? result["事业部"].officeName : "事业部" }, { - value : result["项目中心"] ? result["项目中心"].wagesRealTotal : "0", + value : result["项目一部"] ? changeMoney(result["项目一部"].wagesRealTotal) : 0 + result["项目二部"] ? changeMoney(result["项目二部"].wagesRealTotal) : 0, color : '#fff648', highlight: '#fff648', label : result["项目中心"] ? result["项目中心"].officeName : "项目中心" }, { - value : result["质量监察部"] ? result["质量监察部"].wagesRealTotal : "0", + value : result["质量监察部"] ? changeMoney(result["质量监察部"].wagesRealTotal) : 0, color : '#f01c1e', highlight: '#f01c1e', label : result["质量监察部"] ? result["质量监察部"].officeName : "质量监察部" }, { - value : result["集成服务事业部"] ? result["集成服务事业部"].wagesRealTotal : "0", + value : result["集成服务事业部"] ? changeMoney(result["集成服务事业部"].wagesRealTotal) : 0, color : '#262ef0', highlight: '#262ef0', label : result["集成服务事业部"] ? result["集成服务事业部"].officeName : "集成服务事业部" }, { - value : result["营销部"] ? result["营销部"].wagesRealTotal : "0", + value : result["营销部"] ? changeMoney(result["营销部"].wagesRealTotal) : 0, color : '#2ef0ae', highlight: '#2ef0ae', label : result["营销部"] ? result["营销部"].officeName : "营销部" }, { - value : result["董经办"] ? result["董经办"].wagesRealTotal : "0", + value : result["董经办"] ? changeMoney(result["董经办"].wagesRealTotal) : 0, color : '#f03065', highlight: '#f03065', label : result["董经办"] ? result["董经办"].officeName : "董经办" } ]; + + $("#zjb").html("总经办 : " + PieData[0].value + " 万元"); + $("#djb").html("董经办 : " + PieData[13].value + " 万元"); + $("#cwb").html("财务部 : " + PieData[1].value + " 万元"); + $("#xzb").html("行政部 : " + PieData[5].value + " 万元"); + $("#swb").html("商务部 : " + PieData[6].value + " 万元"); + $("#syb").html("事业部 : " + PieData[8].value + " 万元"); + $("#rlzyb").html("人力资源部 : " + PieData[7].value + " 万元"); + $("#xmzx").html("项目中心 : " + PieData[9].value + " 万元"); + $("#zljcb").html("质量监察部 : " + PieData[10].value + " 万元"); + $("#jcfwsyb").html("集成服务事业部 : " + PieData[11].value + " 万元"); + $("#yxb").html("营销部 : " + PieData[12].value + " 万元"); + $("#djjfywxm").html("东郊机房运维项目 : " + PieData[2].value + " 万元"); + $("#pdsywxm").html("配电室运维项目 : " + PieData[3].value + " 万元"); + $("#dkyjfywxm").html("电科院机房运维项目 : " + PieData[4].value + " 万元"); + var pieChartCanvas = $('#pieChart').get(0).getContext('2d'); var pieChart = new Chart(pieChartCanvas); var pieOptions = { @@ -437,7 +453,7 @@ //请求成功时执行该函数内容,result即为服务器返回的json对象 if (wagesSummaryByMonth) { for (var i=0;i"; + for(var i=0;i"; + } + return cont+contT + } }, legend:{ // data:['合同金额','分月汇总'] @@ -488,6 +514,20 @@ }; myChart.setOption(option); }); + + // 金额转换 + function changeMoney(num) { + var regexp = /(?:\.0*|(\.\d+?)0+)$/ + if (num > 10000) { + num = (num/10000).toFixed(2); + return num; + } else { + num = (num/10000).toFixed(8); + num = num.replace(regexp, '$1') + return num; + } + } +