| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239 | 
							- $(function () {
 
-     BWA.ChartOptions = BWA.ChartOptions || {};
 
-     BWA.ChartOptions.GreenEnergy = BWA.ChartOptions.GreenEnergy || {};
 
-     BWA.ChartOptions.GreenEnergy.getChartElecOptions = function (codeTimeType) {
 
-         return {
 
-             palette: "Bright",
 
-             legend: {
 
-                 visible: true,
 
-                 verticalAlignment: 'top',
 
-                 horizontalAlignment: 'center'
 
-             },
 
-             argumentAxis: BWA.Chart.getTimeLineArgumentAxis(moment(), codeTimeType),
 
-             commonSeriesSettings: {
 
-                 argumentField: "DateTime",
 
-                 selectionStyle: {
 
-                     hatching: {
 
-                         direction: "left"
 
-                     }
 
-                 }
 
-             },
 
-             valueAxis:
 
-             {
 
-                 name: 'elec', // 
 
-                 //position: 'right',
 
-                 label: {
 
-                     //font: { color: '#c96374' },
 
-                     visible: true,
 
-                 },
 
-                 title: {
 
-                     text: '생산전력량 (kWh)'
 
-                 }
 
-             },
 
-             series:
 
-             {
 
-                 axis: 'elec',
 
-                 type: 'bar',
 
-                 //color: 'red',
 
-                 name: '생산전력량',
 
-                 argumentField: "DateTime",
 
-                 valueField: 'elec', // 
 
-                 label: {
 
-                     visible: false,
 
-                 },
 
-                 point: { size: 4 },
 
-             },
 
-             tooltip: {
 
-                 format: 'fixedPoint',
 
-                 enabled: true,
 
-                 precision: 2,
 
-             },
 
-             crosshair: {
 
-                 enabled: true,
 
-                 width: 2,
 
-                 horizontalLine: {
 
-                     //color: 'limegreen',
 
-                     dashStyle: 'dash',
 
-                     visible: false
 
-                 },
 
-                 verticalLine: {
 
-                     //color: 'limegreen',
 
-                     dashStyle: 'dash',
 
-                 },
 
-                 label: {
 
-                     visible: true,
 
-                     backgroundColor: "#949494",
 
-                     font: {
 
-                         color: "#fff",
 
-                         size: 12,
 
-                     }
 
-                 }
 
-             }
 
-         };
 
-     };
 
-     BWA.ChartOptions.GreenEnergy.getChartElecConsumeOptions = function (codeTimeType) {
 
-         return {
 
-             palette: "Harmony Light",
 
-             legend: {
 
-                 visible: true,
 
-                 verticalAlignment: 'top',
 
-                 horizontalAlignment: 'center'
 
-             },
 
-             argumentAxis: BWA.Chart.getTimeLineArgumentAxis(moment(), codeTimeType),
 
-             commonSeriesSettings: {
 
-                 argumentField: "DateTime",
 
-                 selectionStyle: {
 
-                     hatching: {
 
-                         direction: "left"
 
-                     }
 
-                 }
 
-             },
 
-             valueAxis:
 
-             {
 
-                 name: 'elec', // 
 
-                 //position: 'right',
 
-                 label: {
 
-                     //font: { color: '#c96374' },
 
-                     visible: true,
 
-                 },
 
-                 title: {
 
-                     text: '소비전력량 (kWh)'
 
-                 }
 
-             },
 
-             series:
 
-             {
 
-                 axis: 'elec',
 
-                 type: 'bar',
 
-                 //color: 'red',
 
-                 name: '소비전력량',
 
-                 argumentField: "DateTime",
 
-                 valueField: 'elec', // 
 
-                 label: {
 
-                     visible: false,
 
-                 },
 
-                 point: { size: 4 },
 
-             },
 
-             tooltip: {
 
-                 format: 'fixedPoint',
 
-                 enabled: true,
 
-                 precision: 2,
 
-             },
 
-             crosshair: {
 
-                 enabled: true,
 
-                 width: 2,
 
-                 horizontalLine: {
 
-                     //color: 'limegreen',
 
-                     dashStyle: 'dash',
 
-                     visible: false
 
-                 },
 
-                 verticalLine: {
 
-                     //color: 'limegreen',
 
-                     dashStyle: 'dash',
 
-                 },
 
-                 label: {
 
-                     visible: true,
 
-                     backgroundColor: "#949494",
 
-                     font: {
 
-                         color: "#fff",
 
-                         size: 12,
 
-                     }
 
-                 }
 
-             }
 
-         };
 
-     };
 
-     BWA.ChartOptions.GreenEnergy.getChartKcalOptions = function (codeTimeType) {
 
-         return {
 
-             palette: "Bright",
 
-             legend: {
 
-                 visible: true,
 
-                 verticalAlignment: 'top',
 
-                 horizontalAlignment: 'center'
 
-             },
 
-             //argumentAxis: BWA.Chart.getTimeLineArgumentAxis(null, codeTimeType),
 
-             commonSeriesSettings: {
 
-                 argumentField: "DateTime",
 
-                 selectionStyle: {
 
-                     hatching: {
 
-                         direction: "left"
 
-                     }
 
-                 }
 
-             },
 
-             valueAxis:
 
-             {
 
-                 name: 'kcal', // 
 
-                 //position: 'right',
 
-                 label: {
 
-                     //font: { color: '#c96374' },
 
-                     visible: true,
 
-                 },
 
-                 title: {
 
-                     text: '생산열량  (kcal)'
 
-                 }
 
-             },
 
-             series:
 
-             {
 
-                 axis: 'kcal',
 
-                 type: 'bar',
 
-                 name: '생산열량',
 
-                 //color:'red',
 
-                 argumentField: "DateTime",
 
-                 valueField: 'kcal', // 
 
-                 label: {
 
-                     visible: false,
 
-                 },
 
-                 point: { size: 4 },
 
-             },
 
-             tooltip: {
 
-                 enabled: true,
 
-                 format: 'fixedPoint',
 
-                 precision: 2,
 
-             },
 
-             crosshair: {
 
-                 enabled: true,
 
-                 width: 2,
 
-                 horizontalLine: {
 
-                     //color: 'limegreen',
 
-                     dashStyle: 'dash',
 
-                     visible: false
 
-                 },
 
-                 verticalLine: {
 
-                     //color: 'limegreen',
 
-                     dashStyle: 'dash',
 
-                 },
 
-                 label: {
 
-                     visible: true,
 
-                     backgroundColor: "#949494",
 
-                     font: {
 
-                         color: "#fff",
 
-                         size: 12,
 
-                     }
 
-                 }
 
-             }
 
-         };
 
-     };
 
-     BWA.ChartOptions.GreenEnergy.getMeasureSelectOptions = function () {
 
-         return {
 
-             dataSource: new Array('생산량', '소비량'),
 
-             onSelectionChanged: function () {
 
-                 //if (initialized){
 
-                 if ($("#measureSelect").dxSelectBox("instance").option('value') == '생산량') {
 
-                     document.getElementById("chartGreenElecConsume").style.visibility = "hidden";
 
-                     document.getElementById("chartGreenElec").style.visibility = "visible";
 
-                     $("#chartText").text('생산량 조회');
 
-                 } else {
 
-                     document.getElementById("chartGreenElec").style.visibility = "hidden";
 
-                     document.getElementById("chartGreenElecConsume").style.visibility = "visible";
 
-                     $("#chartText").text('소비량 조회');
 
-                 }
 
-                 //}
 
-             }
 
-         };
 
-     };
 
- });
 
 
  |