@vendasta/forms_microservice 0.0.9 → 0.0.12

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.
@@ -5,5 +5,5 @@
5
5
  // Objects Index.
6
6
  // *********************************
7
7
  export { PagedRequestOptions, PagedResponseMetadata, } from './paging';
8
- export { CreateFormRequest, CreateFormResponse, CreateFormSubmissionRequest, FormConfigFieldDefault, DeleteFormRequest, FormConfigFieldUnmappedFieldDropdownOption, FormConfigField, ListFormsRequestFilters, FormConfig, ListFormsResponseFormRow, FormSubmission, GetEmbedCodeRequest, GetEmbedCodeResponse, GetFormRequest, GetFormResponse, ListFormsRequest, ListFormsResponse, RenderFormRequest, RenderFormResponse, FormConfigFieldSchema, Styles, FormConfigFieldUnmappedField, UpdateFormRequest, UpdateFormResponse, } from './api';
9
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9mb3Jtc19zZGsvc3JjL2xpYi9faW50ZXJuYWwvb2JqZWN0cy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxvQ0FBb0M7QUFDcEMsMkJBQTJCO0FBQzNCLGdCQUFnQjtBQUNoQixFQUFFO0FBQ0YsaUJBQWlCO0FBQ2pCLG9DQUFvQztBQUNwQyxPQUFPLEVBQ0gsbUJBQW1CLEVBQ25CLHFCQUFxQixHQUN4QixNQUFNLFVBQVUsQ0FBQztBQUVsQixPQUFPLEVBQ0gsaUJBQWlCLEVBQ2pCLGtCQUFrQixFQUNsQiwyQkFBMkIsRUFDM0Isc0JBQXNCLEVBQ3RCLGlCQUFpQixFQUNqQiwwQ0FBMEMsRUFDMUMsZUFBZSxFQUNmLHVCQUF1QixFQUN2QixVQUFVLEVBQ1Ysd0JBQXdCLEVBQ3hCLGNBQWMsRUFDZCxtQkFB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N0LFxuICAgIEdldEZvcm1SZXNwb25zZSxcbiAgICBMaXN0Rm9ybXNSZXF1ZXN0LFxuICAgIExpc3RGb3Jtc1Jlc3BvbnNlLFxuICAgIFJlbmRlckZvcm1SZXF1ZXN0LFxuICAgIFJlbmRlckZvcm1SZXNwb25zZSxcbiAgICBGb3JtQ29uZmlnRmllbGRTY2hlbWEsXG4gICAgU3R5bGVzLFxuICAgIEZvcm1Db25maWdGaWVsZFVubWFwcGVkRmllbGQsXG4gICAgVXBkYXRlRm9ybVJlcXVlc3QsXG4gICAgVXBkYXRlRm9ybVJlc3BvbnNlLFxufSBmcm9tICcuL2FwaSc7XG5cbiJdfQ==
8
+ export { CreateFormRequest, CreateFormResponse, CreateFormSubmissionRequest, FormConfigFieldDefault, DeleteFormRequest, FormConfigFieldUnmappedFieldDropdownOption, FormConfigField, FieldValue, ListFormsRequestFilters, FormConfig, GetMultiRequestFormConfigIdentifier, ListFormsResponseFormRow, FormSubmission, ListFormSubmissionResponseFormSubmission, GetEmbedCodeRequest, GetEmbedCodeResponse, GetFormRequest, GetFormResponse, GetMultiFormVersionsListRequest, GetMultiFormVersionsListResponse, GetMultiRequest, GetMultiResponse, ListFormSubmissionRequest, ListFormSubmissionResponse, ListFormsRequest, ListFormsResponse, PreviewFormRequest, PreviewFormResponse, RenderFormRequest, RenderFormResponse, FormConfigFieldSchema, Styles, ListFormSubmissionResponseFormSubmissionSubmittedValue, FormConfigFieldUnmappedField, UpdateFormRequest, UpdateFormResponse, GetMultiFormVersionsListResponseVersions, } from './api';
9
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9mb3Jtc19zZGsvc3JjL2xpYi9faW50ZXJuYWwvb2JqZWN0cy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxvQ0FBb0M7QUF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jtc1Jlc3BvbnNlLFxuICAgIFByZXZpZXdGb3JtUmVxdWVzdCxcbiAgICBQcmV2aWV3Rm9ybVJlc3BvbnNlLFxuICAgIFJlbmRlckZvcm1SZXF1ZXN0LFxuICAgIFJlbmRlckZvcm1SZXNwb25zZSxcbiAgICBGb3JtQ29uZmlnRmllbGRTY2hlbWEsXG4gICAgU3R5bGVzLFxuICAgIExpc3RGb3JtU3VibWlzc2lvblJlc3BvbnNlRm9ybVN1Ym1pc3Npb25TdWJtaXR0ZWRWYWx1ZSxcbiAgICBGb3JtQ29uZmlnRmllbGRVbm1hcHBlZEZpZWxkLFxuICAgIFVwZGF0ZUZvcm1SZXF1ZXN0LFxuICAgIFVwZGF0ZUZvcm1SZXNwb25zZSxcbiAgICBHZXRNdWx0aUZvcm1WZXJzaW9uc0xpc3RSZXNwb25zZVZlcnNpb25zLFxufSBmcm9tICcuL2FwaSc7XG5cbiJdfQ==
@@ -20,11 +20,11 @@ var FieldType;
20
20
  FieldType[FieldType["FIELD_TYPE_CURRENCY"] = 5] = "FIELD_TYPE_CURRENCY";
