Commit 767162bb authored by 李苏's avatar 李苏 💬

大屏数据变更

parent 63cc5851
......@@ -60,7 +60,7 @@
padding: .1rem .2rem .1rem .2rem;
}
.center .center-left{
width: 25%;
width: 30%;
padding: .1rem;
/* border: 1px solid red;*/
......@@ -181,7 +181,7 @@
margin-top: 0.1rem;
}
.center .center-cen{
width: 50%;
width: 40%;
padding: .1rem;
}
.center .center-cen .cen-top{
......@@ -253,7 +253,7 @@
}
.center .center-right{
width: 25%;
width: 30%;
padding: .1rem;
}
......@@ -308,7 +308,7 @@
display: block;
float: left;
height: .2rem;
width: 12.5%;
width: 14.28%;
/*background: red;*/
/*margin: 15px 10px 10px 10px;*/
/*padding: 20px;*/
......@@ -365,7 +365,7 @@
display: inline-block;
/* float: left; */
/* height: 20px; */
width: 12.5%;
width: 14.28%;
color: #ffffff;
float: left;
overflow: hidden;
......
/* 获取真实数据 */
//时段产量
function apisetTimeProductionEchart(myChartSdcl){
HTTP.post("querySdcl", {}, function(result) {
HTTP.post("queryWeekPcsl", {}, function(result) {
if (result['success']) {
let data={}
data.xseriesList=result.data.records.xseriesList||[]
data.timeperiodMount=result.data.records.timeperiodMount||[]
data.xseriesList=result.data.records.map(e=>new Date(e.pcrq).toLocaleDateString().split('/').join('-').slice(5))
data.timeperiodMount=result.data.records.map(e=>e.wgsl)
console.log(data)
setTimeProductionEchart(myChartSdcl,data); /*时段产量*/
} else {
console.log("请求失败")
......@@ -125,7 +126,7 @@
"</span>"+
"<span>"+djid+"</span>"+
"<span>"+wlxxCode+"</span>"+
"<span>"+wlxxName+"</span>"+
// "<span>"+wlxxName+"</span>"+
"<span>"+pcsl+"</span>"+
"<span>"+wgsl+"</span>"+
"<span>"+ywrq+"</span>"+
......@@ -162,7 +163,7 @@
$($point[index]).css("background-color","skyblue");
shdata.s++
}
$($point1[index]).html(e.itemId)
$($point1[index]).html(e.name)
})
setchartJdshCirle(chartJdshCirle,shdata)
} else {
......
......@@ -1940,6 +1940,7 @@ $(function () {
});
/*时段产量图表*/
function setTimeProductionEchart(chart,apidata) {
console.log(apidata)
if(apidata){
var list=[]
apidata.xseriesList.forEach(function(e,index){
......@@ -2022,7 +2023,7 @@ function setTimeProductionEchart(chart,apidata) {
type: 'category',
data: dateList,
axisLabel: {
interval: 1,
interval: 0,
tooltip: {
show: true,
},
......@@ -2031,26 +2032,26 @@ function setTimeProductionEchart(chart,apidata) {
fontSize: 12
},
color: 'rgba(255,255,255,0.6)',
formatter:function(value){
var str = "";
var num = 6; //每行显示字数
var valLength = value.length; //该项x轴字数
var rowNum = Math.ceil(valLength / num); // 行数
// formatter:function(value){
// var str = "";
// var num = 4; //每行显示字数
// var valLength = value.length; //该项x轴字数
// var rowNum = Math.ceil(valLength / num); // 行数
if(rowNum > 1) {
for(var i = 0; i < rowNum; i++) {
var temp = "";
var start = i * num;
var end = start + num;
// if(rowNum > 1) {
// for(var i = 0; i < rowNum; i++) {
// var temp = "";
// var start = i * num;
// var end = start + num;
temp = value.substring(start, end) + "\n";
str += temp;
}
return str;
} else {
return value;
}
}
// temp = value.substring(start, end) + "\n";
// str += temp;
// }
// return str;
// } else {
// return value;
// }
// }
},
axisTick: {
show: false
......@@ -2064,6 +2065,8 @@ function setTimeProductionEchart(chart,apidata) {
},
yAxis: [{
type: 'value',
min: 0.0,
max: 50.0,
splitLine: {
show: false,
lineStyle: {
......
......@@ -32,7 +32,9 @@
</div>
<div class="header-img"></div>
</div>
<div class="header-right fl"></div>
<div class="header-right fl" style="line-height: 1.05rem;text-align:center;">
<span>温度:22°C</span>&nbsp;&nbsp;<span>湿度:12%rh</span>
</div>
<div class="header-bottom fl"></div>
</div>
......@@ -41,7 +43,7 @@
<div class="center-left fl">
<div class="left-top rightTop border">
<!--<h1 id="ceshi">数据可视化</h1>-->
<div class="title">时段产量</div>
<div class="title">产量</div>
<div class="bottom-b">
<div id="chartSdcl" class="allnav"></div>
</div>
......@@ -114,7 +116,6 @@
<span>序号</span>
<span>订单号</span>
<span>物料</span>
<span>描述</span>
<span>计划</span>
<span>完工</span>
<span>订单时间</span>
......
......@@ -62,7 +62,7 @@
</div>
</div>
<div class="left-bottom rightTop border">
<div class="title">时段产量</div>
<div class="title">产量</div>
<div class="bottom-b">
<div id="chartSdcl" class="allnav"></div>
</div>
......@@ -124,7 +124,7 @@
<span>序号</span>
<span>订单号</span>
<span>物料</span>
<span>描述</span>
<!-- <span>描述</span> -->
<span>计划</span>
<span>完工</span>
<span>订单时间</span>
......
......@@ -30,7 +30,7 @@
</video>
</div>
<div class="cen-bottom rightTop border" style="width: calc(50% - 0.1rem);float: left;margin-right: 0.1rem">
<div class="title">时段产量</div>
<div class="title">产量</div>
<div class="bottom-b">
<div id="chartSdcl" class="allnav"></div>
</div>
......@@ -44,7 +44,7 @@
<span>序号</span>
<span>订单号</span>
<span>物料</span>
<span>描述</span>
<!-- <span>描述</span> -->
<span>计划</span>
<span>完工</span>
<span>订单时间</span>
......
......@@ -48,7 +48,7 @@
<span>序号</span>
<span>订单号</span>
<span>物料</span>
<span>描述</span>
<!-- <span>描述</span> -->
<span>计划</span>
<span>完工</span>
<span>订单时间</span>
......@@ -235,7 +235,7 @@
</div>
</div>
<div class="right-bottom rightTop border">
<div class="title">时段产量</div>
<div class="title">产量</div>
<div class="bottom-b">
<div id="chartSdcl" class="allnav"></div>
</div>
......
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