marty 8.5.0 → 9.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/.eslintignore +1 -0
  3. data/.eslintrc.js +26 -0
  4. data/.gitignore +3 -0
  5. data/.gitlab-ci.yml +7 -0
  6. data/.prettierignore +14 -0
  7. data/.rubocop_todo.yml +1 -1
  8. data/Dockerfile.dummy +3 -0
  9. data/Makefile +1 -0
  10. data/app/assets/javascripts/marty/cable.js +7 -3
  11. data/app/assets/javascripts/marty/extjs/extensions/datetime_field/component.js +401 -0
  12. data/app/assets/javascripts/marty/extjs/extensions/datetime_field/field.js +140 -0
  13. data/app/assets/javascripts/marty/extjs/extensions/marty.js +845 -781
  14. data/app/assets/stylesheets/marty/codemirror/codemirror.css +215 -77
  15. data/app/assets/stylesheets/marty/codemirror/delorean.css +2 -2
  16. data/app/assets/stylesheets/marty/dark_mode.css +13 -3
  17. data/app/components/marty/auth_app/client/auth_app.js +107 -102
  18. data/app/components/marty/base_rule_view/client/base_rule_view.js +10 -8
  19. data/app/components/marty/data_grid_view/client/data_grid_edit.js +534 -519
  20. data/app/components/marty/form/client/form.js +3 -3
  21. data/app/components/marty/grid/client/grid.js +110 -87
  22. data/app/components/marty/import_view/client/import_view.js +18 -18
  23. data/app/components/marty/live_search_grid_panel/client/live_search_grid_panel.js +14 -13
  24. data/app/components/marty/main_auth_app/client/main_auth_app.js +42 -42
  25. data/app/components/marty/mcfly_grid_panel/client/mcfly_grid_panel.js +27 -18
  26. data/app/components/marty/new_posting_form/client/new_posting_form.js +3 -3
  27. data/app/components/marty/panel/client/panel.js +3 -3
  28. data/app/components/marty/posting_grid/client/posting_grid.js +24 -18
  29. data/app/components/marty/promise_view/client/promise_view.css +12 -12
  30. data/app/components/marty/promise_view/client/promise_view.js +46 -38
  31. data/app/components/marty/report_form/client/report_form.js +30 -28
  32. data/app/components/marty/report_select/client/report_select.js +28 -23
  33. data/app/components/marty/reporting/client/reporting.js +3 -3
  34. data/app/components/marty/script_form/client/script_form.js +29 -23
  35. data/app/components/marty/script_tester/client/script_tester.js +4 -5
  36. data/app/components/marty/scripting/client/scripting.js +40 -36
  37. data/app/components/marty/simple_app/client/simple_app.js +33 -24
  38. data/app/components/marty/simple_app/client/statusbar_ext.js +1 -1
  39. data/app/controllers/marty/rpc_controller.rb +3 -0
  40. data/app/models/marty/promise.rb +10 -2
  41. data/app/services/marty/data_grid/constraint.rb +2 -1
  42. data/app/services/marty/jobs/schedule.rb +2 -2
  43. data/app/services/marty/promises/delorean/create.rb +9 -2
  44. data/app/services/marty/promises/ruby/create.rb +7 -2
  45. data/config/initializers/delayed_job_config.rb +1 -0
  46. data/delorean/blame_report.dl +50 -58
  47. data/delorean/enum_report.dl +2 -3
  48. data/delorean/{marty_fields.dl → fields.dl} +16 -0
  49. data/delorean/styles.dl +216 -0
  50. data/delorean/table_report.dl +4 -4
  51. data/lib/marty/monkey.rb +17 -0
  52. data/lib/marty/promise_job.rb +9 -0
  53. data/lib/marty/promise_ruby_job.rb +8 -0
  54. data/lib/marty/version.rb +1 -1
  55. data/make-lint.mk +19 -0
  56. data/package.json +16 -0
  57. data/prettier.config.js +6 -0
  58. data/spec/controllers/diagnostic/controller_spec.rb +0 -1
  59. data/spec/controllers/rpc_controller_spec.rb +21 -7
  60. data/spec/dummy/delorean/data_report.dl +4 -4
  61. data/spec/dummy/delorean/fields.dl +1 -0
  62. data/spec/features/data_grid_spec.rb +37 -1
  63. data/spec/job_helper.rb +6 -0
  64. data/spec/lib/data_blame_spec.rb +4 -4
  65. data/spec/lib/data_importer_spec.rb +6 -4
  66. data/spec/models/promise_spec.rb +31 -0
  67. data/spec/spec_helper.rb +8 -0
  68. data/spec/support/download_helper.rb +53 -49
  69. data/spec/support/json_helper.rb +11 -0
  70. data/spec/support/shared_connection_db_helpers.rb +1 -0
  71. data/spec/support/suite.rb +20 -14
  72. data/yarn.lock +967 -0
  73. metadata +16 -4
  74. data/spec/dummy/delorean/marty_fields.dl +0 -1
