lurker 0.5.3 → 0.5.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. checksums.yaml +4 -4
  2. checksums.yaml.gz.asc +7 -7
  3. data.tar.gz.asc +7 -7
  4. data/.gitignore +1 -0
  5. data/.travis.yml +4 -4
  6. data/README.md +4 -2
  7. data/Rakefile +13 -1
  8. data/features/controller_specs/nested_schema_scaffolding.feature +4 -4
  9. data/features/controller_specs/test_endpoint.feature +36 -15
  10. data/features/request_specs/nested_schema_scaffolding.feature +4 -4
  11. data/features/request_specs/schema_suffixes.feature +173 -0
  12. data/features/support/env.rb +7 -1
  13. data/gemfiles/Gemfile32.ci +6 -0
  14. data/{Gemfile.ci → gemfiles/Gemfile40.ci} +3 -1
  15. data/gemfiles/Gemfile41.ci +6 -0
  16. data/lib/lurker.rb +0 -2
  17. data/lib/lurker/cli.rb +10 -55
  18. data/lib/lurker/controller_spec_watcher.rb +12 -6
  19. data/lib/lurker/endpoint.rb +1 -1
  20. data/lib/lurker/presenters/base_presenter.rb +0 -13
  21. data/lib/lurker/presenters/endpoint_presenter.rb +7 -6
  22. data/lib/lurker/presenters/json_presenter.rb +0 -9
  23. data/lib/lurker/presenters/response_code_presenter.rb +0 -9
  24. data/lib/lurker/presenters/schema_presenter.rb +1 -33
  25. data/lib/lurker/presenters/service_presenter.rb +2 -24
  26. data/lib/lurker/request_spec_watcher.rb +11 -6
  27. data/lib/lurker/service.rb +1 -1
  28. data/lib/lurker/templates/javascripts/application.js +0 -2
  29. data/lib/lurker/templates/public/application.css +0 -148
  30. data/lib/lurker/templates/public/application.js +2 -1904
  31. data/lib/lurker/templates/stylesheets/application.css +0 -2
  32. data/lib/lurker/version.rb +1 -1
  33. data/lurker.gemspec +2 -1
  34. data/templates/generate_stuff.rb +111 -22
  35. data/templates/lurker_app.rb +0 -5
  36. metadata +31 -32
  37. metadata.gz.asc +7 -7
  38. data/lib/lurker/meta_service.rb +0 -46
  39. data/lib/lurker/presenters/meta_service_presenter.rb +0 -85
  40. data/lib/lurker/templates/endpoint.html.erb +0 -62
  41. data/lib/lurker/templates/endpoint.md.erb +0 -40
  42. data/lib/lurker/templates/javascripts/demo/dashboard-demo.js +0 -117
  43. data/lib/lurker/templates/javascripts/demo/flot-demo.js +0 -1242
  44. data/lib/lurker/templates/javascripts/demo/morris-demo.js +0 -155
  45. data/lib/lurker/templates/javascripts/plugins/dataTables/dataTables.bootstrap.js +0 -245
  46. data/lib/lurker/templates/javascripts/plugins/dataTables/jquery.dataTables.js +0 -14013
  47. data/lib/lurker/templates/javascripts/plugins/flot/excanvas.min.js +0 -1
  48. data/lib/lurker/templates/javascripts/plugins/flot/jquery.flot.js +0 -2599
  49. data/lib/lurker/templates/javascripts/plugins/flot/jquery.flot.pie.js +0 -750
  50. data/lib/lurker/templates/javascripts/plugins/flot/jquery.flot.resize.js +0 -60
  51. data/lib/lurker/templates/javascripts/plugins/flot/jquery.flot.tooltip.min.js +0 -12
  52. data/lib/lurker/templates/javascripts/plugins/morris/morris.js +0 -1888
  53. data/lib/lurker/templates/javascripts/plugins/morris/raphael-2.1.0.min.js +0 -10
  54. data/lib/lurker/templates/lurker/rendering/_endpoint.html.erb +0 -65
  55. data/lib/lurker/templates/meta_service.html.erb +0 -54
  56. data/lib/lurker/templates/service.html.erb +0 -50
  57. data/lib/lurker/templates/service.md.erb +0 -18
  58. data/lib/lurker/templates/styles.css +0 -75
  59. data/lib/lurker/templates/stylesheets/plugins/dataTables/dataTables.bootstrap.css +0 -233
  60. data/lib/lurker/templates/stylesheets/plugins/morris/morris-0.4.3.min.css +0 -2
  61. data/lib/lurker/templates/stylesheets/plugins/social-buttons/social-buttons.css +0 -68
  62. data/lib/lurker/templates/stylesheets/plugins/timeline/timeline.css +0 -144
