tx · bzyAH92iAHm7XFjzt4E2bHtNhUFLCUzSWgWBMkQxBNR 3N1rgNAEfetRH87WQqJan6zSy7Wp1byercW: -0.01800000 Waves 2022.10.26 07:46 [2288920] smart account 3N1rgNAEfetRH87WQqJan6zSy7Wp1byercW > SELF 0.00000000 Waves
{ "type": 13, "id": "bzyAH92iAHm7XFjzt4E2bHtNhUFLCUzSWgWBMkQxBNR", "fee": 1800000, "feeAssetId": null, "timestamp": 1666759602114, "version": 2, "chainId": 84, "sender": "3N1rgNAEfetRH87WQqJan6zSy7Wp1byercW", "senderPublicKey": "4dLVvLszUGcr1uHnDX72QuZxqaZTntQWRbbhn8YQDgA4", "proofs": [ "KSkNFF5FvjLQ8Q3WtKsTKk9BvoZw1QuXhmxQWEvZxQZzurX2Ltxpruk1uoQrB7XFfcvtf19JGmWUDJJEN2Hquwc" ], "script": "base64:BgJhCAISBAoCCAgSCQoHCAgICAgICBIKCggICAgICAgICBIDCgEIEgQKAggIEgYKBAgICAgSCAoGCAgIAQEBEgkKBwgICAgBAQESBQoDCAEEEgQKAggIEgUKAwgICBIECgIICDUAB1ZFUlNJT04CBTEuMC4wAQ5nZXRTdHJpbmdCeUtleQEDa2V5CQELdmFsdWVPckVsc2UCCQCdCAIFBHRoaXMFA2tleQIAAAh1c2VyRGFwcAkBBXZhbHVlAQkApggBCQEOZ2V0U3RyaW5nQnlLZXkBAg9jb25mX3VzZXJzX2RhcHAAC2ZlZVJlY2VpdmVyCQEOZ2V0U3RyaW5nQnlLZXkBAhFjb25mX2ZlZV9yZWNlaXZlcgALc2lnbkFzc2V0SWQJANkEAQkBDmdldFN0cmluZ0J5S2V5AQIYY29uZl9hY2NlcHRlZF9hc3NldF9TSUdOAAVjaHJpcwkBDmdldFN0cmluZ0J5S2V5AQIMY29uZl9hZG1pbl8xAQ9nZXRJbnRlZ2VyQnlLZXkBA2tleQkBC3ZhbHVlT3JFbHNlAgkAmggCBQR0aGlzBQNrZXkAAAEPZ2V0Qm9vbGVhbkJ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WQDCQEBIQEJAQt0aWNrZXRFeGlzdAMFBmlzc3VlcgUHZXZlbnRJZAUIdGlja2V0SWQJAAIBAhBUaWNrZXQgbm90IGZvdW5kBAphbW91bnRVc2VkCQEPZ2V0SW50ZWdlckJ5S2V5AQkBE2tleVRpY2tldEFtb3VudFVzZWQDBQZpc3N1ZXIFB2V2ZW50SWQFCHRpY2tldElkBAxtYXhVc2luZ1RpbWUJAQ9nZXRJbnRlZ2VyQnlLZXkBCQEPa2V5VGlja2V0TWF4VXNlAwUGaXNzdWVyBQdldmVudElkBQh0aWNrZXRJZAMJAAACBQxtYXhVc2luZ1RpbWUFCmFtb3VudFVzZWQJAAIBCQCsAgIJAKwCAgIMVGlja2V0IHVzZWQgCQCkAwEFCmFtb3VudFVzZWQCDiB0aW1lcyBhbHJlYWR5CQDMCAIJAQxJbnRlZ2VyRW50cnkCCQETa2V5VGlja2V0QW1vdW50VXNlZAMFBmlzc3VlcgUHZXZlbnRJZAUIdGlja2V0SWQJAGQCBQphbW91bnRVc2VkAAEJAMwIAgkBDlNjcmlwdFRyYW5zZmVyAwkBB0FkZHJlc3MBCQDZBAEFBmNhbGxlcgABCAUHcGF5bWVudAdhc3NldElkBQNuaWwAaIMwKg==", "height": 2288920, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 5gwopvTbjWqqHoJburCNDHWxg8YqJcaJ8uo6aQAJ16bk Next: FM3GR4mX8F3GfyxApi8R7fPotqqREwvNcJ9MR8GciHC Diff:
Old | New | Differences | |
---|---|---|---|
431 | 431 | then throw(checkUser) | |
432 | 432 | else if (!(isEventOwner(eventId, caller))) | |
433 | 433 | then throw("You are not the owner of this event") | |
434 | - | else if (!(ticketExist(caller, eventId, ticketId))) | |
435 | - | then throw("Ticket not found") | |
436 | - | else { | |
437 | - | let amountSold = getIntegerByKey(keyTicketSold(caller, eventId, ticketId)) | |
438 | - | if ((amountSold != 0)) | |
439 | - | then throw("Cannot delete ticket that sold already") | |
440 | - | else { | |
441 | - | let totalTicketTypeForEvent = getIntegerByKey(keyEventTotalTicketTypes(caller, eventId)) | |
434 | + | else { | |
435 | + | let amountSold = getIntegerByKey(keyTicketSold(caller, eventId, ticketId)) | |
436 | + | if ((amountSold != 0)) | |
437 | + | then throw("Cannot delete ticket that sold already") | |
438 | + | else { | |
439 | + | let totalTicketTypeForEvent = getIntegerByKey(keyEventTotalTicketTypes(caller, eventId)) | |
442 | 440 | [DeleteEntry(keyTicketName(caller, eventId, ticketId)), DeleteEntry(keyTicketDate(caller, eventId, ticketId)), DeleteEntry(keyTicketDesc(caller, eventId, ticketId)), DeleteEntry(keyTicketPrice(caller, eventId, ticketId)), DeleteEntry(keyTicketMaxAvailable(caller, eventId, ticketId)), DeleteEntry(keyTicketOnSale(caller, eventId, ticketId)), DeleteEntry(keyTicketMaxUse(caller, eventId, ticketId)), IntegerEntry(keyEventTotalTicketTypes(caller, eventId), (totalTicketTypeForEvent - 1))] | |
443 | - | ||
444 | - | ||
441 | + | } | |
442 | + | } | |
445 | 443 | } | |
446 | 444 | ||
447 | 445 | ||
448 | 446 | ||
449 | 447 | @Callable(i) | |
450 | 448 | func buyTicket (ticketId,eventId,issuer) = { | |
451 | - | let $ | |
452 | - | let id = $ | |
453 | - | let caller = $ | |
454 | - | let date = $ | |
449 | + | let $t01707217110 = idCallerDate(i) | |
450 | + | let id = $t01707217110._1 | |
451 | + | let caller = $t01707217110._2 | |
452 | + | let date = $t01707217110._3 | |
455 | 453 | let totalNFT = valueOrElse(getIntegerByKey("total_tickets_issued"), 0) | |
456 | 454 | if (!(isEventOwner(eventId, issuer))) | |
457 | 455 | then throw("Event ID and Issuer don't match") | |
471 | 469 | let amountSold = getIntegerByKey(keyTicketSold(issuer, eventId, ticketId)) | |
472 | 470 | let ticketPrice = getIntegerByKey(keyTicketPrice(issuer, eventId, ticketId)) | |
473 | 471 | let priceAssetId = toBase58String(signAssetId) | |
474 | - | let $ | |
475 | - | let amount = $ | |
476 | - | let assetId = $ | |
472 | + | let $t01795618030 = validatePriceAssetId(i, priceAssetId, ticketPrice) | |
473 | + | let amount = $t01795618030._1 | |
474 | + | let assetId = $t01795618030._2 | |
477 | 475 | let maxCanSell = getIntegerByKey(keyTicketMaxAvailable(issuer, eventId, ticketId)) | |
478 | 476 | let amountForSign = fraction(amount, signCut, 100) | |
479 | 477 | let amountForOrganizer = (amount - amountForSign) | |
509 | 507 | ||
510 | 508 | @Callable(i) | |
511 | 509 | func useTicket (eventId,issuer) = { | |
512 | - | let $ | |
513 | - | let id = $ | |
514 | - | let caller = $ | |
515 | - | let date = $ | |
516 | - | let $ | |
517 | - | let payment = $ | |
518 | - | let amount = $ | |
510 | + | let $t02030920347 = idCallerDate(i) | |
511 | + | let id = $t02030920347._1 | |
512 | + | let caller = $t02030920347._2 | |
513 | + | let date = $t02030920347._3 | |
514 | + | let $t02035320389 = isPayment(i) | |
515 | + | let payment = $t02035320389._1 | |
516 | + | let amount = $t02035320389._2 | |
519 | 517 | if (!(isDefined(payment.assetId))) | |
520 | 518 | then throw("Wrong asset attached") | |
521 | 519 | else { |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let VERSION = "1.0.0" | |
5 | 5 | ||
6 | 6 | func getStringByKey (key) = valueOrElse(getString(this, key), "") | |
7 | 7 | ||
8 | 8 | ||
9 | 9 | let userDapp = value(addressFromString(getStringByKey("conf_users_dapp"))) | |
10 | 10 | ||
11 | 11 | let feeReceiver = getStringByKey("conf_fee_receiver") | |
12 | 12 | ||
13 | 13 | let signAssetId = fromBase58String(getStringByKey("conf_accepted_asset_SIGN")) | |
14 | 14 | ||
15 | 15 | let chris = getStringByKey("conf_admin_1") | |
16 | 16 | ||
17 | 17 | func getIntegerByKey (key) = valueOrElse(getInteger(this, key), 0) | |
18 | 18 | ||
19 | 19 | ||
20 | 20 | func getBooleanByKey (key) = valueOrElse(getBoolean(this, key), false) | |
21 | 21 | ||
22 | 22 | ||
23 | 23 | let dappRunning = valueOrElse(getBoolean(userDapp, "conf_dapp_is_running"), true) | |
24 | 24 | ||
25 | 25 | let maintenanceMSG = valueOrElse(getString(userDapp, "conf_maintenance_msg"), "") | |
26 | 26 | ||
27 | 27 | let userSuspended = "SUSPENDED" | |
28 | 28 | ||
29 | 29 | let userUnregistered = "UNREGISTERED" | |
30 | 30 | ||
31 | 31 | func validateCID (cid) = if (contains(cid, "/")) | |
32 | 32 | then if (if ((76 > size(cid))) | |
33 | 33 | then (size(split(cid, "/")[0]) == 59) | |
34 | 34 | else false) | |
35 | 35 | then (16 > size(split(cid, "/")[1])) | |
36 | 36 | else false | |
37 | 37 | else false | |
38 | 38 | ||
39 | 39 | ||
40 | 40 | let signCut = 2 | |
41 | 41 | ||
42 | 42 | func keyUserStatus (caller) = ("user_status_" + caller) | |
43 | 43 | ||
44 | 44 | ||
45 | 45 | func keyEventOwnerByEventId (eventId) = ("get_event_owner_" + eventId) | |
46 | 46 | ||
47 | 47 | ||
48 | 48 | func keyEventAddedDate (caller,eventId) = ((("event_addedDate_" + eventId) + "_") + caller) | |
49 | 49 | ||
50 | 50 | ||
51 | 51 | func keyEventDate (caller,eventId) = ((("event_date_" + eventId) + "_") + caller) | |
52 | 52 | ||
53 | 53 | ||
54 | 54 | func keyEventName (caller,eventId) = ((("event_name_" + eventId) + "_") + caller) | |
55 | 55 | ||
56 | 56 | ||
57 | 57 | func keyEventDesc (caller,eventId) = ((("event_desc_" + eventId) + "_") + caller) | |
58 | 58 | ||
59 | 59 | ||
60 | 60 | func keyEventDisplayCid (caller,eventId) = ((("event_displayCid_" + eventId) + "_") + caller) | |
61 | 61 | ||
62 | 62 | ||
63 | 63 | func keyEventTags (caller,eventId) = ((("event_tags_" + eventId) + "_") + caller) | |
64 | 64 | ||
65 | 65 | ||
66 | 66 | func keyEventFlag (caller,eventId) = ((("event_flag_" + eventId) + "_") + caller) | |
67 | 67 | ||
68 | 68 | ||
69 | 69 | func keyEventNote (caller,eventId) = ((("event_note_" + eventId) + "_") + caller) | |
70 | 70 | ||
71 | 71 | ||
72 | 72 | func keyEventCrawler (caller,eventId) = ((("event_crawlerCid_" + eventId) + "_") + caller) | |
73 | 73 | ||
74 | 74 | ||
75 | 75 | func keyEventType (caller,eventId) = ((("event_type_" + eventId) + "_") + caller) | |
76 | 76 | ||
77 | 77 | ||
78 | 78 | func keyEventTotalTicketTypes (caller,eventId) = ((("event_totalTicketTypes_" + eventId) + "_") + caller) | |
79 | 79 | ||
80 | 80 | ||
81 | 81 | func keyEventTotalTicketsIssued (caller,eventId) = ((("event_totalIssued_" + eventId) + "_") + caller) | |
82 | 82 | ||
83 | 83 | ||
84 | 84 | func keyEventCanceled (caller,eventId) = ((("event_canceled_" + eventId) + "_") + caller) | |
85 | 85 | ||
86 | 86 | ||
87 | 87 | func keyEventCanceledReason (caller,eventId) = ((("event_canceledReason_" + eventId) + "_") + caller) | |
88 | 88 | ||
89 | 89 | ||
90 | 90 | func keyTicketName (caller,eventId,ticketId) = ((((("ticket_name_" + eventId) + "_") + caller) + "_") + ticketId) | |
91 | 91 | ||
92 | 92 | ||
93 | 93 | func keyTicketDesc (caller,eventId,ticketId) = ((((("ticket_desc_" + eventId) + "_") + caller) + "_") + ticketId) | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | func keyTicketPrice (caller,eventId,ticketId) = ((((("ticket_price_" + eventId) + "_") + caller) + "_") + ticketId) | |
97 | 97 | ||
98 | 98 | ||
99 | 99 | func keyTicketDate (caller,eventId,ticketId) = ((((("ticket_date_" + eventId) + "_") + caller) + "_") + ticketId) | |
100 | 100 | ||
101 | 101 | ||
102 | 102 | func keyTicketMaxAvailable (caller,eventId,ticketId) = ((((("ticket_maxAvailable_" + eventId) + "_") + caller) + "_") + ticketId) | |
103 | 103 | ||
104 | 104 | ||
105 | 105 | func keyTicketSold (caller,eventId,ticketId) = ((((("ticket_sold_" + eventId) + "_") + caller) + "_") + ticketId) | |
106 | 106 | ||
107 | 107 | ||
108 | 108 | func keyTicketOnSale (caller,eventId,ticketId) = ((((("ticket_onSale_" + eventId) + "_") + caller) + "_") + ticketId) | |
109 | 109 | ||
110 | 110 | ||
111 | 111 | func keyTicketAmountUsed (caller,eventId,ticketId) = ((((("ticket_amountUsed_" + eventId) + "_") + caller) + "_") + ticketId) | |
112 | 112 | ||
113 | 113 | ||
114 | 114 | func keyTicketMaxUse (caller,eventId,ticketId) = ((((("ticket_maxUse_" + eventId) + "_") + caller) + "_") + ticketId) | |
115 | 115 | ||
116 | 116 | ||
117 | 117 | func keyTicketTotalIssued (caller,eventId,ticketId) = ((((("ticket_totalIssued_" + eventId) + "_") + caller) + "_") + ticketId) | |
118 | 118 | ||
119 | 119 | ||
120 | 120 | func validateString (str,max) = if ((size(str) == 0)) | |
121 | 121 | then throw("Field cannot be is empty") | |
122 | 122 | else if ((size(str) > max)) | |
123 | 123 | then throw((str + " is too long")) | |
124 | 124 | else true | |
125 | 125 | ||
126 | 126 | ||
127 | 127 | func validateInt (num) = (0 > num) | |
128 | 128 | ||
129 | 129 | ||
130 | 130 | func getEventOwnerByEventId (eventId) = valueOrElse(getString(this, keyEventOwnerByEventId(eventId)), "") | |
131 | 131 | ||
132 | 132 | ||
133 | 133 | func validateUser (caller) = { | |
134 | 134 | let userStatus = valueOrElse(getString(userDapp, keyUserStatus(caller)), userUnregistered) | |
135 | 135 | if ((userStatus == userUnregistered)) | |
136 | 136 | then "Register this account first with \"Account\" tab" | |
137 | 137 | else if ((userStatus == userSuspended)) | |
138 | 138 | then "Account suspended" | |
139 | 139 | else "" | |
140 | 140 | } | |
141 | 141 | ||
142 | 142 | ||
143 | 143 | func validateType (type) = containsElement(["online", "offline", "both"], type) | |
144 | 144 | ||
145 | 145 | ||
146 | 146 | func validateEventData (caller,cidDisplay,name,description,tags,type,date) = { | |
147 | 147 | let checkUser = validateUser(caller) | |
148 | 148 | if ((checkUser != "")) | |
149 | 149 | then throw(checkUser) | |
150 | 150 | else if ((size(cidDisplay) == 0)) | |
151 | 151 | then throw("Display CID cannot be empty") | |
152 | 152 | else if (!(validateCID(cidDisplay))) | |
153 | 153 | then throw("Problem with CID") | |
154 | 154 | else if (!(validateString(name, 200))) | |
155 | 155 | then throw("100 Char. max name") | |
156 | 156 | else if (!(validateType(type))) | |
157 | 157 | then throw("Wrong event type") | |
158 | 158 | else if (!(validateString(description, 1000))) | |
159 | 159 | then throw("1000 Char. max description") | |
160 | 160 | else if (!(validateString(date, 1000))) | |
161 | 161 | then throw("1000 Char. max date") | |
162 | 162 | else if ((size(split(tags, ",")) > 5)) | |
163 | 163 | then throw("5 tags max.") | |
164 | 164 | else "" | |
165 | 165 | } | |
166 | 166 | ||
167 | 167 | ||
168 | 168 | func validateTicketData (eventId,caller,name,description,price,maxAvailable,maxUse) = { | |
169 | 169 | let checkUser = validateUser(caller) | |
170 | 170 | if ((checkUser != "")) | |
171 | 171 | then throw(checkUser) | |
172 | 172 | else if (!(validateString(name, 200))) | |
173 | 173 | then throw("100 Char. max name") | |
174 | 174 | else if (!(validateString(description, 1000))) | |
175 | 175 | then throw("1000 Char. max description") | |
176 | 176 | else if (if (if (validateInt(price)) | |
177 | 177 | then true | |
178 | 178 | else validateInt(maxUse)) | |
179 | 179 | then true | |
180 | 180 | else validateInt(maxAvailable)) | |
181 | 181 | then throw("Positive amount only") | |
182 | 182 | else if (!(validateString(description, 1000))) | |
183 | 183 | then throw("1000 Char. max description") | |
184 | 184 | else "" | |
185 | 185 | } | |
186 | 186 | ||
187 | 187 | ||
188 | 188 | func idCallerDate (i) = if (!(dappRunning)) | |
189 | 189 | then throw(maintenanceMSG) | |
190 | 190 | else $Tuple3(toBase58String(i.transactionId), toBase58String(i.caller.bytes), lastBlock.timestamp) | |
191 | 191 | ||
192 | 192 | ||
193 | 193 | func isPayment (i) = if ((size(i.payments) == 0)) | |
194 | 194 | then throw("No payment attached") | |
195 | 195 | else { | |
196 | 196 | let payment = value(i.payments[0]) | |
197 | 197 | let amount = value(payment.amount) | |
198 | 198 | $Tuple2(payment, amount) | |
199 | 199 | } | |
200 | 200 | ||
201 | 201 | ||
202 | 202 | func validatePriceAssetId (i,priceAssetId,artworkPrice) = { | |
203 | 203 | let $t067396775 = isPayment(i) | |
204 | 204 | let payment = $t067396775._1 | |
205 | 205 | let amount = $t067396775._2 | |
206 | 206 | if (!(isDefined(payment.assetId))) | |
207 | 207 | then throw("Wrong asset attached") | |
208 | 208 | else { | |
209 | 209 | let assetId = if (if ((size(priceAssetId) > 0)) | |
210 | 210 | then (toBase58String(value(payment.assetId)) == priceAssetId) | |
211 | 211 | else false) | |
212 | 212 | then payment.assetId | |
213 | 213 | else throw("Wrong asset attached") | |
214 | 214 | if ((artworkPrice != amount)) | |
215 | 215 | then throw("Payment amount don't match") | |
216 | 216 | else $Tuple2(amount, assetId) | |
217 | 217 | } | |
218 | 218 | } | |
219 | 219 | ||
220 | 220 | ||
221 | 221 | func isEventOwner (eventId,caller) = { | |
222 | 222 | let eventOwner = getEventOwnerByEventId(eventId) | |
223 | 223 | if ((eventOwner == "")) | |
224 | 224 | then throw("Event not found") | |
225 | 225 | else (eventOwner == caller) | |
226 | 226 | } | |
227 | 227 | ||
228 | 228 | ||
229 | 229 | func ticketExist (caller,eventId,ticketId) = { | |
230 | 230 | let ticket = getStringByKey(keyTicketName(caller, eventId, ticketId)) | |
231 | 231 | (size(ticket) != 0) | |
232 | 232 | } | |
233 | 233 | ||
234 | 234 | ||
235 | 235 | func eventIsCanceled (issuer,eventId) = getBooleanByKey(keyEventCanceled(issuer, eventId)) | |
236 | 236 | ||
237 | 237 | ||
238 | 238 | @Callable(invoke) | |
239 | 239 | func setConf (key,val) = { | |
240 | 240 | let caller = toString(invoke.caller) | |
241 | 241 | if (containsElement([chris, toString(this)], caller)) | |
242 | 242 | then if (contains(key, "conf_")) | |
243 | 243 | then [StringEntry(key, val)] | |
244 | 244 | else throw("Entries starting with conf_ only") | |
245 | 245 | else throw("You are not allowed to change this") | |
246 | 246 | } | |
247 | 247 | ||
248 | 248 | ||
249 | 249 | ||
250 | 250 | @Callable(i) | |
251 | 251 | func addEvent (name,description,tags,cidDisplay,crawler,type,date) = { | |
252 | 252 | let $t081188167 = idCallerDate(i) | |
253 | 253 | let eventId = $t081188167._1 | |
254 | 254 | let caller = $t081188167._2 | |
255 | 255 | let addedDate = $t081188167._3 | |
256 | 256 | let checkUser = validateUser(caller) | |
257 | 257 | if ((checkUser != "")) | |
258 | 258 | then throw(checkUser) | |
259 | 259 | else { | |
260 | 260 | let validateEvent = validateEventData(caller, cidDisplay, name, description, tags, type, date) | |
261 | 261 | if ((validateEvent != "")) | |
262 | 262 | then throw("Something went wrong!") | |
263 | 263 | else [IntegerEntry(keyEventAddedDate(caller, eventId), addedDate), StringEntry(keyEventDate(caller, eventId), date), StringEntry(keyEventName(caller, eventId), name), StringEntry(keyEventDesc(caller, eventId), description), StringEntry(keyEventDisplayCid(caller, eventId), cidDisplay), StringEntry(keyEventTags(caller, eventId), tags), StringEntry(keyEventCrawler(caller, eventId), crawler), StringEntry(keyEventType(caller, eventId), type), IntegerEntry(keyEventTotalTicketsIssued(caller, eventId), 0), BooleanEntry(keyEventCanceled(caller, eventId), false), StringEntry(keyEventOwnerByEventId(eventId), caller)] | |
264 | 264 | } | |
265 | 265 | } | |
266 | 266 | ||
267 | 267 | ||
268 | 268 | ||
269 | 269 | @Callable(i) | |
270 | 270 | func editEvent (eventId,name,description,tags,cidDisplay,crawler,type,date) = if (!(dappRunning)) | |
271 | 271 | then throw(maintenanceMSG) | |
272 | 272 | else { | |
273 | 273 | let caller = toBase58String(i.caller.bytes) | |
274 | 274 | let checkUser = validateUser(caller) | |
275 | 275 | if ((checkUser != "")) | |
276 | 276 | then throw(checkUser) | |
277 | 277 | else { | |
278 | 278 | let validateEvent = validateEventData(caller, cidDisplay, name, description, tags, type, date) | |
279 | 279 | if ((validateEvent != "")) | |
280 | 280 | then throw("Something went wrong!") | |
281 | 281 | else { | |
282 | 282 | let entryExist = getStringByKey(keyEventName(caller, eventId)) | |
283 | 283 | if ((entryExist == "")) | |
284 | 284 | then throw("Entry not found") | |
285 | 285 | else { | |
286 | 286 | let flag = getStringByKey(keyEventFlag(caller, eventId)) | |
287 | 287 | if ((flag == "ILLEGAL")) | |
288 | 288 | then throw("Cannot update ILLEGAL Event") | |
289 | 289 | else [StringEntry(keyEventName(caller, eventId), name), StringEntry(keyEventDate(caller, eventId), date), StringEntry(keyEventDesc(caller, eventId), description), StringEntry(keyEventTags(caller, eventId), tags), StringEntry(keyEventType(caller, eventId), type), StringEntry(keyEventCrawler(caller, eventId), crawler)] | |
290 | 290 | } | |
291 | 291 | } | |
292 | 292 | } | |
293 | 293 | } | |
294 | 294 | ||
295 | 295 | ||
296 | 296 | ||
297 | 297 | @Callable(i) | |
298 | 298 | func deleteEvent (eventId) = { | |
299 | 299 | let $t01053110575 = idCallerDate(i) | |
300 | 300 | let id = $t01053110575._1 | |
301 | 301 | let caller = $t01053110575._2 | |
302 | 302 | let addedDate = $t01053110575._3 | |
303 | 303 | let checkUser = validateUser(caller) | |
304 | 304 | if ((checkUser != "")) | |
305 | 305 | then throw(checkUser) | |
306 | 306 | else if (!(isEventOwner(eventId, caller))) | |
307 | 307 | then throw("You are not the owner of this event") | |
308 | 308 | else { | |
309 | 309 | let eventTotalNFT = getIntegerByKey(keyEventTotalTicketsIssued(caller, eventId)) | |
310 | 310 | if ((eventTotalNFT != 0)) | |
311 | 311 | then throw("Cannot delete event with already sold tickets") | |
312 | 312 | else { | |
313 | 313 | let totalTicketTypeForEvent = getIntegerByKey(keyEventTotalTicketTypes(caller, eventId)) | |
314 | 314 | if ((totalTicketTypeForEvent > 0)) | |
315 | 315 | then throw("Delete all tickets first") | |
316 | 316 | else [DeleteEntry(keyEventAddedDate(caller, eventId)), DeleteEntry(keyEventDate(caller, eventId)), DeleteEntry(keyEventName(caller, eventId)), DeleteEntry(keyEventDesc(caller, eventId)), DeleteEntry(keyEventDisplayCid(caller, eventId)), DeleteEntry(keyEventTags(caller, eventId)), DeleteEntry(keyEventCrawler(caller, eventId)), DeleteEntry(keyEventType(caller, eventId)), DeleteEntry(keyEventTotalTicketsIssued(caller, eventId)), DeleteEntry(keyEventCanceled(caller, eventId)), DeleteEntry(keyEventOwnerByEventId(eventId))] | |
317 | 317 | } | |
318 | 318 | } | |
319 | 319 | } | |
320 | 320 | ||
321 | 321 | ||
322 | 322 | ||
323 | 323 | @Callable(i) | |
324 | 324 | func cancelEvent (eventId,reason) = { | |
325 | 325 | let $t01190411948 = idCallerDate(i) | |
326 | 326 | let id = $t01190411948._1 | |
327 | 327 | let caller = $t01190411948._2 | |
328 | 328 | let addedDate = $t01190411948._3 | |
329 | 329 | let checkUser = validateUser(caller) | |
330 | 330 | if ((checkUser != "")) | |
331 | 331 | then throw(checkUser) | |
332 | 332 | else if (!(isEventOwner(eventId, caller))) | |
333 | 333 | then throw("You are not the owner of this event") | |
334 | 334 | else [BooleanEntry(keyEventCanceled(caller, eventId), true), StringEntry(keyEventCanceledReason(caller, eventId), reason)] | |
335 | 335 | } | |
336 | 336 | ||
337 | 337 | ||
338 | 338 | ||
339 | 339 | @Callable(i) | |
340 | 340 | func flagEvent (eventId,addr,flag,note) = { | |
341 | 341 | let $t01238312416 = idCallerDate(i) | |
342 | 342 | let id = $t01238312416._1 | |
343 | 343 | let caller = $t01238312416._2 | |
344 | 344 | if (containsElement([chris, toString(this)], caller)) | |
345 | 345 | then if (containsElement(["", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
346 | 346 | then [StringEntry(keyEventFlag(addr, eventId), flag), StringEntry(keyEventNote(addr, eventId), note)] | |
347 | 347 | else throw(("Unknow status " + flag)) | |
348 | 348 | else throw("You are not allowed") | |
349 | 349 | } | |
350 | 350 | ||
351 | 351 | ||
352 | 352 | ||
353 | 353 | @Callable(i) | |
354 | 354 | func addTicket (eventId,name,description,price,maxAvailable,MaxUse) = { | |
355 | 355 | let $t01291712957 = idCallerDate(i) | |
356 | 356 | let id = $t01291712957._1 | |
357 | 357 | let caller = $t01291712957._2 | |
358 | 358 | let date = $t01291712957._3 | |
359 | 359 | let checkUser = validateUser(caller) | |
360 | 360 | if ((checkUser != "")) | |
361 | 361 | then throw(checkUser) | |
362 | 362 | else if (eventIsCanceled(caller, eventId)) | |
363 | 363 | then throw("Event have been canceled") | |
364 | 364 | else if (!(isEventOwner(eventId, caller))) | |
365 | 365 | then throw("You are not the owner of this event") | |
366 | 366 | else { | |
367 | 367 | let validateTicket = validateTicketData(eventId, caller, name, description, price, maxAvailable, MaxUse) | |
368 | 368 | if ((validateTicket != "")) | |
369 | 369 | then throw("Something went wrong!") | |
370 | 370 | else { | |
371 | 371 | let totalTicketTypeForEvent = getIntegerByKey(keyEventTotalTicketTypes(caller, eventId)) | |
372 | 372 | [StringEntry(keyTicketName(caller, eventId, id), name), IntegerEntry(keyTicketDate(caller, eventId, id), date), StringEntry(keyTicketDesc(caller, eventId, id), description), IntegerEntry(keyTicketPrice(caller, eventId, id), price), IntegerEntry(keyTicketMaxAvailable(caller, eventId, id), maxAvailable), BooleanEntry(keyTicketOnSale(caller, eventId, id), true), IntegerEntry(keyTicketMaxUse(caller, eventId, id), MaxUse), IntegerEntry(keyTicketTotalIssued(caller, eventId, id), 0), IntegerEntry(keyEventTotalTicketTypes(caller, eventId), (totalTicketTypeForEvent + 1))] | |
373 | 373 | } | |
374 | 374 | } | |
375 | 375 | } | |
376 | 376 | ||
377 | 377 | ||
378 | 378 | ||
379 | 379 | @Callable(i) | |
380 | 380 | func editTicket (ticketId,eventId,name,description,price,maxAvailable,maxUse) = { | |
381 | 381 | let $t01429214332 = idCallerDate(i) | |
382 | 382 | let id = $t01429214332._1 | |
383 | 383 | let caller = $t01429214332._2 | |
384 | 384 | let date = $t01429214332._3 | |
385 | 385 | let checkUser = validateUser(caller) | |
386 | 386 | if ((checkUser != "")) | |
387 | 387 | then throw(checkUser) | |
388 | 388 | else if (!(isEventOwner(eventId, caller))) | |
389 | 389 | then throw("You are not the owner of this event") | |
390 | 390 | else if (!(ticketExist(caller, eventId, ticketId))) | |
391 | 391 | then throw("Ticket not found") | |
392 | 392 | else { | |
393 | 393 | let validateTicket = validateTicketData(eventId, caller, name, description, price, maxAvailable, maxUse) | |
394 | 394 | if ((validateTicket != "")) | |
395 | 395 | then throw("Something went wrong!") | |
396 | 396 | else { | |
397 | 397 | let ticketSold = valueOrElse(getInteger(keyTicketSold(caller, eventId, ticketId)), 0) | |
398 | 398 | if ((ticketSold > maxAvailable)) | |
399 | 399 | then throw("Max tickets available cannot be lower than amount already sold") | |
400 | 400 | else [StringEntry(keyTicketName(caller, eventId, ticketId), name), StringEntry(keyTicketDesc(caller, eventId, ticketId), description), IntegerEntry(keyTicketPrice(caller, eventId, ticketId), price), IntegerEntry(keyTicketMaxAvailable(caller, eventId, ticketId), maxAvailable), IntegerEntry(keyTicketMaxUse(caller, eventId, id), maxUse)] | |
401 | 401 | } | |
402 | 402 | } | |
403 | 403 | } | |
404 | 404 | ||
405 | 405 | ||
406 | 406 | ||
407 | 407 | @Callable(i) | |
408 | 408 | func pauseTicketSale (eventId,ticketId,status) = { | |
409 | 409 | let $t01546115501 = idCallerDate(i) | |
410 | 410 | let id = $t01546115501._1 | |
411 | 411 | let caller = $t01546115501._2 | |
412 | 412 | let date = $t01546115501._3 | |
413 | 413 | let checkUser = validateUser(caller) | |
414 | 414 | if ((checkUser != "")) | |
415 | 415 | then throw(checkUser) | |
416 | 416 | else if (!(isEventOwner(eventId, caller))) | |
417 | 417 | then throw("You are not the owner of this event") | |
418 | 418 | else [BooleanEntry(keyTicketOnSale(caller, eventId, id), status)] | |
419 | 419 | } | |
420 | 420 | ||
421 | 421 | ||
422 | 422 | ||
423 | 423 | @Callable(i) | |
424 | 424 | func deleteTicket (ticketId,eventId) = { | |
425 | 425 | let $t01587515915 = idCallerDate(i) | |
426 | 426 | let id = $t01587515915._1 | |
427 | 427 | let caller = $t01587515915._2 | |
428 | 428 | let date = $t01587515915._3 | |
429 | 429 | let checkUser = validateUser(caller) | |
430 | 430 | if ((checkUser != "")) | |
431 | 431 | then throw(checkUser) | |
432 | 432 | else if (!(isEventOwner(eventId, caller))) | |
433 | 433 | then throw("You are not the owner of this event") | |
434 | - | else if (!(ticketExist(caller, eventId, ticketId))) | |
435 | - | then throw("Ticket not found") | |
436 | - | else { | |
437 | - | let amountSold = getIntegerByKey(keyTicketSold(caller, eventId, ticketId)) | |
438 | - | if ((amountSold != 0)) | |
439 | - | then throw("Cannot delete ticket that sold already") | |
440 | - | else { | |
441 | - | let totalTicketTypeForEvent = getIntegerByKey(keyEventTotalTicketTypes(caller, eventId)) | |
434 | + | else { | |
435 | + | let amountSold = getIntegerByKey(keyTicketSold(caller, eventId, ticketId)) | |
436 | + | if ((amountSold != 0)) | |
437 | + | then throw("Cannot delete ticket that sold already") | |
438 | + | else { | |
439 | + | let totalTicketTypeForEvent = getIntegerByKey(keyEventTotalTicketTypes(caller, eventId)) | |
442 | 440 | [DeleteEntry(keyTicketName(caller, eventId, ticketId)), DeleteEntry(keyTicketDate(caller, eventId, ticketId)), DeleteEntry(keyTicketDesc(caller, eventId, ticketId)), DeleteEntry(keyTicketPrice(caller, eventId, ticketId)), DeleteEntry(keyTicketMaxAvailable(caller, eventId, ticketId)), DeleteEntry(keyTicketOnSale(caller, eventId, ticketId)), DeleteEntry(keyTicketMaxUse(caller, eventId, ticketId)), IntegerEntry(keyEventTotalTicketTypes(caller, eventId), (totalTicketTypeForEvent - 1))] | |
443 | - | ||
444 | - | ||
441 | + | } | |
442 | + | } | |
445 | 443 | } | |
446 | 444 | ||
447 | 445 | ||
448 | 446 | ||
449 | 447 | @Callable(i) | |
450 | 448 | func buyTicket (ticketId,eventId,issuer) = { | |
451 | - | let $ | |
452 | - | let id = $ | |
453 | - | let caller = $ | |
454 | - | let date = $ | |
449 | + | let $t01707217110 = idCallerDate(i) | |
450 | + | let id = $t01707217110._1 | |
451 | + | let caller = $t01707217110._2 | |
452 | + | let date = $t01707217110._3 | |
455 | 453 | let totalNFT = valueOrElse(getIntegerByKey("total_tickets_issued"), 0) | |
456 | 454 | if (!(isEventOwner(eventId, issuer))) | |
457 | 455 | then throw("Event ID and Issuer don't match") | |
458 | 456 | else if (!(ticketExist(issuer, eventId, ticketId))) | |
459 | 457 | then throw("Ticket not found") | |
460 | 458 | else { | |
461 | 459 | let eventName = getStringByKey(keyEventName(issuer, eventId)) | |
462 | 460 | if ((eventName == "")) | |
463 | 461 | then throw("Art doesn't exist") | |
464 | 462 | else if (eventIsCanceled(issuer, eventId)) | |
465 | 463 | then throw("Event have been canceled") | |
466 | 464 | else { | |
467 | 465 | let isOnSale = getBooleanByKey(keyTicketOnSale(issuer, eventId, ticketId)) | |
468 | 466 | if (!(isOnSale)) | |
469 | 467 | then throw("Tickets not for sale") | |
470 | 468 | else { | |
471 | 469 | let amountSold = getIntegerByKey(keyTicketSold(issuer, eventId, ticketId)) | |
472 | 470 | let ticketPrice = getIntegerByKey(keyTicketPrice(issuer, eventId, ticketId)) | |
473 | 471 | let priceAssetId = toBase58String(signAssetId) | |
474 | - | let $ | |
475 | - | let amount = $ | |
476 | - | let assetId = $ | |
472 | + | let $t01795618030 = validatePriceAssetId(i, priceAssetId, ticketPrice) | |
473 | + | let amount = $t01795618030._1 | |
474 | + | let assetId = $t01795618030._2 | |
477 | 475 | let maxCanSell = getIntegerByKey(keyTicketMaxAvailable(issuer, eventId, ticketId)) | |
478 | 476 | let amountForSign = fraction(amount, signCut, 100) | |
479 | 477 | let amountForOrganizer = (amount - amountForSign) | |
480 | 478 | if ((amountSold == maxCanSell)) | |
481 | 479 | then throw("Art sold out") | |
482 | 480 | else { | |
483 | 481 | let newAmountSold = (amountSold + 1) | |
484 | 482 | let issueMeta = ((((((((((("Organizer: " + issuer) + ", | |
485 | 483 | EventID: ") + eventId) + ", | |
486 | 484 | TicketID: ") + ticketId) + ", | |
487 | 485 | EventName: ") + eventName) + ", | |
488 | 486 | Issue: ") + toString(newAmountSold)) + "/") + toString(maxCanSell)) | |
489 | 487 | let issueNFT = Issue(("ST_" + toString((totalNFT + 1))), issueMeta, 1, 0, false) | |
490 | 488 | let idNFT = calculateAssetId(issueNFT) | |
491 | 489 | let sellStatus = if ((newAmountSold == maxCanSell)) | |
492 | 490 | then false | |
493 | 491 | else true | |
494 | 492 | let receiveNFT = i.caller | |
495 | 493 | let soldKey = ((((((((("ticket_sold_" + toString(newAmountSold)) + "_of_") + toString(maxCanSell)) + "_") + eventId) + "_") + issuer) + "_") + ticketId) | |
496 | 494 | let soldValue = ((((((((toString(receiveNFT) + "_") + toString(date)) + "_") + id) + "_") + toString(amount)) + "_") + toBase58String(idNFT)) | |
497 | 495 | let soldData = StringEntry(soldKey, soldValue) | |
498 | 496 | let eventTotalNFT = getIntegerByKey(keyEventTotalTicketsIssued(issuer, eventId)) | |
499 | 497 | let ticketTotalNFT = getIntegerByKey(keyTicketTotalIssued(issuer, eventId, ticketId)) | |
500 | 498 | let buyRes = [IntegerEntry(keyTicketSold(issuer, eventId, ticketId), newAmountSold), StringEntry(("nft_" + toBase58String(idNFT)), soldKey), IntegerEntry("total_nft_issued", (totalNFT + 1)), IntegerEntry(keyEventTotalTicketsIssued(issuer, eventId), (eventTotalNFT + 1)), IntegerEntry(keyTicketTotalIssued(issuer, eventId, ticketId), (ticketTotalNFT + 1)), StringEntry((("ST_" + toString((totalNFT + 1))) + "_assetId"), toBase58String(idNFT)), BooleanEntry(keyTicketOnSale(issuer, eventId, ticketId), sellStatus), IntegerEntry(keyTicketAmountUsed(issuer, eventId, ticketId), 0), issueNFT, ScriptTransfer(Address(fromBase58String(issuer)), amountForOrganizer, assetId), ScriptTransfer(receiveNFT, 1, idNFT), ScriptTransfer(Address(fromBase58String(feeReceiver)), amountForSign, assetId)] | |
501 | 499 | soldData :: buyRes | |
502 | 500 | } | |
503 | 501 | } | |
504 | 502 | } | |
505 | 503 | } | |
506 | 504 | } | |
507 | 505 | ||
508 | 506 | ||
509 | 507 | ||
510 | 508 | @Callable(i) | |
511 | 509 | func useTicket (eventId,issuer) = { | |
512 | - | let $ | |
513 | - | let id = $ | |
514 | - | let caller = $ | |
515 | - | let date = $ | |
516 | - | let $ | |
517 | - | let payment = $ | |
518 | - | let amount = $ | |
510 | + | let $t02030920347 = idCallerDate(i) | |
511 | + | let id = $t02030920347._1 | |
512 | + | let caller = $t02030920347._2 | |
513 | + | let date = $t02030920347._3 | |
514 | + | let $t02035320389 = isPayment(i) | |
515 | + | let payment = $t02035320389._1 | |
516 | + | let amount = $t02035320389._2 | |
519 | 517 | if (!(isDefined(payment.assetId))) | |
520 | 518 | then throw("Wrong asset attached") | |
521 | 519 | else { | |
522 | 520 | let ticketId = toBase58String(value(payment.assetId)) | |
523 | 521 | if (!(ticketExist(issuer, eventId, ticketId))) | |
524 | 522 | then throw("Ticket not found") | |
525 | 523 | else { | |
526 | 524 | let amountUsed = getIntegerByKey(keyTicketAmountUsed(issuer, eventId, ticketId)) | |
527 | 525 | let maxUsingTime = getIntegerByKey(keyTicketMaxUse(issuer, eventId, ticketId)) | |
528 | 526 | if ((maxUsingTime == amountUsed)) | |
529 | 527 | then throw((("Ticket used " + toString(amountUsed)) + " times already")) | |
530 | 528 | else [IntegerEntry(keyTicketAmountUsed(issuer, eventId, ticketId), (amountUsed + 1)), ScriptTransfer(Address(fromBase58String(caller)), 1, payment.assetId)] | |
531 | 529 | } | |
532 | 530 | } | |
533 | 531 | } | |
534 | 532 | ||
535 | 533 |
github/deemru/w8io/fabc49c 61.19 ms ◑