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