@@ -17,7 +17,8 @@
17
17
  padding: 0 4px; /* Horizontal padding of content */
18
18
  }
19
19
 
20
- .CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler {
20
+ .CodeMirror-scrollbar-filler,
21
+ .CodeMirror-gutter-filler {
21
22
  background-color: white; /* The little square between H and V scrollbars */
22
23
  }
23
24
 
@@ -28,7 +29,8 @@
28
29
  background-color: #f7f7f7;
29
30
  white-space: nowrap;
30
31
  }
31
- .CodeMirror-linenumbers {}
32
+ .CodeMirror-linenumbers {
33
+ }
32
34
  .CodeMirror-linenumber {
33
35
  padding: 0 3px 0 5px;
34
36
  min-width: 20px;
@@ -37,8 +39,12 @@
37
39
  white-space: nowrap;
38
40
  }
39
41
 
40
- .CodeMirror-guttermarker { color: black; }
41
- .CodeMirror-guttermarker-subtle { color: #999; }
42
+ .CodeMirror-guttermarker {
43
+ color: black;
44
+ }
45
+ .CodeMirror-guttermarker-subtle {
46
+ color: #999;
47
+ }
42
48
 
43
49
  /* CURSOR */
44
50
 
@@ -74,81 +80,168 @@
74
80
  background-color: #7e7;
75
81
  }
76
82
  @-moz-keyframes blink {
77
- 0% {}
78
- 50% { background-color: transparent; }
79
- 100% {}
83
+ 0% {
84
+ }
85
+ 50% {
86
+ background-color: transparent;
87
+ }
88
+ 100% {
89
+ }
80
90
  }
81
91
  @-webkit-keyframes blink {
82
- 0% {}
83
- 50% { background-color: transparent; }
84
- 100% {}
92
+ 0% {
93
+ }
94
+ 50% {
95
+ background-color: transparent;
96
+ }
97
+ 100% {
98
+ }
85
99
  }
86
100
  @keyframes blink {
87
- 0% {}
88
- 50% { background-color: transparent; }
89
- 100% {}
101
+ 0% {
102
+ }
103
+ 50% {
104
+ background-color: transparent;
105
+ }
106
+ 100% {
107
+ }
90
108
  }
91
109
 
92
110
  /* Can style cursor different in overwrite (non-insert) mode */
93
- .CodeMirror-overwrite .CodeMirror-cursor {}
111
+ .CodeMirror-overwrite .CodeMirror-cursor {
112
+ }
94
113
 
95
- .cm-tab { display: inline-block; text-decoration: inherit; }
114
+ .cm-tab {
115
+ display: inline-block;
116
+ text-decoration: inherit;
117
+ }
96
118
 
97
119
  .CodeMirror-rulers {
98
120
  position: absolute;
99
- left: 0; right: 0; top: -50px; bottom: -20px;
121
+ left: 0;
122
+ right: 0;
123
+ top: -50px;
124
+ bottom: -20px;
100
125
  overflow: hidden;
101
126
  }
102
127
  .CodeMirror-ruler {
103
128
  border-left: 1px solid #ccc;
104
- top: 0; bottom: 0;
129
+ top: 0;
130
+ bottom: 0;
105
131
  position: absolute;
106
132
  }
107
133
 
108
134
  /* DEFAULT THEME */
109
135
 
