206 lines
8.1 KiB
Java
206 lines
8.1 KiB
Java
<!DOCTYPE html>
|
|
<html>
|
|
<head><meta charset="utf-8">
|
|
<title>首页-华夏ERP</title>
|
|
<link rel="shortcut icon" href="images/favicon.ico" type="image/x-icon"/>
|
|
<script src="js/jquery/jquery-1.12.4.min.js"></script>
|
|
<!--[if lt IE 9]><script src="js/common/h5fix.min.js"></script><![endif]-->
|
|
<link rel="stylesheet" href="css/fonts/font-icons.min.css">
|
|
<link rel="stylesheet" href="js/bootstrap/css/bootstrap.min.css">
|
|
<link rel="stylesheet" href="js/adminlte/css/AdminLTE.min.css">
|
|
<link rel="stylesheet" href="css/jsherp.css">
|
|
<link rel="stylesheet" href="js/adminlte/css/skins/skin-blue-light2.css">
|
|
</head><body class="hold-transition ">
|
|
<div class="wrapper">
|
|
<div class="content pb0">
|
|
<div class="row">
|
|
<div class="col-md-3 col-sm-6 col-xs-12">
|
|
<div class="info-box">
|
|
<span class="info-box-icon bg-aqua"><i class="fa fa-shopping-bag"></i></span>
|
|
<div class="info-box-content">
|
|
<span class="info-box-text">今日累计销售</span>
|
|
<span id="todaySale" class="info-box-number">0元</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-3 col-sm-6 col-xs-12">
|
|
<div class="info-box">
|
|
<span class="info-box-icon bg-red"><i class="fa fa-shopping-cart"></i></span>
|
|
<div class="info-box-content">
|
|
<span class="info-box-text">本月累计销售</span>
|
|
<span id="thisMonthSale" class="info-box-number">0元</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="clearfix visible-sm-block"></div>
|
|
<div class="col-md-3 col-sm-6 col-xs-12">
|
|
<div class="info-box">
|
|
<span class="info-box-icon bg-green"><i class="fa fa-shopping-basket"></i></span>
|
|
<div class="info-box-content">
|
|
<span class="info-box-text">本月累计进货</span>
|
|
<span id="thisMonthBuy" class="info-box-number">0元</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-3 col-sm-6 col-xs-12">
|
|
<div class="info-box">
|
|
<span class="info-box-icon bg-yellow"><i class="fa fa-users"></i></span>
|
|
<div class="info-box-content">
|
|
<span class="info-box-text">用户数量</span>
|
|
<span id="thisUserSum" class="info-box-number">0</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<section class="col-md-6 ui-sortable">
|
|
<div class="box box-solid">
|
|
<div class="box-header ui-sortable-handle">
|
|
<i class="fa fa-th"></i>
|
|
<h3 class="box-title">采购统计</h3>
|
|
<div class="box-tools pull-right"></div>
|
|
</div>
|
|
<div class="box-body border-radius-none">
|
|
<div id="buyIn" style="min-width:400px;height:380px"></div>
|
|
</div>
|
|
</div>
|
|
</section>
|
|
<section class="col-md-6 ui-sortable ui-sortable">
|
|
<div class="box box-solid">
|
|
<div class="box-header ui-sortable-handle">
|
|
<i class="fa fa-th"></i>
|
|
<h3 class="box-title">销售统计</h3>
|
|
<div class="box-tools pull-right"></div>
|
|
</div>
|
|
<div class="box-body border-radius-none">
|
|
<div id="saleOut" style="min-width:400px;height:380px"></div>
|
|
</div>
|
|
</div>
|
|
</section>
|
|
</div>
|
|
</div>
|
|
<footer class="main-footer m0">
|
|
<div class="pull-right hidden-xs">当前版本: V2.1</div>
|
|
© 2015-2020 华夏ERP Demo - Powered By <a href="http://home.huaxiaerp.com/" target="_blank">官方网站</a>
|
|
</footer>
|
|
</div>
|
|
|
|
<a id="scroll-up" href="#" class="btn btn-sm"><i class="fa fa-angle-double-up"></i></a>
|
|
<script src="js/layer/3.1/layer.js"></script>
|
|
<script src="js/common/jsherp.js"></script>
|
|
<script src="js/common/common.js"></script>
|
|
<script src="js/common/i18n/jsherp_zh_CN.js"></script>
|
|
<script>
|
|
if ($('#switchSkin').length > 0){
|
|
$('#switchSkin i').addClass('jump5');
|
|
setTimeout(function(){
|
|
$('.main-sidebar [title="角色管理"]').append('<span class="pull-right-container">'
|
|
+'<small class="label pull-right bg-red jump">hot</small></span>');
|
|
},2000);
|
|
}
|
|
</script>
|
|
<script src="js/jquery/jquery-ui-sortable-1.12.1.min.js"></script>
|
|
<script src="js/highcharts/highcharts.js"></script>
|
|
<script src="js/highcharts/exporting.js"></script>
|
|
<script src="js/highcharts/highcharts-zh_CN.js"></script>
|
|
<script>
|
|
$(window).resize(function(){
|
|
var footerHeight = $('.main-footer').outerHeight() || 0;
|
|
var windowHeight = $(window).height();
|
|
$('.content').css('min-height', windowHeight - footerHeight)
|
|
}).resize();
|
|
$('.ui-sortable').sortable({
|
|
placeholder : 'sort-highlight',
|
|
connectWith : '.ui-sortable',
|
|
handle : '.box-header, .nav-tabs',
|
|
forcePlaceholderSize: true, zIndex : 999999
|
|
}).find('.box-header, .nav-tabs').css('cursor', 'move');
|
|
|
|
$(function () {
|
|
$.ajax({
|
|
type: "get",
|
|
url: "/depotHead/getBuyAndSaleStatistics",
|
|
dataType: "json",
|
|
success: function (res) {
|
|
if(res && res.code === 200) {
|
|
if(res.data) {
|
|
$("#todaySale").text(res.data.todaySale);
|
|
$("#thisMonthSale").text(res.data.thisMonthSale);
|
|
$("#thisMonthBuy").text(res.data.thisMonthBuy);
|
|
}
|
|
}
|
|
},
|
|
error:function(res){
|
|
|
|
}
|
|
});
|
|
});
|
|
|
|
$(function () {
|
|
$.ajax({
|
|
type: "get",
|
|
url: "/user/list",
|
|
dataType: "json",
|
|
data: ({
|
|
search: JSON.stringify({
|
|
userName: "",
|
|
loginName: ""
|
|
}),
|
|
currentPage: 1,
|
|
pageSize: 10
|
|
}),
|
|
success: function (res) {
|
|
if(res && res.code === 200) {
|
|
if(res.data && res.data.page) {
|
|
$("#thisUserSum").text(res.data.page.total);
|
|
}
|
|
}
|
|
},
|
|
error:function(res){
|
|
|
|
}
|
|
});
|
|
});
|
|
|
|
function getChartObj(titleName, categories, seriesData) {
|
|
var chartObj = {
|
|
chart: {
|
|
type: 'spline'
|
|
},
|
|
title: {
|
|
text: titleName
|
|
},
|
|
xAxis: {
|
|
categories: categories
|
|
},
|
|
yAxis: {
|
|
title: {
|
|
text: '金额(元)'
|
|
}
|
|
},
|
|
series: [{
|
|
name: titleName,
|
|
data: seriesData
|
|
}]
|
|
}
|
|
return chartObj;
|
|
}
|
|
$(function () {
|
|
$.ajax({
|
|
type: "get",
|
|
url: "/depotItem/buyOrSalePrice",
|
|
dataType: "json",
|
|
success: function (res) {
|
|
if(res && res.code === 200) {
|
|
var data = res.data;
|
|
Highcharts.chart('buyIn', getChartObj("最近6个月采购数据", res.data.monthList, res.data.buyPriceList));
|
|
Highcharts.chart('saleOut', getChartObj("最近6个月销售数据", res.data.monthList, res.data.salePriceList));
|
|
}
|
|
},
|
|
error:function(res){
|
|
|
|
}
|
|
});
|
|
});
|
|
|
|
</script> |