pict-section-form 1.0.124 → 1.0.127
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/debug/Harness.js +2 -2
- package/debug/data/DefaultFormManifest.json +1 -1
- package/debug/data/MathExampleForm.json +1 -1
- package/debug/input_data/Rectangles.csv +1 -1
- package/package.json +1 -1
- package/source/providers/Pict-Provider-DynamicFormSolverBehaviors.js +4 -4
- package/source/services/ManifestFactory.js +1 -1
- package/source/views/Pict-View-DynamicForm.js +77 -21
- package/types/source/views/Pict-View-DynamicForm.d.ts.map +1 -1
- package/utility/csvparser/ParseCSV-Command-Inject.js +2 -0
- package/utility/csvparser/ParseCSV-Command-Parse.js +2 -0
package/debug/Harness.js
CHANGED
|
@@ -3,5 +3,5 @@ const libParseCSV = require('../utility/csvparser/ParseCSV-Program.js');
|
|
|
3
3
|
// This command takes the `TabularManifestCSV.csv` file and imports it into a JSON file
|
|
4
4
|
//libParseCSV.run(['node', 'Harness.js', 'import']);
|
|
5
5
|
// This command takes the `data/MathExampleForm.json` file and injects any sidecare files in the `input_data` folder into the JSON file
|
|
6
|
-
|
|
7
|
-
libParseCSV.run(['node', 'Harness.js', 'intersect']);
|
|
6
|
+
libParseCSV.run(['node', 'Harness.js', 'inject']);
|
|
7
|
+
//libParseCSV.run(['node', 'Harness.js', 'intersect']);
|
package/package.json
CHANGED
|
@@ -283,10 +283,10 @@ class PictDynamicFormsSolverBehaviors extends libPictProvider
|
|
|
283
283
|
* @param {string} pInputHash - The hash of the input to color.
|
|
284
284
|
* @param {string} pColor - The HTML hex color to apply (e.g. #FF0000 for red).
|
|
285
285
|
* @param {string} pApplyChange - If "0", the change will not be applied.
|
|
286
|
-
* @param {string} [
|
|
286
|
+
* @param {string} [pCSSSelector] - Optional. If provided, the color will be applied to the closest element matching this selector instead of the input itself.
|
|
287
287
|
* @returns {boolean} - Returns true if the color was applied successfully or if the change was skipped for pApplyChange equal to "0", false otherwise.
|
|
288
288
|
*/
|
|
289
|
-
colorInputBackground(pSectionHash, pInputHash, pColor, pApplyChange,
|
|
289
|
+
colorInputBackground(pSectionHash, pInputHash, pColor, pApplyChange, pCSSSelector)
|
|
290
290
|
{
|
|
291
291
|
if (pApplyChange == "0")
|
|
292
292
|
{
|
|
@@ -321,13 +321,13 @@ class PictDynamicFormsSolverBehaviors extends libPictProvider
|
|
|
321
321
|
|
|
322
322
|
// if we passed a class target, find the closest element with that class and apply the color to it
|
|
323
323
|
// otherwise, just apply it to the input element itself
|
|
324
|
-
if (
|
|
324
|
+
if (pCSSSelector)
|
|
325
325
|
{
|
|
326
326
|
// find closest target by class name and if we find it, immediately break out of the loop
|
|
327
327
|
for (let i = 0; i < tmpElementSet.length; i++)
|
|
328
328
|
{
|
|
329
329
|
const element = tmpElementSet[i];
|
|
330
|
-
const closest = element.closest(
|
|
330
|
+
const closest = element.closest(`${pCSSSelector}`);
|
|
331
331
|
if (closest)
|
|
332
332
|
{
|
|
333
333
|
tmpElement = closest;
|
|
@@ -624,7 +624,7 @@ class ManifestFactory extends libFableServiceProviderBase
|
|
|
624
624
|
{
|
|
625
625
|
// Clean up the equation a bit to remove any leading/trailing spaces and replace HTML quotes
|
|
626
626
|
// that may have been added by the CSV or other source.
|
|
627
|
-
const tmpCleanEquation = tmpRecord['Equation'].trim()
|
|
627
|
+
const tmpCleanEquation = tmpRecord['Equation'].trim();
|
|
628
628
|
this.log.trace(`Adding solver to ${tmpRecord.Form} --> ${tmpGroup.Name} for ${tmpRecord['Input Hash']}: ${tmpRecord['Equation']}`);
|
|
629
629
|
if ((tmpGroup.Layout == 'Tabular') || (tmpGroup.Layout == 'RecordSet'))
|
|
630
630
|
{
|
|
@@ -169,6 +169,8 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
169
169
|
{
|
|
170
170
|
// The informary stuff doesn't know the resolution of the hash to address, so do it here.
|
|
171
171
|
let tmpHashAddress = this.sectionManifest.resolveHashAddress(pInputHash);
|
|
172
|
+
const tmpTransactionGUID = this.fable.getUUID();
|
|
173
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
172
174
|
try
|
|
173
175
|
{
|
|
174
176
|
let tmpMarshalDestinationObject = this.getMarshalDestinationObject();
|
|
@@ -177,8 +179,6 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
177
179
|
let tmpValue = this.sectionManifest.getValueByHash(tmpMarshalDestinationObject, tmpHashAddress);
|
|
178
180
|
|
|
179
181
|
let tmpInputProviderList = this.getInputProviderList(tmpInput);
|
|
180
|
-
const tmpTransactionGUID = this.fable.getUUID();
|
|
181
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
182
182
|
for (let i = 0; i < tmpInputProviderList.length; i++)
|
|
183
183
|
{
|
|
184
184
|
if (this.pict.providers[tmpInputProviderList[i]])
|
|
@@ -195,6 +195,10 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
195
195
|
{
|
|
196
196
|
this.log.error(`Dynamic form [${this.Hash}]::[${this.UUID}] gross error marshaling specific (${pInputHash}) data from view in dataChanged event: ${pError}`);
|
|
197
197
|
}
|
|
198
|
+
finally
|
|
199
|
+
{
|
|
200
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
201
|
+
}
|
|
198
202
|
}
|
|
199
203
|
else
|
|
200
204
|
{
|
|
@@ -229,6 +233,8 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
229
233
|
{
|
|
230
234
|
// The informary stuff doesn't know the resolution of the hash to address, so do it here.
|
|
231
235
|
let tmpHashAddress = tmpInput.Address;
|
|
236
|
+
const tmpTransactionGUID = this.fable.getUUID();
|
|
237
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
232
238
|
try
|
|
233
239
|
{
|
|
234
240
|
let tmpMarshalDestinationObject = this.getMarshalDestinationObject();
|
|
@@ -240,8 +246,6 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
240
246
|
// Each row has a distinct address!
|
|
241
247
|
let tmpVirtualInformaryHTMLSelector = tmpInput.Macro.HTMLSelectorTabular + `[data-i-index="${pRowIndex}"]`;
|
|
242
248
|
let tmpInputProviderList = this.getInputProviderList(tmpInput);
|
|
243
|
-
const tmpTransactionGUID = this.fable.getUUID();
|
|
244
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
245
249
|
for (let i = 0; i < tmpInputProviderList.length; i++)
|
|
246
250
|
{
|
|
247
251
|
if (this.pict.providers[tmpInputProviderList[i]])
|
|
@@ -258,6 +262,10 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
258
262
|
{
|
|
259
263
|
this.log.error(`Dynamic form [${this.Hash}]::[${this.UUID}] gross error marshaling specific (${tmpInput.Hash}) tabular data for group ${pGroupIndex} row ${pRowIndex} from view in dataChanged event: ${pError}`);
|
|
260
264
|
}
|
|
265
|
+
finally
|
|
266
|
+
{
|
|
267
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
268
|
+
}
|
|
261
269
|
}
|
|
262
270
|
else
|
|
263
271
|
{
|
|
@@ -280,6 +288,8 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
280
288
|
*/
|
|
281
289
|
setDataByInput(pInput, pValue)
|
|
282
290
|
{
|
|
291
|
+
const tmpTransactionGUID = this.fable.getUUID();
|
|
292
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
283
293
|
try
|
|
284
294
|
{
|
|
285
295
|
this.sectionManifest.setValueByHash(this.getMarshalDestinationObject(), pInput.Hash, pValue)
|
|
@@ -289,8 +299,6 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
289
299
|
// Each row has a distinct address!
|
|
290
300
|
let tmpVirtualInformaryHTMLSelector = pInput.Macro.HTMLSelector;
|
|
291
301
|
let tmpInputProviderList = this.getInputProviderList(pInput);
|
|
292
|
-
const tmpTransactionGUID = this.fable.getUUID();
|
|
293
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
294
302
|
for (let i = 0; i < tmpInputProviderList.length; i++)
|
|
295
303
|
{
|
|
296
304
|
if (this.pict.providers[tmpInputProviderList[i]])
|
|
@@ -302,12 +310,15 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
302
310
|
this.log.error(`Dynamic form setDataByInput [${this.Hash}]::[${this.UUID}] cannot find provider [${tmpInputProviderList[i]}] for input [${pInput.Hash}].`);
|
|
303
311
|
}
|
|
304
312
|
}
|
|
305
|
-
this.finalizeTransaction(tmpTransactionGUID);
|
|
306
313
|
}
|
|
307
314
|
catch (pError)
|
|
308
315
|
{
|
|
309
316
|
this.log.error(`Dynamic form setDataByInput [${this.Hash}]::[${this.UUID}] gross error marshaling specific (${pInput.Hash}) from view in dataChanged event: ${pError}`);
|
|
310
317
|
}
|
|
318
|
+
finally
|
|
319
|
+
{
|
|
320
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
321
|
+
}
|
|
311
322
|
|
|
312
323
|
return false;
|
|
313
324
|
}
|
|
@@ -358,6 +369,8 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
358
369
|
)
|
|
359
370
|
{
|
|
360
371
|
// The informary stuff doesn't know the resolution of the hash to address, so do it here.
|
|
372
|
+
const tmpTransactionGUID = this.fable.getUUID();
|
|
373
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
361
374
|
try
|
|
362
375
|
{
|
|
363
376
|
let tmpMarshalDestinationObject = this.getMarshalDestinationObject();
|
|
@@ -369,8 +382,6 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
369
382
|
// Each row has a distinct address!
|
|
370
383
|
let tmpVirtualInformaryHTMLSelector = tmpInput.Macro.HTMLSelectorTabular + `[data-i-index="${pRowIndex}"]`;
|
|
371
384
|
let tmpInputProviderList = this.getInputProviderList(tmpInput);
|
|
372
|
-
const tmpTransactionGUID = this.fable.getUUID();
|
|
373
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
374
385
|
for (let i = 0; i < tmpInputProviderList.length; i++)
|
|
375
386
|
{
|
|
376
387
|
if (this.pict.providers[tmpInputProviderList[i]])
|
|
@@ -382,12 +393,15 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
382
393
|
this.log.error(`Dynamic form setDataTabularByHash [${this.Hash}]::[${this.UUID}] cannot find provider [${tmpInputProviderList[i]}] for input [${tmpInput.Hash}] row ${pRowIndex}.`);
|
|
383
394
|
}
|
|
384
395
|
}
|
|
385
|
-
this.finalizeTransaction(tmpTransactionGUID);
|
|
386
396
|
}
|
|
387
397
|
catch (pError)
|
|
388
398
|
{
|
|
389
399
|
this.log.error(`Dynamic form setDataTabularByHash [${this.Hash}]::[${this.UUID}] gross error marshaling specific (${pInputHash}) tabular data for group ${pGroupIndex} row ${pRowIndex} from view in dataChanged event: ${pError}`);
|
|
390
400
|
}
|
|
401
|
+
finally
|
|
402
|
+
{
|
|
403
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
404
|
+
}
|
|
391
405
|
}
|
|
392
406
|
|
|
393
407
|
return false;
|
|
@@ -444,10 +458,10 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
444
458
|
onMarshalToView()
|
|
445
459
|
{
|
|
446
460
|
// TODO: Only marshal data that has changed since the last marshal. Thought experiment: who decides what changes happened?
|
|
461
|
+
const tmpTransactionGUID = this.fable.getUUID();
|
|
462
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
447
463
|
try
|
|
448
464
|
{
|
|
449
|
-
let tmpTransactionGUID = this.fable.getUUID();
|
|
450
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
451
465
|
let tmpMarshalDestinationObject = this.getMarshalDestinationObject();
|
|
452
466
|
// TODO: Add optional transaction awareness to informary
|
|
453
467
|
this.pict.providers.Informary.marshalDataToForm(tmpMarshalDestinationObject, this.formID, this.sectionManifest);
|
|
@@ -458,15 +472,19 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
458
472
|
{
|
|
459
473
|
this.log.error(`Gross error marshaling data to view: ${pError}`);
|
|
460
474
|
}
|
|
475
|
+
finally
|
|
476
|
+
{
|
|
477
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
478
|
+
}
|
|
461
479
|
return super.onMarshalToView();
|
|
462
480
|
}
|
|
463
481
|
|
|
464
482
|
manualMarshalDataToViewByInput(pInput, pTransactionGUID)
|
|
465
483
|
{
|
|
484
|
+
const tmpTransactionGUID = (typeof(pTransactionGUID) == 'string') ? pTransactionGUID : this.fable.getUUID();
|
|
485
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
466
486
|
try
|
|
467
487
|
{
|
|
468
|
-
let tmpTransactionGUID = (typeof(pTransactionGUID) == 'string') ? pTransactionGUID : this.fable.getUUID();
|
|
469
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
470
488
|
this.pict.providers.Informary.manualMarshalDataToFormByInput(pInput);
|
|
471
489
|
this.runLayoutProviderFunctions('onDataMarshalToForm', tmpTransactionGUID);
|
|
472
490
|
this.runInputProviderFunctions('onDataMarshalToForm', pInput.Hash, null, tmpTransactionGUID);
|
|
@@ -475,14 +493,21 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
475
493
|
{
|
|
476
494
|
this.log.error(`Gross error marshaling data to view: ${pError}`);
|
|
477
495
|
}
|
|
496
|
+
finally
|
|
497
|
+
{
|
|
498
|
+
if (tmpTransactionGUID !== pTransactionGUID)
|
|
499
|
+
{
|
|
500
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
501
|
+
}
|
|
502
|
+
}
|
|
478
503
|
}
|
|
479
504
|
|
|
480
505
|
manualMarshalTabularDataToViewByInput(pInput, pRowIndex, pTransactionGUID)
|
|
481
506
|
{
|
|
507
|
+
const tmpTransactionGUID = (typeof(pTransactionGUID) == 'string') ? pTransactionGUID : this.fable.getUUID();
|
|
508
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
482
509
|
try
|
|
483
510
|
{
|
|
484
|
-
let tmpTransactionGUID = (typeof(pTransactionGUID) == 'string') ? pTransactionGUID : this.fable.getUUID();
|
|
485
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
486
511
|
this.pict.providers.Informary.manualMarshalTabularDataToFormByInput(pInput, pRowIndex);
|
|
487
512
|
this.runLayoutProviderFunctions('onDataMarshalToForm', tmpTransactionGUID);
|
|
488
513
|
this.runInputProviderFunctions('onDataMarshalToForm', pInput.Hash, pRowIndex, tmpTransactionGUID);
|
|
@@ -491,6 +516,13 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
491
516
|
{
|
|
492
517
|
this.log.error(`Gross error marshaling tabular data to view: ${pError}`);
|
|
493
518
|
}
|
|
519
|
+
finally
|
|
520
|
+
{
|
|
521
|
+
if (tmpTransactionGUID !== pTransactionGUID)
|
|
522
|
+
{
|
|
523
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
524
|
+
}
|
|
525
|
+
}
|
|
494
526
|
}
|
|
495
527
|
|
|
496
528
|
/**
|
|
@@ -518,10 +550,10 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
518
550
|
onAfterMarshalToForm()
|
|
519
551
|
{
|
|
520
552
|
// Check to see if there are any hooks set from the input templates
|
|
553
|
+
const tmpTransactionGUID = this.fable.getUUID();
|
|
554
|
+
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
521
555
|
try
|
|
522
556
|
{
|
|
523
|
-
let tmpTransactionGUID = this.fable.getUUID();
|
|
524
|
-
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
525
557
|
this.runInputProviderFunctions('onAfterMarshalToForm', null, null, tmpTransactionGUID);
|
|
526
558
|
|
|
527
559
|
}
|
|
@@ -529,6 +561,10 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
529
561
|
{
|
|
530
562
|
this.log.error(`Gross error running after marshal to form: ${pError}`);
|
|
531
563
|
}
|
|
564
|
+
finally
|
|
565
|
+
{
|
|
566
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
567
|
+
}
|
|
532
568
|
}
|
|
533
569
|
|
|
534
570
|
/**
|
|
@@ -609,8 +645,19 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
609
645
|
let tmpTransactionGUID = this.fable.getUUID();
|
|
610
646
|
this.pict.TransactionTracking.registerTransaction(tmpTransactionGUID);
|
|
611
647
|
|
|
612
|
-
|
|
613
|
-
|
|
648
|
+
try
|
|
649
|
+
{
|
|
650
|
+
this.runLayoutProviderFunctions('onGroupLayoutInitialize', tmpTransactionGUID);
|
|
651
|
+
this.runInputProviderFunctions('onInputInitialize', null, null, tmpTransactionGUID);
|
|
652
|
+
}
|
|
653
|
+
catch (pError)
|
|
654
|
+
{
|
|
655
|
+
this.log.error(`Gross error running after render: ${pError.message || pError}`);
|
|
656
|
+
}
|
|
657
|
+
finally
|
|
658
|
+
{
|
|
659
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
660
|
+
}
|
|
614
661
|
return super.onAfterRender(pRenderable);
|
|
615
662
|
}
|
|
616
663
|
|
|
@@ -671,6 +718,10 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
671
718
|
}
|
|
672
719
|
}
|
|
673
720
|
}
|
|
721
|
+
if (tmpTransactionGUID !== pTransactionGUID)
|
|
722
|
+
{
|
|
723
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
724
|
+
}
|
|
674
725
|
}
|
|
675
726
|
|
|
676
727
|
/**
|
|
@@ -792,7 +843,10 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
792
843
|
}
|
|
793
844
|
}
|
|
794
845
|
}
|
|
795
|
-
|
|
846
|
+
if (pTransactionGUID !== tmpTransactionGUID)
|
|
847
|
+
{
|
|
848
|
+
this.finalizeTransaction(tmpTransactionGUID);
|
|
849
|
+
}
|
|
796
850
|
}
|
|
797
851
|
|
|
798
852
|
/**
|
|
@@ -1184,6 +1238,8 @@ class PictViewDynamicForm extends libPictViewClass
|
|
|
1184
1238
|
}
|
|
1185
1239
|
}
|
|
1186
1240
|
}
|
|
1241
|
+
//TODO: figure out how to safely clean up old transactions
|
|
1242
|
+
//delete this.pict.TransactionTracking.transactions[pTransactionGUID];
|
|
1187
1243
|
return true;
|
|
1188
1244
|
}
|
|
1189
1245
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Pict-View-DynamicForm.d.ts","sourceRoot":"","sources":["../../../source/views/Pict-View-DynamicForm.js"],"names":[],"mappings":";AAYA;;;;;;;GAOG;AACH;IAEC,2DAwGC;IArDA,kCAAkC;IAClC,kBADW,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CACO;IAIrC,uBAAqC;IAGrC,qBAA2H;IAG3H,sBAAwB;IAcxB,+BAA6D;IAmB7D,iCAAuC;IAEvC,eAAmD;IAEnD,4BAAkC;IAClC,6BAAgC;IAMjC;;;;OAIG;IACH,6BAFa,MAAM,CAgBlB;IAED;;;;;;;;OAQG;IACH,wBAFW,MAAM,
|
|
1
|
+
{"version":3,"file":"Pict-View-DynamicForm.d.ts","sourceRoot":"","sources":["../../../source/views/Pict-View-DynamicForm.js"],"names":[],"mappings":";AAYA;;;;;;;GAOG;AACH;IAEC,2DAwGC;IArDA,kCAAkC;IAClC,kBADW,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CACO;IAIrC,uBAAqC;IAGrC,qBAA2H;IAG3H,sBAAwB;IAcxB,+BAA6D;IAmB7D,iCAAuC;IAEvC,eAAmD;IAEnD,4BAAkC;IAClC,6BAAgC;IAMjC;;;;OAIG;IACH,6BAFa,MAAM,CAgBlB;IAED;;;;;;;;OAQG;IACH,wBAFW,MAAM,QAqDhB;IAGD;;;;;;OAMG;IACH,gCAJW,MAAM,eACN,MAAM,aACN,MAAM,QA4DhB;IAED;;;;;;;;OAQG;IACH,uBAJW,MAAM,UACN,GAAG,GACD,OAAO,CAqCnB;IAED;;;;;;;;;;OAUG;IACH,kCANW,MAAM,cACN,MAAM,aACN,MAAM,UACN,GAAG,GAC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ends libPictCommandLineUtility.ServiceCommand
|
|
|
27
27
|
// Parse the CSV file
|
|
28
28
|
const tmpRecords = [];
|
|
29
29
|
const tmpCSVParser = this.fable.instantiateServiceProvider('CSVParser');
|
|
30
|
+
tmpCSVParser.EscapedQuoteString = '"';
|
|
30
31
|
this.fable.log.info(`Parsing CSV file [${pFilePath}]...`);
|
|
31
32
|
|
|
32
33
|
const tmpReadline = libReadline.createInterface(
|
|
@@ -59,6 +60,7 @@ class ImportExtraDataCSVCommand extends libPictCommandLineUtility.ServiceCommand
|
|
|
59
60
|
// Parse the CSV file
|
|
60
61
|
const tmpRecords = [];
|
|
61
62
|
const tmpCSVParser = this.fable.instantiateServiceProvider('CSVParser');
|
|
63
|
+
tmpCSVParser.EscapedQuoteString = '"';
|
|
62
64
|
this.fable.log.info(`Parsing Options CSV file [${pFilePath}]...`);
|
|
63
65
|
|
|
64
66
|
const tmpReadline = libReadline.createInterface(
|
|
@@ -67,6 +67,7 @@ class ImportCSVCommand extends libPictCommandLineUtility.ServiceCommandLineComma
|
|
|
67
67
|
// Parse the CSV file
|
|
68
68
|
const tmpRecords = [];
|
|
69
69
|
const tmpCSVParser = this.fable.instantiateServiceProvider('CSVParser');
|
|
70
|
+
tmpCSVParser.EscapedQuoteString = '"';
|
|
70
71
|
|
|
71
72
|
this.fable.log.info(`Parsing CSV file [${tmpFileName}]...`);
|
|
72
73
|
|
|
@@ -82,6 +83,7 @@ class ImportCSVCommand extends libPictCommandLineUtility.ServiceCommandLineComma
|
|
|
82
83
|
const tmpRecord = tmpCSVParser.parseCSVLine(pLine);
|
|
83
84
|
if (tmpRecord)
|
|
84
85
|
{
|
|
86
|
+
tmpRecord.Equation = tmpRecord.Equation.replace(/"/g, '"');
|
|
85
87
|
tmpRecords.push(tmpRecord);
|
|
86
88
|
}
|
|
87
89
|
});
|