@@ -1,85 +0,0 @@
1
- # BasePresenter for Lurker::MetaService
2
- class Lurker::MetaServicePresenter < Lurker::BasePresenter
3
- attr_reader :meta_service
4
- extend Forwardable
5
-
6
- def_delegators :meta_service, :name, :meta_service_dir
7
-
8
- def initialize(meta_service, options = {})
9
- super(options)
10
- @meta_service = meta_service
11
- end
12
-
13
- def name
14
- meta_service.name
15
- end
16
-
17
- def to_html
18
- render_erb('meta_service.html.erb')
19
- end
20
-
21
- def to_markdown
22
- render_erb('meta_service.md.erb')
23
- end
24
-
25
- def services
26
- @services ||= meta_service.services.
27
- sort_by(&:name).
28
- map do |service|
29
- Lurker::ServicePresenter.new(service, options)
30
- end
31
- end
32
-
33
- def endpoints
34
- if !@endpoints
35
- @endpoints = []
36
- prefix = nil
37
-
38
- ungrouped_endpoints.each do |endpoint|
39
- presenter = presenter_from_endpoint(endpoint)
40
- current_prefix = presenter.prefix
41
-
42
- @endpoints << [] if prefix != current_prefix
43
- @endpoints.last << presenter
44
-
45
- prefix = current_prefix
46
- end
47
- end
48
-
49
- @endpoints
50
- end
51
-
52
- def description(options = {:render => true})
53
- options[:render] ? render_markdown(meta_service.description) : meta_service.description
54
- end
55
-
56
- def discussion(options = {:render => true})
57
- options[:render] ? render_markdown(meta_service.discussion) : meta_service.discussion
58
- end
59
-
60
- def relative_service_path(service_presenter, file_name = nil)
61
- service_path = service_presenter.slug_name
62
- if file_name
63
- service_path = File.join(service_path, file_name)
64
- end
65
- service_path
66
- end
67
-
68
- private
69
-
70
- def ungrouped_endpoints
71
- meta_service.services.
72
- map(&:endpoints).
73
- flatten.
74
- sort_by(&:endpoint_path)
75
- end
76
-
77
- def presenter_from_endpoint(endpoint)
78
- service_presenter = Lurker::ServicePresenter.new(endpoint.service)
79
-
80
- presenter = Lurker::EndpointPresenter.new(endpoint,
81
- options.merge(:prefix => (service_presenter.slug_name + "/")))
82
- presenter.service_presenter = service_presenter
83
- presenter
84
- end
85
- end
@@ -1,62 +0,0 @@
1
- <div id="page">
2
- <div id="content">
3
- <h1>
4
- <%=# render_erb('shared/endpoint_name.html.erb', endpoint_presenter.get_binding) %>
5
- </h1>
6
-
7
- <div id="nav">
8
- <% if @endpoint.service.meta_service %>
9
- <a href="<%= @service_presenter.html_directory %>">
10
- &#187; <%=# @endpoint.service.meta_service.name %>
11
- </a>
12
- <% end %>
13
- <% if @service_presenter %>
14
- <%= @service_presenter.name_as_link(:prefix => '&#187;') %>
15
- <% end %>
16
- </div>
17
-
18
- <%= @endpoint_presenter.description %>
19
-
20
- <% if show_request? %>
21
- <%= tag_with_anchor('h2', 'Request') %>
22
-
23
- <%= tag_with_anchor('h3', 'Example Request') %>
24
- <%= example_request.to_html %>
25
-
26
- <%= tag_with_anchor('h3', 'Request Parameters') %>
27
- <%= request_parameters.to_html %>
28
- <% end %>
29
-
30
- <%= tag_with_anchor('h2', 'Response') %>
31
- <% if show_response? %>
32
- <%= tag_with_anchor('h3', 'Example Response') %>
33
- <%= example_response.to_html %>
34
-
35
- <%= tag_with_anchor('h3', 'Response Parameters') %>
36
- <%= response_parameters.to_html %>
37
- <% end %>
38
-
39
- <%= tag_with_anchor('h3', 'Response Codes') %>
40
- <% if !successful_response_codes.empty? %>
41
- <%= tag_with_anchor('h4', 'Successful Response Codes') %>
42
- <ul>
43
- <% successful_response_codes.each do |response_code| %>
44
- <li>
45
- <%= response_code.to_html %>
46
- </li>
47
- <% end %>
48
- </ul>
49
- <% end %>
50
-
51
- <% if !failure_response_codes.empty? %>
52
- <%= tag_with_anchor('h4', 'Failure Response Codes') %>
53
- <ul>
54
- <% failure_response_codes.each do |response_code| %>
55
- <li>
56
- <%= response_code.to_html %>
57
- </li>
58
- <% end %>
59
- </ul>
60
- <% end %>
61
- </div>
62
- </div>
@@ -1,40 +0,0 @@
1
- # <%= endpoint.verb -%> <%= base_path -%><%= path -%><%= "deprecated" if deprecated? -%>
2
-
3
- <%= description %>
4
-
5
- <% if show_request? %>
6
- ## Request
7
- ### Example Request
8
- ```
9
- <%= example_request.to_markdown %>
10
- ```
11
-
12
- ### Example Parameters
13
- <%= request_parameters.to_markdown %>
14
- <% end %>
15
-
16
- ## Response
17
- <% if show_response? %>
18
- ### Example Response
19
- ```
20
- <%= example_response.to_markdown %>
21
- ```
22
-
23
- ### Response Parameters
24
- <%= response_parameters.to_markdown %>
25
- <% end %>
26
-
27
- ### Response Codes
28
- <% if !successful_response_codes.empty? %>
29
- #### Successful Response Codes
30
- <% successful_response_codes.each do |response_code| %>
31
- * <%= response_code.to_markdown %>
32
- <% end %>
33
- <% end %>
34
-
35
- <% if !failure_response_codes.empty? %>
36
- #### Failure Response Codes
37
- <% failure_response_codes.each do |response_code| %>
38
- * <%= response_code.to_markdown %>
39
- <% end %>
40
- <% end %>
@@ -1,117 +0,0 @@
1
- $(function() {
2
-
3
- Morris.Area({
4
- element: 'morris-area-chart',
5
- data: [{
6
- period: '2010 Q1',
7
- iphone: 2666,
8
- ipad: null,
9
- itouch: 2647
10
- }, {
11
- period: '2010 Q2',
12
- iphone: 2778,
13
- ipad: 2294,
14
- itouch: 2441
15
- }, {
16
- period: '2010 Q3',
17
- iphone: 4912,
18
- ipad: 1969,
19
- itouch: 2501
20
- }, {
21
- period: '2010 Q4',
22
- iphone: 3767,
23
- ipad: 3597,
24
- itouch: 5689
25
- }, {
26
- period: '2011 Q1',
27
- iphone: 6810,
28
- ipad: 1914,
29
- itouch: 2293
30
- }, {
31
- period: '2011 Q2',
32
- iphone: 5670,
33
- ipad: 4293,
34
- itouch: 1881
35
- }, {
36
- period: '2011 Q3',
37
- iphone: 4820,
38
- ipad: 3795,
39
- itouch: 1588
40
- }, {
41
- period: '2011 Q4',
42
- iphone: 15073,
43
- ipad: 5967,
44
- itouch: 5175
45
- }, {
46
- period: '2012 Q1',
47
- iphone: 10687,
48
- ipad: 4460,
49
- itouch: 2028
50
- }, {
51
- period: '2012 Q2',
52
- iphone: 8432,
53
- ipad: 5713,
54
- itouch: 1791
55
- }],
56
- xkey: 'period',
57
- ykeys: ['iphone', 'ipad', 'itouch'],
58
- labels: ['iPhone', 'iPad', 'iPod Touch'],
59
- pointSize: 2,
60
- hideHover: 'auto',
61
- resize: true
62
- });
63
-
64
- Morris.Donut({
65
- element: 'morris-donut-chart',
66
- data: [{
67
- label: "Download Sales",
68
- value: 12
69
- }, {
70
- label: "In-Store Sales",
71
- value: 30
72
- }, {
73
- label: "Mail-Order Sales",
74
- value: 20
75
- }],
76
- resize: true
77
- });
78
-
79
- Morris.Bar({
80
- element: 'morris-bar-chart',
81
- data: [{
82
- y: '2006',
83
- a: 100,
84
- b: 90
85
- }, {
86
- y: '2007',
87
- a: 75,
88
- b: 65
89
- }, {
90
- y: '2008',
91
- a: 50,
92
- b: 40
93
- }, {
94
- y: '2009',
95
- a: 75,
96
- b: 65
97
- }, {
98
- y: '2010',
99
- a: 50,
100
- b: 40
101
- }, {
102
- y: '2011',
103
- a: 75,
104
- b: 65
105
- }, {
106
- y: '2012',
107
- a: 100,
108
- b: 90
109
- }],
110
- xkey: 'y',
111
- ykeys: ['a', 'b'],
112
- labels: ['Series A', 'Series B'],
113
- hideHover: 'auto',
114
- resize: true
115
- });
116
-
117
- });
@@ -1,1242 +0,0 @@
1
- //Flot Line Chart
2
- $(document).ready(function() {
3
- console.log("document ready");
4
- var offset = 0;
5
- plot();
6
-
7
- function plot() {
8
- var sin = [],
9
- cos = [];
10
- for (var i = 0; i < 12; i += 0.2) {
11
- sin.push([i, Math.sin(i + offset)]);
12
- cos.push([i, Math.cos(i + offset)]);
13
- }
14
-
15
- var options = {
16
- series: {
17
- lines: {
18
- show: true
19
- },
20
- points: {
21
- show: true
22
- }
23
- },
24
- grid: {
25
- hoverable: true //IMPORTANT! this is needed for tooltip to work
26
- },
27
- yaxis: {
28
- min: -1.2,
29
- max: 1.2
30
- },
31
- tooltip: true,
32
- tooltipOpts: {
33
- content: "'%s' of %x.1 is %y.4",
34
- shifts: {
35
- x: -60,
36
- y: 25
37
- }
38
- }
39
- };
40
-
41
- var plotObj = $.plot($("#flot-line-chart"), [{
42
- data: sin,
43
- label: "sin(x)"
44
- }, {
45
- data: cos,
46
- label: "cos(x)"
47
- }],
48
- options);
49
- }
50
- });
51
-
52
- //Flot Pie Chart
53
- $(function() {
54
-
55
- var data = [{
56
- label: "Series 0",
57
- data: 1
58
- }, {
59
- label: "Series 1",
60
- data: 3
61
- }, {
62
- label: "Series 2",
63
- data: 9
64
- }, {
65
- label: "Series 3",
66
- data: 20
67
- }];
68
-
69
- var plotObj = $.plot($("#flot-pie-chart"), data, {
70
- series: {
71
- pie: {
72
- show: true
73
- }
74
- },
75
- grid: {
76
- hoverable: true
77
- },
78
- tooltip: true,
79
- tooltipOpts: {
80
- content: "%p.0%, %s", // show percentages, rounding to 2 decimal places
81
- shifts: {
82
- x: 20,
83
- y: 0
84
- },
85
- defaultTheme: false
86
- }
87
- });
88
-
89
- });
90
-
91
- //Flot Multiple Axes Line Chart
92
- $(function() {
93
- var oilprices = [
94
- [1167692400000, 61.05],
95
- [1167778800000, 58.32],
96
- [1167865200000, 57.35],
97
- [1167951600000, 56.31],
98
- [1168210800000, 55.55],
99
- [1168297200000, 55.64],
100
- [1168383600000, 54.02],
101
- [1168470000000, 51.88],
102
- [1168556400000, 52.99],
103
- [1168815600000, 52.99],
104
- [1168902000000, 51.21],
105
- [1168988400000, 52.24],
106
- [1169074800000, 50.48],
107
- [1169161200000, 51.99],
108
- [1169420400000, 51.13],
109
- [1169506800000, 55.04],
110
- [1169593200000, 55.37],
111
- [1169679600000, 54.23],
112
- [1169766000000, 55.42],
113
- [1170025200000, 54.01],
114
- [1170111600000, 56.97],
115
- [1170198000000, 58.14],
116
- [1170284400000, 58.14],
117
- [1170370800000, 59.02],
118
- [1170630000000, 58.74],
119
- [1170716400000, 58.88],
120
- [1170802800000, 57.71],
121
- [1170889200000, 59.71],
122
- [1170975600000, 59.89],
123
- [1171234800000, 57.81],
124
- [1171321200000, 59.06],
125
- [1171407600000, 58.00],
126
- [1171494000000, 57.99],
127
- [1171580400000, 59.39],
128
- [1171839600000, 59.39],
129
- [1171926000000, 58.07],
130
- [1172012400000, 60.07],
131
- [1172098800000, 61.14],
132
- [1172444400000, 61.39],
133
- [1172530800000, 61.46],
134
- [1172617200000, 61.79],
135
- [1172703600000, 62.00],
136
- [1172790000000, 60.07],
137
- [1173135600000, 60.69],
138
- [1173222000000, 61.82],
139
- [1173308400000, 60.05],
140
- [1173654000000, 58.91],
141
- [1173740400000, 57.93],
142
- [1173826800000, 58.16],
143
- [1173913200000, 57.55],
144
- [1173999600000, 57.11],
145
- [1174258800000, 56.59],
146
- [1174345200000, 59.61],
147
- [1174518000000, 61.69],
148
- [1174604400000, 62.28],
149
- [1174860000000, 62.91],
150
- [1174946400000, 62.93],
151
- [1175032800000, 64.03],
152
- [1175119200000, 66.03],
153
- [1175205600000, 65.87],
154
- [1175464800000, 64.64],
155
- [1175637600000, 64.38],
156
- [1175724000000, 64.28],
157
- [1175810400000, 64.28],
158
- [1176069600000, 61.51],
159
- [1176156000000, 61.89],
160
- [1176242400000, 62.01],
161
- [1176328800000, 63.85],
162
- [1176415200000, 63.63],
163
- [1176674400000, 63.61],
164
- [1176760800000, 63.10],
165
- [1176847200000, 63.13],
166
- [1176933600000, 61.83],
167
- [1177020000000, 63.38],
168
- [1177279200000, 64.58],
169
- [1177452000000, 65.84],
170
- [1177538400000, 65.06],
171
- [1177624800000, 66.46],
172
- [1177884000000, 64.40],
173
- [1178056800000, 63.68],
174
- [1178143200000, 63.19],
175
- [1178229600000, 61.93],
176
- [1178488800000, 61.47],
177
- [1178575200000, 61.55],
178
- [1178748000000, 61.81],
179
- [1178834400000, 62.37],
180
- [1179093600000, 62.46],
181
- [1179180000000, 63.17],
182
- [1179266400000, 62.55],
183
- [1179352800000, 64.94],
184
- [1179698400000, 66.27],
185
- [1179784800000, 65.50],
186
- [1179871200000, 65.77],
187
- [1179957600000, 64.18],
188
- [1180044000000, 65.20],
189
- [1180389600000, 63.15],
190
- [1180476000000, 63.49],
191
- [1180562400000, 65.08],
192
- [1180908000000, 66.30],
193
- [1180994400000, 65.96],
194
- [1181167200000, 66.93],
195
- [1181253600000, 65.98],
196
- [1181599200000, 65.35],
197
- [1181685600000, 66.26],
198
- [1181858400000, 68.00],
199
- [1182117600000, 69.09],
200
- [1182204000000, 69.10],
201
- [1182290400000, 68.19],
202
- [1182376800000, 68.19],
203
- [1182463200000, 69.14],
204
- [1182722400000, 68.19],
205
- [1182808800000, 67.77],
206
- [1182895200000, 68.97],
207
- [1182981600000, 69.57],
208
- [1183068000000, 70.68],
209
- [1183327200000, 71.09],
210
- [1183413600000, 70.92],
211
- [1183586400000, 71.81],
212
- [1183672800000, 72.81],
213
- [1183932000000, 72.19],
214
- [1184018400000, 72.56],
215
- [1184191200000, 72.50],
216
- [1184277600000, 74.15],
217
- [1184623200000, 75.05],
218
- [1184796000000, 75.92],
219
- [1184882400000, 75.57],
220
- [1185141600000, 74.89],
221
- [1185228000000, 73.56],
222
- [1185314400000, 75.57],
223
- [1185400800000, 74.95],
224
- [1185487200000, 76.83],
225
- [1185832800000, 78.21],
226
- [1185919200000, 76.53],
227
- [1186005600000, 76.86],
228
- [1186092000000, 76.00],
229
- [1186437600000, 71.59],
230
- [1186696800000, 71.47],
231
- [1186956000000, 71.62],
232
- [1187042400000, 71.00],
233
- [1187301600000, 71.98],
234
- [1187560800000, 71.12],
235
- [1187647200000, 69.47],
236
- [1187733600000, 69.26],
237
- [1187820000000, 69.83],
238
- [1187906400000, 71.09],
239
- [1188165600000, 71.73],
240
- [1188338400000, 73.36],
241
- [1188511200000, 74.04],
242
- [1188856800000, 76.30],
243
- [1189116000000, 77.49],
244
- [1189461600000, 78.23],
245
- [1189548000000, 79.91],
246
- [1189634400000, 80.09],
247
- [1189720800000, 79.10],
248
- [1189980000000, 80.57],
249
- [1190066400000, 81.93],
250
- [1190239200000, 83.32],
251
- [1190325600000, 81.62],
252
- [1190584800000, 80.95],
253
- [1190671200000, 79.53],
254
- [1190757600000, 80.30],
255
- [1190844000000, 82.88],
256
- [1190930400000, 81.66],
257
- [1191189600000, 80.24],
258
- [1191276000000, 80.05],
259
- [1191362400000, 79.94],
260
- [1191448800000, 81.44],
261
- [1191535200000, 81.22],
262
- [1191794400000, 79.02],
263
- [1191880800000, 80.26],
264
- [1191967200000, 80.30],
265
- [1192053600000, 83.08],
266
- [1192140000000, 83.69],
267
- [1192399200000, 86.13],
268
- [1192485600000, 87.61],
269
- [1192572000000, 87.40],
270
- [1192658400000, 89.47],
271
- [1192744800000, 88.60],
272
- [1193004000000, 87.56],
273
- [1193090400000, 87.56],
274
- [1193176800000, 87.10],
275
- [1193263200000, 91.86],
276
- [1193612400000, 93.53],
277
- [1193698800000, 94.53],
278
- [1193871600000, 95.93],
279
- [1194217200000, 93.98],
280
- [1194303600000, 96.37],
281
- [1194476400000, 95.46],
282
- [1194562800000, 96.32],
283
- [1195081200000, 93.43],
284
- [1195167600000, 95.10],
285
- [1195426800000, 94.64],
286
- [1195513200000, 95.10],
287
- [1196031600000, 97.70],
288
- [1196118000000, 94.42],
289
- [1196204400000, 90.62],
290
- [1196290800000, 91.01],
291
- [1196377200000, 88.71],
292
- [1196636400000, 88.32],
293
- [1196809200000, 90.23],
294
- [1196982000000, 88.28],
295
- [1197241200000, 87.86],
296
- [1197327600000, 90.02],
297
- [1197414000000, 92.25],
298
- [1197586800000, 90.63],
299
- [1197846000000, 90.63],
300
- [1197932400000, 90.49],
301
- [1198018800000, 91.24],
302
- [1198105200000, 91.06],
303
- [1198191600000, 90.49],
304
- [1198710000000, 96.62],
305
- [1198796400000, 96.00],
306
- [1199142000000, 99.62],
307
- [1199314800000, 99.18],
308
- [1199401200000, 95.09],
309
- [1199660400000, 96.33],
310
- [1199833200000, 95.67],
311
- [1200351600000, 91.90],
312
- [1200438000000, 90.84],
313
- [1200524400000, 90.13],
314
- [1200610800000, 90.57],
315
- [1200956400000, 89.21],
316
- [1201042800000, 86.99],
317
- [1201129200000, 89.85],
318
- [1201474800000, 90.99],
319
- [1201561200000, 91.64],
320
- [1201647600000, 92.33],
321
- [1201734000000, 91.75],
322
- [1202079600000, 90.02],
323
- [1202166000000, 88.41],
324
- [1202252400000, 87.14],
325
- [1202338800000, 88.11],
326
- [1202425200000, 91.77],
327
- [1202770800000, 92.78],
328
- [1202857200000, 93.27],
329
- [1202943600000, 95.46],
330
- [1203030000000, 95.46],
331
- [1203289200000, 101.74],
332
- [1203462000000, 98.81],
333
- [1203894000000, 100.88],
334
- [1204066800000, 99.64],
335
- [1204153200000, 102.59],
336
- [1204239600000, 101.84],
337
- [1204498800000, 99.52],
338
- [1204585200000, 99.52],
339
- [1204671600000, 104.52],
340
- [1204758000000, 105.47],
341
- [1204844400000, 105.15],
342
- [1205103600000, 108.75],
343
- [1205276400000, 109.92],
344
- [1205362800000, 110.33],
345
- [1205449200000, 110.21],
346
- [1205708400000, 105.68],
347
- [1205967600000, 101.84],
348
- [1206313200000, 100.86],
349
- [1206399600000, 101.22],
350
- [1206486000000, 105.90],
351
- [1206572400000, 107.58],
352
- [1206658800000, 105.62],
353
- [1206914400000, 101.58],
354
- [1207000800000, 100.98],
355
- [1207173600000, 103.83],
356
- [1207260000000, 106.23],
357
- [1207605600000, 108.50],
358
- [1207778400000, 110.11],
359
- [1207864800000, 110.14],
360
- [1208210400000, 113.79],
361
- [1208296800000, 114.93],
362
- [1208383200000, 114.86],
363
- [1208728800000, 117.48],
364
- [1208815200000, 118.30],
365
- [1208988000000, 116.06],
366
- [1209074400000, 118.52],
367
- [1209333600000, 118.75],
368
- [1209420000000, 113.46],
369
- [1209592800000, 112.52],
370
- [1210024800000, 121.84],
371
- [1210111200000, 123.53],
372
- [1210197600000, 123.69],
373
- [1210543200000, 124.23],
374
- [1210629600000, 125.80],
375
- [1210716000000, 126.29],
376
- [1211148000000, 127.05],
377
- [1211320800000, 129.07],
378
- [1211493600000, 132.19],
379
- [1211839200000, 128.85],
380
- [1212357600000, 127.76],
381
- [1212703200000, 138.54],
382
- [1212962400000, 136.80],
383
- [1213135200000, 136.38],
384
- [1213308000000, 134.86],
385
- [1213653600000, 134.01],
386
- [1213740000000, 136.68],
387
- [1213912800000, 135.65],
388
- [1214172000000, 134.62],
389
- [1214258400000, 134.62],
390
- [1214344800000, 134.62],
391
- [1214431200000, 139.64],
392
- [1214517600000, 140.21],
393
- [1214776800000, 140.00],
394
- [1214863200000, 140.97],
395
- [1214949600000, 143.57],
396
- [1215036000000, 145.29],
397
- [1215381600000, 141.37],
398
- [1215468000000, 136.04],
399
- [1215727200000, 146.40],
400
- [1215986400000, 145.18],
401
- [1216072800000, 138.74],
402
- [1216159200000, 134.60],
403
- [1216245600000, 129.29],
404
- [1216332000000, 130.65],
405
- [1216677600000, 127.95],
406
- [1216850400000, 127.95],
407
- [1217282400000, 122.19],
408
- [1217455200000, 124.08],
409
- [1217541600000, 125.10],
410
- [1217800800000, 121.41],
411
- [1217887200000, 119.17],
412
- [1217973600000, 118.58],
413
- [1218060000000, 120.02],
414
- [1218405600000, 114.45],
415
- [1218492000000, 113.01],
416
- [1218578400000, 116.00],
417
- [1218751200000, 113.77],
418
- [1219010400000, 112.87],
419
- [1219096800000, 114.53],
420
- [1219269600000, 114.98],
421
- [1219356000000, 114.98],
422
- [1219701600000, 116.27],
423
- [1219788000000, 118.15],
424
- [1219874400000, 115.59],
425
- [1219960800000, 115.46],
426
- [1220306400000, 109.71],
427
- [1220392800000, 109.35],
428
- [1220565600000, 106.23],
429
- [1220824800000, 106.34]
430
- ];
431
- var exchangerates = [
432
- [1167606000000, 0.7580],
433
- [1167692400000, 0.7580],
434
- [1167778800000, 0.75470],
435
- [1167865200000, 0.75490],
436
- [1167951600000, 0.76130],
437
- [1168038000000, 0.76550],
438
- [1168124400000, 0.76930],
439
- [1168210800000, 0.76940],
440
- [1168297200000, 0.76880],
441
- [1168383600000, 0.76780],
442
- [1168470000000, 0.77080],
443
- [1168556400000, 0.77270],
444
- [1168642800000, 0.77490],
445
- [1168729200000, 0.77410],
446
- [1168815600000, 0.77410],
447
- [1168902000000, 0.77320],
448
- [1168988400000, 0.77270],
449
- [1169074800000, 0.77370],
450
- [1169161200000, 0.77240],
451
- [1169247600000, 0.77120],
452
- [1169334000000, 0.7720],
453
- [1169420400000, 0.77210],
454
- [1169506800000, 0.77170],
455
- [1169593200000, 0.77040],
456
- [1169679600000, 0.7690],
457
- [1169766000000, 0.77110],
458
- [1169852400000, 0.7740],
459
- [1169938800000, 0.77450],
460
- [1170025200000, 0.77450],
461
- [1170111600000, 0.7740],
462
- [1170198000000, 0.77160],
463
- [1170284400000, 0.77130],
464
- [1170370800000, 0.76780],
465
- [1170457200000, 0.76880],
466
- [1170543600000, 0.77180],
467
- [1170630000000, 0.77180],
468
- [1170716400000, 0.77280],
469
- [1170802800000, 0.77290],
470
- [1170889200000, 0.76980],
471
- [1170975600000, 0.76850],
472
- [1171062000000, 0.76810],
473
- [1171148400000, 0.7690],
474
- [1171234800000, 0.7690],
475
- [1171321200000, 0.76980],
476
- [1171407600000, 0.76990],
477
- [1171494000000, 0.76510],
478
- [1171580400000, 0.76130],
479
- [1171666800000, 0.76160],
480
- [1171753200000, 0.76140],
481
- [1171839600000, 0.76140],
482
- [1171926000000, 0.76070],
483
- [1172012400000, 0.76020],
484
- [1172098800000, 0.76110],
485
- [1172185200000, 0.76220],
486
- [1172271600000, 0.76150],
487
- [1172358000000, 0.75980],
488
- [1172444400000, 0.75980],
489
- [1172530800000, 0.75920],
490
- [1172617200000, 0.75730],
491
- [1172703600000, 0.75660],
492
- [1172790000000, 0.75670],
493
- [1172876400000, 0.75910],
494
- [1172962800000, 0.75820],
495
- [1173049200000, 0.75850],
496
- [1173135600000, 0.76130],
497
- [1173222000000, 0.76310],
498
- [1173308400000, 0.76150],
499
- [1173394800000, 0.760],
500
- [1173481200000, 0.76130],
501
- [1173567600000, 0.76270],
502
- [1173654000000, 0.76270],
503
- [1173740400000, 0.76080],
504
- [1173826800000, 0.75830],
505
- [1173913200000, 0.75750],
506
- [1173999600000, 0.75620],
507
- [1174086000000, 0.7520],
508
- [1174172400000, 0.75120],
509
- [1174258800000, 0.75120],
510
- [1174345200000, 0.75170],
511
- [1174431600000, 0.7520],
512
- [1174518000000, 0.75110],
513
- [1174604400000, 0.7480],
514
- [1174690800000, 0.75090],
515
- [1174777200000, 0.75310],
516
- [1174860000000, 0.75310],
517
- [1174946400000, 0.75270],
518
- [1175032800000, 0.74980],
519
- [1175119200000, 0.74930],
520
- [1175205600000, 0.75040],
521
- [1175292000000, 0.750],
522
- [1175378400000, 0.74910],
523
- [1175464800000, 0.74910],
524
- [1175551200000, 0.74850],
525
- [1175637600000, 0.74840],
526
- [1175724000000, 0.74920],
527
- [1175810400000, 0.74710],
528
- [1175896800000, 0.74590],
529
- [1175983200000, 0.74770],
530
- [1176069600000, 0.74770],
531
- [1176156000000, 0.74830],
532
- [1176242400000, 0.74580],
533
- [1176328800000, 0.74480],
534
- [1176415200000, 0.7430],
535
- [1176501600000, 0.73990],
536
- [1176588000000, 0.73950],
537
- [1176674400000, 0.73950],
538
- [1176760800000, 0.73780],
539
- [1176847200000, 0.73820],
540
- [1176933600000, 0.73620],
541
- [1177020000000, 0.73550],
542
- [1177106400000, 0.73480],
543
- [1177192800000, 0.73610],
544
- [1177279200000, 0.73610],
545
- [1177365600000, 0.73650],
546
- [1177452000000, 0.73620],
547
- [1177538400000, 0.73310],
548
- [1177624800000, 0.73390],
549
- [1177711200000, 0.73440],
550
- [1177797600000, 0.73270],
551
- [1177884000000, 0.73270],
552
- [1177970400000, 0.73360],
553
- [1178056800000, 0.73330],
554
- [1178143200000, 0.73590],
555
- [1178229600000, 0.73590],
556
- [1178316000000, 0.73720],
557
- [1178402400000, 0.7360],
558
- [1178488800000, 0.7360],
559
- [1178575200000, 0.7350],
560
- [1178661600000, 0.73650],
561
- [1178748000000, 0.73840],
562
- [1178834400000, 0.73950],
563
- [1178920800000, 0.74130],
564
- [1179007200000, 0.73970],
565
- [1179093600000, 0.73960],
566
- [1179180000000, 0.73850],
567
- [1179266400000, 0.73780],
568
- [1179352800000, 0.73660],
569
- [1179439200000, 0.740],
570
- [1179525600000, 0.74110],
571
- [1179612000000, 0.74060],
572
- [1179698400000, 0.74050],
573
- [1179784800000, 0.74140],
574
- [1179871200000, 0.74310],
575
- [1179957600000, 0.74310],
576
- [1180044000000, 0.74380],
577
- [1180130400000, 0.74430],
578
- [1180216800000, 0.74430],
579
- [1180303200000, 0.74430],
580
- [1180389600000, 0.74340],
581
- [1180476000000, 0.74290],
582
- [1180562400000, 0.74420],
583
- [1180648800000, 0.7440],
584
- [1180735200000, 0.74390],
585
- [1180821600000, 0.74370],
586
- [1180908000000, 0.74370],
587
- [1180994400000, 0.74290],
588
- [1181080800000, 0.74030],
589
- [1181167200000, 0.73990],
590
- [1181253600000, 0.74180],
591
- [1181340000000, 0.74680],
592
- [1181426400000, 0.7480],
593
- [1181512800000, 0.7480],
594
- [1181599200000, 0.7490],
595
- [1181685600000, 0.74940],
596
- [1181772000000, 0.75220],
597
- [1181858400000, 0.75150],
598
- [1181944800000, 0.75020],
599
- [1182031200000, 0.74720],
600
- [1182117600000, 0.74720],
601
- [1182204000000, 0.74620],
602
- [1182290400000, 0.74550],
603
- [1182376800000, 0.74490],
604
- [1182463200000, 0.74670],
605
- [1182549600000, 0.74580],
606
- [1182636000000, 0.74270],
607
- [1182722400000, 0.74270],
608
- [1182808800000, 0.7430],
609
- [1182895200000, 0.74290],
610
- [1182981600000, 0.7440],
611
- [1183068000000, 0.7430],
612
- [1183154400000, 0.74220],
613
- [1183240800000, 0.73880],
614
- [1183327200000, 0.73880],
615
- [1183413600000, 0.73690],
616
- [1183500000000, 0.73450],
617
- [1183586400000, 0.73450],
618
- [1183672800000, 0.73450],
619
- [1183759200000, 0.73520],
620
- [1183845600000, 0.73410],
621
- [1183932000000, 0.73410],
622
- [1184018400000, 0.7340],
623
- [1184104800000, 0.73240],
624
- [1184191200000, 0.72720],
625
- [1184277600000, 0.72640],
626
- [1184364000000, 0.72550],
627
- [1184450400000, 0.72580],
628
- [1184536800000, 0.72580],
629
- [1184623200000, 0.72560],
630
- [1184709600000, 0.72570],
631
- [1184796000000, 0.72470],
632
- [1184882400000, 0.72430],
633
- [1184968800000, 0.72440],
634
- [1185055200000, 0.72350],
635
- [1185141600000, 0.72350],
636
- [1185228000000, 0.72350],
637
- [1185314400000, 0.72350],
638
- [1185400800000, 0.72620],
639
- [1185487200000, 0.72880],
640
- [1185573600000, 0.73010],
641
- [1185660000000, 0.73370],
642
- [1185746400000, 0.73370],
643
- [1185832800000, 0.73240],
644
- [1185919200000, 0.72970],
645
- [1186005600000, 0.73170],
646
- [1186092000000, 0.73150],
647
- [1186178400000, 0.72880],
648
- [1186264800000, 0.72630],
649
- [1186351200000, 0.72630],
650
- [1186437600000, 0.72420],
651
- [1186524000000, 0.72530],
652
- [1186610400000, 0.72640],
653
- [1186696800000, 0.7270],
654
- [1186783200000, 0.73120],
655
- [1186869600000, 0.73050],
656
- [1186956000000, 0.73050],
657
- [1187042400000, 0.73180],
658
- [1187128800000, 0.73580],
659
- [1187215200000, 0.74090],
660
- [1187301600000, 0.74540],
661
- [1187388000000, 0.74370],
662
- [1187474400000, 0.74240],
663
- [1187560800000, 0.74240],
664
- [1187647200000, 0.74150],
665
- [1187733600000, 0.74190],
666
- [1187820000000, 0.74140],
667
- [1187906400000, 0.73770],
668
- [1187992800000, 0.73550],
669
- [1188079200000, 0.73150],
670
- [1188165600000, 0.73150],
671
- [1188252000000, 0.7320],
672
- [1188338400000, 0.73320],
673
- [1188424800000, 0.73460],
674
- [1188511200000, 0.73280],
675
- [1188597600000, 0.73230],
676
- [1188684000000, 0.7340],
677
- [1188770400000, 0.7340],
678
- [1188856800000, 0.73360],
679
- [1188943200000, 0.73510],
680
- [1189029600000, 0.73460],
681
- [1189116000000, 0.73210],
682
- [1189202400000, 0.72940],
683
- [1189288800000, 0.72660],
684
- [1189375200000, 0.72660],
685
- [1189461600000, 0.72540],
686
- [1189548000000, 0.72420],
687
- [1189634400000, 0.72130],
688
- [1189720800000, 0.71970],
689
- [1189807200000, 0.72090],
690
- [1189893600000, 0.7210],
691
- [1189980000000, 0.7210],
692
- [1190066400000, 0.7210],
693
- [1190152800000, 0.72090],
694
- [1190239200000, 0.71590],
695
- [1190325600000, 0.71330],
696
- [1190412000000, 0.71050],
697
- [1190498400000, 0.70990],
698
- [1190584800000, 0.70990],
699
- [1190671200000, 0.70930],
700
- [1190757600000, 0.70930],
701
- [1190844000000, 0.70760],
702
- [1190930400000, 0.7070],
703
- [1191016800000, 0.70490],
704
- [1191103200000, 0.70120],
705
- [1191189600000, 0.70110],
706
- [1191276000000, 0.70190],
707
- [1191362400000, 0.70460],
708
- [1191448800000, 0.70630],
709
- [1191535200000, 0.70890],
710
- [1191621600000, 0.70770],
711
- [1191708000000, 0.70770],
712
- [1191794400000, 0.70770],
713
- [1191880800000, 0.70910],
714
- [1191967200000, 0.71180],
715
- [1192053600000, 0.70790],
716
- [1192140000000, 0.70530],
717
- [1192226400000, 0.7050],
718
- [1192312800000, 0.70550],
719
- [1192399200000, 0.70550],
720
- [1192485600000, 0.70450],
721
- [1192572000000, 0.70510],
722
- [1192658400000, 0.70510],
723
- [1192744800000, 0.70170],
724
- [1192831200000, 0.70],
725
- [1192917600000, 0.69950],
726
- [1193004000000, 0.69940],
727
- [1193090400000, 0.70140],
728
- [1193176800000, 0.70360],
729
- [1193263200000, 0.70210],
730
- [1193349600000, 0.70020],
731
- [1193436000000, 0.69670],
732
- [1193522400000, 0.6950],
733
- [1193612400000, 0.6950],
734
- [1193698800000, 0.69390],
735
- [1193785200000, 0.6940],
736
- [1193871600000, 0.69220],
737
- [1193958000000, 0.69190],
738
- [1194044400000, 0.69140],
739
- [1194130800000, 0.68940],
740
- [1194217200000, 0.68910],
741
- [1194303600000, 0.69040],
742
- [1194390000000, 0.6890],
743
- [1194476400000, 0.68340],
744
- [1194562800000, 0.68230],
745
- [1194649200000, 0.68070],
746
- [1194735600000, 0.68150],
747
- [1194822000000, 0.68150],
748
- [1194908400000, 0.68470],
749
- [1194994800000, 0.68590],
750
- [1195081200000, 0.68220],
751
- [1195167600000, 0.68270],
752
- [1195254000000, 0.68370],
753
- [1195340400000, 0.68230],
754
- [1195426800000, 0.68220],
755
- [1195513200000, 0.68220],
756
- [1195599600000, 0.67920],
757
- [1195686000000, 0.67460],
758
- [1195772400000, 0.67350],
759
- [1195858800000, 0.67310],
760
- [1195945200000, 0.67420],
761
- [1196031600000, 0.67440],
762
- [1196118000000, 0.67390],
763
- [1196204400000, 0.67310],
764
- [1196290800000, 0.67610],
765
- [1196377200000, 0.67610],
766
- [1196463600000, 0.67850],
767
- [1196550000000, 0.68180],
768
- [1196636400000, 0.68360],
769
- [1196722800000, 0.68230],
770
- [1196809200000, 0.68050],
771
- [1196895600000, 0.67930],
772
- [1196982000000, 0.68490],
773
- [1197068400000, 0.68330],
774
- [1197154800000, 0.68250],
775
- [1197241200000, 0.68250],
776
- [1197327600000, 0.68160],
777
- [1197414000000, 0.67990],
778
- [1197500400000, 0.68130],
779
- [1197586800000, 0.68090],
780
- [1197673200000, 0.68680],
781
- [1197759600000, 0.69330],
782
- [1197846000000, 0.69330],
783
- [1197932400000, 0.69450],
784
- [1198018800000, 0.69440],
785
- [1198105200000, 0.69460],
786
- [1198191600000, 0.69640],
787
- [1198278000000, 0.69650],
788
- [1198364400000, 0.69560],
789
- [1198450800000, 0.69560],
790
- [1198537200000, 0.6950],
791
- [1198623600000, 0.69480],
792
- [1198710000000, 0.69280],
793
- [1198796400000, 0.68870],
794
- [1198882800000, 0.68240],
795
- [1198969200000, 0.67940],
796
- [1199055600000, 0.67940],
797
- [1199142000000, 0.68030],
798
- [1199228400000, 0.68550],
799
- [1199314800000, 0.68240],
800
- [1199401200000, 0.67910],
801
- [1199487600000, 0.67830],
802
- [1199574000000, 0.67850],
803
- [1199660400000, 0.67850],
804
- [1199746800000, 0.67970],
805
- [1199833200000, 0.680],
806
- [1199919600000, 0.68030],
807
- [1200006000000, 0.68050],
808
- [1200092400000, 0.6760],
809
- [1200178800000, 0.6770],
810
- [1200265200000, 0.6770],
811
- [1200351600000, 0.67360],
812
- [1200438000000, 0.67260],
813
- [1200524400000, 0.67640],
814
- [1200610800000, 0.68210],
815
- [1200697200000, 0.68310],
816
- [1200783600000, 0.68420],
817
- [1200870000000, 0.68420],
818
- [1200956400000, 0.68870],
819
- [1201042800000, 0.69030],
820
- [1201129200000, 0.68480],
821
- [1201215600000, 0.68240],
822
- [1201302000000, 0.67880],
823
- [1201388400000, 0.68140],
824
- [1201474800000, 0.68140],
825
- [1201561200000, 0.67970],
826
- [1201647600000, 0.67690],
827
- [1201734000000, 0.67650],
828
- [1201820400000, 0.67330],
829
- [1201906800000, 0.67290],
830
- [1201993200000, 0.67580],
831
- [1202079600000, 0.67580],
832
- [1202166000000, 0.6750],
833
- [1202252400000, 0.6780],
834
- [1202338800000, 0.68330],
835
- [1202425200000, 0.68560],
836
- [1202511600000, 0.69030],
837
- [1202598000000, 0.68960],
838
- [1202684400000, 0.68960],
839
- [1202770800000, 0.68820],
840
- [1202857200000, 0.68790],
841
- [1202943600000, 0.68620],
842
- [1203030000000, 0.68520],
843
- [1203116400000, 0.68230],
844
- [1203202800000, 0.68130],
845
- [1203289200000, 0.68130],
846
- [1203375600000, 0.68220],
847
- [1203462000000, 0.68020],
848
- [1203548400000, 0.68020],
849
- [1203634800000, 0.67840],
850
- [1203721200000, 0.67480],
851
- [1203807600000, 0.67470],
852
- [1203894000000, 0.67470],
853
- [1203980400000, 0.67480],
854
- [1204066800000, 0.67330],
855
- [1204153200000, 0.6650],
856
- [1204239600000, 0.66110],
857
- [1204326000000, 0.65830],
858
- [1204412400000, 0.6590],
859
- [1204498800000, 0.6590],
860
- [1204585200000, 0.65810],
861
- [1204671600000, 0.65780],
862
- [1204758000000, 0.65740],
863
- [1204844400000, 0.65320],
864
- [1204930800000, 0.65020],
865
- [1205017200000, 0.65140],
866
- [1205103600000, 0.65140],
867
- [1205190000000, 0.65070],
868
- [1205276400000, 0.6510],
869
- [1205362800000, 0.64890],
870
- [1205449200000, 0.64240],
871
- [1205535600000, 0.64060],
872
- [1205622000000, 0.63820],
873
- [1205708400000, 0.63820],
874
- [1205794800000, 0.63410],
875
- [1205881200000, 0.63440],
876
- [1205967600000, 0.63780],
877
- [1206054000000, 0.64390],
878
- [1206140400000, 0.64780],
879
- [1206226800000, 0.64810],
880
- [1206313200000, 0.64810],
881
- [1206399600000, 0.64940],
882
- [1206486000000, 0.64380],
883
- [1206572400000, 0.63770],
884
- [1206658800000, 0.63290],
885
- [1206745200000, 0.63360],
886
- [1206831600000, 0.63330],
887
- [1206914400000, 0.63330],
888
- [1207000800000, 0.6330],
889
- [1207087200000, 0.63710],
890
- [1207173600000, 0.64030],
891
- [1207260000000, 0.63960],
892
- [1207346400000, 0.63640],
893
- [1207432800000, 0.63560],
894
- [1207519200000, 0.63560],
895
- [1207605600000, 0.63680],
896
- [1207692000000, 0.63570],
897
- [1207778400000, 0.63540],
898
- [1207864800000, 0.6320],
899
- [1207951200000, 0.63320],
900
- [1208037600000, 0.63280],
901
- [1208124000000, 0.63310],
902
- [1208210400000, 0.63420],
903
- [1208296800000, 0.63210],
904
- [1208383200000, 0.63020],
905
- [1208469600000, 0.62780],
906
- [1208556000000, 0.63080],
907
- [1208642400000, 0.63240],
908
- [1208728800000, 0.63240],
909
- [1208815200000, 0.63070],
910
- [1208901600000, 0.62770],
911
- [1208988000000, 0.62690],
912
- [1209074400000, 0.63350],
913
- [1209160800000, 0.63920],
914
- [1209247200000, 0.640],
915
- [1209333600000, 0.64010],
916
- [1209420000000, 0.63960],
917
- [1209506400000, 0.64070],
918
- [1209592800000, 0.64230],
919
- [1209679200000, 0.64290],
920
- [1209765600000, 0.64720],
921
- [1209852000000, 0.64850],
922
- [1209938400000, 0.64860],
923
- [1210024800000, 0.64670],
924
- [1210111200000, 0.64440],
925
- [1210197600000, 0.64670],
926
- [1210284000000, 0.65090],
927
- [1210370400000, 0.64780],
928
- [1210456800000, 0.64610],
929
- [1210543200000, 0.64610],
930
- [1210629600000, 0.64680],
931
- [1210716000000, 0.64490],
932
- [1210802400000, 0.6470],
933
- [1210888800000, 0.64610],
934
- [1210975200000, 0.64520],
935
- [1211061600000, 0.64220],
936
- [1211148000000, 0.64220],
937
- [1211234400000, 0.64250],
938
- [1211320800000, 0.64140],
939
- [1211407200000, 0.63660],
940
- [1211493600000, 0.63460],
941
- [1211580000000, 0.6350],
942
- [1211666400000, 0.63460],
943
- [1211752800000, 0.63460],
944
- [1211839200000, 0.63430],
945
- [1211925600000, 0.63460],
946
- [1212012000000, 0.63790],
947
- [1212098400000, 0.64160],
948
- [1212184800000, 0.64420],
949
- [1212271200000, 0.64310],
950
- [1212357600000, 0.64310],
951
- [1212444000000, 0.64350],
952
- [1212530400000, 0.6440],
953
- [1212616800000, 0.64730],
954
- [1212703200000, 0.64690],
955
- [1212789600000, 0.63860],
956
- [1212876000000, 0.63560],
957
- [1212962400000, 0.6340],
958
- [1213048800000, 0.63460],
959
- [1213135200000, 0.6430],
960
- [1213221600000, 0.64520],
961
- [1213308000000, 0.64670],
962
- [1213394400000, 0.65060],
963
- [1213480800000, 0.65040],
964
- [1213567200000, 0.65030],
965
- [1213653600000, 0.64810],
966
- [1213740000000, 0.64510],
967
- [1213826400000, 0.6450],
968
- [1213912800000, 0.64410],
969
- [1213999200000, 0.64140],
970
- [1214085600000, 0.64090],
971
- [1214172000000, 0.64090],
972
- [1214258400000, 0.64280],
973
- [1214344800000, 0.64310],
974
- [1214431200000, 0.64180],
975
- [1214517600000, 0.63710],
976
- [1214604000000, 0.63490],
977
- [1214690400000, 0.63330],
978
- [1214776800000, 0.63340],
979
- [1214863200000, 0.63380],
980
- [1214949600000, 0.63420],
981
- [1215036000000, 0.6320],
982
- [1215122400000, 0.63180],
983
- [1215208800000, 0.6370],
984
- [1215295200000, 0.63680],
985
- [1215381600000, 0.63680],
986
- [1215468000000, 0.63830],
987
- [1215554400000, 0.63710],
988
- [1215640800000, 0.63710],
989
- [1215727200000, 0.63550],
990
- [1215813600000, 0.6320],
991
- [1215900000000, 0.62770],
992
- [1215986400000, 0.62760],
993
- [1216072800000, 0.62910],
994
- [1216159200000, 0.62740],
995
- [1216245600000, 0.62930],
996
- [1216332000000, 0.63110],
997
- [1216418400000, 0.6310],
998
- [1216504800000, 0.63120],
999
- [1216591200000, 0.63120],
1000
- [1216677600000, 0.63040],
1001
- [1216764000000, 0.62940],
1002
- [1216850400000, 0.63480],
1003
- [1216936800000, 0.63780],
1004
- [1217023200000, 0.63680],
1005
- [1217109600000, 0.63680],
1006
- [1217196000000, 0.63680],
1007
- [1217282400000, 0.6360],
1008
- [1217368800000, 0.6370],
1009
- [1217455200000, 0.64180],
1010
- [1217541600000, 0.64110],
1011
- [1217628000000, 0.64350],
1012
- [1217714400000, 0.64270],
1013
- [1217800800000, 0.64270],
1014
- [1217887200000, 0.64190],
1015
- [1217973600000, 0.64460],
1016
- [1218060000000, 0.64680],
1017
- [1218146400000, 0.64870],
1018
- [1218232800000, 0.65940],
1019
- [1218319200000, 0.66660],
1020
- [1218405600000, 0.66660],
1021
- [1218492000000, 0.66780],
1022
- [1218578400000, 0.67120],
1023
- [1218664800000, 0.67050],
1024
- [1218751200000, 0.67180],
1025
- [1218837600000, 0.67840],
1026
- [1218924000000, 0.68110],
1027
- [1219010400000, 0.68110],
1028
- [1219096800000, 0.67940],
1029
- [1219183200000, 0.68040],
1030
- [1219269600000, 0.67810],
1031
- [1219356000000, 0.67560],
1032
- [1219442400000, 0.67350],
1033
- [1219528800000, 0.67630],
1034
- [1219615200000, 0.67620],
1035
- [1219701600000, 0.67770],
1036
- [1219788000000, 0.68150],
1037
- [1219874400000, 0.68020],
1038
- [1219960800000, 0.6780],
1039
- [1220047200000, 0.67960],
1040
- [1220133600000, 0.68170],
1041
- [1220220000000, 0.68170],
1042
- [1220306400000, 0.68320],
1043
- [1220392800000, 0.68770],
1044
- [1220479200000, 0.69120],
1045
- [1220565600000, 0.69140],
1046
- [1220652000000, 0.70090],
1047
- [1220738400000, 0.70120],
1048
- [1220824800000, 0.7010],
1049
- [1220911200000, 0.70050]
1050
- ];
1051
-
1052
- function euroFormatter(v, axis) {
1053
- return v.toFixed(axis.tickDecimals) + "€";
1054
- }
1055
-
1056
- function doPlot(position) {
1057
- $.plot($("#flot-line-chart-multi"), [{
1058
- data: oilprices,
1059
- label: "Oil price ($)"
1060
- }, {
1061
- data: exchangerates,
1062
- label: "USD/EUR exchange rate",
1063
- yaxis: 2
1064
- }], {
1065
- xaxes: [{
1066
- mode: 'time'
1067
- }],
1068
- yaxes: [{
1069
- min: 0
1070
- }, {
1071
- // align if we are to the right
1072
- alignTicksWithAxis: position == "right" ? 1 : null,
1073
- position: position,
1074
- tickFormatter: euroFormatter
1075
- }],
1076
- legend: {
1077
- position: 'sw'
1078
- },
1079
- grid: {
1080
- hoverable: true //IMPORTANT! this is needed for tooltip to work
1081
- },
1082
- tooltip: true,
1083
- tooltipOpts: {
1084
- content: "%s for %x was %y",
1085
- xDateFormat: "%y-%0m-%0d",
1086
-
1087
- onHover: function(flotItem, $tooltipEl) {
1088
- // console.log(flotItem, $tooltipEl);
1089
- }
1090
- }
1091
-
1092
- });
1093
- }
1094
-
1095
- doPlot("right");
1096
-
1097
- $("button").click(function() {
1098
- doPlot($(this).text());
1099
- });
1100
- });
1101
-
1102
- //Flot Moving Line Chart
1103
-
1104
- $(function() {
1105
-
1106
- var container = $("#flot-line-chart-moving");
1107
-
1108
- // Determine how many data points to keep based on the placeholder's initial size;
1109
- // this gives us a nice high-res plot while avoiding more than one point per pixel.
1110
-
1111
- var maximum = container.outerWidth() / 2 || 300;
1112
-
1113
- //
1114
-
1115
- var data = [];
1116
-
1117
- function getRandomData() {
1118
-
1119
- if (data.length) {
1120
- data = data.slice(1);
1121
- }
1122
-
1123
- while (data.length < maximum) {
1124
- var previous = data.length ? data[data.length - 1] : 50;
1125
- var y = previous + Math.random() * 10 - 5;
1126
- data.push(y < 0 ? 0 : y > 100 ? 100 : y);
1127
- }
1128
-
1129
- // zip the generated y values with the x values
1130
-
1131
- var res = [];
1132
- for (var i = 0; i < data.length; ++i) {
1133
- res.push([i, data[i]])
1134
- }
1135
-
1136
- return res;
1137
- }
1138
-
1139
- //
1140
-
1141
- series = [{
1142
- data: getRandomData(),
1143
- lines: {
1144
- fill: true
1145
- }
1146
- }];
1147
-
1148
- //
1149
-
1150
- var plot = $.plot(container, series, {
1151
- grid: {
1152
- borderWidth: 1,
1153
- minBorderMargin: 20,
1154
- labelMargin: 10,
1155
- backgroundColor: {
1156
- colors: ["#fff", "#e4f4f4"]
1157
- },
1158
- margin: {
1159
- top: 8,
1160
- bottom: 20,
1161
- left: 20
1162
- },
1163
- markings: function(axes) {
1164
- var markings = [];
1165
- var xaxis = axes.xaxis;
1166
- for (var x = Math.floor(xaxis.min); x < xaxis.max; x += xaxis.tickSize * 2) {
1167
- markings.push({
1168
- xaxis: {
1169
- from: x,
1170
- to: x + xaxis.tickSize
1171
- },
1172
- color: "rgba(232, 232, 255, 0.2)"
1173
- });
1174
- }
1175
- return markings;
1176
- }
1177
- },
1178
- xaxis: {
1179
- tickFormatter: function() {
1180
- return "";
1181
- }
1182
- },
1183
- yaxis: {
1184
- min: 0,
1185
- max: 110
1186
- },
1187
- legend: {
1188
- show: true
1189
- }
1190
- });
1191
-
1192
- // Update the random dataset at 25FPS for a smoothly-animating chart
1193
-
1194
- setInterval(function updateRandom() {
1195
- series[0].data = getRandomData();
1196
- plot.setData(series);
1197
- plot.draw();
1198
- }, 40);
1199
-
1200
- });
1201
-
1202
- //Flot Bar Chart
1203
-
1204
- $(function() {
1205
-
1206
- var barOptions = {
1207
- series: {
1208
- bars: {
1209
- show: true,
1210
- barWidth: 43200000
1211
- }
1212
- },
1213
- xaxis: {
1214
- mode: "time",
1215
- timeformat: "%m/%d",
1216
- minTickSize: [1, "day"]
1217
- },
1218
- grid: {
1219
- hoverable: true
1220
- },
1221
- legend: {
1222
- show: false
1223
- },
1224
- tooltip: true,
1225
- tooltipOpts: {
1226
- content: "x: %x, y: %y"
1227
- }
1228
- };
1229
- var barData = {
1230
- label: "bar",
1231
- data: [
1232
- [1354521600000, 1000],
1233
- [1355040000000, 2000],
1234
- [1355223600000, 3000],
1235
- [1355306400000, 4000],
1236
- [1355487300000, 5000],
1237
- [1355571900000, 6000]
1238
- ]
1239
- };
1240
- $.plot($("#flot-bar-chart"), [barData], barOptions);
1241
-
1242
- });