wowok 1.6.84 → 1.6.85
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/dist/permission.d.ts +1 -1
- package/dist/permission.d.ts.map +1 -1
- package/dist/permission.js +0 -45
- package/package.json +1 -1
- package/src/permission.ts +18 -60
- package/tsconfig.json +112 -112
- package/dist/empty.d.ts +0 -1
- package/dist/empty.d.ts.map +0 -1
- package/dist/empty.js +0 -1
- package/dist/src/arbitration.d.ts +0 -61
- package/dist/src/arbitration.d.ts.map +0 -1
- package/dist/src/arbitration.js +0 -473
- package/dist/src/demand.d.ts +0 -26
- package/dist/src/demand.d.ts.map +0 -1
- package/dist/src/demand.js +0 -256
- package/dist/src/entity.d.ts +0 -27
- package/dist/src/entity.d.ts.map +0 -1
- package/dist/src/entity.js +0 -95
- package/dist/src/exception.d.ts +0 -31
- package/dist/src/exception.d.ts.map +0 -1
- package/dist/src/exception.js +0 -34
- package/dist/src/guard.d.ts +0 -79
- package/dist/src/guard.d.ts.map +0 -1
- package/dist/src/guard.js +0 -749
- package/dist/src/index.d.ts +0 -25
- package/dist/src/index.d.ts.map +0 -1
- package/dist/src/index.js +0 -24
- package/dist/src/machine.d.ts +0 -67
- package/dist/src/machine.d.ts.map +0 -1
- package/dist/src/machine.js +0 -518
- package/dist/src/passport.d.ts +0 -86
- package/dist/src/passport.d.ts.map +0 -1
- package/dist/src/passport.js +0 -645
- package/dist/src/payment.d.ts +0 -16
- package/dist/src/payment.d.ts.map +0 -1
- package/dist/src/payment.js +0 -41
- package/dist/src/permission.d.ts +0 -150
- package/dist/src/permission.d.ts.map +0 -1
- package/dist/src/permission.js +0 -502
- package/dist/src/progress.d.ts +0 -72
- package/dist/src/progress.d.ts.map +0 -1
- package/dist/src/progress.js +0 -301
- package/dist/src/protocol.d.ts +0 -226
- package/dist/src/protocol.d.ts.map +0 -1
- package/dist/src/protocol.js +0 -482
- package/dist/src/repository.d.ts +0 -83
- package/dist/src/repository.d.ts.map +0 -1
- package/dist/src/repository.js +0 -528
- package/dist/src/resource.d.ts +0 -35
- package/dist/src/resource.d.ts.map +0 -1
- package/dist/src/resource.js +0 -130
- package/dist/src/service.d.ts +0 -128
- package/dist/src/service.d.ts.map +0 -1
- package/dist/src/service.js +0 -1234
- package/dist/src/treasury.d.ts +0 -55
- package/dist/src/treasury.d.ts.map +0 -1
- package/dist/src/treasury.js +0 -396
- package/dist/src/utils.d.ts +0 -93
- package/dist/src/utils.d.ts.map +0 -1
- package/dist/src/utils.js +0 -616
- package/dist/src/wowok.d.ts +0 -15
- package/dist/src/wowok.d.ts.map +0 -1
- package/dist/src/wowok.js +0 -67
package/dist/src/permission.js
DELETED
|
@@ -1,502 +0,0 @@
|
|
|
1
|
-
import { Protocol, MODULES } from './protocol';
|
|
2
|
-
import { array_unique, IsValidAddress, IsValidArray, IsValidDesription, Bcs, IsValidName, IsValidU64 } from './utils';
|
|
3
|
-
import { ERROR, Errors } from './exception';
|
|
4
|
-
import { BCS } from '@mysten/bcs';
|
|
5
|
-
export var PermissionIndex;
|
|
6
|
-
(function (PermissionIndex) {
|
|
7
|
-
PermissionIndex[PermissionIndex["repository"] = 100] = "repository";
|
|
8
|
-
PermissionIndex[PermissionIndex["repository_description"] = 101] = "repository_description";
|
|
9
|
-
PermissionIndex[PermissionIndex["repository_mode"] = 102] = "repository_mode";
|
|
10
|
-
PermissionIndex[PermissionIndex["repository_policies"] = 103] = "repository_policies";
|
|
11
|
-
PermissionIndex[PermissionIndex["repository_reference"] = 104] = "repository_reference";
|
|
12
|
-
/*
|
|
13
|
-
vote = 150,
|
|
14
|
-
vote_description = 151,
|
|
15
|
-
vote_reference = 152,
|
|
16
|
-
vote_guard = 153,
|
|
17
|
-
vote_option = 155,
|
|
18
|
-
vote_max_choice_count = 157,
|
|
19
|
-
vote_open_voting = 158,
|
|
20
|
-
vote_lock_deadline = 159,
|
|
21
|
-
vote_expand_deadline = 160,
|
|
22
|
-
vote_lock_guard = 161,
|
|
23
|
-
*/
|
|
24
|
-
PermissionIndex[PermissionIndex["service"] = 200] = "service";
|
|
25
|
-
PermissionIndex[PermissionIndex["service_description"] = 201] = "service_description";
|
|
26
|
-
PermissionIndex[PermissionIndex["service_sales"] = 202] = "service_sales";
|
|
27
|
-
PermissionIndex[PermissionIndex["service_payee"] = 203] = "service_payee";
|
|
28
|
-
PermissionIndex[PermissionIndex["service_repository"] = 204] = "service_repository";
|
|
29
|
-
PermissionIndex[PermissionIndex["service_withdraw_guards"] = 205] = "service_withdraw_guards";
|
|
30
|
-
PermissionIndex[PermissionIndex["service_refund_guards"] = 206] = "service_refund_guards";
|
|
31
|
-
PermissionIndex[PermissionIndex["service_discount_transfer"] = 207] = "service_discount_transfer";
|
|
32
|
-
PermissionIndex[PermissionIndex["service_withdraw"] = 208] = "service_withdraw";
|
|
33
|
-
PermissionIndex[PermissionIndex["service_buyer_guard"] = 209] = "service_buyer_guard";
|
|
34
|
-
PermissionIndex[PermissionIndex["service_machine"] = 210] = "service_machine";
|
|
35
|
-
PermissionIndex[PermissionIndex["service_endpoint"] = 211] = "service_endpoint";
|
|
36
|
-
PermissionIndex[PermissionIndex["service_publish"] = 212] = "service_publish";
|
|
37
|
-
PermissionIndex[PermissionIndex["service_clone"] = 213] = "service_clone";
|
|
38
|
-
PermissionIndex[PermissionIndex["service_customer_required"] = 214] = "service_customer_required";
|
|
39
|
-
PermissionIndex[PermissionIndex["service_pause"] = 215] = "service_pause";
|
|
40
|
-
PermissionIndex[PermissionIndex["service_treasury"] = 216] = "service_treasury";
|
|
41
|
-
PermissionIndex[PermissionIndex["service_arbitration"] = 217] = "service_arbitration";
|
|
42
|
-
/*
|
|
43
|
-
reward = 240,
|
|
44
|
-
reward_refund = 241,
|
|
45
|
-
reward_expand_time = 242,
|
|
46
|
-
reward_guard = 243,
|
|
47
|
-
reward_description = 245,
|
|
48
|
-
reward_lock_guards = 246,
|
|
49
|
-
reward_claim_repeatably = 247,
|
|
50
|
-
reward_allow_claiming = 248,
|
|
51
|
-
*/
|
|
52
|
-
PermissionIndex[PermissionIndex["demand"] = 260] = "demand";
|
|
53
|
-
PermissionIndex[PermissionIndex["demand_refund"] = 261] = "demand_refund";
|
|
54
|
-
PermissionIndex[PermissionIndex["demand_expand_time"] = 262] = "demand_expand_time";
|
|
55
|
-
PermissionIndex[PermissionIndex["demand_guard"] = 263] = "demand_guard";
|
|
56
|
-
PermissionIndex[PermissionIndex["demand_description"] = 264] = "demand_description";
|
|
57
|
-
PermissionIndex[PermissionIndex["demand_yes"] = 265] = "demand_yes";
|
|
58
|
-
PermissionIndex[PermissionIndex["machine"] = 600] = "machine";
|
|
59
|
-
PermissionIndex[PermissionIndex["machine_description"] = 601] = "machine_description";
|
|
60
|
-
PermissionIndex[PermissionIndex["machine_repository"] = 602] = "machine_repository";
|
|
61
|
-
PermissionIndex[PermissionIndex["machine_clone"] = 604] = "machine_clone";
|
|
62
|
-
PermissionIndex[PermissionIndex["machine_node"] = 606] = "machine_node";
|
|
63
|
-
PermissionIndex[PermissionIndex["machine_endpoint"] = 608] = "machine_endpoint";
|
|
64
|
-
PermissionIndex[PermissionIndex["machine_pause"] = 609] = "machine_pause";
|
|
65
|
-
PermissionIndex[PermissionIndex["machine_publish"] = 610] = "machine_publish";
|
|
66
|
-
PermissionIndex[PermissionIndex["progress"] = 650] = "progress";
|
|
67
|
-
PermissionIndex[PermissionIndex["progress_namedOperator"] = 651] = "progress_namedOperator";
|
|
68
|
-
PermissionIndex[PermissionIndex["progress_bind_task"] = 652] = "progress_bind_task";
|
|
69
|
-
PermissionIndex[PermissionIndex["progress_context_repository"] = 653] = "progress_context_repository";
|
|
70
|
-
PermissionIndex[PermissionIndex["progress_unhold"] = 654] = "progress_unhold";
|
|
71
|
-
PermissionIndex[PermissionIndex["progress_parent"] = 655] = "progress_parent";
|
|
72
|
-
PermissionIndex[PermissionIndex["treasury"] = 700] = "treasury";
|
|
73
|
-
PermissionIndex[PermissionIndex["treasury_receive"] = 701] = "treasury_receive";
|
|
74
|
-
PermissionIndex[PermissionIndex["treasury_deposit"] = 702] = "treasury_deposit";
|
|
75
|
-
PermissionIndex[PermissionIndex["treasury_withdraw"] = 703] = "treasury_withdraw";
|
|
76
|
-
PermissionIndex[PermissionIndex["treasury_descritption"] = 704] = "treasury_descritption";
|
|
77
|
-
PermissionIndex[PermissionIndex["treasury_deposit_guard"] = 705] = "treasury_deposit_guard";
|
|
78
|
-
PermissionIndex[PermissionIndex["treasury_withdraw_mode"] = 706] = "treasury_withdraw_mode";
|
|
79
|
-
PermissionIndex[PermissionIndex["treasury_withdraw_guard"] = 707] = "treasury_withdraw_guard";
|
|
80
|
-
PermissionIndex[PermissionIndex["arbitration"] = 800] = "arbitration";
|
|
81
|
-
PermissionIndex[PermissionIndex["arbitration_description"] = 801] = "arbitration_description";
|
|
82
|
-
PermissionIndex[PermissionIndex["arbitration_fee"] = 802] = "arbitration_fee";
|
|
83
|
-
PermissionIndex[PermissionIndex["arbitration_voting_guard"] = 803] = "arbitration_voting_guard";
|
|
84
|
-
PermissionIndex[PermissionIndex["arbitration_endpoint"] = 804] = "arbitration_endpoint";
|
|
85
|
-
PermissionIndex[PermissionIndex["arbitration_guard"] = 805] = "arbitration_guard";
|
|
86
|
-
PermissionIndex[PermissionIndex["arbitration_pause"] = 806] = "arbitration_pause";
|
|
87
|
-
PermissionIndex[PermissionIndex["arbitration_vote"] = 807] = "arbitration_vote";
|
|
88
|
-
PermissionIndex[PermissionIndex["arbitration_arbitration"] = 808] = "arbitration_arbitration";
|
|
89
|
-
PermissionIndex[PermissionIndex["arbitration_withdraw"] = 809] = "arbitration_withdraw";
|
|
90
|
-
PermissionIndex[PermissionIndex["arbitration_treasury"] = 810] = "arbitration_treasury";
|
|
91
|
-
PermissionIndex[PermissionIndex["user_defined_start"] = 1000] = "user_defined_start";
|
|
92
|
-
})(PermissionIndex || (PermissionIndex = {}));
|
|
93
|
-
export const PermissionInfo = [
|
|
94
|
-
{ index: PermissionIndex.repository, name: 'Repository', description: 'Launch new Repository', module: MODULES.repository },
|
|
95
|
-
{ index: PermissionIndex.repository_description, name: 'Description', description: 'Set Repository description', module: MODULES.repository },
|
|
96
|
-
{ index: PermissionIndex.repository_mode, name: 'Policy mode', description: 'Set Repository mode', module: MODULES.repository },
|
|
97
|
-
{ index: PermissionIndex.repository_policies, name: 'Policy', description: 'Set Repository policies', module: MODULES.repository },
|
|
98
|
-
{ index: PermissionIndex.repository_reference, name: 'Reference', description: 'Set Repository reference', module: MODULES.repository },
|
|
99
|
-
/*
|
|
100
|
-
{index:PermissionIndex.vote, name:'Vote', description:'Launch new Vote', module: 'vote'},
|
|
101
|
-
{index:PermissionIndex.vote_description, name:'Description', description:'Set Vote description', module: 'vote'},
|
|
102
|
-
{index:PermissionIndex.vote_reference, name:'Reference', description:'Set Vote reference', module: 'vote'},
|
|
103
|
-
{index:PermissionIndex.vote_guard, name:'Guard', description:'Set Vote guards', module: 'vote'},
|
|
104
|
-
{index:PermissionIndex.vote_option, name:'Option', description:'Set Vote options', module: 'vote'},
|
|
105
|
-
{index:PermissionIndex.vote_max_choice_count, name:'Choice count', description:'Set Vote max choice count', module: 'vote'},
|
|
106
|
-
{index:PermissionIndex.vote_open_voting, name:'Open voting', description:'Open voting', module: 'vote'},
|
|
107
|
-
{index:PermissionIndex.vote_lock_deadline, name:'Lock deadline', description:'Set Vote deadline immutable', module: 'vote'},
|
|
108
|
-
{index:PermissionIndex.vote_expand_deadline, name:'Expand deadline', description:'Expand Vote deadline', module: 'vote'},
|
|
109
|
-
{index:PermissionIndex.vote_lock_guard, name:'Lock Guard', description:'Set Vote guards immutable', module: 'vote'},
|
|
110
|
-
*/
|
|
111
|
-
{ index: PermissionIndex.service, name: 'Service', description: 'Launch new Service', module: MODULES.service },
|
|
112
|
-
{ index: PermissionIndex.service_description, name: 'Description', description: 'Set Service description', module: MODULES.service },
|
|
113
|
-
{ index: PermissionIndex.service_sales, name: 'Sales', description: 'Set Service sales items', module: MODULES.service },
|
|
114
|
-
{ index: PermissionIndex.service_payee, name: 'Payee', description: 'Set Service payee', module: MODULES.service },
|
|
115
|
-
{ index: PermissionIndex.service_repository, name: 'Repository', description: 'Set Service repositories', module: MODULES.service },
|
|
116
|
-
{ index: PermissionIndex.service_withdraw_guards, name: 'Withdraw Guard', description: 'Set Service withdraw guards', module: MODULES.service },
|
|
117
|
-
{ index: PermissionIndex.service_refund_guards, name: 'Refund Guard', description: 'Set Service refund guards', module: MODULES.service },
|
|
118
|
-
{ index: PermissionIndex.service_discount_transfer, name: 'Discount', description: 'Launch discounts for Service', module: MODULES.service },
|
|
119
|
-
{ index: PermissionIndex.service_buyer_guard, name: 'Buyer Guard', description: 'Set Guard of buying for Service', module: MODULES.service },
|
|
120
|
-
{ index: PermissionIndex.service_machine, name: 'Machine', description: 'Set Machine for Service', module: MODULES.service },
|
|
121
|
-
{ index: PermissionIndex.service_endpoint, name: 'Endpoint', description: 'Set Service endpoint', module: MODULES.service },
|
|
122
|
-
{ index: PermissionIndex.service_publish, name: 'Publish', description: 'Allowing the creation of Order', module: MODULES.service },
|
|
123
|
-
{ index: PermissionIndex.service_clone, name: 'Clone', description: 'Clone Service', module: MODULES.service },
|
|
124
|
-
{ index: PermissionIndex.service_customer_required, name: 'Buyer info', description: 'Set Service buyer info required', module: MODULES.service },
|
|
125
|
-
//{index:PermissionIndex.service_change_order_required_pubkey, name:'Order pubkey', description:'Update Serivce order pubkey', module: MODULES.service},
|
|
126
|
-
{ index: PermissionIndex.service_pause, name: 'Pause', description: 'Pause/Unpause Service', module: MODULES.service },
|
|
127
|
-
{ index: PermissionIndex.service_treasury, name: 'Treasury', description: 'Externally withdrawable treasury for compensation or rewards', module: MODULES.service },
|
|
128
|
-
{ index: PermissionIndex.service_arbitration, name: 'Arbitration', description: 'Add/Remove arbitration that allows refunds from orders at any time based on arbitration results', module: MODULES.service },
|
|
129
|
-
/*
|
|
130
|
-
{index:PermissionIndex.reward, name:'reward', description:'Launch new reward', module: 'reward'},
|
|
131
|
-
{index:PermissionIndex.reward_refund, name:'Refund', description:'Refund from reward', module: 'reward'},
|
|
132
|
-
{index:PermissionIndex.reward_expand_time, name:'Expand deadline', description:'Expand reward deadline', module: 'reward'},
|
|
133
|
-
{index:PermissionIndex.reward_guard, name:'Guard', description:'Set reward guard', module: 'reward'},
|
|
134
|
-
{index:PermissionIndex.reward_description, name:'Description', description:'Set reward description', module: 'reward'},
|
|
135
|
-
{index:PermissionIndex.reward_lock_guards, name:'Lock Guard', description:'Set reward guard immutable', module: 'reward'},
|
|
136
|
-
{index:PermissionIndex.reward_claim_repeatably, name:'Claim repeatably', description:'Allow claimming repeatably', module: 'reward'},
|
|
137
|
-
{index:PermissionIndex.reward_allow_claiming, name:'Allow claiming', description:'Allow claiming', module: 'reward'},
|
|
138
|
-
*/
|
|
139
|
-
{ index: PermissionIndex.demand, name: 'Demand', description: 'Launch new Demand', module: MODULES.demand },
|
|
140
|
-
{ index: PermissionIndex.demand_refund, name: 'Refund', description: 'Refund from Demand', module: MODULES.demand },
|
|
141
|
-
{ index: PermissionIndex.demand_expand_time, name: 'Expand deadline', description: 'Expand Demand deadline', module: MODULES.demand },
|
|
142
|
-
{ index: PermissionIndex.demand_guard, name: 'Guard', description: 'Set Demand guard', module: MODULES.demand },
|
|
143
|
-
{ index: PermissionIndex.demand_description, name: 'Description', description: 'Set Demand description', module: MODULES.demand },
|
|
144
|
-
{ index: PermissionIndex.demand_yes, name: 'Yes', description: 'Pick the Deamand serice', module: MODULES.demand },
|
|
145
|
-
{ index: PermissionIndex.machine, name: 'Machine', description: 'Launch new Machine', module: MODULES.machine },
|
|
146
|
-
{ index: PermissionIndex.machine_description, name: 'Description', description: 'Set Machine description', module: MODULES.machine },
|
|
147
|
-
{ index: PermissionIndex.machine_repository, name: 'Repository', description: 'Set Machine repository', module: MODULES.machine },
|
|
148
|
-
{ index: PermissionIndex.machine_clone, name: 'Clone', description: 'Clone Machine', module: MODULES.machine },
|
|
149
|
-
{ index: PermissionIndex.machine_node, name: 'Node', description: 'Set Machine nodes', module: MODULES.machine },
|
|
150
|
-
{ index: PermissionIndex.machine_endpoint, name: 'Endpoint', description: 'Set Machine endpoint', module: MODULES.machine },
|
|
151
|
-
{ index: PermissionIndex.machine_pause, name: 'Pause', description: 'Pause/Unpause Machine', module: MODULES.machine },
|
|
152
|
-
{ index: PermissionIndex.machine_publish, name: 'Publish', description: 'Allowing the creation of Progress', module: MODULES.machine },
|
|
153
|
-
{ index: PermissionIndex.progress, name: 'Progress', description: 'Launch new Progress', module: MODULES.progress },
|
|
154
|
-
{ index: PermissionIndex.progress_namedOperator, name: 'Operator', description: 'Set Progress operators', module: MODULES.progress },
|
|
155
|
-
{ index: PermissionIndex.progress_bind_task, name: 'Bind', description: 'Set Progress task', module: MODULES.progress },
|
|
156
|
-
{ index: PermissionIndex.progress_context_repository, name: 'Repository', description: 'Set Progress repository', module: MODULES.progress },
|
|
157
|
-
{ index: PermissionIndex.progress_unhold, name: 'Unhold', description: 'Release Progress holdings', module: MODULES.progress },
|
|
158
|
-
{ index: PermissionIndex.progress_parent, name: 'Parent', description: 'Set Progress parent', module: MODULES.progress },
|
|
159
|
-
{ index: PermissionIndex.treasury, name: 'Treasury', description: 'Launch new Treasury', module: MODULES.treasury },
|
|
160
|
-
{ index: PermissionIndex.treasury_deposit, name: 'Deposit', description: 'Deposit coins', module: MODULES.treasury },
|
|
161
|
-
{ index: PermissionIndex.treasury_receive, name: 'Receive', description: 'Receive coins from some address sent', module: MODULES.treasury },
|
|
162
|
-
{ index: PermissionIndex.treasury_withdraw, name: 'Withdraw', description: 'Withdraw coins', module: MODULES.treasury },
|
|
163
|
-
{ index: PermissionIndex.treasury_withdraw_guard, name: 'Withdraw Guard', description: 'Add/Remove Treasury withdraw guard', module: MODULES.treasury },
|
|
164
|
-
{ index: PermissionIndex.treasury_withdraw_mode, name: 'Withdraw mode', description: 'Set Treasury withdraw mode', module: MODULES.treasury },
|
|
165
|
-
{ index: PermissionIndex.treasury_deposit_guard, name: 'Deposit Guard', description: 'Set Treasury deposit guard', module: MODULES.treasury },
|
|
166
|
-
{ index: PermissionIndex.treasury_descritption, name: 'Description', description: 'Set Treasury description', module: MODULES.treasury },
|
|
167
|
-
{ index: PermissionIndex.arbitration, name: 'Arbitration', description: 'Launch new Arbitration', module: MODULES.arbitration },
|
|
168
|
-
{ index: PermissionIndex.arbitration_description, name: 'Description', description: 'Set Arbitration description', module: MODULES.arbitration },
|
|
169
|
-
{ index: PermissionIndex.arbitration_endpoint, name: 'Endpoint', description: 'Set Arbitration endpoint', module: MODULES.arbitration },
|
|
170
|
-
{ index: PermissionIndex.arbitration_fee, name: 'Fee', description: 'Set Arbitration fee', module: MODULES.arbitration },
|
|
171
|
-
{ index: PermissionIndex.arbitration_guard, name: 'Guard', description: 'Set Guard to apply for arbitration', module: MODULES.arbitration },
|
|
172
|
-
{ index: PermissionIndex.arbitration_arbitration, name: 'Arbitrate', description: 'Determine the outcome of arbitration', module: MODULES.arbitration },
|
|
173
|
-
{ index: PermissionIndex.arbitration_pause, name: 'Pause', description: 'Allowing/forbidding the creation of Arb', module: MODULES.arbitration },
|
|
174
|
-
{ index: PermissionIndex.arbitration_voting_guard, name: 'Voting Guard', description: 'Add/Remove voting Guard', module: MODULES.arbitration },
|
|
175
|
-
{ index: PermissionIndex.arbitration_vote, name: 'Vote', description: 'Vote on the application for arbitration', module: MODULES.arbitration },
|
|
176
|
-
{ index: PermissionIndex.arbitration_withdraw, name: 'Withdraw', description: 'Withdraw the arbitration fee', module: MODULES.arbitration },
|
|
177
|
-
{ index: PermissionIndex.arbitration_treasury, name: 'Withdraw', description: 'Set Treasury that fees was collected at the time of withdrawal', module: MODULES.arbitration },
|
|
178
|
-
];
|
|
179
|
-
export class Permission {
|
|
180
|
-
txb;
|
|
181
|
-
object;
|
|
182
|
-
get_object() { return this.object; }
|
|
183
|
-
constructor(txb) {
|
|
184
|
-
this.txb = txb;
|
|
185
|
-
this.object = '';
|
|
186
|
-
}
|
|
187
|
-
static From(txb, object) {
|
|
188
|
-
let p = new Permission(txb);
|
|
189
|
-
p.object = Protocol.TXB_OBJECT(txb, object);
|
|
190
|
-
return p;
|
|
191
|
-
}
|
|
192
|
-
static New(txb, description) {
|
|
193
|
-
if (!IsValidDesription(description)) {
|
|
194
|
-
ERROR(Errors.IsValidDesription);
|
|
195
|
-
}
|
|
196
|
-
let p = new Permission(txb);
|
|
197
|
-
p.object = txb.moveCall({
|
|
198
|
-
target: Protocol.Instance().permissionFn('new'),
|
|
199
|
-
arguments: [txb.pure.string(description)]
|
|
200
|
-
});
|
|
201
|
-
return p;
|
|
202
|
-
}
|
|
203
|
-
launch() {
|
|
204
|
-
return this.txb.moveCall({
|
|
205
|
-
target: Protocol.Instance().permissionFn('create'),
|
|
206
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object)]
|
|
207
|
-
});
|
|
208
|
-
}
|
|
209
|
-
add_bizPermission(index, name) {
|
|
210
|
-
if (!Permission.IsValidBizPermissionIndex(index)) {
|
|
211
|
-
ERROR(Errors.IsValidBizPermissionIndex, 'add_bizPermission');
|
|
212
|
-
}
|
|
213
|
-
if (!IsValidName(name)) {
|
|
214
|
-
ERROR(Errors.IsValidName, 'add_bizPermission');
|
|
215
|
-
}
|
|
216
|
-
this.txb.moveCall({
|
|
217
|
-
target: Protocol.Instance().permissionFn('user_define_add'),
|
|
218
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.u64(index), this.txb.pure.string(name)]
|
|
219
|
-
});
|
|
220
|
-
}
|
|
221
|
-
remove_bizPermission(index) {
|
|
222
|
-
if (!Permission.IsValidBizPermissionIndex(index)) {
|
|
223
|
-
ERROR(Errors.IsValidBizPermissionIndex, 'remove_bizPermission');
|
|
224
|
-
}
|
|
225
|
-
this.txb.moveCall({
|
|
226
|
-
target: Protocol.Instance().permissionFn('user_define_remove'),
|
|
227
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.u64(index)]
|
|
228
|
-
});
|
|
229
|
-
}
|
|
230
|
-
transfer_permission(old_entity, new_entity) {
|
|
231
|
-
if (!IsValidAddress(old_entity) || !IsValidAddress(new_entity)) {
|
|
232
|
-
ERROR(Errors.IsValidAddress, 'transfer_permission');
|
|
233
|
-
}
|
|
234
|
-
this.txb.moveCall({
|
|
235
|
-
target: Protocol.Instance().permissionFn('change_entity'),
|
|
236
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(old_entity),
|
|
237
|
-
this.txb.pure.address(new_entity)]
|
|
238
|
-
});
|
|
239
|
-
}
|
|
240
|
-
add_entity2(entities, index) {
|
|
241
|
-
if (entities.length === 0)
|
|
242
|
-
return;
|
|
243
|
-
if (!IsValidArray(entities, IsValidAddress)) {
|
|
244
|
-
ERROR(Errors.IsValidArray, 'add_entity2');
|
|
245
|
-
}
|
|
246
|
-
if (index !== undefined) {
|
|
247
|
-
this.txb.moveCall({
|
|
248
|
-
target: Protocol.Instance().permissionFn('add_with_index'),
|
|
249
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.u64(index),
|
|
250
|
-
this.txb.pure.vector('address', array_unique(entities))]
|
|
251
|
-
});
|
|
252
|
-
}
|
|
253
|
-
else {
|
|
254
|
-
this.txb.moveCall({
|
|
255
|
-
target: Protocol.Instance().permissionFn('add'),
|
|
256
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.vector('address', array_unique(entities))]
|
|
257
|
-
});
|
|
258
|
-
}
|
|
259
|
-
}
|
|
260
|
-
add_entity3(entities) {
|
|
261
|
-
if (entities.length === 0)
|
|
262
|
-
return;
|
|
263
|
-
const e = [];
|
|
264
|
-
entities.forEach((v) => {
|
|
265
|
-
v.entities.forEach((p) => {
|
|
266
|
-
const f = e.find((i) => i.address === p.address);
|
|
267
|
-
if (f) {
|
|
268
|
-
const t = f.permissions.find((k) => k.index === v.index);
|
|
269
|
-
if (t) {
|
|
270
|
-
t.guard = p.guard;
|
|
271
|
-
}
|
|
272
|
-
else {
|
|
273
|
-
f.permissions.push({ guard: p.guard, index: v.index });
|
|
274
|
-
}
|
|
275
|
-
}
|
|
276
|
-
else {
|
|
277
|
-
e.push({ address: p.address, permissions: [{ guard: p.guard, index: v.index }] });
|
|
278
|
-
}
|
|
279
|
-
});
|
|
280
|
-
});
|
|
281
|
-
this.add_entity(e);
|
|
282
|
-
}
|
|
283
|
-
add_entity(entities) {
|
|
284
|
-
if (entities.length === 0)
|
|
285
|
-
return;
|
|
286
|
-
let bValid = true;
|
|
287
|
-
entities.forEach((v) => {
|
|
288
|
-
if (!IsValidAddress(v.address))
|
|
289
|
-
bValid = false;
|
|
290
|
-
v.permissions.forEach((p) => {
|
|
291
|
-
if (!Permission.IsValidPermissionIndex(p.index))
|
|
292
|
-
bValid = false;
|
|
293
|
-
if (p?.guard && !Protocol.IsValidObjects([p.guard]))
|
|
294
|
-
bValid = false;
|
|
295
|
-
});
|
|
296
|
-
});
|
|
297
|
-
if (!bValid) {
|
|
298
|
-
ERROR(Errors.InvalidParam, 'add_entity.entities');
|
|
299
|
-
}
|
|
300
|
-
let guards = [];
|
|
301
|
-
for (let i = 0; i < entities.length; i++) {
|
|
302
|
-
let entity = entities[i];
|
|
303
|
-
let indexes = [];
|
|
304
|
-
for (let j = 0; j < entity.permissions.length; j++) {
|
|
305
|
-
let index = entity.permissions[j];
|
|
306
|
-
if (!Permission.IsValidPermissionIndex(index.index)) {
|
|
307
|
-
continue;
|
|
308
|
-
}
|
|
309
|
-
if (!indexes.includes(index.index)) {
|
|
310
|
-
indexes.push(index.index);
|
|
311
|
-
if (index?.guard) {
|
|
312
|
-
guards.push({ address: entity.address, index: index.index, guard: index.guard });
|
|
313
|
-
}
|
|
314
|
-
}
|
|
315
|
-
}
|
|
316
|
-
if (indexes.length > 0) {
|
|
317
|
-
this.txb.moveCall({
|
|
318
|
-
target: Protocol.Instance().permissionFn('add_batch'),
|
|
319
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(entity.address),
|
|
320
|
-
this.txb.pure.vector('u64', indexes)]
|
|
321
|
-
});
|
|
322
|
-
}
|
|
323
|
-
}
|
|
324
|
-
// set guards
|
|
325
|
-
guards.forEach(({ address, index, guard }) => {
|
|
326
|
-
this.txb.moveCall({
|
|
327
|
-
target: Protocol.Instance().permissionFn('guard_set'),
|
|
328
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(address),
|
|
329
|
-
this.txb.pure.u64(index), Protocol.TXB_OBJECT(this.txb, guard)]
|
|
330
|
-
});
|
|
331
|
-
});
|
|
332
|
-
}
|
|
333
|
-
// guard: undefine to set none
|
|
334
|
-
set_guard(address, index, guard) {
|
|
335
|
-
if (!IsValidAddress(address)) {
|
|
336
|
-
ERROR(Errors.IsValidAddress, 'address');
|
|
337
|
-
}
|
|
338
|
-
if (!Permission.IsValidPermissionIndex(index) && !Permission.IsValidBizPermissionIndex(index)) {
|
|
339
|
-
ERROR(Errors.IsValidPermissionIndex, 'index');
|
|
340
|
-
}
|
|
341
|
-
if (guard) {
|
|
342
|
-
this.txb.moveCall({
|
|
343
|
-
target: Protocol.Instance().permissionFn('guard_set'),
|
|
344
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(address),
|
|
345
|
-
this.txb.pure.u64(index), Protocol.TXB_OBJECT(this.txb, guard)]
|
|
346
|
-
});
|
|
347
|
-
}
|
|
348
|
-
else {
|
|
349
|
-
this.txb.moveCall({
|
|
350
|
-
target: Protocol.Instance().permissionFn('guard_none'),
|
|
351
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(address),
|
|
352
|
-
this.txb.pure.u64(index)]
|
|
353
|
-
});
|
|
354
|
-
}
|
|
355
|
-
;
|
|
356
|
-
}
|
|
357
|
-
remove_index(address, index) {
|
|
358
|
-
if (!IsValidAddress(address)) {
|
|
359
|
-
ERROR(Errors.IsValidAddress);
|
|
360
|
-
}
|
|
361
|
-
if (index.length === 0)
|
|
362
|
-
return;
|
|
363
|
-
if (!(IsValidArray(index, Permission.IsValidPermissionIndex))) {
|
|
364
|
-
ERROR(Errors.InvalidParam, 'index');
|
|
365
|
-
}
|
|
366
|
-
this.txb.moveCall({
|
|
367
|
-
target: Protocol.Instance().permissionFn('remove_index'),
|
|
368
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(address),
|
|
369
|
-
this.txb.pure.vector('u64', array_unique(index))]
|
|
370
|
-
});
|
|
371
|
-
}
|
|
372
|
-
remove_entity(address) {
|
|
373
|
-
if (address.length === 0)
|
|
374
|
-
return;
|
|
375
|
-
if (!IsValidArray(address, IsValidAddress)) {
|
|
376
|
-
ERROR(Errors.IsValidArray);
|
|
377
|
-
}
|
|
378
|
-
this.txb.moveCall({
|
|
379
|
-
target: Protocol.Instance().permissionFn('remove'),
|
|
380
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.vector('address', array_unique(address))]
|
|
381
|
-
});
|
|
382
|
-
}
|
|
383
|
-
set_description(description) {
|
|
384
|
-
if (!IsValidDesription(description)) {
|
|
385
|
-
ERROR(Errors.IsValidDesription);
|
|
386
|
-
}
|
|
387
|
-
this.txb.moveCall({
|
|
388
|
-
target: Protocol.Instance().permissionFn('description_set'),
|
|
389
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.string(description)]
|
|
390
|
-
});
|
|
391
|
-
}
|
|
392
|
-
add_admin(admin) {
|
|
393
|
-
if (admin.length === 0)
|
|
394
|
-
return;
|
|
395
|
-
if (!IsValidArray(admin, IsValidAddress)) {
|
|
396
|
-
ERROR(Errors.IsValidArray);
|
|
397
|
-
}
|
|
398
|
-
this.txb.moveCall({
|
|
399
|
-
target: Protocol.Instance().permissionFn('admin_add_batch'),
|
|
400
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.vector('address', array_unique(admin))]
|
|
401
|
-
});
|
|
402
|
-
}
|
|
403
|
-
remove_admin(admin, removeall) {
|
|
404
|
-
if (!removeall && admin.length === 0)
|
|
405
|
-
return;
|
|
406
|
-
if (!IsValidArray(admin, IsValidAddress)) {
|
|
407
|
-
ERROR(Errors.IsValidArray, 'admin');
|
|
408
|
-
}
|
|
409
|
-
if (removeall) {
|
|
410
|
-
this.txb.moveCall({
|
|
411
|
-
target: Protocol.Instance().permissionFn('admins_clear'),
|
|
412
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object)]
|
|
413
|
-
});
|
|
414
|
-
}
|
|
415
|
-
else if (admin) {
|
|
416
|
-
this.txb.moveCall({
|
|
417
|
-
target: Protocol.Instance().permissionFn('admin_remove_batch'),
|
|
418
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.vector('address', array_unique(admin))]
|
|
419
|
-
});
|
|
420
|
-
}
|
|
421
|
-
}
|
|
422
|
-
change_owner(new_owner) {
|
|
423
|
-
if (!IsValidAddress(new_owner)) {
|
|
424
|
-
ERROR(Errors.IsValidAddress);
|
|
425
|
-
}
|
|
426
|
-
this.txb.moveCall({
|
|
427
|
-
target: Protocol.Instance().permissionFn('builder_set'),
|
|
428
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(new_owner)]
|
|
429
|
-
});
|
|
430
|
-
}
|
|
431
|
-
// query all permissions for address
|
|
432
|
-
query_permissions_all(address_queried) {
|
|
433
|
-
if (!IsValidAddress(address_queried)) {
|
|
434
|
-
ERROR(Errors.InvalidParam, 'query_permissions');
|
|
435
|
-
}
|
|
436
|
-
this.txb.moveCall({
|
|
437
|
-
target: Protocol.Instance().permissionFn('query_permissions_all'),
|
|
438
|
-
arguments: [Protocol.TXB_OBJECT(this.txb, this.object), this.txb.pure.address(address_queried)]
|
|
439
|
-
});
|
|
440
|
-
}
|
|
441
|
-
QueryPermissions(permission, address_queried, onPermissionAnswer, sender) {
|
|
442
|
-
//@ be the same txb
|
|
443
|
-
this.query_permissions_all(address_queried);
|
|
444
|
-
//console.log(address_queried)
|
|
445
|
-
Protocol.Client().devInspectTransactionBlock({ sender: sender ?? address_queried, transactionBlock: this.txb }).then((res) => {
|
|
446
|
-
if (res.results && res.results[0].returnValues && res.results[0].returnValues.length !== 2) {
|
|
447
|
-
onPermissionAnswer({ who: address_queried, object: permission });
|
|
448
|
-
return;
|
|
449
|
-
}
|
|
450
|
-
const perm = Bcs.getInstance().de(BCS.U8, Uint8Array.from(res.results[0].returnValues[0][0]));
|
|
451
|
-
if (perm === Permission.PERMISSION_ADMIN || perm === Permission.PERMISSION_OWNER_AND_ADMIN) {
|
|
452
|
-
onPermissionAnswer({ who: address_queried, admin: true, owner: perm % 2 === 1, items: [], object: permission });
|
|
453
|
-
}
|
|
454
|
-
else {
|
|
455
|
-
const perms = Bcs.getInstance().de_perms(Uint8Array.from(res.results[0].returnValues[1][0]));
|
|
456
|
-
onPermissionAnswer({ who: address_queried, admin: false, owner: perm % 2 === 1, items: perms.map((v) => {
|
|
457
|
-
return { query: v?.index, permission: true, guard: v?.guard };
|
|
458
|
-
}), object: permission });
|
|
459
|
-
}
|
|
460
|
-
}).catch((e) => {
|
|
461
|
-
console.log(e);
|
|
462
|
-
onPermissionAnswer({ who: address_queried, object: permission });
|
|
463
|
-
});
|
|
464
|
-
}
|
|
465
|
-
static HasPermission(answer, index, bStrict = false) {
|
|
466
|
-
if (answer) {
|
|
467
|
-
if (answer.admin)
|
|
468
|
-
return { has: true, owner: answer.owner }; // admin
|
|
469
|
-
let i = answer.items?.find((v) => v.query == index); // index maybe string, so ==
|
|
470
|
-
if (i) {
|
|
471
|
-
return { has: i.permission, guard: i.guard, owner: answer.owner };
|
|
472
|
-
}
|
|
473
|
-
else {
|
|
474
|
-
return { has: false, guard: undefined, owner: answer?.owner };
|
|
475
|
-
}
|
|
476
|
-
}
|
|
477
|
-
if (bStrict) {
|
|
478
|
-
return { has: false, guard: undefined, owner: false };
|
|
479
|
-
}
|
|
480
|
-
return undefined; // basic: !== false ; otherwise: !
|
|
481
|
-
}
|
|
482
|
-
static MAX_ADMIN_COUNT = 64;
|
|
483
|
-
static MAX_ENTITY_COUNT = 2000;
|
|
484
|
-
static MAX_PERMISSION_INDEX_COUNT = 200;
|
|
485
|
-
static MAX_PERSONAL_PERMISSION_COUNT = 200;
|
|
486
|
-
static PERMISSION_NORMAL = 0;
|
|
487
|
-
static PERMISSION_OWNER = 1;
|
|
488
|
-
static PERMISSION_ADMIN = 2;
|
|
489
|
-
static PERMISSION_OWNER_AND_ADMIN = 3;
|
|
490
|
-
static BUSINESS_PERMISSIONS_START = PermissionIndex.user_defined_start;
|
|
491
|
-
static IsValidBizPermissionIndex = (index) => {
|
|
492
|
-
return index >= Permission.BUSINESS_PERMISSIONS_START && IsValidU64(index);
|
|
493
|
-
};
|
|
494
|
-
static IsValidPermissionIndex = (index) => {
|
|
495
|
-
//console.log(index)
|
|
496
|
-
if (Object.values(PermissionIndex).includes(index)) {
|
|
497
|
-
return true;
|
|
498
|
-
}
|
|
499
|
-
//console.log(Object.keys(PermissionIndex))
|
|
500
|
-
return Permission.IsValidBizPermissionIndex(index);
|
|
501
|
-
};
|
|
502
|
-
}
|
package/dist/src/progress.d.ts
DELETED
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import { PermissionObject, RepositoryObject, PassportObject, MachineObject, ProgressObject, ProgressAddress, TxbObject, OrderObject } from './protocol';
|
|
2
|
-
import { type TransactionResult, Transaction as TransactionBlock } from '@mysten/sui/transactions';
|
|
3
|
-
export interface OrderWrap {
|
|
4
|
-
object: OrderObject;
|
|
5
|
-
pay_token_type: string;
|
|
6
|
-
}
|
|
7
|
-
export interface Deliverable {
|
|
8
|
-
msg: string;
|
|
9
|
-
orders: OrderWrap[];
|
|
10
|
-
}
|
|
11
|
-
export type ProgressNext = {
|
|
12
|
-
next_node_name: string;
|
|
13
|
-
forward: string;
|
|
14
|
-
};
|
|
15
|
-
export type ParentProgress = {
|
|
16
|
-
parent_id: string;
|
|
17
|
-
parent_session_id: number;
|
|
18
|
-
next_node: string;
|
|
19
|
-
forward: string;
|
|
20
|
-
};
|
|
21
|
-
export type CurrentSessionId = TransactionResult;
|
|
22
|
-
export interface Holder {
|
|
23
|
-
forward: string;
|
|
24
|
-
who?: string;
|
|
25
|
-
deliverable: Deliverable;
|
|
26
|
-
accomplished: boolean;
|
|
27
|
-
time: string;
|
|
28
|
-
}
|
|
29
|
-
export interface Session {
|
|
30
|
-
id?: number;
|
|
31
|
-
next_node: string;
|
|
32
|
-
holders: Holder[];
|
|
33
|
-
weights: number;
|
|
34
|
-
threshold: number;
|
|
35
|
-
node?: string;
|
|
36
|
-
bComplete?: boolean;
|
|
37
|
-
}
|
|
38
|
-
export interface History {
|
|
39
|
-
id: number;
|
|
40
|
-
node: string;
|
|
41
|
-
next_node: string;
|
|
42
|
-
time: string;
|
|
43
|
-
sessions: Session[];
|
|
44
|
-
}
|
|
45
|
-
export declare class Progress {
|
|
46
|
-
protected permission: PermissionObject;
|
|
47
|
-
protected machine: MachineObject;
|
|
48
|
-
protected object: TxbObject;
|
|
49
|
-
protected txb: TransactionBlock;
|
|
50
|
-
get_object(): TxbObject;
|
|
51
|
-
private constructor();
|
|
52
|
-
static From(txb: TransactionBlock, machine: MachineObject, permission: PermissionObject, object: TxbObject): Progress;
|
|
53
|
-
static New(txb: TransactionBlock, machine: MachineObject, permission: PermissionObject, task?: string | null, passport?: PassportObject): Progress;
|
|
54
|
-
launch(): ProgressAddress;
|
|
55
|
-
set_namedOperator(name: string, addresses: string[], passport?: PassportObject): void;
|
|
56
|
-
bind_task(task_address: string, passport?: PassportObject): void;
|
|
57
|
-
set_context_repository(repository?: RepositoryObject, passport?: PassportObject): void;
|
|
58
|
-
unhold(next: ProgressNext, passport?: PassportObject): void;
|
|
59
|
-
parent_none(passport?: PassportObject): void;
|
|
60
|
-
parent(parent: ParentProgress, passport?: PassportObject): void;
|
|
61
|
-
private deliverable;
|
|
62
|
-
next(next: ProgressNext, deliverable: Deliverable, passport?: PassportObject): CurrentSessionId;
|
|
63
|
-
hold(next: ProgressNext, hold: boolean): CurrentSessionId;
|
|
64
|
-
static QueryForwardGuard: (progress: ProgressObject, machine: MachineObject, sender: string, next_node: string, forward: string) => Promise<string | undefined>;
|
|
65
|
-
static DeSessions: (session: any) => Session[];
|
|
66
|
-
static DeHistories: (fields: any) => History[];
|
|
67
|
-
static DeHistory: (data: any) => History;
|
|
68
|
-
static MAX_NAMED_OPERATOR_COUNT: number;
|
|
69
|
-
static MAX_DELEVERABLE_ORDER_COUNT: number;
|
|
70
|
-
static IsValidProgressNext: (next: ProgressNext) => boolean;
|
|
71
|
-
}
|
|
72
|
-
//# sourceMappingURL=progress.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"progress.d.ts","sourceRoot":"","sources":["../../src/progress.ts"],"names":[],"mappings":"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"}
|