110
- .cm-s-default .cm-header {color: blue;}
111
- .cm-s-default .cm-quote {color: #090;}
112
- .cm-negative {color: #d44;}
113
- .cm-positive {color: #292;}
114
- .cm-header, .cm-strong {font-weight: bold;}
115
- .cm-em {font-style: italic;}
116
- .cm-link {text-decoration: underline;}
117
- .cm-strikethrough {text-decoration: line-through;}
118
-
119
- .cm-s-default .cm-keyword {color: #708;}
120
- .cm-s-default .cm-atom {color: #219;}
121
- .cm-s-default .cm-number {color: #164;}
122
- .cm-s-default .cm-def {color: #00f;}
136
+ .cm-s-default .cm-header {
137
+ color: blue;
138
+ }
139
+ .cm-s-default .cm-quote {
140
+ color: #090;
141
+ }
142
+ .cm-negative {
143
+ color: #d44;
144
+ }
145
+ .cm-positive {
146
+ color: #292;
147
+ }
148
+ .cm-header,
149
+ .cm-strong {
150
+ font-weight: bold;
151
+ }
152
+ .cm-em {
153
+ font-style: italic;
154
+ }
155
+ .cm-link {
156
+ text-decoration: underline;
157
+ }
158
+ .cm-strikethrough {
159
+ text-decoration: line-through;
160
+ }
161
+
162
+ .cm-s-default .cm-keyword {
163
+ color: #708;
164
+ }
165
+ .cm-s-default .cm-atom {
166
+ color: #219;
167
+ }
168
+ .cm-s-default .cm-number {
169
+ color: #164;
170
+ }
171
+ .cm-s-default .cm-def {
172
+ color: #00f;
173
+ }
123
174
  .cm-s-default .cm-variable,
124
175
  .cm-s-default .cm-punctuation,
125
176
  .cm-s-default .cm-property,
126
- .cm-s-default .cm-operator {}
127
- .cm-s-default .cm-variable-2 {color: #05a;}
128
- .cm-s-default .cm-variable-3, .cm-s-default .cm-type {color: #085;}
129
- .cm-s-default .cm-comment {color: #a50;}
130
- .cm-s-default .cm-string {color: #a11;}
131
- .cm-s-default .cm-string-2 {color: #f50;}
132
- .cm-s-default .cm-meta {color: #555;}
133
- .cm-s-default .cm-qualifier {color: #555;}
134
- .cm-s-default .cm-builtin {color: #30a;}
135
- .cm-s-default .cm-bracket {color: #997;}
136
- .cm-s-default .cm-tag {color: #170;}
137
- .cm-s-default .cm-attribute {color: #00c;}
138
- .cm-s-default .cm-hr {color: #999;}
139
- .cm-s-default .cm-link {color: #00c;}
140
-
141
- .cm-s-default .cm-error {color: #f00;}
142
- .cm-invalidchar {color: #f00;}
143
-
144
- .CodeMirror-composing { border-bottom: 2px solid; }
177
+ .cm-s-default .cm-operator {
178
+ }
179
+ .cm-s-default .cm-variable-2 {
180
+ color: #05a;
181
+ }
182
+ .cm-s-default .cm-variable-3,
183
+ .cm-s-default .cm-type {
184
+ color: #085;
185
+ }
186
+ .cm-s-default .cm-comment {
187
+ color: #a50;
188
+ }
189
+ .cm-s-default .cm-string {
190
+ color: #a11;
191
+ }
192
+ .cm-s-default .cm-string-2 {
193
+ color: #f50;
194
+ }
195
+ .cm-s-default .cm-meta {
196
+ color: #555;
197
+ }
198
+ .cm-s-default .cm-qualifier {
199
+ color: #555;
200
+ }
201
+ .cm-s-default .cm-builtin {
202
+ color: #30a;
203
+ }
204
+ .cm-s-default .cm-bracket {
205
+ color: #997;
206
+ }
207
+ .cm-s-default .cm-tag {
208
+ color: #170;
209
+ }
210
+ .cm-s-default .cm-attribute {
211
+ color: #00c;
212
+ }
213
+ .cm-s-default .cm-hr {
214
+ color: #999;
215
+ }
216
+ .cm-s-default .cm-link {
217
+ color: #00c;
218
+ }
219
+
220
+ .cm-s-default .cm-error {
221
+ color: #f00;
222
+ }
223
+ .cm-invalidchar {
224
+ color: #f00;
225
+ }
226
+
227
+ .CodeMirror-composing {
228
+ border-bottom: 2px solid;
229
+ }
145
230
 
146
231
  /* Default styles for common addons */
147
232
 
148
- div.CodeMirror span.CodeMirror-matchingbracket {color: #0b0;}
149
- div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
150
- .CodeMirror-matchingtag { background: rgba(255, 150, 0, .3); }
151
- .CodeMirror-activeline-background {background: #e8f2ff;}
233
+ div.CodeMirror span.CodeMirror-matchingbracket {
234
+ color: #0b0;
235
+ }
236
+ div.CodeMirror span.CodeMirror-nonmatchingbracket {
237
+ color: #a22;
238
+ }
239
+ .CodeMirror-matchingtag {
240
+ background: rgba(255, 150, 0, 0.3);
241
+ }
242
+ .CodeMirror-activeline-background {
243
+ background: #e8f2ff;
244
+ }
152
245
 
153
246
  /* STOP */
154
247
 
@@ -165,7 +258,8 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
165
258
  overflow: scroll !important; /* Things will break if this is overridden */
166
259
  /* 30px is the magic margin used to hide the element's real scrollbars */
167
260
  /* See overflow: hidden in .CodeMirror */
168
- margin-bottom: -30px; margin-right: -30px;
261
+ margin-bottom: -30px;
262
+ margin-right: -30px;
169
263
  padding-bottom: 30px;
170
264
  height: 100%;
171
265
  outline: none; /* Prevent dragging from highlighting the element */
@@ -179,30 +273,39 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
179
273
  /* The fake, visible scrollbars. Used to force redraw during scrolling
180
274
  before actual scrolling happens, thus preventing shaking and
181
275
  flickering artifacts. */
182
- .CodeMirror-vscrollbar, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler {
276
+ .CodeMirror-vscrollbar,
277
+ .CodeMirror-hscrollbar,
278
+ .CodeMirror-scrollbar-filler,
279
+ .CodeMirror-gutter-filler {
183
280
  position: absolute;
184
281
  z-index: 6;
185
282
  display: none;
186
283
  }
187
284
  .CodeMirror-vscrollbar {
188
- right: 0; top: 0;
285
+ right: 0;
286
+ top: 0;
189
287
  overflow-x: hidden;
190
288
  overflow-y: scroll;
191
289
  }
192
290
  .CodeMirror-hscrollbar {
193
- bottom: 0; left: 0;
291
+ bottom: 0;
292
+ left: 0;
194
293
  overflow-y: hidden;
195
294
  overflow-x: scroll;
196
295
  }
197
296
  .CodeMirror-scrollbar-filler {
198
- right: 0; bottom: 0;
297
+ right: 0;
298
+ bottom: 0;
199
299
  }
200
300
  .CodeMirror-gutter-filler {
201
- left: 0; bottom: 0;
301
+ left: 0;
302
+ bottom: 0;
202
303
  }
203
304
 
204
305
  .CodeMirror-gutters {
205
- position: absolute; left: 0; top: 0;
306
+ position: absolute;
307
+ left: 0;
308
+ top: 0;
206
309
  min-height: 100%;
207
310
  z-index: 3;
208
311
  }
@@ -221,7 +324,8 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
221
324
  }
222
325
  .CodeMirror-gutter-background {
223
326
  position: absolute;
224
- top: 0; bottom: 0;
327
+ top: 0;
328
+ bottom: 0;
225
329
  z-index: 4;
226
330
  }
227
331
  .CodeMirror-gutter-elt {
@@ -229,8 +333,12 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
229
333
  cursor: default;
230
334
  z-index: 4;
231
335
  }
232
- .CodeMirror-gutter-wrapper ::selection { background-color: transparent }
233
- .CodeMirror-gutter-wrapper ::-moz-selection { background-color: transparent }
336
+ .CodeMirror-gutter-wrapper ::selection {
337
+ background-color: transparent;
338
+ }
339
+ .CodeMirror-gutter-wrapper ::-moz-selection {
340
+ background-color: transparent;
341
+ }
234
342
 
235
343
  .CodeMirror-lines {
236
344
  cursor: text;
@@ -238,7 +346,9 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
238
346
  }
239
347
  .CodeMirror pre {
240
348
  /* Reset some styles that the rest of the page might have set */
241
- -moz-border-radius: 0; -webkit-border-radius: 0; border-radius: 0;
349
+ -moz-border-radius: 0;
350
+ -webkit-border-radius: 0;
351
+ border-radius: 0;
242
352
  border-width: 0;
243
353
  background: transparent;
244
354
  font-family: inherit;
@@ -263,7 +373,10 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
263
373
 
264
374
  .CodeMirror-linebackground {
265
375
  position: absolute;
266
- left: 0; right: 0; top: 0; bottom: 0;
376
+ left: 0;
377
+ right: 0;
378
+ top: 0;
379
+ bottom: 0;
267
380
  z-index: 0;
268
381
  }
269
382
 
@@ -273,9 +386,12 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
273
386
  padding: 0.1px; /* Force widget margins to stay inside of the container */
274
387
  }
275
388
 
276
- .CodeMirror-widget {}
389
+ .CodeMirror-widget {
390
+ }
277
391
 
278
- .CodeMirror-rtl pre { direction: rtl; }
392
+ .CodeMirror-rtl pre {
393
+ direction: rtl;
394
+ }
279
395
 
280
396
  .CodeMirror-code {
281
397
  outline: none;
@@ -303,7 +419,9 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
303
419
  position: absolute;
304
420
  pointer-events: none;
305
421
  }
306
- .CodeMirror-measure pre { position: static; }
422
+ .CodeMirror-measure pre {
423
+ position: static;
424
+ }
307
425
 
308
426
  div.CodeMirror-cursors {
309
427
  visibility: hidden;
@@ -318,19 +436,35 @@ div.CodeMirror-dragcursors {
318
436
  visibility: visible;
319
437
  }
320
438
 
321
- .CodeMirror-selected { background: #d9d9d9; }
322
- .CodeMirror-focused .CodeMirror-selected { background: #d7d4f0; }
323
- .CodeMirror-crosshair { cursor: crosshair; }
324
- .CodeMirror-line::selection, .CodeMirror-line > span::selection, .CodeMirror-line > span > span::selection { background: #d7d4f0; }
325
- .CodeMirror-line::-moz-selection, .CodeMirror-line > span::-moz-selection, .CodeMirror-line > span > span::-moz-selection { background: #d7d4f0; }
439
+ .CodeMirror-selected {
440
+ background: #d9d9d9;
441
+ }
442
+ .CodeMirror-focused .CodeMirror-selected {
443
+ background: #d7d4f0;
444
+ }
445
+ .CodeMirror-crosshair {
446
+ cursor: crosshair;
447
+ }
448
+ .CodeMirror-line::selection,
449
+ .CodeMirror-line > span::selection,
450
+ .CodeMirror-line > span > span::selection {
451
+ background: #d7d4f0;
452
+ }
453
+ .CodeMirror-line::-moz-selection,
454
+ .CodeMirror-line > span::-moz-selection,
455
+ .CodeMirror-line > span > span::-moz-selection {
456
+ background: #d7d4f0;
457
+ }
326
458
 
327
459
  .cm-searching {
328
460
  background-color: #ffa;
329
- background-color: rgba(255, 255, 0, .4);
461
+ background-color: rgba(255, 255, 0, 0.4);
330
462
  }
331
463
 
332
464
  /* Used to force a border model for a node */
333
- .cm-force-border { padding-right: .1px; }
465
+ .cm-force-border {
466
+ padding-right: 0.1px;
467
+ }
334
468
 
335
469
  @media print {
336
470
  /* Hide the cursor when printing */
@@ -340,7 +474,11 @@ div.CodeMirror-dragcursors {
340
474
  }
341
475
 
342
476
  /* See issue #2901 */
343
- .cm-tab-wrap-hack:after { content: ''; }
477
+ .cm-tab-wrap-hack:after {
478
+ content: "";
479
+ }
344
480
 
345
481
  /* Help users use markselection to safely style text background */
346
- span.CodeMirror-selectedtext { background: none; }
482
+ span.CodeMirror-selectedtext {
483
+ background: none;
484
+ }
@@ -1,10 +1,10 @@
1
1
  .CodeMirror {
2
- /*
2
+ /*
3
3
  border-top: 1px solid black;
4
4
  border-bottom: 1px solid black;
5
5
  */
6
6
  }
7
7
 
8
8
  .errorline {
9
- background: #FF5959 !important;
9
+ background: #ff5959 !important;
10
10
  }
@@ -3,15 +3,25 @@ html {
3
3
  }
4
4
 
5
5
  body {
6
- background-color: #FFF !important;
6
+ background-color: #fff !important;
7
7
  filter: invert(90%) grayscale(10%) hue-rotate(180deg) !important;
8
8
  -moz-filter: invert(90%) grayscale(10%) hue-rotate(180deg) !important;
9
9
  -webkit-filter: invert(90%) grayscale(10%) hue-rotate(180deg) !important;
10
10
  }
11
11
 
12
- em, img, svg, image, video, audio, embed, iframe, object, button, canvas, figure:empty {
12
+ em,
13
+ img,
14
+ svg,
15
+ image,
16
+ video,
17
+ audio,
18
+ embed,
19
+ iframe,
20
+ object,
21
+ button,
22
+ canvas,
23
+ figure:empty {
13
24
  filter: invert(100%) !important;
14
25
  -moz-filter: invert(100%) !important;
15
26
  -webkit-filter: invert(100%) !important;
16
27
  }
17
-