21
21
  FieldType[FieldType["FIELD_TYPE_BOOLEAN"] = 6] = "FIELD_TYPE_BOOLEAN";
22
22
  })(FieldType || (FieldType = {}));
23
- var RenderFormRequestJsonSchemaLibrary;
24
- (function (RenderFormRequestJsonSchemaLibrary) {
25
- RenderFormRequestJsonSchemaLibrary[RenderFormRequestJsonSchemaLibrary["RENDER_FORM_REQUEST_JSON_SCHEMA_LIBRARY_UNDEFINED"] = 0] = "RENDER_FORM_REQUEST_JSON_SCHEMA_LIBRARY_UNDEFINED";
26
- RenderFormRequestJsonSchemaLibrary[RenderFormRequestJsonSchemaLibrary["RENDER_FORM_REQUEST_JSON_SCHEMA_LIBRARY_JSONFORM"] = 1] = "RENDER_FORM_REQUEST_JSON_SCHEMA_LIBRARY_JSONFORM";
27
- })(RenderFormRequestJsonSchemaLibrary || (RenderFormRequestJsonSchemaLibrary = {}));
23
+ var JsonSchemaLibrary;
24
+ (function (JsonSchemaLibrary) {
25
+ JsonSchemaLibrary[JsonSchemaLibrary["JSON_SCHEMA_LIBRARY_UNDEFINED"] = 0] = "JSON_SCHEMA_LIBRARY_UNDEFINED";
26
+ JsonSchemaLibrary[JsonSchemaLibrary["JSON_SCHEMA_LIBRARY_JSONFORM"] = 1] = "JSON_SCHEMA_LIBRARY_JSONFORM";
27
+ })(JsonSchemaLibrary || (JsonSchemaLibrary = {}));
28
28
 
29
29
  // *********************************
30
30
 
