• Edit
  • Download
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7. <script nonce="undefined" src="//www.zingchart.com/scripts/zcDocs.js"></script>
    8. <link href='//www.zingchart.com/css/zcDocs.css' rel='stylesheet' type='text/css'>
    9.  
    10. <script nonce="undefined" src="https://cdn.zingchart.com/zingchart.min.js"></script>
    11. <style></style>
    12. </head>
    13.  
    14. <body>
    15. <div id="myChart"></div>
    16. <button class='btn btn-info' id='demo1'>Run Demo 1</button>
    17. <pre id="output"></pre>
    18. <script>
    19. ZC.LICENSE = ["569d52cefae586f634c54f86dc99e6a9", "b55b025e438fa8a98e32482b5f768ff5"];
    20. var myConfig = {
    21. 'type': 'bar',
    22. 'legend': {},
    23. 'series': [{
    24. 'values': [11, 26, 7, 44, 11]
    25. },
    26. {
    27. 'values': [42, 13, 21, 15, 33]
    28. }
    29. ]
    30. };
    31.  
    32. zingchart.bind('myChart', 'plot_add', function(p) {
    33. zcdocs.demos.dump('plot_add', p);
    34. });
    35.  
    36. demo1.addEventListener('click', function() {
    37. zingchart.exec('myChart', 'addplot', {
    38. 'data': {
    39. 'values': zcdocs.utils.rvalues(5, 0, 50)
    40. }
    41. });
    42. });
    43.  
    44. zingchart.render({
    45. id: 'myChart',
    46. data: myConfig,
    47. height: 400,
    48. width: '100%'
    49. });
    50. </script>
    51. </body>
    52.  
    53. </html>
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7. <script src="//www.zingchart.com/scripts/zcDocs.js"></script>
    8. <link href='//www.zingchart.com/css/zcDocs.css' rel='stylesheet' type='text/css'>
    9.  
    10. <script src="https://cdn.zingchart.com/zingchart.min.js"></script>
    11. </head>
    12.  
    13. <body>
    14. <div id="myChart"></div>
    15. <button class='btn btn-info' id='demo1'>Run Demo 1</button>
    16. <pre id="output"></pre>
    17. </body>
    18.  
    19. </html>
    1.  
    1. var myConfig = {
    2. 'type': 'bar',
    3. 'legend': {},
    4. 'series': [{
    5. 'values': [11, 26, 7, 44, 11]
    6. },
    7. {
    8. 'values': [42, 13, 21, 15, 33]
    9. }
    10. ]
    11. };
    12.  
    13. zingchart.bind('myChart', 'plot_add', function(p) {
    14. zcdocs.demos.dump('plot_add', p);
    15. });
    16.  
    17. demo1.addEventListener('click', function() {
    18. zingchart.exec('myChart', 'addplot', {
    19. 'data': {
    20. 'values': zcdocs.utils.rvalues(5, 0, 50)
    21. }
    22. });
    23. });
    24.  
    25. zingchart.render({
    26. id: 'myChart',
    27. data: myConfig,
    28. height: 400,
    29. width: '100%'
    30. });