@lingk/sync 0.0.15 → 0.0.17

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/build/main.js CHANGED
@@ -485,7 +485,11 @@ module.exports =
485
485
  credentials: [{ name: 'Username' }, { name: 'Password' }, { name: 'Public Key' }]
486
486
  },
487
487
  Banner: {
488
- credentials: null
488
+ credentials: null,
489
+ customStep: {
490
+ type: 'adapter',
491
+ title: 'Banner Adapter'
492
+ }
489
493
  }
490
494
  };
491
495
 
@@ -1860,13 +1864,13 @@ module.exports =
1860
1864
 
1861
1865
  function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
1862
1866
 
1863
- var BannerAdapterStep = function (_Component) {
1864
- _inherits(BannerAdapterStep, _Component);
1867
+ var AdapterStep = function (_Component) {
1868
+ _inherits(AdapterStep, _Component);
1865
1869
 
1866
- function BannerAdapterStep() {
1867
- _classCallCheck(this, BannerAdapterStep);
1870
+ function AdapterStep() {
1871
+ _classCallCheck(this, AdapterStep);
1868
1872
 
1869
- var _this = _possibleConstructorReturn(this, (BannerAdapterStep.__proto__ || Object.getPrototypeOf(BannerAdapterStep)).call(this));
1873
+ var _this = _possibleConstructorReturn(this, (AdapterStep.__proto__ || Object.getPrototypeOf(AdapterStep)).call(this));
1870
1874
 
1871
1875
  _this.state = {
1872
1876
  showSecret: false
@@ -1874,7 +1878,7 @@ module.exports =
1874
1878
  return _this;
1875
1879
  }
1876
1880
 
1877
- _createClass(BannerAdapterStep, [{
1881
+ _createClass(AdapterStep, [{
1878
1882
  key: 'render',
1879
1883
  value: function render() {
1880
1884
  var _this2 = this;
@@ -2018,7 +2022,7 @@ module.exports =
2018
2022
  }
2019
2023
  }]);
2020
2024
 
2021
- return BannerAdapterStep;
2025
+ return AdapterStep;
2022
2026
  }(_react.Component);
2023
2027
 
2024
2028
  exports.default = (0, _reduxForm.reduxForm)({
@@ -2027,7 +2031,7 @@ module.exports =
2027
2031
  forceUnregisterOnUnmount: true,
2028
2032
  touchOnBlur: false,
2029
2033
  validate: _validate2.default
2030
- })(BannerAdapterStep);
2034
+ })(AdapterStep);
2031
2035
 
2032
2036
  /***/ },
2033
2037
  /* 37 */
@@ -2082,6 +2086,19 @@ module.exports =
2082
2086
 
2083
2087
  change('deployment', formValues.deployment || Object.keys(step.options)[0]);
2084
2088
  }
2089
+ }, {
2090
+ key: 'options',
2091
+ value: function options(ops) {
2092
+ var deploymentTitles = {
2093
+ 'once': 'Run Once',
2094
+ 'scheduled': 'Timed Schedule'
2095
+ };
2096
+ var obj = {};
2097
+ ops.forEach(function (o) {
2098
+ obj[o] = deploymentTitles[o];
2099
+ });
2100
+ return obj;
2101
+ }
2085
2102
  }, {
2086
2103
  key: 'render',
2087
2104
  value: function render() {
@@ -2108,7 +2125,7 @@ module.exports =
2108
2125
  'div',
2109
2126
  { style: { marginLeft: 16 } },
2110
2127
  _react2.default.createElement(_reduxForm.Field, { name: 'deployment', component: inputs.rfRadioGroup, label: 'Deployment Type',
2111
- options: step.options
2128
+ options: this.options(step.options)
2112
2129
  }),
2113
2130
  _react2.default.createElement('br', null),
2114
2131
  step.options && formValues.deployment === 'scheduled' ? _react2.default.createElement(
@@ -3191,6 +3208,7 @@ module.exports =
3191
3208
  _this.addDefaultDataEntity = _this.addDefaultDataEntity.bind(_this);
3192
3209
  _this.selectAll = _this.selectAll.bind(_this);
3193
3210
  _this.deselectAll = _this.deselectAll.bind(_this);
3211
+ _this.removeEntity = _this.removeEntity.bind(_this);
3194
3212
  return _this;
3195
3213
  }
3196
3214
 
@@ -3233,7 +3251,8 @@ module.exports =
3233
3251
  var obj = Object.assign({}, includedFields) || {};
3234
3252
  obj[this.state.newEntity] = {};
3235
3253
  change(step.mode + 'Schema', obj);
3236
- this.setState({ selectedDataEntity: this.state.newEntity, newEntity: '' });
3254
+ this.pickEntity(this.state.newEntity);
3255
+ this.setState({ newEntity: '' });
3237
3256
  }
3238
3257
  }, {
3239
3258
  key: 'addDefaultDataEntity',
@@ -3267,7 +3286,11 @@ module.exports =
3267
3286
 
3268
3287
  var includedFields = formValues[step.mode + 'Schema'] || {};
3269
3288
  var obj = Object.assign({}, includedFields) || {};
3270
- obj[this.state.selectedDataEntity] = step.defaultSchema[this.state.selectedDataEntity];
3289
+ var rsc = obj[this.state.selectedDataEntity] || {};
3290
+ Object.keys(rsc).forEach(function (field) {
3291
+ rsc[field] = true;
3292
+ });
3293
+ obj[this.state.selectedDataEntity] = rsc;
3271
3294
  change(step.mode + 'Schema', obj);
3272
3295
  }
3273
3296
  }, {
@@ -3278,9 +3301,27 @@ module.exports =
3278
3301
  step = _props6.step,
3279
3302
  formValues = _props6.formValues;
3280
3303
 
3304
+ var includedFields = formValues[step.mode + 'Schema'] || {};
3305
+ var obj = Object.assign({}, includedFields) || {};
3306
+ var rsc = obj[this.state.selectedDataEntity] || {};
3307
+ Object.keys(rsc).forEach(function (field) {
3308
+ rsc[field] = false;
3309
+ });
3310
+ obj[this.state.selectedDataEntity] = rsc;
3311
+ change(step.mode + 'Schema', obj);
3312
+ }
3313
+ }, {
3314
+ key: 'removeEntity',
3315
+ value: function removeEntity(e, entity) {
3316
+ e.stopPropagation();
3317
+ var _props7 = this.props,
3318
+ change = _props7.change,
3319
+ step = _props7.step,
3320
+ formValues = _props7.formValues;
3321
+
3281
3322
  var includedFields = formValues[step.mode + 'Schema'] || {};
3282
3323
  var obj = Object.assign({}, includedFields);
3283
- obj[this.state.selectedDataEntity] = {};
3324
+ delete obj[entity];
3284
3325
  change(step.mode + 'Schema', obj);
3285
3326
  }
3286
3327
  }, {
@@ -3288,29 +3329,19 @@ module.exports =
3288
3329
  value: function render() {
3289
3330
  var _this2 = this;
3290
3331
 
3291
- var _props7 = this.props,
3292
- inputs = _props7.inputs,
3293
- handleSubmit = _props7.handleSubmit,
3294
- nav = _props7.nav,
3295
- formValues = _props7.formValues,
3296
- step = _props7.step,
3297
- reset = _props7.reset,
3298
- change = _props7.change;
3332
+ var _props8 = this.props,
3333
+ inputs = _props8.inputs,
3334
+ handleSubmit = _props8.handleSubmit,
3335
+ nav = _props8.nav,
3336
+ formValues = _props8.formValues,
3337
+ step = _props8.step,
3338
+ reset = _props8.reset,
3339
+ change = _props8.change;
3299
3340
 
3300
3341
  var includedFields = formValues[step.mode + 'Schema'] || {};
3301
3342
  var Button = inputs.Button;
3302
3343
  var Input = inputs.Input;
3303
3344
  var Select = inputs.Select;
3304
- var smallButtonStyle = {
3305
- marginLeft: 4,
3306
- height: 22,
3307
- width: 68,
3308
- lineHeight: '20px',
3309
- padding: 0,
3310
- verticalAlign: 'middle',
3311
- marginBottom: 4,
3312
- fontSize: 10
3313
- };
3314
3345
  return _react2.default.createElement(
3315
3346
  'form',
3316
3347
  { onKeyPress: function onKeyPress(e) {
@@ -3320,26 +3351,18 @@ module.exports =
3320
3351
  'div',
3321
3352
  { style: { fontSize: 20 } },
3322
3353
  step.mode.charAt(0).toUpperCase() + step.mode.slice(1),
3323
- ': Select ',
3354
+ ': Build ',
3324
3355
  step.provider,
3325
- ' Data Definition'
3356
+ ' Dataset'
3326
3357
  ),
3327
3358
  _react2.default.createElement('br', null),
3328
3359
  _react2.default.createElement(
3329
3360
  'div',
3330
3361
  { style: { marginLeft: 16 } },
3331
- _react2.default.createElement(
3332
- 'div',
3333
- { style: { display: 'inline-block', width: 166 } },
3334
- _react2.default.createElement(Select, { selectedDataEntity: this.state.selectedDataEntity, label: 'Add Default Entity',
3335
- onSelect: this.addDefaultDataEntity, values: step.defaultSchema,
3336
- selectedValues: formValues[step.mode + 'Schema']
3337
- })
3338
- ),
3339
3362
  _react2.default.createElement(
3340
3363
  Button,
3341
3364
  { type: 'brand', onClick: this.loadDefault },
3342
- 'Load All Defaults'
3365
+ 'Load Default Dataset'
3343
3366
  ),
3344
3367
  '\xA0\xA0',
3345
3368
  _react2.default.createElement(
@@ -3349,10 +3372,18 @@ module.exports =
3349
3372
  ),
3350
3373
  _react2.default.createElement('br', null),
3351
3374
  _react2.default.createElement('br', null),
3375
+ _react2.default.createElement(
3376
+ 'div',
3377
+ { style: { display: 'inline-block', width: 166 } },
3378
+ _react2.default.createElement(Select, { selectedDataEntity: this.state.selectedDataEntity, label: 'Add Default Entity',
3379
+ onSelect: this.addDefaultDataEntity, values: step.defaultSchema,
3380
+ selectedValues: formValues[step.mode + 'Schema'], title: 'Customize Dataset'
3381
+ })
3382
+ ),
3352
3383
  _react2.default.createElement(
3353
3384
  'div',
3354
3385
  { style: { display: 'inline-block' } },
3355
- _react2.default.createElement(Input, { label: 'Add Data Entity', type: 'text', value: this.state.newEntity, onChange: function onChange(e) {
3386
+ _react2.default.createElement(Input, { label: '', type: 'text', value: this.state.newEntity, onChange: function onChange(e) {
3356
3387
  return !e.target.value.includes('.') ? _this2.setState({ newEntity: e.target.value }) : {};
3357
3388
  },
3358
3389
  style: { width: 245 }, placeholder: 'Add Custom Data Entity', onKeyPress: this.newEntityKeyPress })
@@ -3371,16 +3402,17 @@ module.exports =
3371
3402
  _react2.default.createElement('br', null),
3372
3403
  _react2.default.createElement('br', null)
3373
3404
  ),
3374
- this.state.selectedDataEntity ? _react2.default.createElement(
3405
+ includedFields && Object.keys(includedFields).length > 0 ? _react2.default.createElement(
3375
3406
  'div',
3376
3407
  { style: { position: 'relative', width: 550, marginLeft: 16 } },
3377
- includedFields ? _react2.default.createElement(_schemaAccordion2.default, { values: includedFields,
3408
+ _react2.default.createElement(_schemaAccordion2.default, { values: includedFields,
3378
3409
  pickEntity: this.pickEntity, inputs: inputs, step: step,
3379
3410
  change: change, formValues: formValues,
3380
3411
  selectedEntity: this.state.selectedDataEntity,
3381
3412
  innerSelectedEntity: this.state.innerSelectedEntity,
3382
- selectAll: this.selectAll, deselectAll: this.deselectAll
3383
- }) : null,
3413
+ selectAll: this.selectAll, deselectAll: this.deselectAll,
3414
+ removeEntity: this.removeEntity
3415
+ }),
3384
3416
  _react2.default.createElement('br', null)
3385
3417
  ) : null,
3386
3418
  _react2.default.createElement(_navButtons2.default, { handleSubmit: handleSubmit, nav: nav, reset: reset, inputs: inputs }),
@@ -3477,7 +3509,7 @@ module.exports =
3477
3509
  'div',
3478
3510
  { ref: function ref(_ref) {
3479
3511
  _this2.main = _ref;
3480
- }, id: 'main',
3512
+ },
3481
3513
  style: {
3482
3514
  background: 'white', height: 288, width: 350, overflow: 'scroll',
3483
3515
  border: '1px solid rgb(204, 205, 207)', padding: 12
@@ -3497,7 +3529,7 @@ module.exports =
3497
3529
  style: { height: 35 },
3498
3530
  onClick: function onClick() {
3499
3531
  _this2.setState({ innerSelectedEntity: selectedEntity === entity && _this2.state.innerSelectedEntity === entity ? '' : entity });
3500
- _this2.scrollToTop(_this2.main, 18, i * 45 + 6);
3532
+ _this2.scrollToTop(_this2.main, 18, i * 43 + 6);
3501
3533
  pickEntity(entity);
3502
3534
  }
3503
3535
  },
@@ -3507,7 +3539,7 @@ module.exports =
3507
3539
  'div',
3508
3540
  { className: 'accordion-panel-collapse',
3509
3541
  style: {
3510
- height: _this2.state.innerSelectedEntity === entity ? Object.keys(values[entity]).length * 19 + 19 : 0
3542
+ height: _this2.state.innerSelectedEntity === entity ? Object.keys(values[entity]).length * 18 + 19 : 0
3511
3543
  }
3512
3544
  },
3513
3545
  _react2.default.createElement('div', { style: { height: 9 } }),
@@ -3520,7 +3552,7 @@ module.exports =
3520
3552
  style: {
3521
3553
  paddingLeft: 5,
3522
3554
  background: selectedField && selectedField === field ? '#dfe0e0' : 'initial',
3523
- fontWeight: mode === 'source' && mappings && Object.keys(mappings).includes(entity + '.' + field) ? 'bold' : 'normal',
3555
+ fontWeight: mode === 'source' && mappings && Object.keys(mappings).includes(entity + '.' + field) || mode === 'destination' && mappings && Object.keys(mappings).includes(entity + '.' + field) ? 'bold' : 'normal',
3524
3556
  color: mode === 'destination' && !selectedField ? 'grey' : 'black'
3525
3557
  },
3526
3558
  onClick: function onClick() {
@@ -3613,7 +3645,9 @@ module.exports =
3613
3645
  value: function newFieldKeyPress(e) {
3614
3646
  if (e.charCode === 13) {
3615
3647
  e.preventDefault();
3616
- this.addCustomField(e);
3648
+ if (this.state.newField) {
3649
+ this.addCustomField(e);
3650
+ }
3617
3651
  }
3618
3652
  }
3619
3653
  }, {
@@ -3647,7 +3681,8 @@ module.exports =
3647
3681
  pickEntity = _props2.pickEntity,
3648
3682
  values = _props2.values,
3649
3683
  selectedEntity = _props2.selectedEntity,
3650
- innerSelectedEntity = _props2.innerSelectedEntity;
3684
+ innerSelectedEntity = _props2.innerSelectedEntity,
3685
+ removeEntity = _props2.removeEntity;
3651
3686
 
3652
3687
  var Button = inputs.Button;
3653
3688
  var Input = inputs.Input;
@@ -3665,7 +3700,7 @@ module.exports =
3665
3700
  'div',
3666
3701
  { ref: function ref(_ref) {
3667
3702
  _this2.main = _ref;
3668
- }, id: 'main',
3703
+ },
3669
3704
  style: {
3670
3705
  background: 'white', height: 350, width: 550, overflow: 'scroll',
3671
3706
  border: '1px solid rgb(204, 205, 207)', padding: 12
@@ -3689,34 +3724,42 @@ module.exports =
3689
3724
  { style: { paddingTop: 8, overflow: 'hidden', display: 'inline-block', width: 227, textDecoration: 'inherit' } },
3690
3725
  entity
3691
3726
  ),
3692
- _react2.default.createElement(
3693
- _reactAddonsCssTransitionGroup2.default,
3694
- { transitionName: 'panel', transitionEnterTimeout: 300, transitionLeaveTimeout: 300 },
3695
- innerSelectedEntity === entity ? _react2.default.createElement(
3696
- 'div',
3697
- { style: { display: 'inline-block', verticalAlign: 'top' }, className: 'transition' },
3698
- _react2.default.createElement(Input, { type: 'text', value: _this2.state.newField, disabled: !selectedEntity,
3699
- onChange: function onChange(e) {
3700
- return !e.target.value.includes('.') && e.target.value.charAt(0) !== ' ' ? _this2.setState({ newField: e.target.value }) : {};
3701
- },
3702
- style: { width: 200, display: 'inline-block' }, placeholder: 'Add Field', onKeyPress: _this2.newFieldKeyPress,
3703
- onClick: function onClick(e) {
3704
- return e.stopPropagation();
3705
- }
3706
- }),
3707
- _react2.default.createElement(
3708
- Button,
3709
- { type: 'neutral', onClick: _this2.addCustomField, disabled: !_this2.state.newField,
3710
- style: { marginLeft: 10 } },
3711
- 'Add'
3712
- )
3713
- ) : null
3727
+ innerSelectedEntity === entity ? _react2.default.createElement(
3728
+ 'div',
3729
+ { style: { display: 'inline-block', verticalAlign: 'top' }, className: 'transition' },
3730
+ _react2.default.createElement(Input, { type: 'text', value: _this2.state.newField, disabled: !selectedEntity,
3731
+ onChange: function onChange(e) {
3732
+ return !e.target.value.includes('.') && e.target.value.charAt(0) !== ' ' ? _this2.setState({ newField: e.target.value }) : {};
3733
+ },
3734
+ style: { width: 200, display: 'inline-block' }, placeholder: 'Add Field', onKeyPress: _this2.newFieldKeyPress,
3735
+ onClick: function onClick(e) {
3736
+ return e.stopPropagation();
3737
+ }
3738
+ }),
3739
+ _react2.default.createElement(
3740
+ Button,
3741
+ { type: 'neutral', onClick: _this2.addCustomField, disabled: !_this2.state.newField,
3742
+ style: { marginLeft: 10 } },
3743
+ 'Add'
3744
+ )
3745
+ ) : _react2.default.createElement(
3746
+ 'div',
3747
+ { className: 'accordion-panel-close', onClick: function onClick(e) {
3748
+ return removeEntity(e, entity);
3749
+ } },
3750
+ _react2.default.createElement(
3751
+ 'svg',
3752
+ { xmlns: 'http://www.w3.org/2000/svg', style: { width: 18, height: 18 }, viewBox: '0 0 60 60' },
3753
+ _react2.default.createElement('path', { style: { stroke: 'white', fill: 'white', strokeWidth: 5, strokeLinecap: 'round' },
3754
+ d: 'M 15.674663,15.572746 L 44.587629,44.485711 M 45.118838,15.420972 L 15.522889,45.016920' })
3755
+ )
3714
3756
  )
3715
3757
  ),
3716
3758
  _react2.default.createElement(
3717
3759
  _reactAddonsCssTransitionGroup2.default,
3718
3760
  { transitionName: 'fieldslabel', transitionEnterTimeout: 200, transitionLeaveTimeout: 200 },
3719
- innerSelectedEntity === entity ? _react2.default.createElement(
3761
+ innerSelectedEntity === entity ? // && Object.keys(values[entity]).length > 0
3762
+ _react2.default.createElement(
3720
3763
  'div',
3721
3764
  null,
3722
3765
  _react2.default.createElement(
@@ -3756,7 +3799,7 @@ module.exports =
3756
3799
  'div',
3757
3800
  { className: 'accordion-panel-collapse',
3758
3801
  style: {
3759
- height: values[entity] && innerSelectedEntity === entity ? Object.keys(values[entity]).length * 19 + 9 : 0
3802
+ height: Object.keys(values[entity]).length * 19 + 9
3760
3803
  }
3761
3804
  },
3762
3805
  Object.keys(values[entity]).filter(function (f) {
@@ -3854,9 +3897,9 @@ module.exports =
3854
3897
 
3855
3898
  var _nameStep2 = _interopRequireDefault(_nameStep);
3856
3899
 
3857
- var _bannerAdapterStep = __webpack_require__(36);
3900
+ var _adapterStep = __webpack_require__(36);
3858
3901
 
3859
- var _bannerAdapterStep2 = _interopRequireDefault(_bannerAdapterStep);
3902
+ var _adapterStep2 = _interopRequireDefault(_adapterStep);
3860
3903
 
3861
3904
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
3862
3905
 
@@ -3891,7 +3934,7 @@ module.exports =
3891
3934
  map: _mapStep2.default,
3892
3935
  preview: _previewStep2.default,
3893
3936
  deploy: _deployStep2.default,
3894
- bannerAdapter: _bannerAdapterStep2.default,
3937
+ adapter: _adapterStep2.default,
3895
3938
  name: _nameStep2.default
3896
3939
  };
3897
3940
  return _this;
@@ -4120,6 +4163,45 @@ module.exports =
4120
4163
 
4121
4164
  function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
4122
4165
 
4166
+ var wiz = {
4167
+ title: 'Banner to Salesforce',
4168
+ source: {
4169
+ type: 'Banner',
4170
+ name: 'Banner',
4171
+ env: true,
4172
+ defaultSchema: example.wizards[1].sourceDefaultSchema
4173
+ },
4174
+ destination: {
4175
+ type: 'Salesforce',
4176
+ name: 'Salesforce',
4177
+ env: false,
4178
+ defaultSchema: example.wizards[1].destinationDefaultSchema
4179
+ },
4180
+ deployment: ['once', 'scheduled'],
4181
+ autoMapData: example.wizards[1].autoMapData,
4182
+ dummyData: example.wizards[1].dummyData
4183
+ };
4184
+ /*
4185
+ id: 2,
4186
+ title: 'Banner to Salesforce',
4187
+ description: 'On-premise Banner instance to Salesforce Org.',
4188
+ tag:'Activated',
4189
+ source:{
4190
+ title: 'Banner',
4191
+ type: 'banner',
4192
+ defaultSchema: 'guid',
4193
+ env: true
4194
+ },
4195
+ destination:{
4196
+ title: 'Salesforce',
4197
+ type: 'salesforce',
4198
+ defaultSchema: 'guid',
4199
+ env: false
4200
+ },
4201
+ defaultMapping: 'guid',
4202
+ deployment: ['once', 'scheduled'], // keys for deployment options
4203
+ */
4204
+
4123
4205
  var LingkSync = function (_Component) {
4124
4206
  _inherits(LingkSync, _Component);
4125
4207
 
@@ -4154,7 +4236,7 @@ module.exports =
4154
4236
  mode: 'source'
4155
4237
  }, {
4156
4238
  type: 'schema',
4157
- title: 'Source Schema',
4239
+ title: 'Source Dataset',
4158
4240
  mode: 'source'
4159
4241
  }, {
4160
4242
  type: 'filter',
@@ -4165,7 +4247,7 @@ module.exports =
4165
4247
  mode: 'destination'
4166
4248
  }, {
4167
4249
  type: 'schema',
4168
- title: 'Destination Schema',
4250
+ title: 'Destination Dataset',
4169
4251
  mode: 'destination'
4170
4252
  }, {
4171
4253
  type: 'map',
@@ -4183,7 +4265,7 @@ module.exports =
4183
4265
  _createClass(LingkSync, [{
4184
4266
  key: 'componentDidMount',
4185
4267
  value: function componentDidMount() {
4186
- var wizard = example.wizards[1];
4268
+ var wizard = wiz;
4187
4269
  var stepList = [];
4188
4270
 
4189
4271
  for (var i = 0; i < this.allSteps.length; i++) {
@@ -4192,35 +4274,37 @@ module.exports =
4192
4274
  step.name = wizard.title;
4193
4275
  stepList.push(step);
4194
4276
  } else if (step.type === 'custom') {
4195
- if (wizard.customStep) {
4196
- step.type = wizard.customStep.type;
4197
- step.title = wizard.customStep.title;
4277
+ var customStep = examp.providerTypes[wizard.source.type].customStep;
4278
+ if (customStep) {
4279
+ step.type = customStep.type;
4280
+ step.title = customStep.title;
4198
4281
  stepList.push(step);
4199
4282
  }
4200
4283
  } else if (step.type === 'environment') {
4201
- if (step.mode === 'source') {
4202
- step.provider = wizard.sourceProvider;
4203
- step.credentials = examp.providerTypes[wizard.sourceProviderType].credentials || null;
4204
- } else if (step.mode === 'destination') {
4284
+ if (step.mode === 'source' && wizard.source.env) {
4285
+ step.provider = wizard.source.name;
4286
+ step.credentials = examp.providerTypes[wizard.source.type].credentials || null;
4287
+ stepList.push(step);
4288
+ } else if (step.mode === 'destination' && wizard.destination.env) {
4205
4289
  step.provider = wizard.destinationProvider;
4206
- step.credentials = examp.providerTypes[wizard.destinationProviderType].credentials || null;
4290
+ step.credentials = examp.providerTypes[wizard.destination.type].credentials || null;
4291
+ stepList.push(step);
4207
4292
  }
4208
- stepList.push(step);
4209
4293
  } else if (step.type === 'schema') {
4210
4294
  if (step.mode === 'source') {
4211
- step.provider = wizard.sourceProvider;
4212
- step.defaultSchema = wizard.sourceDefaultSchema || null;
4295
+ step.provider = wizard.source.name;
4296
+ step.defaultSchema = wizard.source.defaultSchema || null;
4213
4297
  } else if (step.mode === 'destination') {
4214
- step.provider = wizard.destinationProvider;
4215
- step.defaultSchema = wizard.destinationDefaultSchema || null;
4298
+ step.provider = wizard.destination.name;
4299
+ step.defaultSchema = wizard.destination.defaultSchema || null;
4216
4300
  }
4217
4301
  stepList.push(step);
4218
4302
  } else if (step.type === 'filter') {
4219
- step.provider = wizard.sourceProvider;
4303
+ step.provider = wizard.source.name;
4220
4304
  stepList.push(step);
4221
4305
  } else if (step.type === 'map') {
4222
- step.sourceProvider = wizard.sourceProvider;
4223
- step.destinationProvider = wizard.destinationProvider;
4306
+ step.sourceProvider = wizard.source.name;
4307
+ step.destinationProvider = wizard.destination.name;
4224
4308
  step.autoMapData = wizard.autoMapData || null;
4225
4309
  stepList.push(step);
4226
4310
  } else if (step.type === 'preview') {