@xbongbong/xbbcli 2.0.0
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/README.md +436 -0
- package/ai-call-add-task.js +106 -0
- package/ai-word-list.js +81 -0
- package/bin/xbbcli.js +120 -0
- package/buyer-inquiry-detail.js +112 -0
- package/buyer-inquiry-list.js +142 -0
- package/clue-add-couser.js +86 -0
- package/clue-add.js +102 -0
- package/clue-back.js +82 -0
- package/clue-del.js +75 -0
- package/clue-delete-couser.js +84 -0
- package/clue-delete-mainuser.js +84 -0
- package/clue-detail.js +78 -0
- package/clue-distribution.js +91 -0
- package/clue-edit.js +101 -0
- package/clue-handover.js +103 -0
- package/clue-list.js +224 -0
- package/clue-thorough-delete.js +82 -0
- package/communicate-add.js +144 -0
- package/communicate-del.js +118 -0
- package/communicate-detail.js +123 -0
- package/communicate-edit.js +146 -0
- package/communicate-list.js +194 -0
- package/communicate-plan-add.js +102 -0
- package/communicate-plan-cancel.js +76 -0
- package/communicate-plan-del.js +76 -0
- package/communicate-plan-detail.js +79 -0
- package/communicate-plan-list.js +129 -0
- package/communicate-plan-single-operate.js +86 -0
- package/contact-add-couser.js +87 -0
- package/contact-add-mainuser.js +87 -0
- package/contact-add.js +125 -0
- package/contact-del.js +70 -0
- package/contact-delete-couser.js +87 -0
- package/contact-delete-mainuser.js +87 -0
- package/contact-detail.js +72 -0
- package/contact-edit.js +103 -0
- package/contact-handover.js +84 -0
- package/contact-list.js +195 -0
- package/contract-add-couser.js +129 -0
- package/contract-add-mainuser.js +129 -0
- package/contract-add.js +148 -0
- package/contract-del.js +117 -0
- package/contract-delete-couser.js +128 -0
- package/contract-delete-mainuser.js +129 -0
- package/contract-detail.js +124 -0
- package/contract-edit.js +147 -0
- package/contract-handover.js +129 -0
- package/contract-list.js +235 -0
- package/contract-outstock-add.js +104 -0
- package/contract-outstock-del.js +78 -0
- package/contract-outstock-detail.js +80 -0
- package/contract-outstock-edit.js +106 -0
- package/contract-outstock-list.js +121 -0
- package/customer-add-couser.js +186 -0
- package/customer-add.js +152 -0
- package/customer-back.js +125 -0
- package/customer-del.js +117 -0
- package/customer-delete-couser.js +128 -0
- package/customer-delete-mainuser.js +129 -0
- package/customer-detail.js +148 -0
- package/customer-distribution.js +132 -0
- package/customer-edit.js +174 -0
- package/customer-handover.js +131 -0
- package/customer-invoice-address-add.js +101 -0
- package/customer-invoice-address-edit.js +102 -0
- package/customer-invoice-address.js +86 -0
- package/customer-invoice-info-add.js +101 -0
- package/customer-invoice-info-edit.js +102 -0
- package/customer-invoice-info.js +88 -0
- package/customer-list.js +187 -0
- package/department-add.js +77 -0
- package/department-del.js +76 -0
- package/department-edit.js +77 -0
- package/department-list.js +190 -0
- package/form-data-add-couser.js +84 -0
- package/form-data-add-mainuser.js +84 -0
- package/form-data-add.js +171 -0
- package/form-data-del.js +135 -0
- package/form-data-delete-couser.js +85 -0
- package/form-data-delete-mainuser.js +84 -0
- package/form-data-detail.js +146 -0
- package/form-data-edit.js +171 -0
- package/form-data-handover.js +84 -0
- package/form-data-list.js +188 -0
- package/form-get.js +157 -0
- package/form-list.js +169 -0
- package/invoice-add.js +98 -0
- package/invoice-cancel.js +97 -0
- package/invoice-del.js +83 -0
- package/invoice-detail.js +85 -0
- package/invoice-edit.js +101 -0
- package/invoice-get-amount-detail.js +84 -0
- package/invoice-list.js +125 -0
- package/invoice-red.js +101 -0
- package/label-add.js +93 -0
- package/label-all-list.js +102 -0
- package/label-batch-add.js +111 -0
- package/label-batch-remove.js +111 -0
- package/label-del-completely.js +88 -0
- package/label-del.js +98 -0
- package/label-edit.js +96 -0
- package/label-group-add.js +89 -0
- package/label-group-del.js +83 -0
- package/label-group-list.js +87 -0
- package/label-group-update.js +92 -0
- package/label-list.js +97 -0
- package/label-reduction.js +92 -0
- package/label-repeat.js +89 -0
- package/market-activity-add.js +109 -0
- package/market-activity-del.js +83 -0
- package/market-activity-detail.js +84 -0
- package/market-activity-edit.js +106 -0
- package/market-activity-handover.js +88 -0
- package/market-activity-list.js +121 -0
- package/opportunity-add-couser.js +129 -0
- package/opportunity-add-mainuser.js +129 -0
- package/opportunity-add.js +147 -0
- package/opportunity-del.js +118 -0
- package/opportunity-delete-couser.js +129 -0
- package/opportunity-delete-mainuser.js +128 -0
- package/opportunity-detail.js +125 -0
- package/opportunity-edit.js +146 -0
- package/opportunity-handover.js +130 -0
- package/opportunity-list.js +169 -0
- package/package.json +34 -0
- package/pay-plan-add-couser.js +88 -0
- package/pay-plan-add-mainuser.js +88 -0
- package/pay-plan-add.js +104 -0
- package/pay-plan-delete-couser.js +87 -0
- package/pay-plan-delete-mainuser.js +87 -0
- package/pay-plan-handover.js +85 -0
- package/pay-sheet-add-bad.js +104 -0
- package/pay-sheet-add-couser.js +87 -0
- package/pay-sheet-add-mainuser.js +88 -0
- package/pay-sheet-add-red.js +104 -0
- package/pay-sheet-add-write-off.js +104 -0
- package/pay-sheet-del.js +86 -0
- package/pay-sheet-delete-couser.js +87 -0
- package/pay-sheet-delete-mainuser.js +88 -0
- package/pay-sheet-detail.js +85 -0
- package/pay-sheet-edit-bad.js +110 -0
- package/pay-sheet-edit-red.js +110 -0
- package/pay-sheet-edit-write-off.js +106 -0
- package/pay-sheet-get-amount-detail.js +83 -0
- package/pay-sheet-list.js +123 -0
- package/payment-add-couser.js +129 -0
- package/payment-add-mainuser.js +129 -0
- package/payment-add.js +142 -0
- package/payment-del.js +117 -0
- package/payment-delete-couser.js +128 -0
- package/payment-delete-mainuser.js +128 -0
- package/payment-detail.js +123 -0
- package/payment-edit.js +146 -0
- package/payment-handover.js +130 -0
- package/payment-list.js +195 -0
- package/payment-sheet-add-bad-debt.js +142 -0
- package/payment-sheet-add-pre.js +104 -0
- package/payment-sheet-add-red.js +142 -0
- package/payment-sheet-add-write-off.js +130 -0
- package/payment-sheet-del.js +106 -0
- package/payment-sheet-detail.js +113 -0
- package/payment-sheet-edit-bad-debt.js +131 -0
- package/payment-sheet-edit-red.js +146 -0
- package/payment-sheet-edit-write-off.js +146 -0
- package/payment-sheet-get-amount-detail.js +84 -0
- package/payment-sheet-handover.js +85 -0
- package/payment-sheet-list.js +206 -0
- package/product-add.js +129 -0
- package/product-category-add.js +124 -0
- package/product-category-del.js +132 -0
- package/product-category-list.js +164 -0
- package/product-category-update.js +139 -0
- package/product-del.js +106 -0
- package/product-detail.js +183 -0
- package/product-edit.js +131 -0
- package/product-list.js +193 -0
- package/product-online.js +91 -0
- package/quotation-add-couser.js +106 -0
- package/quotation-add-mainuser.js +101 -0
- package/quotation-add.js +100 -0
- package/quotation-del.js +83 -0
- package/quotation-delete-couser.js +101 -0
- package/quotation-delete-mainuser.js +101 -0
- package/quotation-detail.js +85 -0
- package/quotation-edit.js +101 -0
- package/quotation-handover.js +84 -0
- package/quotation-list.js +123 -0
- package/refund-add.js +83 -0
- package/refund-del.js +68 -0
- package/refund-detail.js +71 -0
- package/refund-edit.js +84 -0
- package/refund-list.js +193 -0
- package/role-list.js +85 -0
- package/sign-in-list.js +136 -0
- package/stage-get.js +100 -0
- package/stage-jump.js +109 -0
- package/supplier-add.js +142 -0
- package/token-generate.js +109 -0
- package/token-set.js +222 -0
- package/user-add.js +103 -0
- package/user-del.js +90 -0
- package/user-edit.js +102 -0
- package/user-handover.js +78 -0
- package/user-list.js +147 -0
- package/version.js +18 -0
- package/work-order-add.js +171 -0
- package/work-order-asset-add-couser.js +101 -0
- package/work-order-asset-add-mainuser.js +104 -0
- package/work-order-asset-add.js +98 -0
- package/work-order-asset-del-couser.js +101 -0
- package/work-order-asset-del-mainuser.js +101 -0
- package/work-order-asset-del.js +83 -0
- package/work-order-asset-detail.js +85 -0
- package/work-order-asset-edit.js +101 -0
- package/work-order-asset-handover.js +101 -0
- package/work-order-asset-list.js +123 -0
- package/work-order-del.js +136 -0
- package/work-order-detail.js +186 -0
- package/work-order-dynamic-list.js +145 -0
- package/work-order-edit.js +170 -0
- package/work-order-list.js +243 -0
- package/work-order-operate.js +167 -0
- package/work-order-template-detail.js +157 -0
- package/work-order-template-list.js +145 -0
- package/work-report-daily-add.js +97 -0
- package/work-report-daily-del.js +75 -0
- package/work-report-daily-detail.js +78 -0
- package/work-report-daily-edit.js +129 -0
- package/work-report-daily-get-work-plan.js +80 -0
- package/work-report-daily-list.js +116 -0
- package/work-report-monthly-add.js +98 -0
- package/work-report-monthly-del.js +79 -0
- package/work-report-monthly-detail.js +78 -0
- package/work-report-monthly-edit.js +98 -0
- package/work-report-monthly-list.js +116 -0
- package/work-report-weekly-add.js +98 -0
- package/work-report-weekly-del.js +76 -0
- package/work-report-weekly-detail.js +79 -0
- package/work-report-weekly-edit.js +99 -0
- package/work-report-weekly-list.js +116 -0
- package/work-task-add-couser.js +88 -0
- package/work-task-add.js +242 -0
- package/work-task-delete-couser.js +85 -0
- package/work-task-detail.js +101 -0
- package/work-task-edit.js +116 -0
- package/work-task-handover.js +85 -0
- package/workorder-add-couser.js +128 -0
- package/workorder-delete-couser.js +129 -0
- package/workorder-handover.js +137 -0
- package/workorderlist.js +194 -0
- package/workorderproductlist.js +159 -0
- package/worktimerecorddetail.js +157 -0
- package/worktimerecordlist.js +199 -0
- package/xbb-registry.js +21 -0
package/customer-edit.js
ADDED
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
import crypto from 'node:crypto';
|
|
2
|
+
import fs from 'node:fs';
|
|
3
|
+
import os from 'node:os';
|
|
4
|
+
import path from 'node:path';
|
|
5
|
+
import { cli, Strategy } from './xbb-registry.js';
|
|
6
|
+
|
|
7
|
+
const CONFIG_FILE = path.join(os.homedir(), '.xbbcli', 'config.env');
|
|
8
|
+
const EDIT_API_URL = 'https://proapi.xbongbong.com/pro/v2/api/customer/edit';
|
|
9
|
+
const DEFAULT_BASE_URL = 'https://proapi.xbongbong.com';
|
|
10
|
+
|
|
11
|
+
function readConfig() {
|
|
12
|
+
try {
|
|
13
|
+
return JSON.parse(fs.readFileSync(CONFIG_FILE, 'utf8'));
|
|
14
|
+
} catch {
|
|
15
|
+
return {};
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
function getRuntimeConfig() {
|
|
20
|
+
const config = readConfig();
|
|
21
|
+
return {
|
|
22
|
+
corpid: String(config.corpid || '').trim(),
|
|
23
|
+
token: String(config.token || '').trim(),
|
|
24
|
+
baseUrl: String(config.baseurl || DEFAULT_BASE_URL).trim(),
|
|
25
|
+
userId: String(config.userId || '').trim(),
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
function buildApiUrl(baseUrl, defaultUrl) {
|
|
30
|
+
const apiPath = new URL(defaultUrl).pathname;
|
|
31
|
+
return `${baseUrl.replace(/\/+$/, '')}${apiPath}`;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
function parseDataList(raw) {
|
|
35
|
+
if (raw && typeof raw === 'object' && !Array.isArray(raw)) {
|
|
36
|
+
return raw;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
const text = String(raw || '').trim();
|
|
40
|
+
if (!text) {
|
|
41
|
+
return null;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
try {
|
|
45
|
+
const parsed = JSON.parse(text);
|
|
46
|
+
if (parsed && typeof parsed === 'object' && !Array.isArray(parsed)) {
|
|
47
|
+
return parsed;
|
|
48
|
+
}
|
|
49
|
+
return undefined;
|
|
50
|
+
} catch {
|
|
51
|
+
return undefined;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
function buildPayload(kwargs, parsedDataList, corpid, defaultUserId) {
|
|
56
|
+
const payload = {
|
|
57
|
+
corpid,
|
|
58
|
+
formId: Number(kwargs.formId || 0),
|
|
59
|
+
dataId: Number(kwargs.dataId || 0),
|
|
60
|
+
};
|
|
61
|
+
|
|
62
|
+
const userId = String(kwargs.userId || defaultUserId || '').trim();
|
|
63
|
+
if (userId) {
|
|
64
|
+
payload.userId = userId;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
if (parsedDataList) {
|
|
68
|
+
payload.dataList = parsedDataList;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
return payload;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
function getValidationError(payload, token, parsedDataList) {
|
|
75
|
+
if (!payload.corpid) {
|
|
76
|
+
return { code: 'NO_CORPID', msg: '缺少本地 corpid;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>' };
|
|
77
|
+
}
|
|
78
|
+
if (!payload.formId) {
|
|
79
|
+
return { code: 'NO_FORMID', msg: '缺少 --formId' };
|
|
80
|
+
}
|
|
81
|
+
if (!payload.dataId) {
|
|
82
|
+
return { code: 'NO_DATAID', msg: '缺少 --dataId' };
|
|
83
|
+
}
|
|
84
|
+
if (!token) {
|
|
85
|
+
return { code: 'NO_TOKEN', msg: '缺少 token;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>' };
|
|
86
|
+
}
|
|
87
|
+
if (parsedDataList === null) {
|
|
88
|
+
return { code: 'NO_DATALIST', msg: '缺少 --dataList' };
|
|
89
|
+
}
|
|
90
|
+
if (parsedDataList === undefined) {
|
|
91
|
+
return { code: 'INVALID_DATALIST', msg: '--dataList 必须是 JSON 对象字符串' };
|
|
92
|
+
}
|
|
93
|
+
return null;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
function makeErrorRow(code, msg) {
|
|
97
|
+
return [{
|
|
98
|
+
dataId: '',
|
|
99
|
+
resultCode: '',
|
|
100
|
+
resultMsg: '',
|
|
101
|
+
code,
|
|
102
|
+
msg,
|
|
103
|
+
}];
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
function makeSuccessRow(data) {
|
|
107
|
+
const result = data.result || {};
|
|
108
|
+
return [{
|
|
109
|
+
dataId: result.dataId || '',
|
|
110
|
+
resultCode: result.code ?? '',
|
|
111
|
+
resultMsg: result.msg || '',
|
|
112
|
+
code: data.code ?? '',
|
|
113
|
+
msg: data.msg || '',
|
|
114
|
+
}];
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
cli({
|
|
118
|
+
site: 'xbb',
|
|
119
|
+
name: 'customer-edit',
|
|
120
|
+
description: '编辑客户接口(businessType: 100;formId必填)',
|
|
121
|
+
strategy: Strategy.PUBLIC,
|
|
122
|
+
access: 'write',
|
|
123
|
+
browser: false,
|
|
124
|
+
domain: 'proapi.xbongbong.com',
|
|
125
|
+
args: [
|
|
126
|
+
{ name: 'formId', type: 'int', help: '表单id(必填)' },
|
|
127
|
+
{ name: 'dataId', type: 'int', help: '表单数据id(必填)' },
|
|
128
|
+
{ name: 'dataList', type: 'str', help: '表单数据JSON字符串(必填)' },
|
|
129
|
+
{ name: 'userId', type: 'str', default: '', help: '操作人id(可选)' },
|
|
130
|
+
{ name: 'debug', type: 'bool', default: false, help: '输出请求体和返回体调试信息' },
|
|
131
|
+
],
|
|
132
|
+
columns: ['dataId', 'resultCode', 'resultMsg', 'code', 'msg'],
|
|
133
|
+
func: async (kwargs) => {
|
|
134
|
+
const debug = Boolean(kwargs.debug);
|
|
135
|
+
const { corpid, token, baseUrl, userId } = getRuntimeConfig();
|
|
136
|
+
const parsedDataList = parseDataList(kwargs.dataList);
|
|
137
|
+
const payload = buildPayload(kwargs, parsedDataList, corpid, userId);
|
|
138
|
+
const body = JSON.stringify(payload);
|
|
139
|
+
|
|
140
|
+
const validationError = getValidationError(payload, token, parsedDataList);
|
|
141
|
+
if (validationError) {
|
|
142
|
+
return makeErrorRow(validationError.code, validationError.msg);
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
const sign = crypto.createHash('sha256').update(body + token).digest('hex');
|
|
146
|
+
const headers = Object.assign({
|
|
147
|
+
'Content-Type': 'application/json;charset=UTF-8',
|
|
148
|
+
sign,
|
|
149
|
+
}, userId ? { userId } : {});
|
|
150
|
+
if (debug) {
|
|
151
|
+
process.stderr.write(`[debug] URL: ${buildApiUrl(baseUrl, EDIT_API_URL)}\n[debug] Headers: ${JSON.stringify(headers)}\n[debug] RequestBody: ${body}\n`);
|
|
152
|
+
}
|
|
153
|
+
const resp = await fetch(buildApiUrl(baseUrl, EDIT_API_URL), {
|
|
154
|
+
method: 'POST',
|
|
155
|
+
headers,
|
|
156
|
+
body,
|
|
157
|
+
});
|
|
158
|
+
|
|
159
|
+
if (!resp.ok) {
|
|
160
|
+
const responseText = await resp.text();
|
|
161
|
+
if (debug) process.stderr.write(`[debug] ResponseBody: ${responseText}\n`);
|
|
162
|
+
return makeErrorRow(resp.status, `HTTP ${resp.status} ${resp.statusText}`);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
const data = await resp.json();
|
|
166
|
+
const responseBody = JSON.stringify(data);
|
|
167
|
+
if (debug) process.stderr.write(`[debug] ResponseBody: ${responseBody}\n`);
|
|
168
|
+
if (data.code !== 1) {
|
|
169
|
+
return makeErrorRow(data.code ?? '', data.msg ?? '未知错误');
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
return makeSuccessRow(data);
|
|
173
|
+
},
|
|
174
|
+
});
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
import fs from 'node:fs';
|
|
2
|
+
import os from 'node:os';
|
|
3
|
+
import path from 'node:path';
|
|
4
|
+
import crypto from 'node:crypto';
|
|
5
|
+
import { cli, Strategy } from './xbb-registry.js';
|
|
6
|
+
|
|
7
|
+
const CONFIG_DIR = path.join(os.homedir(), '.xbbcli');
|
|
8
|
+
const CONFIG_FILE = path.join(CONFIG_DIR, 'config.env');
|
|
9
|
+
const API_URL = 'https://proapi.xbongbong.com/pro/v2/api/customer/handover';
|
|
10
|
+
const DEFAULT_BASE_URL = 'https://proapi.xbongbong.com';
|
|
11
|
+
|
|
12
|
+
function readConfig() {
|
|
13
|
+
try {
|
|
14
|
+
return JSON.parse(fs.readFileSync(CONFIG_FILE, 'utf8'));
|
|
15
|
+
} catch {
|
|
16
|
+
return {};
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function getRuntimeConfig() {
|
|
21
|
+
const config = readConfig();
|
|
22
|
+
return {
|
|
23
|
+
corpid: String(config.corpid || '').trim(),
|
|
24
|
+
token: String(config.token || '').trim(),
|
|
25
|
+
baseUrl: String(config.baseurl || DEFAULT_BASE_URL).trim(),
|
|
26
|
+
userId: String(config.userId || '').trim(),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function buildApiUrl(baseUrl, defaultUrl) {
|
|
31
|
+
const apiPath = new URL(defaultUrl).pathname;
|
|
32
|
+
return `${baseUrl.replace(/\/+$/, '')}${apiPath}`;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
function makeErrorRow(code, msg) {
|
|
36
|
+
return [{
|
|
37
|
+
resultType: '',
|
|
38
|
+
resultMsg: '',
|
|
39
|
+
code,
|
|
40
|
+
msg,
|
|
41
|
+
}];
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
cli({
|
|
45
|
+
site: 'xbb',
|
|
46
|
+
name: 'customer-handover',
|
|
47
|
+
description: '客户移交接口(businessType: 100)',
|
|
48
|
+
strategy: Strategy.PUBLIC,
|
|
49
|
+
access: 'write',
|
|
50
|
+
browser: false,
|
|
51
|
+
domain: 'proapi.xbongbong.com',
|
|
52
|
+
args: [
|
|
53
|
+
{ name: 'dataIdList', type: 'str', help: '客户id列表,JSON数组字符串,最多200条(必填)' },
|
|
54
|
+
{ name: 'businessUserId', type: 'str', help: '移交目标人员id(必填)' },
|
|
55
|
+
{ name: 'userId', type: 'str', default: '', help: '操作人id(可选)' },
|
|
56
|
+
{ name: 'originUserId', type: 'str', default: '', help: '被移交用户,隔离模式的移交客户必填(可选)' },
|
|
57
|
+
{ name: 'debug', type: 'bool', default: false, help: '输出请求体和返回体调试信息' },
|
|
58
|
+
],
|
|
59
|
+
columns: ['resultType', 'resultMsg', 'code', 'msg'],
|
|
60
|
+
func: async (kwargs) => {
|
|
61
|
+
const debug = Boolean(kwargs.debug);
|
|
62
|
+
const { corpid, token, baseUrl, userId } = getRuntimeConfig();
|
|
63
|
+
|
|
64
|
+
const payload = {
|
|
65
|
+
corpid,
|
|
66
|
+
};
|
|
67
|
+
if (kwargs.userId) payload.userId = String(kwargs.userId);
|
|
68
|
+
if (kwargs.businessUserId) payload.businessUserId = String(kwargs.businessUserId);
|
|
69
|
+
if (kwargs.originUserId) payload.originUserId = String(kwargs.originUserId);
|
|
70
|
+
|
|
71
|
+
let dataIdList;
|
|
72
|
+
try {
|
|
73
|
+
dataIdList = JSON.parse(String(kwargs.dataIdList || ''));
|
|
74
|
+
} catch {
|
|
75
|
+
dataIdList = null;
|
|
76
|
+
}
|
|
77
|
+
if (Array.isArray(dataIdList)) {
|
|
78
|
+
payload.dataIdList = dataIdList;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
const body = JSON.stringify(payload);
|
|
82
|
+
|
|
83
|
+
if (!payload.corpid) {
|
|
84
|
+
return makeErrorRow('NO_CORPID', '缺少本地 corpid;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>');
|
|
85
|
+
}
|
|
86
|
+
if (!Array.isArray(dataIdList) || !dataIdList.length) {
|
|
87
|
+
return makeErrorRow('NO_DATAIDLIST', '缺少 --dataIdList 或格式不正确,需为JSON数组');
|
|
88
|
+
}
|
|
89
|
+
if (!payload.businessUserId) {
|
|
90
|
+
return makeErrorRow('NO_BUSINESSUSERID', '缺少 --businessUserId');
|
|
91
|
+
}
|
|
92
|
+
if (!token) {
|
|
93
|
+
return makeErrorRow('NO_TOKEN', '缺少 token;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>');
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
const sign = crypto.createHash('sha256').update(body + token).digest('hex');
|
|
97
|
+
const headers = Object.assign({
|
|
98
|
+
'Content-Type': 'application/json;charset=UTF-8',
|
|
99
|
+
sign,
|
|
100
|
+
}, userId ? { userId } : {});
|
|
101
|
+
if (debug) {
|
|
102
|
+
process.stderr.write(`[debug] URL: ${buildApiUrl(baseUrl, API_URL)}\n[debug] Headers: ${JSON.stringify(headers)}\n[debug] RequestBody: ${body}\n`);
|
|
103
|
+
}
|
|
104
|
+
const resp = await fetch(buildApiUrl(baseUrl, API_URL), {
|
|
105
|
+
method: 'POST',
|
|
106
|
+
headers,
|
|
107
|
+
body,
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
if (!resp.ok) {
|
|
111
|
+
const responseText = await resp.text();
|
|
112
|
+
if (debug) process.stderr.write(`[debug] ResponseBody: ${responseText}\n`);
|
|
113
|
+
return makeErrorRow(resp.status, `HTTP ${resp.status} ${resp.statusText}`);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
const data = await resp.json();
|
|
117
|
+
const responseBody = JSON.stringify(data);
|
|
118
|
+
if (debug) process.stderr.write(`[debug] ResponseBody: ${responseBody}\n`);
|
|
119
|
+
if (data.code !== 1) {
|
|
120
|
+
return makeErrorRow(data.code ?? '', data.msg ?? '未知错误');
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
const result = data.result || {};
|
|
124
|
+
return [{
|
|
125
|
+
resultType: result.resultType || '',
|
|
126
|
+
resultMsg: result.resultMsg || '',
|
|
127
|
+
code: data.code ?? '',
|
|
128
|
+
msg: data.msg || '',
|
|
129
|
+
}];
|
|
130
|
+
},
|
|
131
|
+
});
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import crypto from 'node:crypto';
|
|
2
|
+
import fs from 'node:fs';
|
|
3
|
+
import os from 'node:os';
|
|
4
|
+
import path from 'node:path';
|
|
5
|
+
import { cli, Strategy } from './xbb-registry.js';
|
|
6
|
+
|
|
7
|
+
const CONFIG_FILE = path.join(os.homedir(), '.xbbcli', 'config.env');
|
|
8
|
+
const API_URL = 'https://proapi.xbongbong.com/pro/v2/api/customer/invoice/addressAdd';
|
|
9
|
+
const DEFAULT_BASE_URL = 'https://proapi.xbongbong.com';
|
|
10
|
+
const MISSING_TOKEN_MESSAGE = '缺少 token;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>';
|
|
11
|
+
|
|
12
|
+
function readConfig() {
|
|
13
|
+
try {
|
|
14
|
+
return JSON.parse(fs.readFileSync(CONFIG_FILE, 'utf8'));
|
|
15
|
+
} catch {
|
|
16
|
+
return {};
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function getRuntimeConfig() {
|
|
21
|
+
const config = readConfig();
|
|
22
|
+
return {
|
|
23
|
+
corpid: String(config.corpid || '').trim(),
|
|
24
|
+
token: String(config.token || '').trim(),
|
|
25
|
+
baseUrl: String(config.baseurl || DEFAULT_BASE_URL).trim(),
|
|
26
|
+
userId: String(config.userId || '').trim(),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function buildApiUrl(baseUrl, apiUrl) {
|
|
31
|
+
const apiPath = new URL(apiUrl).pathname;
|
|
32
|
+
return `${baseUrl.replace(/\/+$/, '')}${apiPath}`;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
function parseDataList(raw) {
|
|
36
|
+
if (raw && typeof raw === 'object' && !Array.isArray(raw)) {
|
|
37
|
+
return raw;
|
|
38
|
+
}
|
|
39
|
+
const text = String(raw || '').trim();
|
|
40
|
+
if (!text) {
|
|
41
|
+
return null;
|
|
42
|
+
}
|
|
43
|
+
try {
|
|
44
|
+
const parsed = JSON.parse(text);
|
|
45
|
+
if (parsed && typeof parsed === 'object' && !Array.isArray(parsed)) {
|
|
46
|
+
return parsed;
|
|
47
|
+
}
|
|
48
|
+
return undefined;
|
|
49
|
+
} catch {
|
|
50
|
+
return undefined;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
function makeErrorRow(code, msg) {
|
|
55
|
+
return [{ addressId: '', resultCode: '', resultMsg: '', code, msg }];
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
cli({
|
|
59
|
+
site: 'xbb',
|
|
60
|
+
name: 'customer-invoice-address-add',
|
|
61
|
+
description: '新增客户开票地址接口(businessType: 100)',
|
|
62
|
+
strategy: Strategy.PUBLIC,
|
|
63
|
+
access: 'write',
|
|
64
|
+
browser: false,
|
|
65
|
+
domain: 'proapi.xbongbong.com',
|
|
66
|
+
args: [
|
|
67
|
+
{ name: 'customerId', type: 'int', help: '客户id(必填)' },
|
|
68
|
+
{ name: 'dataList', type: 'str', help: '开票地址JSON字符串(必填)' },
|
|
69
|
+
{ name: 'userId', type: 'str', default: '', help: '操作人id(可选)' },
|
|
70
|
+
{ name: 'debug', type: 'bool', default: false, help: '输出请求体和返回体调试信息' },
|
|
71
|
+
],
|
|
72
|
+
columns: ['addressId', 'resultCode', 'resultMsg', 'code', 'msg'],
|
|
73
|
+
func: async function (kwargs) {
|
|
74
|
+
const debug = Boolean(kwargs.debug);
|
|
75
|
+
const { corpid, token, baseUrl, userId } = getRuntimeConfig();
|
|
76
|
+
const parsedDataList = parseDataList(kwargs.dataList);
|
|
77
|
+
const payload = { corpid, customerId: Number(kwargs.customerId || 0) };
|
|
78
|
+
if (kwargs.userId) payload.userId = String(kwargs.userId);
|
|
79
|
+
if (parsedDataList) payload.dataList = parsedDataList;
|
|
80
|
+
const requestBody = JSON.stringify(payload);
|
|
81
|
+
if (!payload.corpid) return makeErrorRow('NO_CORPID', '缺少本地 corpid;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>');
|
|
82
|
+
if (!payload.customerId) return makeErrorRow('NO_CUSTOMERID', '缺少 --customerId');
|
|
83
|
+
if (!token) return makeErrorRow('NO_TOKEN', MISSING_TOKEN_MESSAGE);
|
|
84
|
+
if (parsedDataList === null) return makeErrorRow('NO_DATALIST', '缺少 --dataList');
|
|
85
|
+
if (parsedDataList === undefined) return makeErrorRow('INVALID_DATALIST', '--dataList 必须是 JSON 对象字符串');
|
|
86
|
+
const sign = crypto.createHash('sha256').update(requestBody + token).digest('hex');
|
|
87
|
+
const headers = Object.assign({ 'Content-Type': 'application/json;charset=UTF-8', sign }, userId ? { userId } : {});
|
|
88
|
+
const apiUrl = buildApiUrl(baseUrl, API_URL);
|
|
89
|
+
if (debug) {
|
|
90
|
+
process.stderr.write(`[debug] URL: ${apiUrl}\n[debug] Headers: ${JSON.stringify(headers)}\n[debug] RequestBody: ${requestBody}\n`);
|
|
91
|
+
}
|
|
92
|
+
const resp = await fetch(apiUrl, { method: 'POST', headers, body: requestBody });
|
|
93
|
+
if (!resp.ok) return makeErrorRow(resp.status, `HTTP ${resp.status} ${resp.statusText}`);
|
|
94
|
+
const data = await resp.json();
|
|
95
|
+
const responseBody = JSON.stringify(data);
|
|
96
|
+
if (debug) process.stderr.write(`[debug] ResponseBody: ${responseBody}\n`);
|
|
97
|
+
if (data.code !== 1) return makeErrorRow(data.code ?? '', data.msg ?? '未知错误');
|
|
98
|
+
const result = data.result || {};
|
|
99
|
+
return [{ addressId: result.addressId || result.dataId || '', resultCode: result.code ?? '', resultMsg: result.msg || '', code: data.code ?? '', msg: data.msg || '' }];
|
|
100
|
+
},
|
|
101
|
+
});
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import crypto from 'node:crypto';
|
|
2
|
+
import fs from 'node:fs';
|
|
3
|
+
import os from 'node:os';
|
|
4
|
+
import path from 'node:path';
|
|
5
|
+
import { cli, Strategy } from './xbb-registry.js';
|
|
6
|
+
|
|
7
|
+
const CONFIG_FILE = path.join(os.homedir(), '.xbbcli', 'config.env');
|
|
8
|
+
const API_URL = 'https://proapi.xbongbong.com/pro/v2/api/customer/invoice/addressEdit';
|
|
9
|
+
const DEFAULT_BASE_URL = 'https://proapi.xbongbong.com';
|
|
10
|
+
const MISSING_TOKEN_MESSAGE = '缺少 token;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>';
|
|
11
|
+
|
|
12
|
+
function readConfig() {
|
|
13
|
+
try {
|
|
14
|
+
return JSON.parse(fs.readFileSync(CONFIG_FILE, 'utf8'));
|
|
15
|
+
} catch {
|
|
16
|
+
return {};
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function getRuntimeConfig() {
|
|
21
|
+
const config = readConfig();
|
|
22
|
+
return {
|
|
23
|
+
corpid: String(config.corpid || '').trim(),
|
|
24
|
+
token: String(config.token || '').trim(),
|
|
25
|
+
baseUrl: String(config.baseurl || DEFAULT_BASE_URL).trim(),
|
|
26
|
+
userId: String(config.userId || '').trim(),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function buildApiUrl(baseUrl, apiUrl) {
|
|
31
|
+
const apiPath = new URL(apiUrl).pathname;
|
|
32
|
+
return `${baseUrl.replace(/\/+$/, '')}${apiPath}`;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
function parseDataList(raw) {
|
|
36
|
+
if (raw && typeof raw === 'object' && !Array.isArray(raw)) {
|
|
37
|
+
return raw;
|
|
38
|
+
}
|
|
39
|
+
const text = String(raw || '').trim();
|
|
40
|
+
if (!text) {
|
|
41
|
+
return null;
|
|
42
|
+
}
|
|
43
|
+
try {
|
|
44
|
+
const parsed = JSON.parse(text);
|
|
45
|
+
if (parsed && typeof parsed === 'object' && !Array.isArray(parsed)) {
|
|
46
|
+
return parsed;
|
|
47
|
+
}
|
|
48
|
+
return undefined;
|
|
49
|
+
} catch {
|
|
50
|
+
return undefined;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
function makeErrorRow(code, msg) {
|
|
55
|
+
return [{ addressId: '', resultCode: '', resultMsg: '', code, msg }];
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
cli({
|
|
59
|
+
site: 'xbb',
|
|
60
|
+
name: 'customer-invoice-address-edit',
|
|
61
|
+
description: '编辑客户开票地址接口(businessType: 100)',
|
|
62
|
+
strategy: Strategy.PUBLIC,
|
|
63
|
+
access: 'write',
|
|
64
|
+
browser: false,
|
|
65
|
+
domain: 'proapi.xbongbong.com',
|
|
66
|
+
args: [
|
|
67
|
+
{ name: 'customerId', type: 'int', help: '客户id(必填)' },
|
|
68
|
+
{ name: 'addressId', type: 'int', help: '开票地址id(必填)' },
|
|
69
|
+
{ name: 'dataList', type: 'str', help: '开票地址JSON字符串(必填)' },
|
|
70
|
+
{ name: 'userId', type: 'str', default: '', help: '操作人id(可选)' },
|
|
71
|
+
{ name: 'debug', type: 'bool', default: false, help: '输出请求体和返回体调试信息' },
|
|
72
|
+
],
|
|
73
|
+
columns: ['addressId', 'resultCode', 'resultMsg', 'code', 'msg'],
|
|
74
|
+
func: async function (kwargs) {
|
|
75
|
+
const debug = Boolean(kwargs.debug);
|
|
76
|
+
const { corpid, token, baseUrl, userId } = getRuntimeConfig();
|
|
77
|
+
const parsedDataList = parseDataList(kwargs.dataList);
|
|
78
|
+
const payload = { corpid, customerId: Number(kwargs.customerId || 0), addressId: Number(kwargs.addressId || 0) };
|
|
79
|
+
if (kwargs.userId) payload.userId = String(kwargs.userId);
|
|
80
|
+
if (parsedDataList) payload.dataList = parsedDataList;
|
|
81
|
+
const requestBody = JSON.stringify(payload);
|
|
82
|
+
if (!payload.corpid) return makeErrorRow('NO_CORPID', '缺少本地 corpid;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>');
|
|
83
|
+
if (!payload.customerId) return makeErrorRow('NO_CUSTOMERID', '缺少 --customerId');
|
|
84
|
+
if (!payload.addressId) return makeErrorRow('NO_ADDRESSID', '缺少 --addressId');
|
|
85
|
+
if (!token) return makeErrorRow('NO_TOKEN', MISSING_TOKEN_MESSAGE);
|
|
86
|
+
if (parsedDataList === null) return makeErrorRow('NO_DATALIST', '缺少 --dataList');
|
|
87
|
+
if (parsedDataList === undefined) return makeErrorRow('INVALID_DATALIST', '--dataList 必须是 JSON 对象字符串');
|
|
88
|
+
const sign = crypto.createHash('sha256').update(requestBody + token).digest('hex');
|
|
89
|
+
const headers = Object.assign({ 'Content-Type': 'application/json;charset=UTF-8', sign }, userId ? { userId } : {});
|
|
90
|
+
if (debug) {
|
|
91
|
+
process.stderr.write(`[debug] URL: ${buildApiUrl(baseUrl, API_URL)}\n[debug] Headers: ${JSON.stringify(headers)}\n[debug] RequestBody: ${requestBody}\n`);
|
|
92
|
+
}
|
|
93
|
+
const resp = await fetch(buildApiUrl(baseUrl, API_URL), { method: 'POST', headers, body: requestBody });
|
|
94
|
+
if (!resp.ok) return makeErrorRow(resp.status, `HTTP ${resp.status} ${resp.statusText}`);
|
|
95
|
+
const data = await resp.json();
|
|
96
|
+
const responseBody = JSON.stringify(data);
|
|
97
|
+
if (debug) process.stderr.write(`[debug] ResponseBody: ${responseBody}\n`);
|
|
98
|
+
if (data.code !== 1) return makeErrorRow(data.code ?? '', data.msg ?? '未知错误');
|
|
99
|
+
const result = data.result || {};
|
|
100
|
+
return [{ addressId: result.addressId || payload.addressId || '', resultCode: result.code ?? '', resultMsg: result.msg || '', code: data.code ?? '', msg: data.msg || '' }];
|
|
101
|
+
},
|
|
102
|
+
});
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import crypto from 'node:crypto';
|
|
2
|
+
import fs from 'node:fs';
|
|
3
|
+
import os from 'node:os';
|
|
4
|
+
import path from 'node:path';
|
|
5
|
+
import { cli, Strategy } from './xbb-registry.js';
|
|
6
|
+
|
|
7
|
+
const CONFIG_FILE = path.join(os.homedir(), '.xbbcli', 'config.env');
|
|
8
|
+
const API_URL = 'https://proapi.xbongbong.com/pro/v2/api/customer/invoice/address';
|
|
9
|
+
const DEFAULT_BASE_URL = 'https://proapi.xbongbong.com';
|
|
10
|
+
const MISSING_TOKEN_MESSAGE = '缺少 token;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>';
|
|
11
|
+
|
|
12
|
+
function readConfig() {
|
|
13
|
+
try {
|
|
14
|
+
return JSON.parse(fs.readFileSync(CONFIG_FILE, 'utf8'));
|
|
15
|
+
} catch {
|
|
16
|
+
return {};
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function getRuntimeConfig() {
|
|
21
|
+
const config = readConfig();
|
|
22
|
+
return {
|
|
23
|
+
corpid: String(config.corpid || '').trim(),
|
|
24
|
+
token: String(config.token || '').trim(),
|
|
25
|
+
baseUrl: String(config.baseurl || DEFAULT_BASE_URL).trim(),
|
|
26
|
+
userId: String(config.userId || '').trim(),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function buildApiUrl(baseUrl, apiUrl) {
|
|
31
|
+
const apiPath = new URL(apiUrl).pathname;
|
|
32
|
+
return `${baseUrl.replace(/\/+$/, '')}${apiPath}`;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
function makeErrorRow(code, msg) {
|
|
36
|
+
return [{ addressId: '', addressName: '', phone: '', address: '', postcode: '', defaultFlag: '', code, msg }];
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
cli({
|
|
40
|
+
site: 'xbb',
|
|
41
|
+
name: 'customer-invoice-address',
|
|
42
|
+
description: '客户开票地址接口(businessType: 100)',
|
|
43
|
+
strategy: Strategy.PUBLIC,
|
|
44
|
+
access: 'read',
|
|
45
|
+
browser: false,
|
|
46
|
+
domain: 'proapi.xbongbong.com',
|
|
47
|
+
args: [
|
|
48
|
+
{ name: 'customerId', type: 'int', help: '客户id(必填)' },
|
|
49
|
+
{ name: 'userId', type: 'str', default: '', help: '操作人id(可选)' },
|
|
50
|
+
{ name: 'debug', type: 'bool', default: false, help: '输出请求体和返回体调试信息' },
|
|
51
|
+
],
|
|
52
|
+
columns: ['addressId', 'addressName', 'phone', 'address', 'postcode', 'defaultFlag', 'code', 'msg'],
|
|
53
|
+
func: async function (kwargs) {
|
|
54
|
+
const debug = Boolean(kwargs.debug);
|
|
55
|
+
const { corpid, token, baseUrl, userId } = getRuntimeConfig();
|
|
56
|
+
const payload = { corpid, customerId: Number(kwargs.customerId || 0) };
|
|
57
|
+
if (kwargs.userId) payload.userId = String(kwargs.userId);
|
|
58
|
+
const requestBody = JSON.stringify(payload);
|
|
59
|
+
if (!payload.corpid) return makeErrorRow('NO_CORPID', '缺少本地 corpid;请先执行 xbbcli token-set --corpid <CORPID> --token <TOKEN> --userId <USERID>');
|
|
60
|
+
if (!payload.customerId) return makeErrorRow('NO_CUSTOMERID', '缺少 --customerId');
|
|
61
|
+
if (!token) return makeErrorRow('NO_TOKEN', MISSING_TOKEN_MESSAGE);
|
|
62
|
+
const sign = crypto.createHash('sha256').update(requestBody + token).digest('hex');
|
|
63
|
+
const headers = Object.assign({ 'Content-Type': 'application/json;charset=UTF-8', sign }, userId ? { userId } : {});
|
|
64
|
+
if (debug) {
|
|
65
|
+
process.stderr.write(`[debug] URL: ${buildApiUrl(baseUrl, API_URL)}\n[debug] Headers: ${JSON.stringify(headers)}\n[debug] RequestBody: ${requestBody}\n`);
|
|
66
|
+
}
|
|
67
|
+
const resp = await fetch(buildApiUrl(baseUrl, API_URL), { method: 'POST', headers, body: requestBody });
|
|
68
|
+
if (!resp.ok) return makeErrorRow(resp.status, `HTTP ${resp.status} ${resp.statusText}`);
|
|
69
|
+
const data = await resp.json();
|
|
70
|
+
const responseBody = JSON.stringify(data);
|
|
71
|
+
if (debug) process.stderr.write(`[debug] ResponseBody: ${responseBody}\n`);
|
|
72
|
+
if (data.code !== 1) return makeErrorRow(data.code ?? '', data.msg ?? '未知错误');
|
|
73
|
+
const list = Array.isArray(data.result?.list) ? data.result.list : [];
|
|
74
|
+
if (!list.length) return [{ addressId: '', addressName: '', phone: '', address: '', postcode: '', defaultFlag: '', code: data.code ?? '', msg: data.msg || '' }];
|
|
75
|
+
return list.map((item) => ({
|
|
76
|
+
addressId: item.addressId || item.dataId || '',
|
|
77
|
+
addressName: item.addressName || item.name || '',
|
|
78
|
+
phone: item.phone || '',
|
|
79
|
+
address: item.address || item.detailAddress || '',
|
|
80
|
+
postcode: item.postcode || '',
|
|
81
|
+
defaultFlag: String(item.defaultFlag ?? item.isDefault ?? ''),
|
|
82
|
+
code: data.code ?? '',
|
|
83
|
+
msg: data.msg || '',
|
|
84
|
+
}));
|
|
85
|
+
},
|
|
86
|
+
});
|