bcb1f4eadea0364485264eb4bfed51b88c4965d4.svn-base 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. $(function () {
  2. BWA.ChartOptions = BWA.ChartOptions || {};
  3. BWA.ChartOptions.PowerSavingCycle = BWA.ChartOptions.PowerSavingCycle || {};
  4. BWA.ChartOptions.PowerSavingCycle.getChartTempOnOFFOptions = function (codeTimeType) {
  5. return {
  6. palette: 'Bright',
  7. legend: {
  8. visible: true,
  9. verticalAlignment: 'top',
  10. horizontalAlignment: 'center'
  11. },
  12. argumentAxis:
  13. {
  14. valueMarginsEnabled: false,
  15. argumentType: 'datetime',
  16. label: {
  17. alignment: 'center',
  18. format: 'HH시-mm분'
  19. },
  20. tickInterval: { minutes: 15 },
  21. },
  22. commonSeriesSettings: {
  23. argumentField: 'DateTime',
  24. selectionStyle: {
  25. hatching: {
  26. direction: 'left'
  27. }
  28. }
  29. },
  30. valueAxis: [
  31. {
  32. name: 'temp',
  33. position: 'left',
  34. pane: 'topPane',
  35. type: 'continuous',
  36. valueType: 'numeric',
  37. valueMarginsEnabled: true,
  38. label: {
  39. },
  40. title: {
  41. text: '온도 (°C)',
  42. }
  43. },
  44. {
  45. label: {
  46. },
  47. name: 'onoff',
  48. tickInterval: 1,
  49. min: 0,
  50. max: 1,
  51. position: 'right',
  52. title: {
  53. text: '공조기 ON/OFF',
  54. }
  55. }
  56. ],
  57. series: [
  58. {
  59. type: 'rangeArea',
  60. rangeValue1Field: 'Mintemp',
  61. rangeValue2Field: 'Maxtemp',
  62. axis: 'temp',
  63. visible: true,
  64. point: { size: 8 },
  65. name: '목표실내온도',
  66. color: 'red',
  67. label: {
  68. visible: false,
  69. customizeText: function () {
  70. return this.valueText + ' °C';
  71. }
  72. }
  73. },
  74. {
  75. type: 'bar',
  76. valueField: 'Indooronoff',
  77. axis: 'onoff',
  78. point: { size: 8 },
  79. name: '공조기 On/Off',
  80. label: {
  81. visible: false,
  82. customizeText: function () {
  83. return this.valueText;
  84. }
  85. }
  86. },
  87. {
  88. type: 'spline',
  89. valueField: 'IndoorTemp',
  90. axis: 'temp',
  91. visible: true,
  92. point: { size: 8 },
  93. name: '실내온도',
  94. color: '#c96374',
  95. label: {
  96. visible: false,
  97. customizeText: function () {
  98. return this.valueText + ' °C';
  99. }
  100. }
  101. }
  102. ],
  103. tooltip: {
  104. enabled: true,
  105. color: "#3e1717",
  106. format: 'fixedPoint',
  107. precision: 2,
  108. font: {
  109. color: "white",
  110. size: 12,
  111. weight: 600,
  112. },
  113. argumentFormat: 'shortDate',
  114. customizeText: function () {
  115. return {
  116. text: [this.argumentText, ': ', this.valueText].join('')
  117. };
  118. }
  119. }
  120. };
  121. };
  122. });