bc33159a90bf44d0a59ae4b525a10949929b9ed6.svn-base 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. $(function () {
  2. BWA.ChartOptions = BWA.ChartOptions || {};
  3. BWA.ChartOptions.PowerSavingCycle = BWA.ChartOptions.PowerSavingCycle || {};
  4. BWA.ChartOptions.PowerSavingCycle.getChartEtcOptions = function (codeTimeType) {
  5. return {
  6. palette: 'Bright',
  7. legend: {
  8. visible: true,
  9. verticalAlignment: 'top',
  10. horizontalAlignment: 'center'
  11. },
  12. //argumentAxis: BWA.Chart.getTimeLineArgumentAxis(null, codeTimeType),
  13. argumentAxis:
  14. {
  15. valueMarginsEnabled: false,
  16. argumentType: 'datetime',
  17. label: {
  18. alignment: 'center',
  19. format: 'HH시-mm분'
  20. },
  21. tickInterval: { minutes: 15 },
  22. },
  23. commonSeriesSettings: {
  24. argumentField: 'DateTime',
  25. selectionStyle: {
  26. hatching: {
  27. direction: 'left'
  28. }
  29. }
  30. },
  31. valueAxis: [
  32. {
  33. name: 'ppm',
  34. position: 'left',
  35. type: 'continuous',
  36. valueType: 'numeric',
  37. tickInterval: 10,
  38. label: {
  39. },
  40. title: {
  41. text: 'CO, CO2, OZONE(ppm)',
  42. },
  43. },
  44. {
  45. label: {
  46. },
  47. name: 'dust',
  48. position: 'right',
  49. title: {
  50. text: '미세먼지(㎍/㎥)',
  51. }
  52. }
  53. ],
  54. series: [
  55. {
  56. type: 'spline',
  57. valueField: 'Co',
  58. axis: 'ppm',
  59. visible: true,
  60. point: { size: 8 },
  61. name: 'CO',
  62. color: '#c96374',
  63. label: {
  64. visible: false,
  65. customizeText: function () {
  66. return this.valueText + ' °C';
  67. }
  68. }
  69. }, {
  70. type: 'spline',
  71. valueField: 'Co2',
  72. axis: 'ppm',
  73. point: { size: 8 },
  74. name: 'CO2',
  75. color: '#00A7C6',
  76. label: {
  77. visible: false,
  78. customizeText: function () {
  79. return this.valueText + ' %';
  80. }
  81. }
  82. },
  83. {
  84. type: 'spline',
  85. valueField: 'Dust',
  86. axis: 'dust',
  87. visible: true,
  88. point: { size: 8 },
  89. name: '미세먼지',
  90. label: {
  91. visible: false,
  92. customizeText: function () {
  93. return this.valueText + ' °C';
  94. }
  95. }
  96. }, {
  97. type: 'spline',
  98. valueField: 'Ozone',
  99. axis: 'ppm',
  100. point: { size: 8 },
  101. name: '오존',
  102. label: {
  103. visible: false,
  104. customizeText: function () {
  105. return this.valueText + ' %';
  106. }
  107. }
  108. }
  109. ],
  110. crosshair: {
  111. enabled: true,
  112. width: 2,
  113. label: {
  114. visible: true,
  115. backgroundColor: "#949494",
  116. font: {
  117. color: "#fff",
  118. size: 12,
  119. }
  120. }
  121. },
  122. tooltip: {
  123. enabled: true,
  124. color: "#3e1717",
  125. format: 'fixedPoint',
  126. precision: 2,
  127. font: {
  128. color: "white",
  129. size: 12,
  130. weight: 600,
  131. },
  132. argumentFormat: 'shortDate',
  133. customizeText: function () {
  134. return {
  135. text: [this.argumentText, ': ', this.valueText].join('')
  136. };
  137. }
  138. }
  139. };
  140. };
  141. });