@@ -178,9 +178,6 @@ class FormConfigFieldDefault {
178
178
  if (proto.integer) {
179
179
  m.integer = parseInt(proto.integer, 10);
180
180
  }
181
- if (proto.date) {
182
- m.date = new Date(proto.date);
183
- }
184
181
  if (proto.currency) {
185
182
  m.currency = parseInt(proto.currency, 10);
186
183
  }
@@ -197,8 +194,8 @@ class FormConfigFieldDefault {
197
194
  if (typeof this.string !== 'undefined') {
198
195
  toReturn['string'] = this.string;
199
196
  }
200
- if (typeof this.date !== 'undefined' && this.date !== null) {
201
- toReturn['date'] = 'toApiJson' in this.date ? this.date.toApiJson() : this.date;
197
+ if (typeof this.date !== 'undefined') {
198
+ toReturn['date'] = this.date;
202
199
  }
203
200
  if (typeof this.dropdown !== 'undefined') {
204
201
  toReturn['dropdown'] = this.dropdown;
@@ -274,6 +271,9 @@ class FormConfigField {
274
271
  if (proto.default) {
275
272
  m.default = FormConfigFieldDefault.fromProto(proto.default);
276
273
  }
274
+ if (proto.defaultValue) {
275
+ m.defaultValue = FieldValue.fromProto(proto.defaultValue);
276
+ }
277
277
  return m;
278
278
  }
279
279
  toApiJson() {
@@ -293,6 +293,53 @@ class FormConfigField {
293
293
  if (typeof this.hidden !== 'undefined') {
294
294
  toReturn['hidden'] = this.hidden;
295
295
  }
296
+ if (typeof this.defaultValue !== 'undefined' && this.defaultValue !== null) {
297
+ toReturn['defaultValue'] = 'toApiJson' in this.defaultValue ? this.defaultValue.toApiJson() : this.defaultValue;
298
+ }
299
+ return toReturn;
300
+ }
301
+ }
302
+ class FieldValue {
303
+ constructor(kwargs) {
304
+ if (!kwargs) {
305
+ return;
306
+ }
307
+ Object.assign(this, kwargs);
308
+ }
309
+ static fromProto(proto) {
310
+ let m = new FieldValue();
311
+ m = Object.assign(m, proto);
312
+ if (proto.integer) {
313
+ m.integer = parseInt(proto.integer, 10);
314
+ }
315
+ if (proto.currency) {
316
+ m.currency = parseInt(proto.currency, 10);
317
+ }
318
+ return m;
319
+ }
320
+ toApiJson() {
321
+ const toReturn = {};
322
+ if (typeof this.invalid !== 'undefined') {
323
+ toReturn['invalid'] = this.invalid;
324
+ }
325
+ if (typeof this.integer !== 'undefined') {
326
+ toReturn['integer'] = this.integer;
327
+ }
328
+ if (typeof this.string !== 'undefined') {
329
+ toReturn['string'] = this.string;
330
+ }
331
+ if (typeof this.date !== 'undefined') {
332
+ toReturn['date'] = this.date;
333
+ }
334
+ if (typeof this.dropdown !== 'undefined') {
335
+ toReturn['dropdown'] = this.dropdown;
336
+ }
337
+ if (typeof this.currency !== 'undefined') {
338
+ toReturn['currency'] = this.currency;
339
+ }
340
+ if (typeof this.boolean !== 'undefined') {
341
+ toReturn['boolean'] = this.boolean;
342
+ }
296
343
  return toReturn;
297
344
  }
298
345
  }
@@ -372,6 +419,29 @@ class FormConfig {
372
419
  return toReturn;
373
420
  }
374
421
  }
422
+ class GetMultiRequestFormConfigIdentifier {
423
+ constructor(kwargs) {
424
+ if (!kwargs) {
425
+ return;
426
+ }
427
+ Object.assign(this, kwargs);
428
+ }
429
+ static fromProto(proto) {
430
+ let m = new GetMultiRequestFormConfigIdentifier();
431
+ m = Object.assign(m, proto);
432
+ return m;
433
+ }
434
+ toApiJson() {
435
+ const toReturn = {};
436
+ if (typeof this.formId !== 'undefined') {
437
+ toReturn['formId'] = this.formId;
438
+ }
439
+ if (typeof this.version !== 'undefined') {
440
+ toReturn['version'] = this.version;
441
+ }
442
+ return toReturn;
443
+ }
444
+ }
375
445
  class ListFormsResponseFormRow {
376
446
  constructor(kwargs) {
377
447
  if (!kwargs) {
@@ -427,6 +497,32 @@ class FormSubmission {
427
497
  return toReturn;
428
498
  }
429
499
  }
500
+ class ListFormSubmissionResponseFormSubmission {
501
+ constructor(kwargs) {
502
+ if (!kwargs) {
503
+ return;
504
+ }
505
+ Object.assign(this, kwargs);
506
+ }
507
+ static fromProto(proto) {
508
+ let m = new ListFormSubmissionResponseFormSubmission();
509
+ m = Object.assign(m, proto);
510
+ if (proto.values) {
511
+ m.values = proto.values.map(ListFormSubmissionResponseFormSubmissionSubmittedValue.fromProto);
512
+ }
513
+ return m;
514
+ }
515
+ toApiJson() {
516
+ const toReturn = {};
517
+ if (typeof this.formSubmissionId !== 'undefined') {
518
+ toReturn['formSubmissionId'] = this.formSubmissionId;
519
+ }
520
+ if (typeof this.values !== 'undefined' && this.values !== null) {
521
+ toReturn['values'] = 'toApiJson' in this.values ? this.values.toApiJson() : this.values;
522
+ }
523
+ return toReturn;
524
+ }
525
+ }
430
526
  class GetEmbedCodeRequest {
431
527
  constructor(kwargs) {
432
528
  if (!kwargs) {
@@ -510,6 +606,153 @@ class GetFormResponse {
510
606
  return toReturn;
511
607
  }
512
608
  }
609
+ class GetMultiFormVersionsListRequest {
610
+ constructor(kwargs) {
611
+ if (!kwargs) {
612
+ return;
613
+ }
614
+ Object.assign(this, kwargs);
615
+ }
616
+ static fromProto(proto) {
617
+ let m = new GetMultiFormVersionsListRequest();
618
+ m = Object.assign(m, proto);
619
+ return m;
620
+ }
621
+ toApiJson() {
622
+ const toReturn = {};
623
+ if (typeof this.formIds !== 'undefined') {
624
+ toReturn['formIds'] = this.formIds;
625
+ }
626
+ return toReturn;
627
+ }
628
+ }
629
+ class GetMultiFormVersionsListResponse {
630
+ constructor(kwargs) {
631
+ if (!kwargs) {
632
+ return;
633
+ }
634
+ Object.assign(this, kwargs);
635
+ }
636
+ static fromProto(proto) {
637
+ let m = new GetMultiFormVersionsListResponse();
638
+ m = Object.assign(m, proto);
639
+ if (proto.versions) {
640
+ m.versions = proto.versions.map(GetMultiFormVersionsListResponseVersions.fromProto);
641
+ }
642
+ return m;
643
+ }
644
+ toApiJson() {
645
+ const toReturn = {};
646
+ if (typeof this.versions !== 'undefined' && this.versions !== null) {
647
+ toReturn['versions'] = 'toApiJson' in this.versions ? this.versions.toApiJson() : this.versions;
648
+ }
649
+ return toReturn;
650
+ }
651
+ }
652
+ class GetMultiRequest {
653
+ constructor(kwargs) {
654
+ if (!kwargs) {
655
+ return;
656
+ }
657
+ Object.assign(this, kwargs);
658
+ }
659
+ static fromProto(proto) {
660
+ let m = new GetMultiRequest();
661
+ m = Object.assign(m, proto);
662
+ if (proto.formConfigIdentifiers) {
663
+ m.formConfigIdentifiers = proto.formConfigIdentifiers.map(GetMultiRequestFormConfigIdentifier.fromProto);
664
+ }
665
+ return m;
666
+ }
667
+ toApiJson() {
668
+ const toReturn = {};
669
+ if (typeof this.formConfigIdentifiers !== 'undefined' && this.formConfigIdentifiers !== null) {
670
+ toReturn['formConfigIdentifiers'] = 'toApiJson' in this.formConfigIdentifiers ? this.formConfigIdentifiers.toApiJson() : this.formConfigIdentifiers;
671
+ }
672
+ return toReturn;
673
+ }
674
+ }
675
+ class GetMultiResponse {
676
+ constructor(kwargs) {
677
+ if (!kwargs) {
678
+ return;
679
+ }
680
+ Object.assign(this, kwargs);
681
+ }
682
+ static fromProto(proto) {
683
+ let m = new GetMultiResponse();
684
+ m = Object.assign(m, proto);
685
+ if (proto.formConfigs) {
686
+ m.formConfigs = proto.formConfigs.map(FormConfig.fromProto);
687
+ }
688
+ return m;
689
+ }
690
+ toApiJson() {
691
+ const toReturn = {};
692
+ if (typeof this.formConfigs !== 'undefined' && this.formConfigs !== null) {
693
+ toReturn['formConfigs'] = 'toApiJson' in this.formConfigs ? this.formConfigs.toApiJson() : this.formConfigs;
694
+ }
695
+ return toReturn;
696
+ }
697
+ }
698
+ class ListFormSubmissionRequest {
699
+ constructor(kwargs) {
700
+ if (!kwargs) {
701
+ return;
702
+ }
703
+ Object.assign(this, kwargs);
704
+ }
705
+ static fromProto(proto) {
706
+ let m = new ListFormSubmissionRequest();
707
+ m = Object.assign(m, proto);
708
+ if (proto.pagingOptions) {
709
+ m.pagingOptions = PagedRequestOptions.fromProto(proto.pagingOptions);
710
+ }
711
+ return m;
712
+ }
713
+ toApiJson() {
714
+ const toReturn = {};
715
+ if (typeof this.formId !== 'undefined') {
716
+ toReturn['formId'] = this.formId;
717
+ }
718
+ if (typeof this.version !== 'undefined') {
719
+ toReturn['version'] = this.version;
720
+ }
721
+ if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {
722
+ toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;
723
+ }
724
+ return toReturn;
725
+ }
726
+ }
727
+ class ListFormSubmissionResponse {
728
+ constructor(kwargs) {
729
+ if (!kwargs) {
730
+ return;
731
+ }
732
+ Object.assign(this, kwargs);
733
+ }
734
+ static fromProto(proto) {
735
+ let m = new ListFormSubmissionResponse();
736
+ m = Object.assign(m, proto);
737
+ if (proto.submissions) {
738
+ m.submissions = proto.submissions.map(ListFormSubmissionResponseFormSubmission.fromProto);
739
+ }
740
+ if (proto.pagingMetadata) {
741
+ m.pagingMetadata = PagedResponseMetadata.fromProto(proto.pagingMetadata);
742
+ }
743
+ return m;
744
+ }
745
+ toApiJson() {
746
+ const toReturn = {};
747
+ if (typeof this.submissions !== 'undefined' && this.submissions !== null) {
748
+ toReturn['submissions'] = 'toApiJson' in this.submissions ? this.submissions.toApiJson() : this.submissions;
749
+ }
750
+ if (typeof this.pagingMetadata !== 'undefined' && this.pagingMetadata !== null) {
751
+ toReturn['pagingMetadata'] = 'toApiJson' in this.pagingMetadata ? this.pagingMetadata.toApiJson() : this.pagingMetadata;
752
+ }
753
+ return toReturn;
754
+ }
755
+ }
513
756
  class ListFormsRequest {
514
757
  constructor(kwargs) {
515
758
  if (!kwargs) {
@@ -568,6 +811,58 @@ class ListFormsResponse {
568
811
  return toReturn;
569
812
  }
570
813
  }
814
+ class PreviewFormRequest {
815
+ constructor(kwargs) {
816
+ if (!kwargs) {
817
+ return;
818
+ }
819
+ Object.assign(this, kwargs);
820
+ }
821
+ static fromProto(proto) {
822
+ let m = new PreviewFormRequest();
823
+ m = Object.assign(m, proto);
824
+ if (proto.formConfig) {
825
+ m.formConfig = FormConfig.fromProto(proto.formConfig);
826
+ }
827
+ if (proto.library) {
828
+ m.library = enumStringToValue(JsonSchemaLibrary, proto.library);
829
+ }
830
+ return m;
831
+ }
832
+ toApiJson() {
833
+ const toReturn = {};
834
+ if (typeof this.formConfig !== 'undefined' && this.formConfig !== null) {
835
+ toReturn['formConfig'] = 'toApiJson' in this.formConfig ? this.formConfig.toApiJson() : this.formConfig;
836
+ }
837
+ if (typeof this.library !== 'undefined') {
838
+ toReturn['library'] = this.library;
839
+ }
840
+ return toReturn;
841
+ }
842
+ }
843
+ class PreviewFormResponse {
844
+ constructor(kwargs) {
845
+ if (!kwargs) {
846
+ return;
847
+ }
848
+ Object.assign(this, kwargs);
849
+ }
850
+ static fromProto(proto) {
851
+ let m = new PreviewFormResponse();
852
+ m = Object.assign(m, proto);
853
+ return m;
854
+ }
855
+ toApiJson() {
856
+ const toReturn = {};
857
+ if (typeof this.jsonSchema !== 'undefined') {
858
+ toReturn['jsonSchema'] = this.jsonSchema;
859
+ }
860
+ if (typeof this.jsonUiSchema !== 'undefined') {
861
+ toReturn['jsonUiSchema'] = this.jsonUiSchema;
862
+ }
863
+ return toReturn;
864
+ }
865
+ }
571
866
  class RenderFormRequest {
572
867
  constructor(kwargs) {
573
868
  if (!kwargs) {
@@ -579,7 +874,7 @@ class RenderFormRequest {
579
874
  let m = new RenderFormRequest();
580
875
  m = Object.assign(m, proto);
581
876
  if (proto.library) {
582
- m.library = enumStringToValue(RenderFormRequestJsonSchemaLibrary, proto.library);
877
+ m.library = enumStringToValue(JsonSchemaLibrary, proto.library);
583
878
  }
584
879
  return m;
585
880
  }
@@ -687,6 +982,32 @@ class Styles {
687
982
  return toReturn;
688
983
  }
689
984
  }
985
+ class ListFormSubmissionResponseFormSubmissionSubmittedValue {
986
+ constructor(kwargs) {
987
+ if (!kwargs) {
988
+ return;
989
+ }
990
+ Object.assign(this, kwargs);
991
+ }
992
+ static fromProto(proto) {
993
+ let m = new ListFormSubmissionResponseFormSubmissionSubmittedValue();
994
+ m = Object.assign(m, proto);
995
+ if (proto.fieldValue) {
996
+ m.fieldValue = FieldValue.fromProto(proto.fieldValue);
997
+ }
998
+ return m;
999
+ }
1000
+ toApiJson() {
1001
+ const toReturn = {};
1002
+ if (typeof this.fieldId !== 'undefined') {
1003
+ toReturn['fieldId'] = this.fieldId;
1004
+ }
1005
+ if (typeof this.fieldValue !== 'undefined' && this.fieldValue !== null) {
1006
+ toReturn['fieldValue'] = 'toApiJson' in this.fieldValue ? this.fieldValue.toApiJson() : this.fieldValue;
1007
+ }
1008
+ return toReturn;
1009
+ }
1010
+ }
690
1011
  class FormConfigFieldUnmappedField {
691
1012
  constructor(kwargs) {
692
1013
  if (!kwargs) {
@@ -765,6 +1086,29 @@ class UpdateFormResponse {
765
1086
  return toReturn;
766
1087
  }
767
1088
  }
1089
+ class GetMultiFormVersionsListResponseVersions {
1090
+ constructor(kwargs) {
1091
+ if (!kwargs) {
1092
+ return;
1093
+ }
1094
+ Object.assign(this, kwargs);
1095
+ }
1096
+ static fromProto(proto) {
1097
+ let m = new GetMultiFormVersionsListResponseVersions();
1098
+ m = Object.assign(m, proto);
1099
+ return m;
1100
+ }
1101
+ toApiJson() {
1102
+ const toReturn = {};
1103
+ if (typeof this.formId !== 'undefined') {
1104
+ toReturn['formId'] = this.formId;
1105
+ }
1106
+ if (typeof this.version !== 'undefined') {
1107
+ toReturn['version'] = this.version;
1108
+ }
1109
+ return toReturn;
1110
+ }
1111
+ }
768
1112
 
769
1113
  // *********************************
770
1114
 
@@ -811,6 +1155,11 @@ class FormSubmissionApiService {
811
1155
  const request = (r.toApiJson) ? r : new CreateFormSubmissionRequest(r);
812
1156
  return this.http.post(this._host + "/forms.v1.FormSubmissionService/CreateFormSubmission", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
813
1157
  }
1158
+ listFormSubmission(r) {
1159
+ const request = (r.toApiJson) ? r : new ListFormSubmissionRequest(r);
1160
+ return this.http.post(this._host + "/forms.v1.FormSubmissionService/ListFormSubmission", request.toApiJson(), this.apiOptions())
1161
+ .pipe(map(resp => ListFormSubmissionResponse.fromProto(resp)));
1162
+ }
814
1163
  }
815
1164
  FormSubmissionApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: FormSubmissionApiService, deps: [{ token: i1.HttpClient }, { token: HostService }], target: i0.ɵɵFactoryTarget.Injectable });
816
1165
  FormSubmissionApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: FormSubmissionApiService, providedIn: 'root' });
@@ -844,6 +1193,16 @@ class FormsApiService {
844
1193
  return this.http.post(this._host + "/forms.v1.Forms/GetForm", request.toApiJson(), this.apiOptions())
845
1194
  .pipe(map(resp => GetFormResponse.fromProto(resp)));
846
1195
  }
1196
+ getMultiFormVersionsList(r) {
1197
+ const request = (r.toApiJson) ? r : new GetMultiFormVersionsListRequest(r);
1198
+ return this.http.post(this._host + "/forms.v1.Forms/GetMultiFormVersionsList", request.toApiJson(), this.apiOptions())
1199
+ .pipe(map(resp => GetMultiFormVersionsListResponse.fromProto(resp)));
1200
+ }
1201
+ getMulti(r) {
1202
+ const request = (r.toApiJson) ? r : new GetMultiRequest(r);
1203
+ return this.http.post(this._host + "/forms.v1.Forms/GetMulti", request.toApiJson(), this.apiOptions())
1204
+ .pipe(map(resp => GetMultiResponse.fromProto(resp)));
1205
+ }
847
1206
  createForm(r) {
848
1207
  const request = (r.toApiJson) ? r : new CreateFormRequest(r);
849
1208
  return this.http.post(this._host + "/forms.v1.Forms/CreateForm", request.toApiJson(), this.apiOptions())
@@ -868,6 +1227,11 @@ class FormsApiService {
868
1227
  const request = (r.toApiJson) ? r : new DeleteFormRequest(r);
869
1228
  return this.http.post(this._host + "/forms.v1.Forms/DeleteForm", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
870
1229
  }
1230
+ previewForm(r) {
1231
+ const request = (r.toApiJson) ? r : new PreviewFormRequest(r);
1232
+ return this.http.post(this._host + "/forms.v1.Forms/PreviewForm", request.toApiJson(), this.apiOptions())
1233
+ .pipe(map(resp => PreviewFormResponse.fromProto(resp)));
1234
+ }
871
1235
  }
872
1236
  FormsApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: FormsApiService, deps: [{ token: i1.HttpClient }, { token: HostService }], target: i0.ɵɵFactoryTarget.Injectable });
873
1237
  FormsApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: FormsApiService, providedIn: 'root' });
@@ -884,5 +1248,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImpor
884
1248
  * Generated bundle index. Do not edit.
885
1249
  */
886
1250
 
887
- export { CreateFormRequest, CreateFormResponse, CreateFormSubmissionRequest, DeleteFormRequest, FieldType, FormConfig, FormConfigField, FormConfigFieldDefault, FormConfigFieldSchema, FormConfigFieldUnmappedField, FormConfigFieldUnmappedFieldDropdownOption, FormSubmission, FormSubmissionApiService, FormsApiService, GetEmbedCodeRequest, GetEmbedCodeResponse, GetFormRequest, GetFormResponse, HostService, ListFormsRequest, ListFormsRequestFilters, ListFormsResponse, ListFormsResponseFormRow, PagedRequestOptions, PagedResponseMetadata, RenderFormRequest, RenderFormRequestJsonSchemaLibrary, RenderFormResponse, Styles, UpdateFormRequest, UpdateFormResponse };
1251
+ export { CreateFormRequest, CreateFormResponse, CreateFormSubmissionRequest, DeleteFormRequest, FieldType, FieldValue, FormConfig, FormConfigField, FormConfigFieldDefault, FormConfigFieldSchema, FormConfigFieldUnmappedField, FormConfigFieldUnmappedFieldDropdownOption, FormSubmission, FormSubmissionApiService, FormsApiService, GetEmbedCodeRequest, GetEmbedCodeResponse, GetFormRequest, GetFormResponse, GetMultiFormVersionsListRequest, GetMultiFormVersionsListResponse, GetMultiFormVersionsListResponseVersions, GetMultiRequest, GetMultiRequestFormConfigIdentifier, GetMultiResponse, HostService, JsonSchemaLibrary, ListFormSubmissionRequest, ListFormSubmissionResponse, ListFormSubmissionResponseFormSubmission, ListFormSubmissionResponseFormSubmissionSubmittedValue, ListFormsRequest, ListFormsRequestFilters, ListFormsResponse, ListFormsResponseFormRow, PagedRequestOptions, PagedResponseMetadata, PreviewFormRequest, PreviewFormResponse, RenderFormRequest, RenderFormResponse, Styles, UpdateFormRequest, UpdateFormResponse };
888
1252
  //# sourceMappingURL=vendasta-forms_microservice.mjs.map