@pxp-nd/flow 1.1.13 → 1.1.15

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.
@@ -252,13 +252,12 @@ let Flow = class Flow extends core_1.Controller {
252
252
  };
253
253
  let flowDataClone;
254
254
  let isCopy = false;
255
- //if we have a vendoId as parameter the origin is a template
256
- if (params.vendorId) {
255
+ //if we have a name as parameter the origin is a template
256
+ if (params.name) {
257
257
  flowDataClone = await (0, typeorm_1.getManager)().save(Flow_1.default, { ...flowToClone, name: `${params.name}`, vendorId: params.vendorId, type: 'custom' });
258
258
  }
259
259
  else {
260
260
  flowDataClone = await (0, typeorm_1.getManager)().save(Flow_1.default, { ...flowToClone, name: `${flowData.name} Copy` });
261
- isCopy = true;
262
261
  }
263
262
  const dataNode = await Node_1.default.findOne({ where: { flowId: params.flowId, isInit: 'Y', isActive: true }, order: { nodeId: "ASC" } });
264
263
  dataNode && await this.copyNode(dataNode, flowDataClone.flowId, manager, true, isCopy);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pxp-nd/flow",
3
- "version": "1.1.13",
3
+ "version": "1.1.15",
4
4
  "description": "Workflow module for pxp-nd framework",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",