diff --git a/src/views/bigScreen/index_6dept.vue b/src/views/bigScreen/index_6dept.vue index 4fb96668..410bc15b 100644 --- a/src/views/bigScreen/index_6dept.vue +++ b/src/views/bigScreen/index_6dept.vue @@ -150,19 +150,17 @@ export default { bottom: '3%', containLabel: true }, - xAxis: [ - { - type: 'category', - boundaryGap: true, - 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日'], - nameTextStyle: { - color: '#ffffff' - }, - axisLabel: { - color: '#ffffff' - }, - } - ], + xAxis: { + type: 'category', + boundaryGap: true, + 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日'], + nameTextStyle: { + color: '#ffffff' + }, + axisLabel: { + color: '#ffffff' + }, + }, yAxis: [ { name: "生产统计", @@ -226,7 +224,7 @@ export default { position: 'insideTop', color:'#666' }, - data: [140, 232, 101, 264, 90, 340, 250,140, 232, 101, 264, 90, 340, 250,140, 232, 101, 264, 90, 340, 250,140, 232, 101, 264, 90, 340, 250, 340, 250] + data: [] }, { name: '管', @@ -272,7 +270,7 @@ export default { color:'#666', font:'10' }, - data:[100, 202, 101, 204, 190, 140, 150,100, 132, 161, 164, 190, 240, 150,110, 202, 100, 164, 90, 240, 150,340, 232, 101, 164, 190, 240, 250, 240, 150] + data:[] }, ] }, @@ -282,28 +280,8 @@ export default { table2Visible:false, refValue1:'moocBox1', refValue2:'moocBox2', - liData1: ['日期', '型号', '规格', '发货数量'], - listData1test: [ - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - [{elType:'primary',value:"2023-11-10"},{elType:'primary',value:"ZJ2"},{elType:'primary',value:"40/360"},{elType:'primary',value:368}], - ], - liData2: ['工序','产品名称', '型号', '计划数量', '合格数量', '完成进度', '合格率','操作人'], - listData2test: [ - [{elType:'primary',value:"平头"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:368},{elType:'progress',value:100},{elType:'primary',value:'60%'},{elType:'primary',value:'李斯'}], - [{elType:'primary',value:"粘头"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:360},{elType:'progress',value:99},{elType:'primary',value:'60%'},{elType:'primary',value:'王丽'}], - [{elType:'primary',value:"粗磨"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:350},{elType:'progress',value:99},{elType:'primary',value:'60%'},{elType:'primary',value:'杜克'}], - [{elType:'primary',value:"中磨"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:360},{elType:'progress',value:99},{elType:'primary',value:'60%'},{elType:'primary',value:'赵莉'}], - [{elType:'primary',value:"细磨"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:340},{elType:'progress',value:99},{elType:'primary',value:'60%'},{elType:'primary',value:'钱多'}], - [{elType:'primary',value:"抛光"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:300},{elType:'progress',value:99},{elType:'primary',value:'60%'},{elType:'primary',value:'孙桑'}], - [{elType:'primary',value:"开凿"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:320},{elType:'progress',value:99},{elType:'primary',value:'60%'},{elType:'primary',value:'周欸'}], - [{elType:'primary',value:"配管"},{elType:'primary',value:"光纤预制管"},{elType:'primary',value:"ZJ2"}, {elType:'primary',value:368},{elType:'primary',value:330},{elType:'progress',value:99},{elType:'primary',value:'60%'},{elType:'primary',value:'吴思'}], - ], + liData1: ['序号','日期', '型号', '规格', '发货数量'], + liData2: ['序号','工序','产品名称', '型号', '计划数量', '合格数量', '完成进度', '合格率','操作人'], todayMtask:[], saleOutData:[], processData:[], @@ -312,6 +290,7 @@ export default { end_date:'', scrollVivible:true, dayInterval:null, + chartInterval1:null, currentTime:'', currentDay:'', @@ -342,9 +321,6 @@ export default { this.yesterday = yesterday.getFullYear()+"-" + (yesterday.getMonth()+1) + "-" + yesterday.getDate(); this.getsaleOut(); - let chart1Option = deepCopy(this.basicOption) - this.setChart("chart1", chart1Option); - let chart2Option = deepCopy(this.basicOption) chart2Option.yAxis[0].name = '交付统计'; chart2Option.series[0].type = 'line'; @@ -482,16 +458,128 @@ export default { query: {start_date:this.start_date,end_date:this.end_date,dept_name: "6车间"}, }; let obj1 ={ - query: {start_date:this.start_date,end_date:this.end_date}, + query: {start_date:this.start_date,end_date:this.end_date,dept_name: "6车间"}, }; //生产车间按日统计 - that.$API.bi.dataset.exec.req('lineDay', obj).then((doInRes) => { - console.log('生产车间按日统计:',doInRes); + that.$API.bi.dataset.exec.req('lineDay', obj).then((res1) => { + console.log('生产车间按日统计:',res1); + let list1 = res1.data2.ds0; + let seriesData1 = [],xAxisData1=[]; + for (let i = 0; i < that.days; i++) { + let day = i+1; + let text = day+'日'; + xAxisData1[i]=text; + } + if(list1.length>0){ + list1.forEach(item1=>{ + let index1 = item1.日-1; + seriesData1[index1] = item1.生产数; + }) + } + console.log(xAxisData1) + console.log(seriesData1) + console.log('00000000000') + let chart1Option = deepCopy(this.basicOption) + chart1Option.xAxis.data = xAxisData1; + chart1Option.series[0].data=seriesData1; + let chart1 = this.setChart("chart1", chart1Option); + let index1 = 0 + this.chartInterval1 = setInterval(function () { + if (index1 < chart1Option.series[0].data.length) { + chart1.dispatchAction({ type: 'downplay', seriesIndex: 0 }); + chart1.dispatchAction({ type: 'highlight', seriesIndex: 0, dataIndex: index2 }); + chart1.dispatchAction({ type: 'showTip', seriesIndex: 0, dataIndex: index2 }); + index1++; + } else { + index1 = 0; + } + }, 3000); debugger; }); //本月交付统计 that.$API.bi.dataset.exec.req('saleOutDay', obj1).then((saleOutRes) => { console.log('本月交付统计:',saleOutRes); + // chart2Option.yAxis.name='合格率'; + // chart2Option.legend = { + // icon: "stack", + // right: 0, + // data: [{ + // backgroundColor: 'rgb(250,205,0)', + // name: '合格率', + // itemStyle: { + // color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + // { + // offset: 0, + // color: 'rgb(1,235,239)' + // }, + // { + // offset: 1, + // color: 'rgb(5, 158, 163)' + // } + // ]) + // }, + // textStyle: { + // color: '#fff' + // } + // }], + // }; + // let series2=[{ + // name: '合格率', + // type: 'line', + // smooth: true, + // lineStyle: { + // width: 1, color: 'rgb(1,235,239)' + // }, + // showSymbol: false, + // areaStyle: { + // opacity: 0.8, + // color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + // { + // offset: 0, + // color: 'rgb(1,235,239)' + // }, + // { + // offset: 1, + // color: 'rgb(5, 158, 163)' + // } + // ]) + // }, + // emphasis: { + // focus: 'series' + // }, + // label: { + // show: true, + // position: 'top', + // color:'#fff' + // }, + // itemStyle: { + // borderRadius: [2, 2, 0, 0], + // color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + // { + // offset: 0, + // color: 'rgb(250,205,0)' + // }, + // { + // offset: 1, + // color: 'rgb(254,129,0)' + // } + // ]) + // }, + // data: seriesData1 + // }]; + // chart2Option.series=series2; + // let chart2 = this.setChart("chart2", chart2Option); + // let index2 = 0 + // this.chartInterval2 = setInterval(function () { + // if (index2 < chart2Option.series[0].data.length) { + // chart2.dispatchAction({ type: 'downplay', seriesIndex: 0 }); + // chart2.dispatchAction({ type: 'highlight', seriesIndex: 0, dataIndex: index2 }); + // chart2.dispatchAction({ type: 'showTip', seriesIndex: 0, dataIndex: index2 }); + // index2++; + // } else { + // index2 = 0; + // } + // }, 3000); debugger; }); }, diff --git a/src/views/home/widgets/index_photon.vue b/src/views/home/widgets/index_photon.vue index 8a295056..78170772 100644 --- a/src/views/home/widgets/index_photon.vue +++ b/src/views/home/widgets/index_photon.vue @@ -92,14 +92,14 @@
{{monthPassRate7}}%
{{monthPassRate10}}%
@@ -107,7 +107,7 @@{{monthRateAVG}}%
@@ -236,12 +236,6 @@