作者 lihongjuan

65232332

  1 +// pages/companybox/qiyeyuebao/qiyeyuebao.js
  2 +import * as echarts from '../../../ec-canvas/echarts';
  3 +const app=getApp()
  4 +// 开平机1
  5 +function initChart1(canvas, width, height) {
  6 + const chart = echarts.init(canvas, null, {
  7 + width: width,
  8 + height: height
  9 + });
  10 + canvas.setChart(chart);
  11 +
  12 + var option = {
  13 + title: {
  14 + text: '开平机01每日开工时间',
  15 + left: 'center'
  16 + },
  17 +
  18 +
  19 + toolbox: {
  20 +
  21 + },
  22 + xAxis: {
  23 + type: 'category',
  24 + boundaryGap: false,
  25 + data: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31'],
  26 + axisLabel: {
  27 + interval: 1,
  28 + },
  29 + name: '日期'
  30 +
  31 +
  32 + },
  33 + yAxis: {
  34 + type: 'value',
  35 + axisLabel: {
  36 + formatter: '{value}'
  37 + },
  38 + min: 1,
  39 + max: 24,
  40 + splitNumber: 24,
  41 + name: '小时(h)'
  42 +
  43 + },
  44 + series: [
  45 + {
  46 + name: '',
  47 + type: 'line',
  48 + smooth: true,
  49 + color: '#FCB237',
  50 + data: [11, 11, 15, 13, 12, 13, 10],
  51 + markPoint: {
  52 + data: [
  53 + { type: 'max', name: '最大值' },
  54 + { type: 'min', name: '最小值' }
  55 + ]
  56 + },
  57 + markLine: {
  58 + data: [
  59 + { type: 'average', name: '平均值' }
  60 + ]
  61 + },
  62 + // areaStyle: {
  63 + // // normal: {
  64 + // // color: '#F8E9DD' //改变区域颜色
  65 + // // }
  66 + // },
  67 + },
  68 +
  69 +
  70 + ]
  71 + };
  72 +
  73 + chart.setOption(option);
  74 + return chart;
  75 +}
  76 +// 开平机2
  77 +function initChart2(canvas, width, height) {
  78 + const chart = echarts.init(canvas, null, {
  79 + width: width,
  80 + height: height
  81 + });
  82 + canvas.setChart(chart);
  83 +
  84 + var option = {
  85 + title: {
  86 + text: '开平机02每日开工时间',
  87 + left: 'center'
  88 + },
  89 +
  90 +
  91 + toolbox: {
  92 +
  93 + },
  94 + xAxis: {
  95 + type: 'category',
  96 + boundaryGap: false,
  97 + data: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31'],
  98 + axisLabel: {
  99 + interval: 1,
  100 + },
  101 + name: '日期'
  102 +
  103 +
  104 + },
  105 + yAxis: {
  106 + type: 'value',
  107 + axisLabel: {
  108 + formatter: '{value}'
  109 + },
  110 + min: 1,
  111 + max: 24,
  112 + splitNumber: 24,
  113 + name: '小时(h)'
  114 +
  115 + },
  116 + series: [
  117 + {
  118 + name: '',
  119 + type: 'line',
  120 + smooth: true,
  121 + color: '#FCB237',
  122 + data: [11, 11, 15, 13, 12, 13, 10],
  123 + markPoint: {
  124 + data: [
  125 + { type: 'max', name: '最大值' },
  126 + { type: 'min', name: '最小值' }
  127 + ]
  128 + },
  129 + markLine: {
  130 + data: [
  131 + { type: 'average', name: '平均值' }
  132 + ]
  133 + },
  134 + // areaStyle: {
  135 + // // normal: {
  136 + // // color: '#F8E9DD' //改变区域颜色
  137 + // // }
  138 + // },
  139 + },
  140 +
  141 + ]
  142 + };
  143 +
  144 + chart.setOption(option);
  145 + return chart;
  146 +}
  147 +
  148 +// 开工月累计时间
  149 +function initChart3(canvas, width, height) {
  150 + const chart = echarts.init(canvas, null, {
  151 + width: width,
  152 + height: height
  153 + });
  154 + canvas.setChart(chart);
  155 +
  156 + var option = {
  157 + title: {
  158 + text: '企业开工月累计时间',
  159 + left: 'center'
  160 + },
  161 +
  162 +
  163 + toolbox: {
  164 +
  165 + },
  166 + xAxis: {
  167 + type: 'category',
  168 + boundaryGap: false,
  169 + data: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31'],
  170 + axisLabel: {
  171 + interval: 1,
  172 + },
  173 + name: '日期'
  174 +
  175 +
  176 + },
  177 + yAxis: {
  178 + type: 'value',
  179 + axisLabel: {
  180 + formatter: '{value}'
  181 + },
  182 + min: 1,
  183 + max: 24,
  184 + splitNumber: 24,
  185 + name: '小时(h)'
  186 +
  187 + },
  188 + series: [
  189 + {
  190 + name: '',
  191 + type: 'line',
  192 + smooth: true,
  193 + color: '#AF56D7',
  194 + data: [11, 11, 15, 13, 12, 13, 10],
  195 + markPoint: {
  196 + data: [
  197 + { type: 'max', name: '最大值' },
  198 + { type: 'min', name: '最小值' }
  199 + ]
  200 + },
  201 + markLine: {
  202 + data: [
  203 + { type: 'average', name: '平均值' }
  204 + ]
  205 + },
  206 + // areaStyle: {
  207 + // // normal: {
  208 + // // color: '#F8E9DD' //改变区域颜色
  209 + // // }
  210 + // },
  211 + },
  212 +
  213 + ]
  214 + };
  215 +
  216 + chart.setOption(option);
  217 + return chart;
  218 +}
  219 +// 半年度开工时间对比
  220 +function initChart4(canvas, width, height) {
  221 + const chart = echarts.init(canvas, null, {
  222 + width: width,
  223 + height: height
  224 + });
  225 + canvas.setChart(chart);
  226 +
  227 + var option = {
  228 + xAxis: {
  229 + type: 'category',
  230 + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
  231 + },
  232 + yAxis: {
  233 + type: 'value'
  234 + },
  235 + series: [{
  236 + data: [120, 200, 150, 80, 70, 110, 130],
  237 + type: 'bar'
  238 + }]
  239 + };
  240 +
  241 + chart.setOption(option);
  242 + return chart;
  243 +}
  244 +// 企业每日电耗
  245 +function initChart5(canvas, width, height) {
  246 + const chart = echarts.init(canvas, null, {
  247 + width: width,
  248 + height: height
  249 + });
  250 + canvas.setChart(chart);
  251 +
  252 + var option = {
  253 + title: {
  254 + text: '企业月开工率',
  255 + left: 'center'
  256 + },
  257 +
  258 +
  259 + toolbox: {
  260 +
  261 + },
  262 + xAxis: {
  263 + type: 'category',
  264 + boundaryGap: false,
  265 + data: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31'],
  266 + axisLabel: {
  267 + interval: 1,
  268 + },
  269 + name: '日期'
  270 +
  271 +
  272 + },
  273 + yAxis: {
  274 + type: 'value',
  275 + axisLabel: {
  276 + formatter: '{value}'
  277 + },
  278 + min: 1,
  279 + max: 24,
  280 + splitNumber: 24,
  281 + name: '小时(h)'
  282 +
  283 + },
  284 + series: [
  285 + {
  286 + name: '',
  287 + type: 'line',
  288 + smooth: true,
  289 + color: '#6495F8',
  290 + data: [11, 11, 15, 13, 12, 13, 10],
  291 + markPoint: {
  292 + data: [
  293 + { type: 'max', name: '最大值' },
  294 + { type: 'min', name: '最小值' }
  295 + ]
  296 + },
  297 + markLine: {
  298 + data: [
  299 + { type: 'average', name: '平均值' }
  300 + ]
  301 + },
  302 + // areaStyle: {
  303 + // // normal: {
  304 + // // color: '#F8E9DD' //改变区域颜色
  305 + // // }
  306 + // },
  307 + },
  308 +
  309 + ]
  310 + };
  311 +
  312 + chart.setOption(option);
  313 + return chart;
  314 +}
  315 +// 企业每日电耗
  316 +function initChart6(canvas, width, height) {
  317 + const chart = echarts.init(canvas, null, {
  318 + width: width,
  319 + height: height
  320 + });
  321 + canvas.setChart(chart);
  322 +
  323 + var option = {
  324 + title: {
  325 + text: '企业月开工率',
  326 + left: 'center'
  327 + },
  328 +
  329 +
  330 + toolbox: {
  331 +
  332 + },
  333 + xAxis: {
  334 + type: 'category',
  335 + boundaryGap: false,
  336 + data: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31'],
  337 + axisLabel: {
  338 + interval: 1,
  339 + },
  340 + name: '日期'
  341 +
  342 +
  343 + },
  344 + yAxis: {
  345 + type: 'value',
  346 + axisLabel: {
  347 + formatter: '{value}'
  348 + },
  349 + min: 1,
  350 + max: 24,
  351 + splitNumber: 24,
  352 + name: '小时(h)'
  353 +
  354 + },
  355 + series: [
  356 + {
  357 + name: '',
  358 + type: 'line',
  359 + smooth: true,
  360 + color: '#6495F8',
  361 + data: [11, 11, 15, 13, 12, 13, 10],
  362 + markPoint: {
  363 + data: [
  364 + { type: 'max', name: '最大值' },
  365 + { type: 'min', name: '最小值' }
  366 + ]
  367 + },
  368 + markLine: {
  369 + data: [
  370 + { type: 'average', name: '平均值' }
  371 + ]
  372 + },
  373 + // areaStyle: {
  374 + // // normal: {
  375 + // // color: '#F8E9DD' //改变区域颜色
  376 + // // }
  377 + // },
  378 + },
  379 +
  380 + ]
  381 + };
  382 +
  383 + chart.setOption(option);
  384 + return chart;
  385 +}
  386 +// 半年度企业电耗对比
  387 +function initChart7(canvas, width, height) {
  388 + const chart = echarts.init(canvas, null, {
  389 + width: width,
  390 + height: height
  391 + });
  392 + canvas.setChart(chart);
  393 +
  394 + var option = {
  395 + xAxis: {
  396 + type: 'category',
  397 + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
  398 + },
  399 + yAxis: {
  400 + type: 'value'
  401 + },
  402 + series: [{
  403 + data: [120, 200, 150, 80, 70, 110, 130],
  404 + type: 'bar'
  405 + }]
  406 + };
  407 +
  408 + chart.setOption(option);
  409 + return chart;
  410 +}
  411 +function initChart8(canvas, width, height) {
  412 + const chart = echarts.init(canvas, null, {
  413 + width: width,
  414 + height: height
  415 + });
  416 + canvas.setChart(chart);
  417 +
  418 + var option = {
  419 +
  420 + tooltip: {
  421 + trigger: 'axis'
  422 + },
  423 +
  424 + title: {
  425 + text: '雷达图',
  426 + textStyle: {
  427 + color: 'rgba(221,221,221,1)', //标题颜色
  428 + fontSize: 14,
  429 + lineHeight: 20,
  430 + },
  431 + // 标题的位置,此时放在图的底边
  432 + left: 'center',
  433 + top: 'bottom',
  434 + },
  435 +
  436 +
  437 +
  438 +
  439 + legend: {
  440 + enabled: true
  441 + },
  442 + radar: [
  443 +
  444 +
  445 + {
  446 + indicator: [
  447 +
  448 + {
  449 + text: '生产:90分',
  450 + max: 100,
  451 +
  452 +
  453 +
  454 + },
  455 + {
  456 + text: '预警:60分',
  457 + max: 100
  458 + },
  459 + {
  460 + text: '稳定性:80分',
  461 + max: 100,
  462 + }
  463 +
  464 + ],
  465 +
  466 + center: ['50%', '60%'],
  467 +
  468 + radius: 80,
  469 +
  470 + name: {
  471 + textStyle: {
  472 +
  473 + fontSize: 14
  474 + }
  475 + },
  476 +
  477 + },
  478 +
  479 +
  480 +
  481 +
  482 + ],
  483 + series: [{
  484 + type: 'radar',
  485 +
  486 + legend: {
  487 +
  488 +
  489 + },
  490 +
  491 +
  492 + itemStyle: {
  493 + normal: {
  494 + color: '#FBCB77',
  495 + areaStyle: {
  496 + type: 'default',
  497 + color: '#FBCB77',
  498 +
  499 + },
  500 + lineStyle: {
  501 + color: '#FBCB77',
  502 +
  503 + }
  504 + }
  505 + },
  506 + data: [{
  507 + value: [60, 73, 85],
  508 +
  509 + // name: '某软件'
  510 + }]
  511 + },
  512 +
  513 +
  514 +
  515 + ]
  516 + };
  517 +
  518 +
  519 +
  520 +
  521 +
  522 +
  523 +
  524 + chart.setOption(option);
  525 +
  526 + return chart;
  527 +}
  528 +Page({
  529 + onShareAppMessage: function (res) {
  530 + return {
  531 + title: 'ECharts 可以在微信小程序中使用啦!',
  532 + path: '',
  533 + success: function () { },
  534 + fail: function () { }
  535 + }
  536 + },
  537 +
  538 + /**
  539 + * 页面的初始数据
  540 + */
  541 + data: {
  542 + statedate:"",
  543 + ec1: {
  544 +
  545 + onInit: initChart1
  546 +
  547 + },
  548 + ec2: {
  549 +
  550 + onInit: initChart2
  551 +
  552 + },
  553 + ec3:{
  554 + onInit: initChart3
  555 + },
  556 + ec4: {
  557 + onInit: initChart4
  558 + },
  559 + ec5: {
  560 + onInit: initChart5
  561 + },
  562 + ec6: {
  563 + onInit: initChart6
  564 + },
  565 + ec7: {
  566 + onInit: initChart7
  567 + },
  568 + ec8: {
  569 + onInit: initChart8
  570 + }
  571 + },
  572 +
  573 + /**
  574 + * 生命周期函数--监听页面加载
  575 + */
  576 + onLoad: function (options) {
  577 + this.setData({
  578 + statedate: app.monthnowDate(),
  579 + })
  580 +
  581 + },
  582 +
  583 + // 选择日期
  584 + bindstateDateChange(e) {
  585 + console.log('picker发送选择改变,携带值为', e.detail.value)
  586 + this.setData({
  587 + statedate: e.detail.value
  588 + })
  589 + let newdate = this.data.statedate.split("-");
  590 + this.setData({
  591 + showdate: newdate[0] + '年' + newdate[1] + '月'
  592 + })
  593 + },
  594 +
  595 + /**
  596 + * 生命周期函数--监听页面初次渲染完成
  597 + */
  598 + onReady: function () {
  599 +
  600 + },
  601 +
  602 + /**
  603 + * 生命周期函数--监听页面显示
  604 + */
  605 + onShow: function () {
  606 +
  607 + },
  608 +
  609 + /**
  610 + * 生命周期函数--监听页面隐藏
  611 + */
  612 + onHide: function () {
  613 +
  614 + },
  615 +
  616 + /**
  617 + * 生命周期函数--监听页面卸载
  618 + */
  619 + onUnload: function () {
  620 +
  621 + },
  622 +
  623 + /**
  624 + * 页面相关事件处理函数--监听用户下拉动作
  625 + */
  626 + onPullDownRefresh: function () {
  627 +
  628 + },
  629 +
  630 + /**
  631 + * 页面上拉触底事件的处理函数
  632 + */
  633 + onReachBottom: function () {
  634 +
  635 + },
  636 +
  637 + /**
  638 + * 用户点击右上角分享
  639 + */
  640 + onShareAppMessage: function () {
  641 +
  642 + }
  643 +})
  1 +{
  2 + "navigationBarTitleText": "企业月报",
  3 + "usingComponents": {
  4 + "ec-canvas": "../../../ec-canvas/ec-canvas"
  5 + }
  6 +}
  1 +<!-- 头部日期 -->
  2 +<view class="date">
  3 + <view class="dateleft">
  4 + <image src="/img/whiterow.png"></image>
  5 + </view>
  6 + <view class="datetime">
  7 + <view class="datesel">
  8 + <picker mode="date" value="{{date}}" start="" end="" bindchange="bindstateDateChange" fields="month">
  9 + <view class="picker">
  10 + {{statedate}}
  11 + </view>
  12 + </picker>
  13 + </view>
  14 +
  15 + <view class="datepic">
  16 + <image src="/img/whiterow.png"></image>
  17 + </view>
  18 + </view>
  19 +
  20 + <view class="dateright">
  21 + <image src="/img/whiterow.png"></image>
  22 + </view>
  23 +</view>
  24 +
  25 +
  26 +
  27 +<!-- 客观信息 -->
  28 +<view class="keguaninfo" wx:if="{{index==0}}">
  29 + <!-- 企业开工时间 -->
  30 + <view class="worktime">
  31 + <!-- 头部日期 -->
  32 +
  33 +
  34 + <!-- 企业设备月开工时间-->
  35 +
  36 + <view class="shebeinum">
  37 + <text class="she">企业设备月开工时间</text>
  38 + </view>
  39 +
  40 + <view class="kaijibox">
  41 + <!-- 开平机1 -->
  42 +
  43 + <view class="containerzhe">
  44 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ ec1 }}"></ec-canvas>
  45 + </view>
  46 +
  47 + <!-- 开平机2 -->
  48 +
  49 + <view class="containerzhe">
  50 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ ec2 }}"></ec-canvas>
  51 + </view>
  52 + </view>
  53 +
  54 + <view class="seemore">查看更多</view>
  55 +
  56 + <!-- 企业得分 -->
  57 +
  58 + <view class="companybox">
  59 + <view class="boxhead">
  60 + <view class="boxtopitem">企业名称</view>
  61 + <view class="boxtopitem">生产平稳性</view>
  62 + <view class="boxtopitem">生产趋势</view>
  63 + <view class="boxtopitem">生产状态</view>
  64 + <view class="boxtopitem">综合评分</view>
  65 + </view>
  66 + <view class="boxhead">
  67 + <view class="boxbottomitem">无锡市好事达人供 应链管理有限公司
  68 + </view>
  69 + <view class="boxbottomitem common">较平稳</view>
  70 + <view class="boxbottomitem common">下降</view>
  71 + <view class="boxbottomitem common">正常</view>
  72 + <view class="boxbottomitem common">87</view>
  73 + </view>
  74 + </view>
  75 + <!-- 分析-->
  76 +
  77 + <view class="desbox">
  78 + <view class="desboxhead">分析</view>
  79 + <view class="destext">
  80 + 在分析无锡市好事达供应链管理有限公司时,综合考虑无锡好事达供应链管理有限公司于2019年4月,目前处于
  81 + <text class="commonstate">正常状态</text>
  82 + </view>
  83 + </view>
  84 + </view>
  85 +
  86 + <!-- 企业累计时间 -->
  87 +
  88 + <view class='worktime'>
  89 + <!-- 企业开工月累计时间-->
  90 +
  91 + <view class="shebeinum">
  92 + <text class="she">企业开工月累计时间</text>
  93 + </view>
  94 + <!-- 企业开工月累计时间 -->
  95 +
  96 + <view class="containerzhe">
  97 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ ec3 }}"></ec-canvas>
  98 + </view>
  99 +
  100 + <view class="atten">注:月累计开工时间=企业所有设备当月开工时间总和。</view>
  101 +
  102 + <!-- 半年度开工时间对比 -->
  103 +
  104 + <view class="containerzhe">
  105 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ec4}}"></ec-canvas>
  106 + </view>
  107 +
  108 + <view class="desbox">
  109 + <view class="desboxhead">分析</view>
  110 + <view class="destext">
  111 + 在分析无锡市好事达供应链管理有限公司时,综合考虑无锡好事达供应链管理有限公司于2019年4月,目前处于
  112 + <text class="commonstate">正常状态</text>
  113 + </view>
  114 + </view>
  115 +
  116 + </view>
  117 + <!-- 企业开工率 -->
  118 + <view class="worktime">
  119 + <!-- 企业月开工率 -->
  120 + <view class="shebeinum">
  121 + <text class="she">企业月开工率</text>
  122 + </view>
  123 + <!-- 企业月开工率 -->
  124 +
  125 + <view class="containerzhe">
  126 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ ec5 }}"></ec-canvas>
  127 + </view>
  128 + <view class="atten">注:企业开工率=企业每日平均开工时间/24。</view>
  129 +
  130 + <view class="desbox">
  131 + <view class="desboxhead">分析</view>
  132 + <view class="destext">
  133 + 无锡好事达供应链管理有限公司于
  134 + <text class="commonstate">2019年4月</text>,所有监测设备平均每日开工时间:
  135 + <text class="commonstate">5.14小时</text>,当月企业月开工率为:
  136 + <text class="commonstate">21.4%</text>
  137 +
  138 + </view>
  139 + </view>
  140 + </view>
  141 +
  142 + <!-- 企业当月用电情况 -->
  143 + <view class="worktime">
  144 + <!-- 企业当月用电情况 -->
  145 + <view class="shebeinum">
  146 + <text class="she">企业当月用电情况</text>
  147 + </view>
  148 + <!-- 企业每日耗电 -->
  149 +
  150 + <view class="containerzhe">
  151 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ ec6}}"></ec-canvas>
  152 + </view>
  153 +
  154 + <view class="containerzhe">
  155 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ ec7}}"></ec-canvas>
  156 + </view>
  157 +
  158 + <view class="desbox">
  159 + <view class="desboxhead">分析</view>
  160 + <view class="destext">无锡好事达供应链管理有限公司
  161 +
  162 + <text class="commonstate">2019年4月</text>总电耗:
  163 + <text class="commonstate">9025千瓦时</text>,日均电耗:
  164 + <text class="commonstate">300.8千瓦时 </text>,较上月减少
  165 + <text class="commonstate">1694千瓦时 </text>
  166 +
  167 +
  168 + </view>
  169 + </view>
  170 + </view>
  171 +
  172 +</view>
  173 +
  174 +<!-- 生产总评 -->
  175 +
  176 +<view class="shengchanzog" wx:if="{{index==0}}">
  177 + <!-- 企业生产总评-->
  178 +
  179 + <view class="shebeinum">
  180 + <text class="she">企业生产总评</text>
  181 + </view>
  182 +
  183 + <view class="containerzhe con">
  184 + <ec-canvas id="mychart-dom-graph" canvas-id="mychart-graph" ec="{{ ec8 }}"></ec-canvas>
  185 + </view>
  186 +
  187 + <!-- 企业得分 -->
  188 +
  189 + <view class="companybox">
  190 + <view class="boxhead">
  191 + <view class="boxtopitem">企业名称</view>
  192 + <view class="boxtopitem">生产平稳性</view>
  193 + <view class="boxtopitem">生产趋势</view>
  194 + <view class="boxtopitem">生产状态</view>
  195 + <view class="boxtopitem">综合评分</view>
  196 + </view>
  197 + <view class="boxhead">
  198 + <view class="boxbottomitem">无锡市好事达人供 应链管理有限公司
  199 + </view>
  200 + <view class="boxbottomitem common">较平稳</view>
  201 + <view class="boxbottomitem common">下降</view>
  202 + <view class="boxbottomitem common">正常</view>
  203 + <view class="boxbottomitem common">87</view>
  204 + </view>
  205 + </view>
  206 +
  207 + <view class="desbox">
  208 + <view class="desboxhead">分析</view>
  209 + <view class="destext">
  210 + 在分析无锡市好事达供应链管理有限公司时,综合考虑该公司客观生产信息、生产稳定性、预警提示信息等维度,进行主客观综合评分。
  211 +
  212 + </view>
  213 + </view>
  214 +</view>
  215 +<!-- 生产预警 -->
  216 +
  217 +<view class="yujing">
  218 + <view class="yujinghead">
  219 + <view class="yuitem xuhao">序号</view>
  220 + <view class="yuitem time">生产预警时间</view>
  221 + <view class="yuitem reason">生产预警原因</view>
  222 + </view>
  223 +
  224 + <view class="yujingbox">
  225 + <view class="yujingitem">
  226 + <view class="yuitem xuhao">1</view>
  227 + <view class="yuitem time">2019-06-12</view>
  228 + <view class="yuitem text">在分析无锡市好事达供应链管理有限公司时,综合考虑该公司客观生产信息、生产稳定性、预警提示信息等维度,进行主客观综合评分。</view>
  229 + </view>
  230 + <view class="yujingitem">
  231 + <view class="yuitem xuhao">1</view>
  232 + <view class="yuitem time">2019-06-12</view>
  233 + <view class="yuitem text">在分析无锡市好事达供应链管理有限公司时,综合考虑该公司客观生产信息、生产稳定性、预警提示信息等维度,进行主客观综合评分。</view>
  234 + </view>
  235 + <view class="yujingitem">
  236 + <view class="yuitem xuhao">1</view>
  237 + <view class="yuitem time">2019-06-12</view>
  238 + <view class="yuitem text">在分析无锡市好事达供应链管理有限公司时,综合考虑该公司客观生产信息、生产稳定性、预警提示信息等维度,进行主客观综合评分。</view>
  239 + </view>
  240 + <view class="yujingitem">
  241 + <view class="yuitem xuhao">1</view>
  242 + <view class="yuitem time">2019-06-12</view>
  243 + <view class="yuitem text">在分析无锡市好事达供应链管理有限公司时,综合考虑该公司客观生产信息、生产稳定性、预警提示信息等维度,进行主客观综合评分。</view>
  244 + </view>
  245 +
  246 +
  247 +
  248 + </view>
  249 +</view>
  1 +@import "../zhishudetail/member/member.wxss";
  2 +
  3 +.date {
  4 + background: #ff9400;
  5 +}
  6 +
  7 +.datesel {
  8 + color: #fff;
  9 +}
  10 +
  11 +.containerzhe {
  12 + height: 800rpx;
  13 + margin-top: 40rpx;
  14 +}
  15 +
  16 +.seemore {
  17 + width: 132rpx;
  18 + height: 49rpx;
  19 + background: rgba(211, 227, 255, 1);
  20 + opacity: 1;
  21 + border-radius: 4rpx;
  22 + font-size: 24rpx;
  23 + color: #538aee;
  24 + text-align: center;
  25 + line-height: 49rpx;
  26 + margin: 0 auto;
  27 +}
  28 +
  29 +.boxhead {
  30 + display: flex;
  31 + align-items: center;
  32 + justify-content: space-between;
  33 +}
  34 +
  35 +.companybox {
  36 + padding: 0 17rpx;
  37 + box-sizing: border-box;
  38 + margin-top: 40rpx;
  39 +}
  40 +
  41 +.boxtopitem {
  42 + width: 190rpx;
  43 + padding: 47rpx 10rpx;
  44 + box-sizing: border-box;
  45 + color: #333;
  46 + font-size: 24rpx;
  47 + border-right: 1rpx solid #f5f5f5;
  48 + border-top: 1rpx solid #f5f5f5;
  49 + border-bottom: 1rpx solid #f5f5f5;
  50 + text-align: center;
  51 +}
  52 +
  53 +.boxtopitem:first-child {
  54 + border-left: 1rpx solid #f5f5f5;
  55 +}
  56 +
  57 +.boxbottomitem {
  58 + width: 190rpx;
  59 + height:130rpx;
  60 + line-height: 130rpx;
  61 + padding: 10rpx;
  62 + box-sizing: border-box;
  63 + color: #333;
  64 + font-size: 24rpx;
  65 + border-right: 1rpx solid #f5f5f5;
  66 + border-bottom: 1rpx solid #f5f5f5;
  67 + text-align: center;
  68 + display: -webkit-box ;
  69 +overflow: hidden;
  70 +text-overflow: ellipsis;
  71 +word-break: break-all;
  72 +-webkit-box-orient:vertical;
  73 +-webkit-line-clamp:4;
  74 +}
  75 +
  76 +.boxbottomitem:first-child {
  77 + border-left: 1rpx solid #f5f5f5;
  78 + text-align: left;
  79 + line-height: 1.3;
  80 +}
  81 +
  82 +.common {
  83 + color: #ff8e5a;
  84 +}
  85 +
  86 +.desbox {
  87 + width: 710rpx;
  88 + margin: 0 auto;
  89 + border: 1rpx solid #d6d8db;
  90 + border-radius: 10rpx;
  91 + padding-bottom: 20rpx;
  92 + box-sizing: border-box;
  93 + margin-top: 50rpx;
  94 +}
  95 +
  96 +.destext {
  97 + padding: 20rpx 20rpx 30rpx;
  98 + box-sizing: border-box;
  99 + color: #333;
  100 + font-size: 28rpx;
  101 +}
  102 +
  103 +.desboxhead {
  104 + height: 70rpx;
  105 + background: #eef1f9;
  106 + line-height: 70rpx;
  107 + padding: 0 20rpx;
  108 + box-sizing: border-box;
  109 + color: #333;
  110 + font-size: 32rpx;
  111 + font-weight: bold;
  112 +}
  113 +
  114 +.commonstate {
  115 + color: #ff8e5a;
  116 +}
  117 +
  118 +.worktime {
  119 + padding-bottom: 30rpx;
  120 + border-bottom: 20rpx solid #f6f7f8;
  121 +}
  122 +.atten{
  123 + color:#538AEE;
  124 + font-size: 20rpx;
  125 + padding: 0 32rpx;
  126 + box-sizing: border-box;
  127 +
  128 +}
  129 +.con {
  130 + width: 100%;
  131 + height: 382rpx;
  132 + margin: 0 auto;
  133 + display: flex;
  134 + justify-content: center;
  135 + align-items: center;
  136 +}
  137 +.con ec-canvas{
  138 + width:100%;
  139 + height:100%;
  140 +}
  141 +.yujinghead{
  142 + display:flex;
  143 + align-items: center;
  144 + /* justify-content: space-between; */
  145 + padding: 27rpx 40rpx;
  146 + box-sizing: border-box;
  147 + background: #F4F4F4;
  148 + color:#A0A0A0;
  149 + font-size: 24rpx;
  150 +}
  151 +.yuitem{
  152 + text-align: center
  153 +}
  154 +.xuhao{
  155 + width:48rpx;
  156 +}
  157 +.time{
  158 + /* width:116rpx; */
  159 + margin-left:40rpx;
  160 +}
  161 +.reason{
  162 + margin-left:49rpx;
  163 + width:56%;
  164 +}
  165 +.yujingbox{
  166 +
  167 +
  168 + padding: 0 40rpx;
  169 + box-sizing: border-box;
  170 +
  171 +
  172 +
  173 +}
  174 +.yujingitem{
  175 + display:flex;
  176 + align-items: center;
  177 + /* justify-content: space-between; */
  178 + padding: 27rpx 0;
  179 + box-sizing: border-box;
  180 +
  181 + color:#A0A0A0;
  182 + font-size: 24rpx;
  183 + border-bottom:1rpx solid #f5f5f5;
  184 +}
  185 +.text{
  186 + margin-left:49rpx;
  187 + width:56%;
  188 + text-align: left
  189 +}
  1 +// pages/member/member.js
  2 +import * as echarts from '../../../../ec-canvas/echarts';
  3 +const app = getApp()
  4 +
  5 +
  6 +function initChart1(canvas, width, height) {
  7 + const chart = echarts.init(canvas, null, {
  8 + width: width,
  9 + height: height
  10 + });
  11 + canvas.setChart(chart);
  12 +
  13 + var option = {
  14 + title: {
  15 + text: '',
  16 + subtext: ''
  17 + },
  18 +
  19 + tooltip: {
  20 + trigger: 'axis'
  21 + },
  22 + legend: {
  23 + data: ['进车辆数', '出车辆数'],
  24 + textStyle: {
  25 + fontSize: 14
  26 + },
  27 +
  28 + },
  29 + toolbox: {
  30 +
  31 +
  32 + },
  33 + xAxis: {
  34 + type: 'category',
  35 + boundaryGap: false,
  36 + data: ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '30', '31'],
  37 + axisLabel: {
  38 + interval: 1,
  39 + textStyle: {
  40 + fontSize: 12
  41 + },
  42 + },
  43 + nameTextStyle: { //在name值存在下,设置name的样式
  44 +
  45 + color: '#333',
  46 + fontStyle: 'normal',
  47 +
  48 +
  49 + },
  50 +
  51 +
  52 + },
  53 + yAxis: {
  54 + type: 'value',
  55 + min: 10,
  56 + max: 100,
  57 + splitNumber: 10,
  58 +
  59 +
  60 + axisLabel: {
  61 + formatter: '{value}',
  62 + textStyle: {
  63 + fontSize: 10
  64 + },
  65 + }
  66 + },
  67 + series: [{
  68 + name: '进车辆数',
  69 + type: 'line',
  70 + color: '#FF5345',
  71 + data: [11, 11, 15, 13, 12, 13, 10],
  72 + markPoint: {
  73 + data: [{
  74 + type: 'max',
  75 + name: '最大值'
  76 + },
  77 + {
  78 + type: 'min',
  79 + name: '最小值'
  80 + }
  81 + ]
  82 + },
  83 + markLine: {
  84 + data: [{
  85 + type: 'average',
  86 + name: '平均值'
  87 + }]
  88 + }
  89 + },
  90 + {
  91 + name: '出车辆数',
  92 + type: 'line',
  93 + color: '#6497F5',
  94 + data: [78, 20, 44, 33, 25, 45, 67],
  95 + markPoint: {
  96 + data: [{
  97 + name: '周最低',
  98 + value: 10,
  99 + xAxis: 1,
  100 + yAxis:10
  101 + }]
  102 + },
  103 + markLine: {
  104 + data: [{
  105 + type: 'average',
  106 + name: '平均值'
  107 + },
  108 + [{
  109 + symbol: 'none',
  110 + x: '90%',
  111 + yAxis: 'max'
  112 + }, {
  113 + symbol: 'circle',
  114 + label: {
  115 + normal: {
  116 + position: 'start',
  117 + formatter: '最大值'
  118 + }
  119 + },
  120 + type: 'max',
  121 + name: '最高点'
  122 + }]
  123 + ]
  124 + }
  125 + }
  126 + ]
  127 + };
  128 +
  129 +
  130 + chart.setOption(option);
  131 + return chart;
  132 +}
  133 +
  134 +Page({
  135 +
  136 + onShareAppMessage: function(res) {
  137 + return {
  138 + title: 'ECharts 可以在微信小程序中使用啦!',
  139 + path: '',
  140 + success: function() {},
  141 + fail: function() {}
  142 + }
  143 + },
  144 +
  145 + /**
  146 + * 页面的初始数据
  147 + */
  148 + data: {
  149 + state: 1,
  150 + timestate: 1,
  151 + ec1: {
  152 + onInit: initChart1,
  153 + },
  154 + statedate: '',
  155 + showdate: "",
  156 + watertime: '',
  157 + timesel: 1,
  158 + timearr: [
  159 +
  160 +
  161 + ],
  162 + date: '',
  163 + datePickerValue: ['', '', ''],
  164 + datePickerIsShow: false,
  165 + datechu: false,
  166 + currentdate: true,
  167 + //开始日期
  168 + startdate: '',
  169 + //结束日期
  170 + enddate: '',
  171 +
  172 + // 车辆状况日期
  173 + showModal: false,
  174 + monthList: ["1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月"],
  175 + time: '',
  176 + year:''
  177 +
  178 + },
  179 +
  180 + /**
  181 + * 生命周期函数--监听页面加载
  182 + */
  183 + onLoad: function(options) {
  184 + this.setData({
  185 + statedate: app.monthnowDate(),
  186 + watertime: app.newnowDate() + '-' + app.endate(),
  187 + startdate: app.newnowDate(),
  188 + enddate: app.endate()
  189 + })
  190 +
  191 +
  192 +
  193 + //默认车辆状况日期
  194 + var date = new Date();
  195 + var month = date.getMonth() + 1;
  196 + var year=date.getFullYear();
  197 + this.setData({
  198 + showdate:year+'年'+month+'月'
  199 + })
  200 + if (month == 1 || month == 3 || month == 5 || month == 7 || month == 8 || month == 10 || month == 12) {
  201 + if (month < 10) {
  202 + this.setData({
  203 + time: "(" + year+"." + "0" + month + ".01" + "-2019." + '0' + month + ".31" + ")"
  204 + })
  205 + } else {
  206 + this.setData({
  207 + time: "(" + year+"." + month + ".01" + "-2019." + month + ".31" + ")"
  208 + })
  209 + }
  210 +
  211 + } else {
  212 + if (month < 10) {
  213 + this.setData({
  214 + time: "(" + year+"." + "0" + month + ".01" + "-2019." + '0' + month + ".30" + ")"
  215 + })
  216 + } else {
  217 + this.setData({
  218 + time: "(" + year+"." + month + ".01" + "-2019." + month + ".30" + ")"
  219 + })
  220 + }
  221 +
  222 + }
  223 +
  224 + },
  225 +
  226 + //车辆状况日期
  227 + choice(e) {
  228 +
  229 + //默认显示当前月份
  230 +
  231 +
  232 + this.setData({
  233 + showt: false
  234 + })
  235 +
  236 + var date = new Date();
  237 +
  238 + var year = date.getFullYear()
  239 + let index = e.currentTarget.dataset.id;
  240 + index = index + 1
  241 + if (index == 1 || index == 3 || index == 5 || index == 7 || index == 8 || index == 10 || index == 12) {
  242 + if (month < 10) {
  243 + this.setData({
  244 + time: "(" + year + "." + "0" + index + ".01" + "-2019." + '0' + index + ".31" + ")"
  245 + })
  246 + } else {
  247 + this.setData({
  248 + time: "(" + year + "." + index + ".01" + "-2019." + index + ".31" + ")"
  249 + })
  250 + }
  251 +
  252 + } else {
  253 + if (index < 10) {
  254 + this.setData({
  255 + time: "(" + year + "." + "0" + index + ".01" + "-2019." + '0' + index + ".30" + ")"
  256 + })
  257 + } else {
  258 + this.setData({
  259 + time: "(" + year + "." + index + ".01" + "-2019." + index + ".30" + ")"
  260 + })
  261 + }
  262 +
  263 + }
  264 + this.setData({
  265 + changeColor: index - 1,
  266 + showdate: year + '年' + index + '月'
  267 +
  268 + })
  269 +
  270 + },
  271 + three() {
  272 + this.setData({
  273 + time: '近30天',
  274 + showt: !this.data.showt,
  275 + changeColor: -1
  276 + })
  277 + },
  278 + toShowModal(e) {
  279 + this.setData({
  280 + showModal: true
  281 +
  282 + })
  283 +
  284 + var date = new Date();
  285 +
  286 + var mon = date.getMonth();
  287 + console.log(mon)
  288 + this.setData({
  289 + changeColor: mon
  290 + })
  291 + },
  292 +
  293 + hideModal() {
  294 + this.setData({
  295 + showModal: false
  296 + });
  297 + },
  298 +
  299 + showDatePicker: function(e) {
  300 + // this.data.datePicker.show(this);
  301 + this.setData({
  302 + datePickerIsShow: true,
  303 + });
  304 + },
  305 +
  306 + datePickerOnSureClick: function(e) {
  307 + console.log('datePickerOnSureClick');
  308 +
  309 + if (this.data.timesel == 1) {
  310 + console.log(e);
  311 + this.setData({
  312 + date: `${e.detail.value[0]}${e.detail.value[1]}${e.detail.value[2]}日`,
  313 + datePickerValue: e.detail.value,
  314 + datePickerIsShow: false,
  315 + currentdate: false,
  316 +
  317 + startdate: e.detail.value[0] + '.' + e.detail.value[1] + "." + e.detail.value[2]
  318 + });
  319 + } else {
  320 + console.log(e);
  321 + this.setData({
  322 + date: `${e.detail.value[0]}${e.detail.value[1]}${e.detail.value[2]}日`,
  323 + datePickerValue: e.detail.value,
  324 + datePickerIsShow: false,
  325 + currentdate: false,
  326 +
  327 + enddate: e.detail.value[0] + '.' + e.detail.value[1] + "." + e.detail.value[2]
  328 + });
  329 + }
  330 +
  331 + },
  332 +
  333 + datePickerOnCancelClick: function(event) {
  334 + console.log('datePickerOnCancelClick');
  335 + console.log(event);
  336 + this.setData({
  337 + datePickerIsShow: false,
  338 +
  339 + currentdate: false,
  340 +
  341 + });
  342 + },
  343 + changedate(e) {
  344 + console.log(e)
  345 + },
  346 + // 选择设备切换
  347 + selectshebei(e) {
  348 + this.setData({
  349 + state: e.currentTarget.dataset.id,
  350 +
  351 + })
  352 + // if (e.currentdate.dataset.id == 1) {
  353 + // this.setData({
  354 + // ec1: {
  355 + // onInit: initChart1,
  356 + // },
  357 + // })
  358 + // }
  359 + },
  360 +
  361 + // 显示日期
  362 + datexianshi() {
  363 + this.setData({
  364 + datechu: true,
  365 + currentdate: true
  366 + })
  367 +
  368 + //获取年
  369 + var date = new Date();
  370 + var obj = {}
  371 + var year = date.getFullYear();
  372 + var month = date.getMonth() + 1;
  373 + if (month < 10) {
  374 + month = '0' + month
  375 + }
  376 +
  377 + var day = date.getDate();
  378 + if (day < 10) {
  379 + day = "0" + day
  380 + }
  381 + console.log()
  382 + if (typeof(day) == 'number') {
  383 + day = day.toString()
  384 + }
  385 + console.log(typeof(day))
  386 + this.setData({
  387 + datePickerValue: [year, month, day],
  388 + })
  389 +
  390 + },
  391 +
  392 +
  393 + // 选择时间和摄像头切换
  394 + seltime(e) {
  395 + this.setData({
  396 + timestate: e.currentTarget.dataset.id
  397 + })
  398 + },
  399 +
  400 + //开始时间和结束时间切换
  401 + xuanshijan(e) {
  402 + this.setData({
  403 + timesel: e.currentTarget.dataset.time,
  404 + currentdate: true
  405 + })
  406 +
  407 + this.datexianshi()
  408 + },
  409 +
  410 +
  411 + //确定选择开始日期和结束日期
  412 + qudingxuandate() {
  413 + this.setData({
  414 + datechu: false,
  415 + watertime: this.data.startdate + '-' + this.data.enddate
  416 + })
  417 + },
  418 + /**
  419 + * 生命周期函数--监听页面初次渲染完成
  420 + */
  421 + onReady: function() {
  422 +
  423 + },
  424 +
  425 + /**
  426 + * 生命周期函数--监听页面显示
  427 + */
  428 + onShow: function() {
  429 +
  430 +
  431 +
  432 +
  433 +
  434 + },
  435 +
  436 + /**
  437 + * 生命周期函数--监听页面隐藏
  438 + */
  439 + onHide: function() {
  440 +
  441 + },
  442 +
  443 + /**
  444 + * 生命周期函数--监听页面卸载
  445 + */
  446 + onUnload: function() {
  447 +
  448 + },
  449 +
  450 + /**
  451 + * 页面相关事件处理函数--监听用户下拉动作
  452 + */
  453 + onPullDownRefresh: function() {
  454 +
  455 + },
  456 +
  457 + /**
  458 + * 页面上拉触底事件的处理函数
  459 + */
  460 + onReachBottom: function() {
  461 +
  462 + },
  463 +
  464 + /**
  465 + * 用户点击右上角分享
  466 + */
  467 + onShareAppMessage: function() {
  468 +
  469 + }
  470 +})
  1 +{
  2 + "navigationBarTitleText": "车辆",
  3 + "usingComponents": {
  4 + "ec-canvas": "../../../../ec-canvas/ec-canvas",
  5 + "date-picker": "../../../../components/date-picker/date-picker"
  6 + }
  7 +}
  1 +<!-- 车辆流水日期弹出层 -->
  2 +<view class="register" wx:if="{{datechu}}">
  3 +
  4 + <view class="timewrap">
  5 + <view class="detailhead">
  6 + <view class="detailname {{timestate==1?'selactive':''}}" bindtap="seltime" data-id="1">选择时间</view>
  7 + <view class="detailname {{timestate==2?'selactive':''}}" bindtap="seltime" data-id="2">选摄像头</view>
  8 + </view>
  9 +
  10 + <!-- 开始时间和结束时间 -->
  11 +
  12 + <view class="timetwo">
  13 + <view class="timebetin" bindtap="xuanshijan" data-time="1">
  14 +
  15 + <view class="timetop {{timesel==1?'seltimeactive':''}}">开始时间</view>
  16 + <view class="timebottom {{timesel==1?'selnameactive':''}}">{{startdate}}</view>
  17 + </view>
  18 + <view class="timebetin" bindtap="xuanshijan" data-time="2">
  19 +
  20 + <view class="timetop {{timesel==2?'seltimeactive':''}}">结束时间</view>
  21 + <view class="timebottom {{timesel==2?'selnameactive':''}}">{{enddate}}</view>
  22 + </view>
  23 + </view>
  24 +
  25 + <view class="timebox" wx:if="{{currentdate}}">
  26 + <view class="timeboxitem {{sel==index?'timeboxactive':''}}" wx:for="{{timearr}}" wx:key="">
  27 + <view class="itemcontent">{{item.year}}</view>
  28 + <view class="itemcontent">{{item.month}}</view>
  29 + <view class="itemcontent">{{item.day}}</view>
  30 + </view>
  31 +
  32 +
  33 + </view>
  34 + <view class="qudingdate" wx:else bindtap='qudingxuandate'>确定</view>
  35 +
  36 +
  37 + <view wx:if="{{currentdate}}">
  38 +
  39 + <date-picker id="date-picker" value="{{datePickerValue}}" isShow="{{datePickerIsShow}}" bindsureclick="datePickerOnSureClick" bindcancelclick="datePickerOnCancelClick" />
  40 +
  41 + </view>
  42 + </view>
  43 +</view>
  44 +
  45 +<!-- 车辆状况日期弹出层 -->
  46 +
  47 +<view class="modal-mask" bindtap="hideModal" wx:if="{{showModal}}"></view>
  48 +<view wx:if="{{showModal}}">
  49 + <view class="modal-content">
  50 + <!-- 年份 -->
  51 + <view class="modal_year">2019年</view>
  52 + <!-- 月份 -->
  53 + <view class="modal_month">
  54 + <view class="month_single {{changeColor == index?'change':''}}" wx:for="{{monthList}}" wx:key="" data-id="{{index}}" catchtap="choice">{{item}}</view>
  55 + </view>
  56 + <view class="date_descript {{showt==true?'tactive':''}}" bindtap="three">近30天</view>
  57 + <view class='btns'>
  58 + <view class="cacle" bindtap="hideModal">取消</view>
  59 + <view class="cacle sure" bindtap="hideModal">确定</view>
  60 + </view>
  61 + </view>
  62 +</view>
  63 +
  64 +
  65 +
  66 +<view class="detailhead">
  67 + <view class="detailname {{state==1?'selactive':''}}" bindtap="selectshebei" data-id="1">车辆状况</view>
  68 + <view class="detailname {{state==2?'selactive':''}}" bindtap="selectshebei" data-id="2">车辆流水</view>
  69 +
  70 +</view>
  71 +
  72 +
  73 +<!-- 车辆状况 -->
  74 +
  75 +<view class="peoplestate" wx:if="{{state==1}}">
  76 + <!-- <view class="date" bindtap="datexianshi">
  77 + <view class="dateleft">
  78 + <image src="/img/row.png"></image>
  79 + </view>
  80 + <view class="datetime">
  81 + <view class="datesel">
  82 + {{watertime}}
  83 + </view>
  84 +
  85 + <view class="datepic">
  86 + <image src="/img/row.png"></image>
  87 + </view>
  88 + </view>
  89 +
  90 + <view class="dateright">
  91 + <image src="/img/row.png"></image>
  92 + </view>
  93 + </view> -->
  94 +
  95 + <view class="date" bindtap='toShowModal'>
  96 + <view class="dateleft">
  97 + <image src="/img/row.png"></image>
  98 + </view>
  99 + <view class="datetime">
  100 + <view class="datesel">
  101 + {{time}}
  102 + </view>
  103 +
  104 + <view class="datepic">
  105 + <image src="/img/row.png"></image>
  106 + </view>
  107 + </view>
  108 +
  109 + <view class="dateright">
  110 + <image src="/img/row.png"></image>
  111 + </view>
  112 + </view>
  113 +
  114 +
  115 + <view class="shebeinum">
  116 + <text class="she">车辆进出信息</text>
  117 + </view>
  118 +
  119 + <view class="containerzhe">
  120 + <ec-canvas id="mychart-dom-line" canvas-id="mychart-line" ec="{{ ec1 }}"></ec-canvas>
  121 + </view>
  122 +
  123 + <view class="datetime">{{showdate}}</view>
  124 +
  125 +
  126 +</view>
  127 +
  128 +<!-- 车辆流水 -->
  129 +
  130 +<view class="lishui" wx:if="{{state==2}}">
  131 + <view class="date" bindtap="datexianshi">
  132 + <view class="dateleft">
  133 + <image src="/img/row.png"></image>
  134 + </view>
  135 + <view class="datetime">
  136 + <view class="datesel">
  137 + {{watertime}}
  138 + </view>
  139 +
  140 + <view class="datepic">
  141 + <image src="/img/row.png"></image>
  142 + </view>
  143 + </view>
  144 +
  145 + <view class="dateright">
  146 + <image src="/img/row.png"></image>
  147 + </view>
  148 + </view>
  149 +
  150 + <view class="shuibox">
  151 +
  152 + <view class="shihead">
  153 + <view class="headitem shijian">时间</view>
  154 + <view class="headitem shexiang">摄像头</view>
  155 + <view class="headitem derition">方向</view>
  156 +
  157 + </view>
  158 + <view class="shuicontent">
  159 + <view class="shuiitem">
  160 + <view class="shuiitemleft shijian">06.01</view>
  161 + <view class="shuiitemleft shexiang">大厅左上角</view>
  162 + <view class="shuiitemleft derition">进</view>
  163 + </view>
  164 + <view class="shuiitem">
  165 + <view class="shuiitemleft shijian">06.01</view>
  166 + <view class="shuiitemleft shexiang">大厅左上角</view>
  167 + <view class="shuiitemleft derition">进</view>
  168 + </view>
  169 +
  170 + <view class="shuiitem">
  171 + <view class="shuiitemleft shijian">06.01</view>
  172 + <view class="shuiitemleft shexiang">大厅左上角</view>
  173 + <view class="shuiitemleft derition">进</view>
  174 + </view>
  175 + <view class="shuiitem">
  176 + <view class="shuiitemleft shijian">06.01</view>
  177 + <view class="shuiitemleft shexiang">车间后方大转盘</view>
  178 + <view class="shuiitemleft derition">进</view>
  179 + </view>
  180 + </view>
  181 +
  182 + </view>
  183 +
  184 +</view>
  1 +@import "../qiyeyongdian/detail/detail.wxss";
  2 +
  3 +.detailhead {
  4 + display: flex;
  5 + align-items: center;
  6 + justify-content: space-around;
  7 + padding: 20rpx 69rpx;
  8 + box-sizing: border-box;
  9 + border-bottom: 1rpx solid #f5f5f5;
  10 +}
  11 +
  12 +.detailname {
  13 + color: #999;
  14 + font-size: 28rpx;
  15 +}
  16 +
  17 +.selactive {
  18 + position: relative;
  19 +}
  20 +
  21 +.selactive::after {
  22 + display: block;
  23 + content: '';
  24 + width: 60rpx;
  25 +
  26 + border: 1rpx solid #ff9400;
  27 + position: absolute;
  28 + left: 50%;
  29 + right: 50%;
  30 + transform: translate(-50%);
  31 + bottom: -20rpx;
  32 +}
  33 +
  34 +.date {
  35 + display: flex;
  36 + align-items: center;
  37 + justify-content: space-between;
  38 + height: 70rpx;
  39 + background: #f3f5f8;
  40 + padding: 0 31rpx;
  41 + box-sizing: border-box;
  42 +}
  43 +
  44 +.dateleft {
  45 + width: 23rpx;
  46 + height: 23rpx;
  47 + font-size: 0;
  48 + transform: rotate(180deg);
  49 +}
  50 +
  51 +.dateright {
  52 + width: 23rpx;
  53 + height: 23rpx;
  54 + font-size: 0;
  55 +}
  56 +
  57 +.datetime {
  58 + display: flex;
  59 + align-items: center;
  60 +}
  61 +
  62 +.datepic {
  63 + width: 16rpx;
  64 + height: 16rpx;
  65 + font-size: 0;
  66 + transform: rotate(90deg);
  67 + margin-left: 12rpx;
  68 +}
  69 +
  70 +.datesel {
  71 + color: #666;
  72 + font-size: 28rpx;
  73 +}
  74 +
  75 +.shebeinum {
  76 + color: #333;
  77 + font-size: 32rpx;
  78 + font-weight: bold;
  79 + padding: 40rpx 0 0 30rpx;
  80 + box-sizing: border-box;
  81 + border-top: 1rpx solid #f5f5f5;
  82 + position: relative;
  83 +}
  84 +
  85 +.she {
  86 + margin-left: 18rpx;
  87 +}
  88 +
  89 +.shebeinum::before {
  90 + content: '';
  91 + display: block;
  92 + width: 8rpx;
  93 + height: 33rpx;
  94 + background: #ff9400ff;
  95 + position: absolute;
  96 + top: 43rpx;
  97 + left: 30rpx;
  98 +}
  99 +
  100 +.containerzhe {
  101 + width: 750rpx;
  102 + height: 500rpx;
  103 +}
  104 +
  105 +.datetime {
  106 + color: #333;
  107 + font-size: 28rpx;
  108 + display: flex;
  109 + justify-content: center;
  110 +}
  111 +
  112 +.timewrap {
  113 + background: #fff;
  114 + /* height: 700rpx; */
  115 + padding-bottom: 40rpx;
  116 + box-sizing: border-box
  117 +}
  118 +
  119 +.timetwo {
  120 + display: flex;
  121 + align-items: center;
  122 + padding: 60rpx 100rpx 50rpx;
  123 + box-sizing: border-box;
  124 + justify-content: space-between;
  125 +}
  126 +
  127 +.timebetin {
  128 + display: flex;
  129 + flex-direction: column;
  130 + justify-content: center;
  131 + align-items: center;
  132 +}
  133 +
  134 +.timetop {
  135 + color: #999;
  136 + font-size: 24rpx;
  137 +}
  138 +
  139 +.timebottom {
  140 + color: #999;
  141 + font-size: 32rpx;
  142 + margin-top: 10rpx;
  143 +}
  144 +
  145 +.seltimeactive {
  146 + color: #ff9400;
  147 +}
  148 +
  149 +.selnameactive {
  150 + color: #333;
  151 +}
  152 +
  153 +.timebox {
  154 + width: 580rpx;
  155 + height: 308rpx;
  156 + overflow-y: scroll;
  157 + margin: 0 auto;
  158 +}
  159 +
  160 +.timeboxitem {
  161 + display: flex;
  162 + align-items: center;
  163 + justify-content: space-between;
  164 + padding: 30rpx 78rpx;
  165 + box-sizing: border-box;
  166 + background: #f9f8fe;
  167 + color: #999;
  168 + font-size: 28rpx;
  169 + border-bottom: 1rpx solid #f5f5f5;
  170 +}
  171 +
  172 +.shihead {
  173 + display: flex;
  174 + align-items: center;
  175 + justify-content: space-between;
  176 + height: 100rpx;
  177 + padding: 0 28rpx;
  178 + border-bottom: 1rpx solid #f5f5f5;
  179 +}
  180 +
  181 +.headitem {
  182 + color: #666;
  183 + font-size: 28rpx;
  184 + text-align: left;
  185 +}
  186 +
  187 +.shuiitem {
  188 + display: flex;
  189 + align-items: center;
  190 + justify-content: space-between;
  191 + padding: 34rpx 28rpx;
  192 + box-sizing: border-box;
  193 + border-bottom: 1rpx solid #f5f5f5;
  194 +}
  195 +
  196 +.shuiitemleft {
  197 + color: #333;
  198 + font-size: 24rpx;
  199 + text-align: left;
  200 +}
  201 +
  202 +.shijian {
  203 + width: 60rpx;
  204 +}
  205 +
  206 +.shexiang {
  207 + width: 196rpx;
  208 + overflow: hidden;
  209 + text-overflow: ellipsis;
  210 + white-space: nowrap;
  211 +}
  212 +
  213 +.derition {
  214 + width: 56rpx;
  215 +}
  216 +
  217 +.qudingdate {
  218 + width: 260rpx;
  219 + height: 80rpx;
  220 + background: rgba(255, 148, 0, 1);
  221 + opacity: 1;
  222 + border-radius: 10rpx;
  223 + color:#fff;
  224 + font-size: 30rpx;
  225 + text-align: center;
  226 + line-height: 80rpx;
  227 + margin:8rpx auto 0;
  228 +
  229 +}
  1 +// pages/companybox/zhishudetail/chengpindetail/chengpindetail.js
  2 +Page({
  3 +
  4 + /**
  5 + * 页面的初始数据
  6 + */
  7 + data: {
  8 +
  9 + },
  10 +
  11 + /**
  12 + * 生命周期函数--监听页面加载
  13 + */
  14 + onLoad: function (options) {
  15 +
  16 + },
  17 +
  18 + /**
  19 + * 生命周期函数--监听页面初次渲染完成
  20 + */
  21 + onReady: function () {
  22 +
  23 + },
  24 +
  25 + /**
  26 + * 生命周期函数--监听页面显示
  27 + */
  28 + onShow: function () {
  29 +
  30 + },
  31 +
  32 + /**
  33 + * 生命周期函数--监听页面隐藏
  34 + */
  35 + onHide: function () {
  36 +
  37 + },
  38 +
  39 + /**
  40 + * 生命周期函数--监听页面卸载
  41 + */
  42 + onUnload: function () {
  43 +
  44 + },
  45 +
  46 + /**
  47 + * 页面相关事件处理函数--监听用户下拉动作
  48 + */
  49 + onPullDownRefresh: function () {
  50 +
  51 + },
  52 +
  53 + /**
  54 + * 页面上拉触底事件的处理函数
  55 + */
  56 + onReachBottom: function () {
  57 +
  58 + },
  59 +
  60 + /**
  61 + * 用户点击右上角分享
  62 + */
  63 + onShareAppMessage: function () {
  64 +
  65 + }
  66 +})
  1 +<!--pages/yuanliaomsg/yuanliaoDetail/yuanliaoDetail.wxml-->
  2 +<view class="detail_single first_single">
  3 + <view>时间</view>
  4 + <view>2019-07-03 19:00:00</view>
  5 +</view>
  6 +<view class="detail_single">
  7 + <view>地磅</view>
  8 + <view>安装位置/地磅名称</view>
  9 +</view>
  10 +<view class="detail_single">
  11 + <view>货物名称</view>
  12 + <view>安装位置/地磅名称</view>
  13 +</view>
  14 +<view class="detail_single">
  15 + <view>车牌号</view>
  16 + <view>784646</view>
  17 +</view>
  18 +<view class="detail_single">
  19 + <view>毛重(吨)</view>
  20 + <view>4154</view>
  21 +</view>
  22 +<view class="detail_single">
  23 + <view>皮重(吨)</view>
  24 + <view>4154</view>
  25 +</view>
  26 +<view class="detail_single">
  27 + <view>净重(吨)</view>
  28 + <view>4154</view>
  29 +</view>
  30 +<view class="equipment_pic">
  31 + <view>设备照片</view>
  32 + <view class="pic_group">
  33 + <view class="equipment_img">
  34 + <image src="/img/logo3.png"></image>
  35 + </view>
  36 + <view class="equipment_img">
  37 + <image src="/img/logo3.png"></image>
  38 + </view>
  39 + <view class="equipment_img">
  40 + <image src="/img/logo3.png"></image>
  41 + </view>
  42 + </view>
  43 +</view>
  1 +/* pages/yuanliaomsg/yuanliaoDetail/yuanliaoDetail.wxss */
  2 +
  3 +
  4 +.detail_single{
  5 + display: flex;
  6 + flex: row;
  7 + align-items: center;
  8 + justify-content: space-between;
  9 + padding: 30rpx;
  10 + border-bottom: 1rpx solid #f5f5f5;
  11 + color: #333;
  12 + font-size: 28rpx;
  13 +}
  14 +.first_single{
  15 + border-top: 1rpx solid #f5f5f5;
  16 +}
  17 +.equipment_pic{
  18 + padding:40rpx;
  19 + color: #333;
  20 + font-size: 32rpx;
  21 + font-weight: 600;
  22 +}
  23 +.pic_group{
  24 + display: flex;
  25 + flex-direction: row;
  26 + justify-content: space-between;
  27 + align-items: center;
  28 + margin-top: 30rpx;
  29 +}
  30 +.equipment_img{
  31 + width: 210rpx;
  32 + height: 210rpx;
  33 + border-radius: 10rpx;
  34 +}
  1 +// pages/ditu/ditu.js
  2 +Page({
  3 +
  4 + /**
  5 + * 页面的初始数据
  6 + */
  7 + data: {
  8 +
  9 + },
  10 +
  11 + /**
  12 + * 生命周期函数--监听页面加载
  13 + */
  14 + onLoad: function (options) {
  15 +
  16 + },
  17 +
  18 + /**
  19 + * 生命周期函数--监听页面初次渲染完成
  20 + */
  21 + onReady: function () {
  22 +
  23 + },
  24 +
  25 + /**
  26 + * 生命周期函数--监听页面显示
  27 + */
  28 + onShow: function () {
  29 +
  30 + },
  31 +
  32 + /**
  33 + * 生命周期函数--监听页面隐藏
  34 + */
  35 + onHide: function () {
  36 +
  37 + },
  38 +
  39 + /**
  40 + * 生命周期函数--监听页面卸载
  41 + */
  42 + onUnload: function () {
  43 +
  44 + },
  45 +
  46 + /**
  47 + * 页面相关事件处理函数--监听用户下拉动作
  48 + */
  49 + onPullDownRefresh: function () {
  50 +
  51 + },
  52 +
  53 + /**
  54 + * 页面上拉触底事件的处理函数
  55 + */
  56 + onReachBottom: function () {
  57 +
  58 + },
  59 +
  60 + /**
  61 + * 用户点击右上角分享
  62 + */
  63 + onShareAppMessage: function () {
  64 +
  65 + }
  66 +})
  1 +{
  2 + "usingComponents": {}
  3 +}
  1 +<!--pages/ditu/ditu.wxml-->
  2 +<text>pages/ditu/ditu.wxml</text>
  1 +/* pages/ditu/ditu.wxss */
  1 +module.exports = [{
  2 + "id": 1,
  3 + "name": "永州市中心医院",
  4 + "longitude": "111.62852107566833",
  5 + "latitude": "26.42142999357519"
  6 +
  7 +},
  8 + {
  9 + "id": 2,
  10 + "name": "永州市中医院",
  11 + "longitude": "111.5972679762268",
  12 + "latitude": "26.44470581245983"
  13 +
  14 +}
  15 +]