From d00f75bc95062e1cc7b138b9a44483454632199d Mon Sep 17 00:00:00 2001 From: r350178982 <32759763+r350178982@users.noreply.github.com> Date: Mon, 22 Jan 2024 18:12:13 +0800 Subject: [PATCH 1/7] Update dtable-web-api.js --- src/dtable-web-api.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/dtable-web-api.js b/src/dtable-web-api.js index 77ee0124..9733986b 100644 --- a/src/dtable-web-api.js +++ b/src/dtable-web-api.js @@ -1659,22 +1659,24 @@ class DTableWebAPI { return this.req.get(url); } - addThirdPartyAccount(dtableUuid, account_name, accout_type, detail) { + addThirdPartyAccount(dtableUuid, account_name, accout_type, detail, ownerID) { let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/'; let data = { 'account_name': account_name, 'account_type': accout_type, - 'detail': detail + 'detail': detail, + 'owner': ownerID }; return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } - updateThirdPartyAccount(dtableUuid, account_id, account_name, account_type, detail) { + updateThirdPartyAccount(dtableUuid, account_id, account_name, account_type, detail, ownerID) { let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/' + account_id + '/'; let data = { 'account_name': account_name, 'account_type': account_type, - 'detail': detail + 'detail': detail, + 'owner': ownerID }; return this.req.put(url, data, { headers: { 'Content-Type': 'application/json' } }); } From 3856242c6261c5530fa2b58fe41bb873279cd3e6 Mon Sep 17 00:00:00 2001 From: r350178982 <32759763+r350178982@users.noreply.github.com> Date: Tue, 23 Jan 2024 11:47:18 +0800 Subject: [PATCH 2/7] change_account_id_for_3rd_messages --- src/dtable-web-api.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/dtable-web-api.js b/src/dtable-web-api.js index 9733986b..793dd4a5 100644 --- a/src/dtable-web-api.js +++ b/src/dtable-web-api.js @@ -1464,10 +1464,10 @@ class DTableWebAPI { return this.req.get(url); } - addEmailSendTask(dtableUuid, account_name, send_to, message, subject, copy_to, reply_to, attachments, html_message, need_message_id, in_reply_to, images_info) { + addEmailSendTask(dtableUuid, account_id, send_to, message, subject, copy_to, reply_to, attachments, html_message, need_message_id, in_reply_to, images_info) { let url = this.server + '/api/v2.1/dtable-message/' + dtableUuid + '/email/'; let data = { - 'account_name': account_name, + 'account_id': account_id, 'send_to': send_to, 'message': message, 'subject': subject, @@ -1496,22 +1496,22 @@ class DTableWebAPI { return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } - addWechatSendTask(dtableUuid, account_name, message, msg_type) { + addWechatSendTask(dtableUuid, account_id, message, msg_type) { let url = this.server + '/api/v2.1/dtable-message/' + dtableUuid + '/wechat/'; let data = { 'message': message, - 'account_name': account_name, + 'account_id': account_id, 'msg_type': msg_type, }; return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } - addDingtalkSendTask(dtableUuid, account_name, message) { + addDingtalkSendTask(dtableUuid, account_id, message) { let url = this.server + '/api/v2.1/dtable-message/' + dtableUuid + '/dingtalk/'; let data = { 'message': message, - 'account_name': account_name, + 'account_id': account_id, }; return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); From 9616fac33493bb7c5384d024f7bedee9f40cbc8c Mon Sep 17 00:00:00 2001 From: r350178982 <32759763+r350178982@users.noreply.github.com> Date: Wed, 31 Jan 2024 13:29:51 +0800 Subject: [PATCH 3/7] Update dtable-web-api.js --- src/dtable-web-api.js | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/dtable-web-api.js b/src/dtable-web-api.js index 793dd4a5..097d77a3 100644 --- a/src/dtable-web-api.js +++ b/src/dtable-web-api.js @@ -1649,8 +1649,8 @@ class DTableWebAPI { return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } - getThirdPartyAccountsDetail(dtableUuid, account_name) { - let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/detail/?account_name=' + encodeURIComponent(account_name); + getThirdPartyAccountsDetail(dtableUuid, account_id) { + let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/' + account_id + '/'; return this.req.get(url); } @@ -1659,24 +1659,22 @@ class DTableWebAPI { return this.req.get(url); } - addThirdPartyAccount(dtableUuid, account_name, accout_type, detail, ownerID) { + addThirdPartyAccount(dtableUuid, account_name, accout_type, detail) { let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/'; let data = { 'account_name': account_name, 'account_type': accout_type, 'detail': detail, - 'owner': ownerID }; return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } - updateThirdPartyAccount(dtableUuid, account_id, account_name, account_type, detail, ownerID) { + updateThirdPartyAccount(dtableUuid, account_id, account_name, account_type, detail) { let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/' + account_id + '/'; let data = { 'account_name': account_name, 'account_type': account_type, 'detail': detail, - 'owner': ownerID }; return this.req.put(url, data, { headers: { 'Content-Type': 'application/json' } }); } From 4299450efa9fae7eef531496e1f849f05c11d83d Mon Sep 17 00:00:00 2001 From: r350178982 <32759763+r350178982@users.noreply.github.com> Date: Wed, 31 Jan 2024 13:35:59 +0800 Subject: [PATCH 4/7] Update dtable-web-api.js --- src/dtable-web-api.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/dtable-web-api.js b/src/dtable-web-api.js index 097d77a3..af96d289 100644 --- a/src/dtable-web-api.js +++ b/src/dtable-web-api.js @@ -1664,7 +1664,7 @@ class DTableWebAPI { let data = { 'account_name': account_name, 'account_type': accout_type, - 'detail': detail, + 'detail': detail }; return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } @@ -1674,7 +1674,7 @@ class DTableWebAPI { let data = { 'account_name': account_name, 'account_type': account_type, - 'detail': detail, + 'detail': detail }; return this.req.put(url, data, { headers: { 'Content-Type': 'application/json' } }); } From 750920eb5e01737476cc9301d42b8b52290e44d3 Mon Sep 17 00:00:00 2001 From: r350178982 <32759763+r350178982@users.noreply.github.com> Date: Mon, 3 Jun 2024 17:08:05 +0800 Subject: [PATCH 5/7] update --- src/dtable-web-api.js | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/dtable-web-api.js b/src/dtable-web-api.js index af96d289..0f7ae128 100644 --- a/src/dtable-web-api.js +++ b/src/dtable-web-api.js @@ -1649,18 +1649,18 @@ class DTableWebAPI { return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } - getThirdPartyAccountsDetail(dtableUuid, account_id) { - let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/' + account_id + '/'; + getThirdPartyAccountsDetail(workspace_id, account_id) { + let url = this.server + '/api/v2.1/workspace/ ' + workspace_id + '/third-party-accounts/' + account_id + '/'; return this.req.get(url); } - listThirdPartyAccounts(dtableUuid) { - let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/'; + listThirdPartyAccounts(workspace_id) { + let url = this.server + '/api/v2.1/workspace/' + workspace_id + '/third-party-accounts/'; return this.req.get(url); } - addThirdPartyAccount(dtableUuid, account_name, accout_type, detail) { - let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/'; + addThirdPartyAccount(workspace_id, account_name, accout_type, detail) { + let url = this.server + '/api/v2.1/workspace/' + workspace_id + '/third-party-accounts/'; let data = { 'account_name': account_name, 'account_type': accout_type, @@ -1669,8 +1669,8 @@ class DTableWebAPI { return this._sendPostRequest(url, data, { headers: { 'Content-Type': 'application/json' } }); } - updateThirdPartyAccount(dtableUuid, account_id, account_name, account_type, detail) { - let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/' + account_id + '/'; + updateThirdPartyAccount(workspace_id, account_id, account_name, account_type, detail) { + let url = this.server + '/api/v2.1/workspace/ ' + workspace_id + '/third-party-accounts/' + account_id + '/'; let data = { 'account_name': account_name, 'account_type': account_type, @@ -1679,8 +1679,8 @@ class DTableWebAPI { return this.req.put(url, data, { headers: { 'Content-Type': 'application/json' } }); } - deleteThirdPartyAccount(dtableUuid, account_id) { - let url = this.server + '/api/v2.1/third-party-accounts/' + dtableUuid + '/' + account_id + '/'; + deleteThirdPartyAccount(workspace_id, account_id) { + let url = this.server + '/api/v2.1/workspace/ ' + workspace_id + '/third-party-accounts/' + account_id + '/'; return this.req.delete(url); } From 4189363ddfb60c9c7347f51fb84e2dc01c621304 Mon Sep 17 00:00:00 2001 From: r350178982 <32759763+r350178982@users.noreply.github.com> Date: Tue, 4 Jun 2024 09:34:24 +0800 Subject: [PATCH 6/7] Update dtable-web-api.js --- src/dtable-web-api.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dtable-web-api.js b/src/dtable-web-api.js index 0f7ae128..f953519c 100644 --- a/src/dtable-web-api.js +++ b/src/dtable-web-api.js @@ -1650,7 +1650,7 @@ class DTableWebAPI { } getThirdPartyAccountsDetail(workspace_id, account_id) { - let url = this.server + '/api/v2.1/workspace/ ' + workspace_id + '/third-party-accounts/' + account_id + '/'; + let url = this.server + '/api/v2.1/workspace/' + workspace_id + '/third-party-accounts/' + account_id + '/'; return this.req.get(url); } From 65543d5a3a0c3246fd93aa3162bf76d66412f2aa Mon Sep 17 00:00:00 2001 From: r350178982 <32759763+r350178982@users.noreply.github.com> Date: Tue, 4 Jun 2024 09:53:21 +0800 Subject: [PATCH 7/7] Update dtable-web-api.js --- src/dtable-web-api.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/dtable-web-api.js b/src/dtable-web-api.js index f953519c..a306a6c0 100644 --- a/src/dtable-web-api.js +++ b/src/dtable-web-api.js @@ -1670,7 +1670,7 @@ class DTableWebAPI { } updateThirdPartyAccount(workspace_id, account_id, account_name, account_type, detail) { - let url = this.server + '/api/v2.1/workspace/ ' + workspace_id + '/third-party-accounts/' + account_id + '/'; + let url = this.server + '/api/v2.1/workspace/' + workspace_id + '/third-party-accounts/' + account_id + '/'; let data = { 'account_name': account_name, 'account_type': account_type, @@ -1680,7 +1680,7 @@ class DTableWebAPI { } deleteThirdPartyAccount(workspace_id, account_id) { - let url = this.server + '/api/v2.1/workspace/ ' + workspace_id + '/third-party-accounts/' + account_id + '/'; + let url = this.server + '/api/v2.1/workspace/' + workspace_id + '/third-party-accounts/' + account_id + '/'; return this.req.delete(url); }