1396edab215231bfe50c0216ae5d999301b80454.svn-base 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751
  1. $(function() {
  2. BWA.ChartOptions = BWA.ChartOptions || {};
  3. BWA.ChartOptions.BoilerAnalysis = BWA.ChartOptions.BoilerAnalysis || {};
  4. BWA.ChartOptions.BoilerAnalysis.getChartEffiOptions = 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. commonSeriesSettings: {
  14. argumentField: "DateTime",
  15. selectionStyle: {
  16. hatching: {
  17. direction: "left"
  18. }
  19. }
  20. },
  21. valueAxis: [{
  22. label: {
  23. visible: true,
  24. },
  25. title: {
  26. text: '효율 (%)'
  27. }
  28. },
  29. {
  30. name: 'kwh', //
  31. position: 'right',
  32. label: {
  33. //font: { color: '#c96374' },
  34. visible: true,
  35. },
  36. title: {
  37. text: '소비전력량 (kWh)'
  38. }
  39. },
  40. /*
  41. {
  42. name: 'kcal', //
  43. position: 'right',
  44. label: {
  45. //font: { color: '#c96374' },
  46. visible: true,
  47. },
  48. title: {
  49. text: '보일러 능력 Kcal'
  50. }
  51. },*/
  52. {
  53. name: 'm3', //
  54. position: 'right',
  55. label: {
  56. visible: true,
  57. },
  58. title: {
  59. text: '연료 사용량 (㎥/h)'
  60. }
  61. }
  62. ],
  63. series: [{
  64. type: 'spline',
  65. name:'시스템효율',
  66. argumentField: "DateTime",
  67. valueField: 'syseffi', //
  68. label: {
  69. visible: false,
  70. },
  71. point: { size: 8 }
  72. },
  73. {
  74. type: 'spline',
  75. name: '보일러효율',
  76. argumentField: "DateTime",
  77. valueField: 'effi', //
  78. label: {
  79. visible: false,
  80. },
  81. point: { size: 8 }
  82. },
  83. /* {
  84. axis: 'kcal',
  85. type: 'bar',
  86. name: '보일러 능력',
  87. argumentField: "DateTime",
  88. valueField: 'kcal', //
  89. label: {
  90. visible: false,
  91. },
  92. point: { size: 8 },
  93. },*/
  94. {
  95. axis: 'kwh',
  96. type: 'scatter',
  97. name: '순환펌프소비전력',
  98. argumentField: "DateTime",
  99. valueField: 'pump_kw', //
  100. label: {
  101. visible: false,
  102. },
  103. point: { size: 8 },
  104. },
  105. {
  106. axis: 'kwh',
  107. type: 'scatter',
  108. name: '보일러소비전력',
  109. argumentField: "DateTime",
  110. valueField: 'elecuse', //
  111. label: {
  112. visible: false,
  113. },
  114. point: { size: 8 },
  115. },
  116. {
  117. axis: 'm3',
  118. name: '연료 사용량',
  119. type: 'scatter',
  120. valueField: 'm3',
  121. point: { size: 8, symbol: 'triangle' },
  122. //name: '외기 온도',
  123. label: {
  124. //font: { color: '#c96374', },
  125. visible: false,
  126. },
  127. }],
  128. tooltip: {
  129. enabled: true,
  130. },
  131. crosshair: {
  132. enabled: true,
  133. width: 2,
  134. horizontalLine: {
  135. color: 'red',
  136. dashStyle: 'dash',
  137. visible: false
  138. },
  139. verticalLine: {
  140. color: 'black',
  141. dashStyle: 'dash',
  142. visible: true
  143. },
  144. label: {
  145. visible: true,
  146. backgroundColor: "#949494",
  147. font: {
  148. color: "#fff",
  149. size: 12,
  150. }
  151. }
  152. }
  153. };
  154. };
  155. BWA.ChartOptions.BoilerAnalysis.getChartAtfwOptions = function (codeTimeType) {
  156. return {
  157. palette: "Default",
  158. legend: {
  159. visible: true,
  160. verticalAlignment: 'top',
  161. horizontalAlignment: 'center'
  162. },
  163. //argumentAxis: BWA.Chart.getTimeLineArgumentAxis(null, codeTimeType),
  164. commonSeriesSettings: {
  165. argumentField: "DateTime",
  166. selectionStyle: {
  167. hatching: {
  168. direction: "left"
  169. }
  170. }
  171. },
  172. valueAxis: [{
  173. label: {
  174. visible: true,
  175. },
  176. title: {
  177. text: '공기 과잉률 (%)'
  178. }
  179. },
  180. {
  181. name: 'fo2', //
  182. position: 'right',
  183. label: {
  184. //font: { color: '#c96374' },
  185. visible: true,
  186. },
  187. title: {
  188. text: '연소공기 산소농도 (%)'
  189. }
  190. },
  191. {
  192. name: 'eo2', //
  193. position: 'right',
  194. label: {
  195. //font: { color: '#c96374' },
  196. visible: true,
  197. },
  198. title: {
  199. text: '배기가스 산소농도 (%)'
  200. }
  201. }
  202. ],
  203. series: [{
  204. name: '공기 과잉률',
  205. argumentField: "DateTime",
  206. valueField: 'airfact', //
  207. label: {
  208. visible: false,
  209. },
  210. point: { size: 8 }
  211. }, {
  212. axis: 'fo2',
  213. type: 'scatter',
  214. name: '연소공기 산소농도',
  215. argumentField: "DateTime",
  216. valueField: 'fo2', //
  217. label: {
  218. visible: false,
  219. },
  220. point: { size: 8 },
  221. },
  222. {
  223. axis: 'eo2',
  224. name: '배기가스 산소농도',
  225. type: 'scatter',
  226. valueField: 'eo2',
  227. point: { size: 8, symbol: 'triangle' },
  228. label: {
  229. visible: false,
  230. }
  231. }],
  232. tooltip: {
  233. enabled: true,
  234. },
  235. };
  236. };
  237. BWA.ChartOptions.BoilerAnalysis.getChartCOPOptions = function (codeTimeType) {
  238. return {
  239. palette: "Harmony Light",
  240. legend: {
  241. visible: true,
  242. verticalAlignment: 'top',
  243. horizontalAlignment: 'center'
  244. },
  245. //argumentAxis: BWA.Chart.getTimeLineArgumentAxis(null, codeTimeType),
  246. commonSeriesSettings: {
  247. argumentField: "DateTime",
  248. selectionStyle: {
  249. hatching: {
  250. direction: "left"
  251. }
  252. }
  253. },
  254. valueAxis: [{
  255. label: {
  256. visible: true,
  257. },
  258. title: {
  259. text: 'COP'
  260. }
  261. },
  262. {
  263. name: 'elec', //
  264. position: 'right',
  265. label: {
  266. visible: true,
  267. },
  268. title: {
  269. text: '시스템 전력량 (kwh)'
  270. }
  271. },
  272. {
  273. name: 'm3', //
  274. position: 'right',
  275. label: {
  276. visible: true,
  277. },
  278. title: {
  279. text: '시스템 연료소비량 (m3/h)'
  280. }
  281. }
  282. ],
  283. series: [{
  284. name: 'COP',
  285. argumentField: "DateTime",
  286. valueField: 'COP', //
  287. label: {
  288. visible: false,
  289. },
  290. point: { size: 8 }
  291. }, {
  292. axis: 'elec',
  293. type: 'scatter',
  294. name: '시스템 전력량',
  295. argumentField: "DateTime",
  296. valueField: 'elecuse', //
  297. label: {
  298. visible: false,
  299. },
  300. point: { size: 8 },
  301. },
  302. {
  303. axis: 'm3',
  304. name: '시스템 연료소비량',
  305. type: 'scatter',
  306. valueField: 'm3',
  307. point: { size: 8, symbol: 'triangle' },
  308. label: {
  309. visible: false,
  310. }
  311. }],
  312. tooltip: {
  313. enabled: true,
  314. },
  315. };
  316. };
  317. BWA.ChartOptions.BoilerAnalysis.getChartFIREOptions = function (codeTimeType) {
  318. return {
  319. palette: "Ocean",
  320. legend: {
  321. visible: true,
  322. verticalAlignment: 'top',
  323. horizontalAlignment: 'center'
  324. },
  325. //argumentAxis: BWA.Chart.getTimeLineArgumentAxis(null, codeTimeType),
  326. commonSeriesSettings: {
  327. argumentField: "DateTime",
  328. selectionStyle: {
  329. hatching: {
  330. direction: "left"
  331. }
  332. }
  333. },
  334. valueAxis: [{
  335. label: {
  336. visible: true,
  337. },
  338. title: {
  339. text: '발열량'
  340. }
  341. },
  342. {
  343. name: 'elec', //
  344. position: 'right',
  345. label: {
  346. visible: true,
  347. },
  348. title: {
  349. text: '시스템 전력량 (kwh)'
  350. }
  351. },
  352. {
  353. name: 'm3', //
  354. position: 'right',
  355. label: {
  356. visible: true,
  357. },
  358. title: {
  359. text: '시스템 연료소비량 (m3/h)'
  360. }
  361. }
  362. ],
  363. series: [{
  364. name: '발열량',
  365. argumentField: "DateTime",
  366. valueField: 'fire', //
  367. label: {
  368. visible: false,
  369. },
  370. point: { size: 8 }
  371. }, {
  372. axis: 'elec',
  373. type: 'scatter',
  374. name: '시스템 전력량',
  375. argumentField: "DateTime",
  376. valueField: 'elecuse', //
  377. label: {
  378. visible: false,
  379. },
  380. point: { size: 8 },
  381. },
  382. {
  383. axis: 'm3',
  384. name: '시스템 연료소비량',
  385. type: 'scatter',
  386. valueField: 'm3',
  387. point: { size: 8, symbol: 'triangle' },
  388. label: {
  389. visible: false,
  390. }
  391. }],
  392. tooltip: {
  393. enabled: true,
  394. },
  395. };
  396. };
  397. BWA.ChartOptions.BoilerAnalysis.getChart_2_Options = function (codeTimeType) {
  398. return {
  399. palette: "Soft Pastel",
  400. legend: {
  401. visible: false
  402. },
  403. argumentAxis: {
  404. max: 100,
  405. min: 0,
  406. title: {
  407. text: $G('loadRateWithUnit')
  408. }
  409. },
  410. valueAxis: {
  411. title: {
  412. text: '보일러 효율 (%)'
  413. }
  414. },
  415. series: {
  416. type: 'scatter',
  417. valueField: 'effi', //
  418. argumentField: 'load', //
  419. label: {
  420. visible: false,
  421. //customizeText: function() {
  422. // return this.argumentField + this.valueText;
  423. //}
  424. },
  425. point: { size: 8 }
  426. },
  427. tooltip: {
  428. enabled: true,
  429. },
  430. crosshair: {
  431. enabled: true,
  432. width: 2,
  433. horizontalLine: {
  434. color: 'red',
  435. dashStyle: 'dash',
  436. visible: true
  437. },
  438. verticalLine: {
  439. color: 'red',
  440. dashStyle: 'dash',
  441. visible: true
  442. },
  443. label: {
  444. visible: true,
  445. backgroundColor: "#949494",
  446. font: {
  447. color: "#fff",
  448. size: 12,
  449. }
  450. }
  451. }
  452. };
  453. };
  454. BWA.ChartOptions.BoilerAnalysis.getChart_3_Options = function (codeTimeType) {
  455. return {
  456. palette: 'Bright',
  457. legend: {
  458. visible: true,
  459. verticalAlignment: 'top',
  460. horizontalAlignment: 'center'
  461. },
  462. //argumentAxis: BWA.Chart.getTimeLineArgumentAxis(null, codeTimeType),
  463. commonSeriesSettings: {
  464. argumentField: 'DateTime',
  465. selectionStyle: {
  466. hatching: {
  467. direction: 'left'
  468. }
  469. }
  470. },
  471. valueAxis: [{
  472. title: {
  473. text: '소비전력량 (kWh)'
  474. }
  475. },
  476. {
  477. //type: 'continuous',
  478. //valueType: 'numeric',
  479. position: 'right',
  480. name: 'hz',
  481. /*label: {
  482. font: { color: '#c96374' },
  483. },*/
  484. title: {
  485. text: '주파수 (Hz)'
  486. }
  487. }],
  488. series: [{
  489. type: 'bar',
  490. valueField: 'pump_kw',
  491. color: "#5F8B95",
  492. name: '소비전력',
  493. label: {
  494. visible: false,
  495. customizeText: function () {
  496. return this.valueText + '(kWh)';
  497. }
  498. },
  499. point: { size: 8 }
  500. }, {
  501. type: 'spline',
  502. valueField: 'pump_hz',
  503. axis: 'hz',
  504. name: '주파수',
  505. label: {
  506. visible: false,
  507. customizeText: function () {
  508. return this.valueText + 'Hz';
  509. }
  510. },
  511. point: { size: 8 }
  512. },
  513. ],
  514. tooltip: {
  515. enabled: true,
  516. },
  517. crosshair: {
  518. enabled: true,
  519. width: 2,
  520. horizontalLine: {
  521. color: 'red',
  522. dashStyle: 'dash',
  523. visible: false
  524. },
  525. verticalLine: {
  526. color: 'red',
  527. dashStyle: 'dash',
  528. visible: true
  529. },
  530. label: {
  531. visible: true,
  532. backgroundColor: "#949494",
  533. font: {
  534. color: "#fff",
  535. size: 12,
  536. }
  537. }
  538. }
  539. };
  540. }
  541. var valueAxises = [{
  542. pane: 'topPane',
  543. name: 'Temperature',
  544. position: 'right',
  545. //valueMarginsEnabled: true,
  546. //minValueMargin: 0,
  547. //maxValueMargin: 0,
  548. type: 'continuous',
  549. valueType: 'numeric',
  550. tickInterval: 10,
  551. valueMarginsEnabled: true,
  552. minValueMargin: 0,
  553. maxValueMargin: 0,
  554. min: -10,
  555. max: 40,
  556. label: {
  557. font: { color: '#c96374' },
  558. visible: true,
  559. //format: 'largeNumber'
  560. },
  561. title: {
  562. text: $G('outdoorTemperatureWithUnit')
  563. }
  564. }, {
  565. pane: 'topPane',
  566. name: 'humidity',
  567. tickInterval: 20,
  568. valueMarginsEnabled: true,
  569. minValueMargin: 0,
  570. maxValueMargin: 0,
  571. //argumentType: 'numeric',
  572. min: 0,
  573. max: 100,
  574. position: 'right',
  575. grid: {
  576. visible: true
  577. },
  578. label: {
  579. font: { color: '#00A7C6' },
  580. visible: true,
  581. //format: 'largeNumber'
  582. },
  583. title: {
  584. text: $G('outdoorHumidityWithUnit')
  585. }
  586. }];
  587. var seriesS = [{
  588. type: 'spline',
  589. color: '#c96374',
  590. pane: 'topPane',
  591. axis: 'Temperature',
  592. valueField: 'Temperature',
  593. point: { size: 2 },
  594. name: $G('outdoorTemperature'),
  595. label: {
  596. visible: false,
  597. font: { color: '#c96374', },
  598. customizeText: function () {
  599. return this.valueText + ' °C';
  600. }
  601. }
  602. }, {
  603. type: 'spline',
  604. pane: 'topPane',
  605. axis: 'humidity',
  606. color: '#00A7C6',
  607. valueField: 'Humidity',
  608. point: { size: 2 },
  609. name: $G('outdoorHumidity'),
  610. label: {
  611. font: { color: '#00A7C6', },
  612. visible: false,
  613. customizeText: function () {
  614. return this.valueText + ' %';
  615. }
  616. }
  617. }];
  618. BWA.ChartOptions.BoilerAnalysis.getChart_4_Options = function (codeTimeType) {
  619. return {
  620. palette: 'Harmony Light',
  621. legend: {
  622. visible: true,
  623. verticalAlignment: 'top',
  624. horizontalAlignment: 'center'
  625. },
  626. commonSeriesSettings: {
  627. argumentField: "DateTime",
  628. selectionStyle: {
  629. hatching: {
  630. direction: "left"
  631. }
  632. }
  633. },
  634. valueAxis: {
  635. pane: 'topPane',
  636. position: 'left',
  637. label: {
  638. visible: true,
  639. //format: 'largeNumber'
  640. },
  641. title: {
  642. text: '부하율 (%)'
  643. }
  644. },
  645. series: {
  646. type: 'bar',
  647. argumentField: "DateTime",
  648. valueField: 'Value',
  649. //valueField: 'Temperature',
  650. name: '부하율',
  651. point: { size: 8 }
  652. },
  653. panes: [{
  654. name: 'topPane',
  655. border: {
  656. visible: false,
  657. left: false,
  658. right: false,
  659. top: false,
  660. color: 'gray'
  661. }
  662. }, ],
  663. defaultPane: "topPane",
  664. tooltip: {
  665. enabled: true,
  666. },
  667. crosshair: {
  668. enabled: true,
  669. width: 2,
  670. horizontalLine: {
  671. color: 'red',
  672. dashStyle: 'dash',
  673. visible: true
  674. },
  675. verticalLine: {
  676. color: 'red',
  677. dashStyle: 'dash',
  678. visible: true
  679. },
  680. label: {
  681. visible: true,
  682. backgroundColor: "#949494",
  683. font: {
  684. color: "#fff",
  685. size: 12,
  686. }
  687. }
  688. }
  689. };
  690. };
  691. });