n8n-nodes-didar-crm 0.0.21 → 0.0.22

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.
@@ -18,13 +18,11 @@ async function activityCreate(i, returnData) {
18
18
  const isDone = this.getNodeParameter('IsDone', i, false);
19
19
  // Additional fields
20
20
  const add = this.getNodeParameter('additionalFields', i, {}) || {};
21
- // Owner
22
- let ownerId = '';
23
- if (add.OwnerMode === 'select')
24
- ownerId = add.OwnerIdSelect || '';
25
- else if (add.OwnerMode === 'manual')
26
- ownerId = add.OwnerIdManual || '';
27
- // OwnerId اختیاری است مگر شما الزامش کنید؛ اگر لازم شد همین‌جا ارور دهید.
21
+ // Owner (select/manual) — optional
22
+ const ownerMode = this.getNodeParameter('OwnerMode', i, 'select');
23
+ const ownerSel = this.getNodeParameter('OwnerIdSelect', i, '');
24
+ const ownerMan = this.getNodeParameter('OwnerIdManual', i, '');
25
+ const ownerId = ownerMode === 'select' ? ownerSel : ownerMan;
28
26
  const note = (_a = add.Note) !== null && _a !== void 0 ? _a : '';
29
27
  const resultNote = (_b = add.ResultNote) !== null && _b !== void 0 ? _b : '';
30
28
  const isDeleted = (_c = add.IsDeleted) !== null && _c !== void 0 ? _c : false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n8n-nodes-didar-crm",
3
- "version": "0.0.21",
3
+ "version": "0.0.22",
4
4
  "description": "Didar CRM nodes for n8n (Trigger + Deal.create)",
5
5
  "author": "You",
6
6
  "license": "MIT",