tx · HsNCuz8ZgBKaAUiVbFo9Fq6WTUGsNFtAzRjPjKk7UtnS 3N9cGtX3t2bByXY5WjKGyZZKYAQ7Eb3sVzA: -0.01000000 Waves 2021.09.20 12:28 [1711187] smart account 3N9cGtX3t2bByXY5WjKGyZZKYAQ7Eb3sVzA > SELF 0.00000000 Waves
{ "type": 13, "id": "HsNCuz8ZgBKaAUiVbFo9Fq6WTUGsNFtAzRjPjKk7UtnS", "fee": 1000000, "feeAssetId": null, "timestamp": 1632130136868, "version": 2, "chainId": 84, "sender": "3N9cGtX3t2bByXY5WjKGyZZKYAQ7Eb3sVzA", "senderPublicKey": "HtkwjC6Vetf2dyWViSJiYEWZfMVob371f2qLR2HaLZBW", "proofs": [ "5XokNcKwPUMqqF7iZPcBUh6bx1dH6sm47RUPX6t7uuFJgY2X4iqVz7oduUYLjto3NshuYT6v7Emc2ENKacpzvNYL" ], "script": "base64:AAIFAAAAAAAAAD8IAhIFCgMBCAgSCQoHCAgICAgICBIJCgcIAQEICAEBEgQKAggIEgMKAQgSBAoCCAgSBgoECAgICBIFCgMICAgAAABOAAAAAAh1bml0VGVzdAcAAAAACW9yYWNsZUZlZQkBAAAABXZhbHVlAAAAAQkABCYAAAABAgAAACMzTXBaUWp6R29nbWlmY0VLZThtRGQ2cmliTDdueFQ5QUN5ZQAAAAALZmVlUmVjZWl2ZXICAAAAIzNONjV4THE4SmNDZWFFaVIxVEpRN2RCcVhCdkV5NkU0OFd6AAAAAAhjZXJ0RGFwcAIAAAAjM014Y1hyTmJNWktZYVNyaGNmZU1tMmhabkJlQ3UzeVJXc3cAAAAACHVzZXJEYXBwCQEAAAAFdmFsdWUAAAABCQAEJgAAAAECAAAAIzNOOWNRZ1pGUEhIVnU4d3FzbjJEa1FGZWhnM2g4Q05pb29BAAAAAA13aGl0ZWxpc3REYXBwCQEAAAAFdmFsdWUAAAABCQAEJgAAAAECAAAAIzNOOXhaWUdwek1GRFh2WHVjdG1VNnpWOHFTem0yWmZGMzFmAAAA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y3Rpb25UeXBlMgkBAAAAFGFjY2VwdEJpZFRyYWRpdGlvbmFsAAAABQUAAAABaQUAAAAFYXJ0SWQFAAAABmlzc3VlcgUAAAAFYmlkSWQFAAAACGJpZE93bmVyCQAAAgAAAAEJAAEsAAAAAgkAASwAAAACAgAAABZVbmtub3duIGF1Y3Rpb24gdHlwZSA6BQAAAAthdWN0aW9uVHlwZQIAAAAbLCBwbGVhc2UgY29udGFjdCB0aGUgYWRtaW5zAAAAAWkBAAAACWNhbmNlbEJpZAAAAAMAAAAFYXJ0SWQAAAAGaXNzdWVyAAAABWJpZElkBAAAAAthdWN0aW9uVHlwZQkBAAAADmdldFN0cmluZ0J5S2V5AAAAAQkBAAAADmtleUF1Y3Rpb25UeXBlAAAAAgUAAAAGaXNzdWVyBQAAAAVhcnRJZAMJAAAAAAAAAgUAAAALYXVjdGlvblR5cGUFAAAADGF1Y3Rpb25UeXBlMQkBAAAADWNhbmNlbEJpZEltcGwAAAAEBQAAAAFpBQAAAAVhcnRJZAUAAAAGaXNzdWVyBQAAAAViaWRJZAkBAAAAGGNhbmNlbEJpZEltcGxUcmFkaXRpb25hbAAAAAQFAAAAAWkFAAAABWFydElkBQAAAAZpc3N1ZXIFAAAABWJpZElkAAAAAGmYuHw=", "height": 1711187, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 5 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let unitTest = false | |
5 | + | ||
6 | + | let oracleFee = value(addressFromString("3MpZQjzGogmifcEKe8mDd6ribL7nxT9ACye")) | |
7 | + | ||
8 | + | let feeReceiver = "3N65xLq8JcCeaEiR1TJQ7dBqXBvEy6E48Wz" | |
9 | + | ||
10 | + | let certDapp = "3MxcXrNbMZKYaSrhcfeMm2hZnBeCu3yRWsw" | |
11 | + | ||
12 | + | let userDapp = value(addressFromString("3N9cQgZFPHHVu8wqsn2DkQFehg3h8CNiooA")) | |
13 | + | ||
14 | + | let whitelistDapp = value(addressFromString("3N9xZYGpzMFDXvXuctmU6zV8qSzm2ZfF31f")) | |
15 | + | ||
16 | + | let USDNAssetId = base58'132maRL3uF35tc2bpRih9D6MYq5DR6H28zkop786dKyu' | |
17 | + | ||
18 | + | let owners = ["3MvSKkqmLjNaJAYrteJB3Hnmu8r8g1sjpYF", "3N1Dhq5ZZyoojQisuTLusYjnGisqrxDwGLy"] | |
19 | + | ||
20 | + | let USDNFirstSellCut = 150 | |
21 | + | ||
22 | + | let USDNSecondSellCut = 30 | |
23 | + | ||
24 | + | let originalCreatorCut = 70 | |
25 | + | ||
26 | + | let dappRunning = valueOrElse(getBoolean(userDapp, "conf_dapp_is_running"), true) | |
27 | + | ||
28 | + | let maintenanceMSG = valueOrElse(getString(userDapp, "conf_maintenance_msg"), "") | |
29 | + | ||
30 | + | let userSuspended = "SUSPENDED" | |
31 | + | ||
32 | + | let userRemoved = "REMOVED" | |
33 | + | ||
34 | + | let userUnregistered = "UNREGISTERED" | |
35 | + | ||
36 | + | let userAllowed = "ALLOWED" | |
37 | + | ||
38 | + | let auctionType1 = "BIDTYPE" | |
39 | + | ||
40 | + | let auctionType2 = "TRADITIONAL" | |
41 | + | ||
42 | + | func getStringByKeyFromUsers (key) = valueOrElse(getString(userDapp, key), "") | |
43 | + | ||
44 | + | ||
45 | + | func getStringByKey (key) = valueOrElse(getString(this, key), "") | |
46 | + | ||
47 | + | ||
48 | + | func getIntegerByKeyFromOracle (key) = valueOrErrorMessage(getInteger(oracleFee, key), "Integer undefine or 0 in oracle") | |
49 | + | ||
50 | + | ||
51 | + | func getIntegerByKey (key) = valueOrElse(getInteger(this, key), 0) | |
52 | + | ||
53 | + | ||
54 | + | func checkWhitelist (key) = valueOrElse(getInteger(whitelistDapp, key), 0) | |
55 | + | ||
56 | + | ||
57 | + | func getBooleanByKey (key) = valueOrElse(getBoolean(this, key), false) | |
58 | + | ||
59 | + | ||
60 | + | func validateHash (hash) = (size(hash) == 64) | |
61 | + | ||
62 | + | ||
63 | + | func keyUserStatus (caller) = ("user_status_" + caller) | |
64 | + | ||
65 | + | ||
66 | + | func keyDate (caller,artId) = ((("art_date_" + artId) + "_") + caller) | |
67 | + | ||
68 | + | ||
69 | + | func keyName (caller,artId) = ((("art_name_" + artId) + "_") + caller) | |
70 | + | ||
71 | + | ||
72 | + | func keyDesc (caller,artId) = ((("art_desc_" + artId) + "_") + caller) | |
73 | + | ||
74 | + | ||
75 | + | func keyDisplayCid (caller,artId) = ((("art_display_cid_" + artId) + "_") + caller) | |
76 | + | ||
77 | + | ||
78 | + | func keyMaxMint (caller,artId) = ((("art_maxmint_" + artId) + "_") + caller) | |
79 | + | ||
80 | + | ||
81 | + | func keyMinPrice (caller,artId) = ((("art_minprice_" + artId) + "_") + caller) | |
82 | + | ||
83 | + | ||
84 | + | func keyHighestBidBidId (artId) = ("art_highestBidBidId_" + artId) | |
85 | + | ||
86 | + | ||
87 | + | func keyBidId (bidId) = ("bid_" + bidId) | |
88 | + | ||
89 | + | ||
90 | + | func keyDuration (caller,artId) = ((("art_duration_" + artId) + "_") + caller) | |
91 | + | ||
92 | + | ||
93 | + | func keyEndHeight (caller,artId) = ((("art_endheight_" + artId) + "_") + caller) | |
94 | + | ||
95 | + | ||
96 | + | func keyAuctionType (caller,artId) = ((("art_auctiontype_" + artId) + "_") + caller) | |
97 | + | ||
98 | + | ||
99 | + | func keyIssued (caller,artId) = ((("art_issued_" + artId) + "_") + caller) | |
100 | + | ||
101 | + | ||
102 | + | func KeyNftIssuer (nftId) = ("nft_issued_" + nftId) | |
103 | + | ||
104 | + | ||
105 | + | func keyOnSale (caller,artId) = ((("art_onsale_" + artId) + "_") + caller) | |
106 | + | ||
107 | + | ||
108 | + | func keyEntitlement (caller,artId) = ((("art_entitlement_" + artId) + "_") + caller) | |
109 | + | ||
110 | + | ||
111 | + | func keyTags (caller,artId) = ((("art_tags_" + artId) + "_") + caller) | |
112 | + | ||
113 | + | ||
114 | + | func keyType (caller,artId) = ((("art_type_" + artId) + "_") + caller) | |
115 | + | ||
116 | + | ||
117 | + | func keyPrice (caller,artId) = ((("art_price_" + artId) + "_") + caller) | |
118 | + | ||
119 | + | ||
120 | + | func keyAssetIdAccepted (caller,artId) = ((("art_assetAccepted_" + artId) + "_") + caller) | |
121 | + | ||
122 | + | ||
123 | + | func keyHashByTxidAddr (caller,txid) = ((("get_hashbytxidaddr_" + txid) + "_") + caller) | |
124 | + | ||
125 | + | ||
126 | + | func keyOwnerByHash (sha256Hash) = ("get_owner_by_hash_" + sha256Hash) | |
127 | + | ||
128 | + | ||
129 | + | func keyTxidByHashOwner (sha256Hash,caller) = ("get_txid_by_hash_owner_" + toBase58String(sha256_16Kb(toBytes((sha256Hash + caller))))) | |
130 | + | ||
131 | + | ||
132 | + | let currentCertificationPrice = getIntegerByKeyFromOracle(("certification_fee_" + toBase58String(USDNAssetId))) | |
133 | + | ||
134 | + | func getAmountByBidId (bidId) = valueOrElse(getIntegerByKey(keyBidId(bidId)), 0) | |
135 | + | ||
136 | + | ||
137 | + | func getAmountHighestBidByArtId (artId) = { | |
138 | + | let bidId = getStringByKey(keyHighestBidBidId(artId)) | |
139 | + | if ((bidId == "")) | |
140 | + | then 0 | |
141 | + | else getAmountByBidId(bidId) | |
142 | + | } | |
143 | + | ||
144 | + | ||
145 | + | func validateString (str,max) = if ((size(str) == 0)) | |
146 | + | then throw("Field cannot be is empty") | |
147 | + | else if ((size(str) > max)) | |
148 | + | then throw((str + " is too long")) | |
149 | + | else true | |
150 | + | ||
151 | + | ||
152 | + | func validateUser (caller) = { | |
153 | + | let userStatus = valueOrElse(getString(userDapp, keyUserStatus(caller)), userUnregistered) | |
154 | + | if (if ((userStatus == userUnregistered)) | |
155 | + | then true | |
156 | + | else (userStatus == userAllowed)) | |
157 | + | then "Register this account first with 'Account' tab" | |
158 | + | else if ((userStatus == userSuspended)) | |
159 | + | then "Account suspended" | |
160 | + | else if ((userStatus == userRemoved)) | |
161 | + | then "Account removed" | |
162 | + | else "" | |
163 | + | } | |
164 | + | ||
165 | + | ||
166 | + | func validateArtworkData (caller,cidDisplay,name,description,tags) = { | |
167 | + | let checkUser = validateUser(caller) | |
168 | + | if ((checkUser != "")) | |
169 | + | then throw(checkUser) | |
170 | + | else if ((size(cidDisplay) == 0)) | |
171 | + | then throw("Display CID cannot be empty") | |
172 | + | else if (!(validateString(name, 100))) | |
173 | + | then throw("100 Char. max name") | |
174 | + | else if (!(validateString(description, 1000))) | |
175 | + | then throw("1000 Char. max description") | |
176 | + | else if ((size(split(tags, ",")) > 5)) | |
177 | + | then throw("5 tags max.") | |
178 | + | else "" | |
179 | + | } | |
180 | + | ||
181 | + | ||
182 | + | func isPayment (i) = if ((size(i.payments) == 0)) | |
183 | + | then throw("No payment attached") | |
184 | + | else { | |
185 | + | let payment = value(i.payments[0]) | |
186 | + | let amount = value(payment.amount) | |
187 | + | $Tuple2(payment, amount) | |
188 | + | } | |
189 | + | ||
190 | + | ||
191 | + | func validatePayment (i) = { | |
192 | + | let t089829018 = isPayment(i) | |
193 | + | let payment = t089829018._1 | |
194 | + | let amount = t089829018._2 | |
195 | + | let assetId = if (if (isDefined(payment.assetId)) | |
196 | + | then (payment.assetId == USDNAssetId) | |
197 | + | else false) | |
198 | + | then payment.assetId | |
199 | + | else throw("Only USDN token accepted as transaction fee") | |
200 | + | if ((amount != currentCertificationPrice)) | |
201 | + | then throw(("Payment amount should be " + toString(currentCertificationPrice))) | |
202 | + | else $Tuple2(amount, assetId) | |
203 | + | } | |
204 | + | ||
205 | + | ||
206 | + | func isArtMinted (addrToUse,artId) = match getInteger(this, keyIssued(addrToUse, artId)) { | |
207 | + | case b: Int => | |
208 | + | if ((b != 0)) | |
209 | + | then true | |
210 | + | else false | |
211 | + | case _ => | |
212 | + | false | |
213 | + | } | |
214 | + | ||
215 | + | ||
216 | + | func validatePriceAssetId (i,priceAssetId,artworkPrice) = { | |
217 | + | let t096119647 = isPayment(i) | |
218 | + | let payment = t096119647._1 | |
219 | + | let amount = t096119647._2 | |
220 | + | let assetId = if (!(isDefined(payment.assetId))) | |
221 | + | then throw("Wrong asset id") | |
222 | + | else if (if ((size(priceAssetId) > 0)) | |
223 | + | then (toBase58String(value(payment.assetId)) == priceAssetId) | |
224 | + | else false) | |
225 | + | then payment.assetId | |
226 | + | else throw("Wrong asset id") | |
227 | + | if (if ((assetId == unit)) | |
228 | + | then (priceAssetId != "") | |
229 | + | else false) | |
230 | + | then throw("Wrong asset id") | |
231 | + | else if ((artworkPrice != amount)) | |
232 | + | then throw(((("Payment don't match " + toString(artworkPrice)) + " ") + toString(amount))) | |
233 | + | else $Tuple2(amount, assetId) | |
234 | + | } | |
235 | + | ||
236 | + | ||
237 | + | func acceptedAssetIds (assetId) = if ((assetId != toBase58String(USDNAssetId))) | |
238 | + | then throw("Only USDN accepted") | |
239 | + | else true | |
240 | + | ||
241 | + | ||
242 | + | func validateMinSell (assetId,price) = { | |
243 | + | let minSellSconex = if (unitTest) | |
244 | + | then 1 | |
245 | + | else (currentCertificationPrice * 2) | |
246 | + | if (if (if ((assetId == toBase58String(USDNAssetId))) | |
247 | + | then (minSellSconex > price) | |
248 | + | else false) | |
249 | + | then (price != 0) | |
250 | + | else false) | |
251 | + | then throw(("Wrong minimum sell price " + toString(minSellSconex))) | |
252 | + | else true | |
253 | + | } | |
254 | + | ||
255 | + | ||
256 | + | func getBidAssetId (assetId) = if ((assetId == "WAVES")) | |
257 | + | then throw("Only USDN is accepted!") | |
258 | + | else fromBase58String(assetId) | |
259 | + | ||
260 | + | ||
261 | + | func getPriceAssetIdFromBid (bidDataKey) = { | |
262 | + | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
263 | + | if ((bidData == "")) | |
264 | + | then throw("Bid not found") | |
265 | + | else { | |
266 | + | let bidDataArr = split(bidData, "_") | |
267 | + | let bidAmount = parseIntValue(bidDataArr[1]) | |
268 | + | let bidAssetId = getBidAssetId(bidDataArr[0]) | |
269 | + | if ((0 >= bidAmount)) | |
270 | + | then throw("Wrong amount") | |
271 | + | else $Tuple2(bidAmount, bidAssetId) | |
272 | + | } | |
273 | + | } | |
274 | + | ||
275 | + | ||
276 | + | func idCallerDate (i) = if (!(dappRunning)) | |
277 | + | then throw(maintenanceMSG) | |
278 | + | else $Tuple3(toBase58String(i.transactionId), toBase58String(i.caller.bytes), lastBlock.timestamp) | |
279 | + | ||
280 | + | ||
281 | + | func isBidCheck (i,issuer,bidOwner,bidId) = if (if (if ((toBase58String(i.caller.bytes) == issuer)) | |
282 | + | then (bidOwner != "") | |
283 | + | else false) | |
284 | + | then (bidId != "") | |
285 | + | else false) | |
286 | + | then true | |
287 | + | else false | |
288 | + | ||
289 | + | ||
290 | + | func getArtData (i,issuer,artId,isBid) = { | |
291 | + | let callerIsIssuer = (toBase58String(i.caller.bytes) == issuer) | |
292 | + | let totalNFT = getIntegerByKey("total_nft_issued") | |
293 | + | let artworkName = getStringByKey(keyName(issuer, artId)) | |
294 | + | if ((artworkName == "")) | |
295 | + | then throw("Art doesn't exist") | |
296 | + | else { | |
297 | + | let isOnSale = getBooleanByKey(keyOnSale(issuer, artId)) | |
298 | + | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
299 | + | let artworkPrice = valueOrElse(getIntegerByKey(keyPrice(issuer, artId)), (currentCertificationPrice * 2)) | |
300 | + | let priceAssetId = if (callerIsIssuer) | |
301 | + | then toBase58String(USDNAssetId) | |
302 | + | else getStringByKey(keyAssetIdAccepted(issuer, artId)) | |
303 | + | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
304 | + | if (if (if (!(isBid)) | |
305 | + | then !(callerIsIssuer) | |
306 | + | else false) | |
307 | + | then if (if ((0 >= artworkPrice)) | |
308 | + | then true | |
309 | + | else !(isOnSale)) | |
310 | + | then true | |
311 | + | else (0 >= maxCanSell) | |
312 | + | else false) | |
313 | + | then throw("Art not for sale") | |
314 | + | else if (if (if (!(isBid)) | |
315 | + | then callerIsIssuer | |
316 | + | else false) | |
317 | + | then (0 >= maxCanSell) | |
318 | + | else false) | |
319 | + | then throw("Max issuable not set") | |
320 | + | else $Tuple7(totalNFT, artworkName, amountSold, artworkPrice, priceAssetId, maxCanSell, isOnSale) | |
321 | + | } | |
322 | + | } | |
323 | + | ||
324 | + | ||
325 | + | func getBidData (i,caller,issuer,artId,bidOwner,bidId,priceAssetId,artworkPrice,isBid) = { | |
326 | + | let checkUser = validateUser(issuer) | |
327 | + | if (if (isBid) | |
328 | + | then (checkUser != "") | |
329 | + | else false) | |
330 | + | then throw(checkUser) | |
331 | + | else { | |
332 | + | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + bidOwner) + "_") + bidId) | |
333 | + | let t01351913648 = if (isBid) | |
334 | + | then getPriceAssetIdFromBid(bidDataKey) | |
335 | + | else validatePriceAssetId(i, priceAssetId, artworkPrice) | |
336 | + | let amount = t01351913648._1 | |
337 | + | let assetId = t01351913648._2 | |
338 | + | $Tuple3(bidDataKey, amount, assetId) | |
339 | + | } | |
340 | + | } | |
341 | + | ||
342 | + | ||
343 | + | func getCommissionData (issuer,assetId,amount,amountSold,maxCanSell) = { | |
344 | + | let isWhitelisted = checkWhitelist(issuer) | |
345 | + | let cut = if ((isWhitelisted > height)) | |
346 | + | then 0 | |
347 | + | else if ((assetId == USDNAssetId)) | |
348 | + | then USDNFirstSellCut | |
349 | + | else throw("Only USDN is accepted!") | |
350 | + | let amountForSconex = fraction(amount, cut, 1000) | |
351 | + | let amountForCreator = (amount - amountForSconex) | |
352 | + | if ((amountSold == maxCanSell)) | |
353 | + | then throw("Art sold out") | |
354 | + | else { | |
355 | + | let newAmountSold = (amountSold + 1) | |
356 | + | $Tuple3(amountForSconex, amountForCreator, newAmountSold) | |
357 | + | } | |
358 | + | } | |
359 | + | ||
360 | + | ||
361 | + | func getIssueData (issuer,artId,artworkName,newAmountSold,maxCanSell,totalNFT,caller,bidOwner,bidId,i,isOnSale) = { | |
362 | + | let issueMeta = ((((((((("Creator: " + issuer) + ",ArtID: ") + artId) + ",Artwork name: ") + artworkName) + ",Issue: ") + toString(newAmountSold)) + "/") + toString(maxCanSell)) | |
363 | + | let sellStatus = if (if ((newAmountSold == maxCanSell)) | |
364 | + | then true | |
365 | + | else !(isOnSale)) | |
366 | + | then false | |
367 | + | else true | |
368 | + | let receiveNFT = if ((bidOwner != "")) | |
369 | + | then addressFromStringValue(bidOwner) | |
370 | + | else i.caller | |
371 | + | $Tuple3(sellStatus, receiveNFT, issueMeta) | |
372 | + | } | |
373 | + | ||
374 | + | ||
375 | + | func getBidKeyVal (assetId,bidDataKey,date) = { | |
376 | + | let assetIdBid = if (!(isDefined(assetId))) | |
377 | + | then throw("Only USDN is accepted") | |
378 | + | else toBase58String(value(assetId)) | |
379 | + | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
380 | + | let bidDelOld = DeleteEntry((bidDataKey + "_OPEN")) | |
381 | + | let bidUpdate = StringEntry((bidDataKey + "_CLOSED"), ((bidData + "_") + toString(date))) | |
382 | + | $Tuple3(assetIdBid, bidDelOld, bidUpdate) | |
383 | + | } | |
384 | + | ||
385 | + | ||
386 | + | func buyMint (i,artId,issuer,bidId,bidOwner,isBid) = { | |
387 | + | let callerData = idCallerDate(i) | |
388 | + | let id = callerData._1 | |
389 | + | let caller = callerData._2 | |
390 | + | let date = callerData._3 | |
391 | + | let artData = getArtData(i, issuer, artId, isBid) | |
392 | + | let totalNFT = artData._1 | |
393 | + | let artworkName = artData._2 | |
394 | + | let amountSold = artData._3 | |
395 | + | let artworkPrice = artData._4 | |
396 | + | let priceAssetId = artData._5 | |
397 | + | let maxCanSell = artData._6 | |
398 | + | let isOnSale = artData._7 | |
399 | + | let bidData = getBidData(i, caller, issuer, artId, bidOwner, bidId, priceAssetId, artworkPrice, isBid) | |
400 | + | let bidDataKey = bidData._1 | |
401 | + | let amount = bidData._2 | |
402 | + | let assetId = bidData._3 | |
403 | + | let commisionData = getCommissionData(issuer, value(assetId), amount, amountSold, maxCanSell) | |
404 | + | let amountForSconex = commisionData._1 | |
405 | + | let amountForCreator = commisionData._2 | |
406 | + | let newAmountSold = commisionData._3 | |
407 | + | let issuerData = getIssueData(issuer, artId, artworkName, newAmountSold, maxCanSell, totalNFT, caller, bidOwner, bidId, i, isOnSale) | |
408 | + | let sellStatus = issuerData._1 | |
409 | + | let receiveNFT = issuerData._2 | |
410 | + | let issueMeta = issuerData._3 | |
411 | + | let idNFTInvoke = invoke(this, "mintNft", [totalNFT, issueMeta, toString(receiveNFT)], nil) | |
412 | + | if ((idNFTInvoke == idNFTInvoke)) | |
413 | + | then { | |
414 | + | let idNFT = match idNFTInvoke { | |
415 | + | case r: String => | |
416 | + | r | |
417 | + | case _ => | |
418 | + | throw("Incorrect invoke result") | |
419 | + | } | |
420 | + | let bidKeyValue = getBidKeyVal(assetId, bidDataKey, date) | |
421 | + | let assetIdBid = bidKeyValue._1 | |
422 | + | let bidDelOld = bidKeyValue._2 | |
423 | + | let bidUpdate = bidKeyValue._3 | |
424 | + | let soldKey = ((((((("art_sold_" + toString(newAmountSold)) + "_of_") + toString(maxCanSell)) + "_") + artId) + "_") + issuer) | |
425 | + | let soldValue = if (!(isBid)) | |
426 | + | then ((((((((((caller + "_") + toString(date)) + "_") + id) + "_") + toString(artworkPrice)) + "_") + priceAssetId) + "_") + idNFT) | |
427 | + | else ((((((((((toString(receiveNFT) + "_") + toString(date)) + "_") + id) + "_") + toString(amount)) + "_") + assetIdBid) + "_") + idNFT) | |
428 | + | let soldData = StringEntry(soldKey, soldValue) | |
429 | + | let buyRes = [IntegerEntry(keyIssued(issuer, artId), newAmountSold), StringEntry(("nft_" + idNFT), soldKey), IntegerEntry("total_nft_issued", (totalNFT + 1)), BooleanEntry(keyOnSale(issuer, artId), sellStatus), ScriptTransfer(Address(fromBase58String(issuer)), amountForCreator, assetId), ScriptTransfer(Address(fromBase58String(feeReceiver)), amountForSconex, assetId), StringEntry(KeyNftIssuer(idNFT), issuer)] | |
430 | + | let res = invoke(addressFromStringValue(certDapp), "createCert", [toString(receiveNFT), idNFT, issuer], nil) | |
431 | + | if ((res == res)) | |
432 | + | then if (isBid) | |
433 | + | then (((buyRes :+ soldData) :+ bidUpdate) :+ bidDelOld) | |
434 | + | else soldData :: buyRes | |
435 | + | else throw("Strict value is not equal to itself.") | |
436 | + | } | |
437 | + | else throw("Strict value is not equal to itself.") | |
438 | + | } | |
439 | + | ||
440 | + | ||
441 | + | func setBidNonTraditional (i,artId,issuer) = { | |
442 | + | let t02770927747 = idCallerDate(i) | |
443 | + | let id = t02770927747._1 | |
444 | + | let caller = t02770927747._2 | |
445 | + | let date = t02770927747._3 | |
446 | + | let t02775227788 = isPayment(i) | |
447 | + | let payment = t02775227788._1 | |
448 | + | let amount = t02775227788._2 | |
449 | + | let assetId = if (!(isDefined(payment.assetId))) | |
450 | + | then throw("Only USDN is accepted!") | |
451 | + | else toBase58String(value(payment.assetId)) | |
452 | + | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
453 | + | if (!(acceptedAssetIds(assetId))) | |
454 | + | then throw("asset not accepted") | |
455 | + | else if (!(validateMinSell(assetId, amount))) | |
456 | + | then throw("Wrong min sell") | |
457 | + | else { | |
458 | + | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
459 | + | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
460 | + | if ((0 >= maxCanSell)) | |
461 | + | then throw("No max edition set for this artwork") | |
462 | + | else if ((amountSold >= maxCanSell)) | |
463 | + | then throw("Sold out, you cannot bid") | |
464 | + | else [StringEntry((((((((("bid_" + artId) + "_") + issuer) + "_") + caller) + "_") + id) + "_OPEN"), ((((assetId + "_") + toString(amount)) + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr + 1))] | |
465 | + | } | |
466 | + | } | |
467 | + | ||
468 | + | ||
469 | + | func setBidTraditional (i,artId,issuer) = { | |
470 | + | let endHeight = getIntegerByKey(keyEndHeight(issuer, artId)) | |
471 | + | let highestBid = getAmountHighestBidByArtId(artId) | |
472 | + | if ((height > endHeight)) | |
473 | + | then throw("This auction is finished already!") | |
474 | + | else { | |
475 | + | let callderData = idCallerDate(i) | |
476 | + | let id = callderData._1 | |
477 | + | let caller = callderData._2 | |
478 | + | let date = callderData._3 | |
479 | + | let isPaymentVar = isPayment(i) | |
480 | + | let payment = isPaymentVar._1 | |
481 | + | let amount = isPaymentVar._2 | |
482 | + | if ((highestBid >= amount)) | |
483 | + | then throw(("Please place a bid higher then: " + toString(highestBid))) | |
484 | + | else { | |
485 | + | let assetId = if (!(isDefined(payment.assetId))) | |
486 | + | then throw("Only USDN is accepted!") | |
487 | + | else toBase58String(value(payment.assetId)) | |
488 | + | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
489 | + | if (!(acceptedAssetIds(assetId))) | |
490 | + | then throw("asset not accepted") | |
491 | + | else if (!(validateMinSell(assetId, amount))) | |
492 | + | then throw("Wrong min sell") | |
493 | + | else { | |
494 | + | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
495 | + | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
496 | + | if ((0 >= maxCanSell)) | |
497 | + | then throw("No max edition set for this artwork") | |
498 | + | else if ((amountSold >= maxCanSell)) | |
499 | + | then throw("Sold out, you cannot bid") | |
500 | + | else [StringEntry((((((((("bid_" + artId) + "_") + issuer) + "_") + caller) + "_") + id) + "_OPEN"), ((((assetId + "_") + toString(amount)) + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr + 1)), StringEntry(keyHighestBidBidId(artId), toBase58String(i.transactionId)), IntegerEntry(keyBidId(toBase58String(i.transactionId)), amount)] | |
501 | + | } | |
502 | + | } | |
503 | + | } | |
504 | + | } | |
505 | + | ||
506 | + | ||
507 | + | func acceptBidNonTraditional (i,artId,issuer,bidId,bidOwner) = { | |
508 | + | let caller = toBase58String(i.caller.bytes) | |
509 | + | if ((caller != issuer)) | |
510 | + | then throw("You cannot do this action") | |
511 | + | else buyMint(i, artId, issuer, bidId, bidOwner, true) | |
512 | + | } | |
513 | + | ||
514 | + | ||
515 | + | func restartAuction (artId,issuer) = { | |
516 | + | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
517 | + | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
518 | + | let oldEndHeight = getIntegerByKey(keyEndHeight(issuer, artId)) | |
519 | + | let duration = getIntegerByKey(keyDuration(issuer, artId)) | |
520 | + | let endHeight = (duration + height) | |
521 | + | if ((height > oldEndHeight)) | |
522 | + | then if ((amountSold == maxCanSell)) | |
523 | + | then throw("Can't restart auction, max amount sold") | |
524 | + | else [IntegerEntry(keyEndHeight(issuer, artId), endHeight), DeleteEntry(keyHighestBidBidId(artId))] | |
525 | + | else throw("Previous auction isn't completed yet") | |
526 | + | } | |
527 | + | ||
528 | + | ||
529 | + | func acceptBidTraditional (i,artId,issuer,bidId,bidOwner) = { | |
530 | + | let endHeight = getIntegerByKey(keyEndHeight(issuer, artId)) | |
531 | + | let highestBidId = getStringByKey(keyHighestBidBidId(artId)) | |
532 | + | if ((height > endHeight)) | |
533 | + | then if ((bidId == highestBidId)) | |
534 | + | then { | |
535 | + | let buyMintData = buyMint(i, artId, issuer, bidId, bidOwner, true) | |
536 | + | let restartAuctionData = restartAuction(artId, issuer) | |
537 | + | (restartAuctionData ++ buyMintData) | |
538 | + | } | |
539 | + | else throw("This is not the winning bid!") | |
540 | + | else throw("This auction is not yet finished!") | |
541 | + | } | |
542 | + | ||
543 | + | ||
544 | + | func cancelBidImpl (i,artId,issuer,bidId) = { | |
545 | + | let t02894229094 = idCallerDate(i) | |
546 | + | let id = t02894229094._1 | |
547 | + | let caller = t02894229094._2 | |
548 | + | let date = t02894229094._3 | |
549 | + | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
550 | + | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + caller) + "_") + bidId) | |
551 | + | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
552 | + | if ((bidData == "")) | |
553 | + | then throw("Bid not found") | |
554 | + | else { | |
555 | + | let bidDataArr = split(bidData, "_") | |
556 | + | let assetId = getBidAssetId(bidDataArr[0]) | |
557 | + | let bidStatus = "CANCELED" | |
558 | + | [DeleteEntry((bidDataKey + "_OPEN")), StringEntry(((bidDataKey + "_") + bidStatus), ((bidData + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr - 1)), ScriptTransfer(Address(fromBase58String(caller)), parseIntValue(bidDataArr[1]), assetId)] | |
559 | + | } | |
560 | + | } | |
561 | + | ||
562 | + | ||
563 | + | func cancelBidImplTraditional (i,artId,issuer,bidId) = { | |
564 | + | let t02894229094 = idCallerDate(i) | |
565 | + | let id = t02894229094._1 | |
566 | + | let caller = t02894229094._2 | |
567 | + | let date = t02894229094._3 | |
568 | + | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
569 | + | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + caller) + "_") + bidId) | |
570 | + | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
571 | + | if ((bidData == "")) | |
572 | + | then throw("Bid not found") | |
573 | + | else { | |
574 | + | let bidDataArr = split(bidData, "_") | |
575 | + | let assetId = getBidAssetId(bidDataArr[0]) | |
576 | + | let bidStatus = "CANCELED" | |
577 | + | let bidAmount = parseIntValue(bidDataArr[1]) | |
578 | + | let highestBidId = getStringByKey(keyHighestBidBidId(artId)) | |
579 | + | if ((bidId == highestBidId)) | |
580 | + | then throw("You can't cancel the highest bid!") | |
581 | + | else [DeleteEntry((bidDataKey + "_OPEN")), StringEntry(((bidDataKey + "_") + bidStatus), ((bidData + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr - 1)), ScriptTransfer(Address(fromBase58String(caller)), bidAmount, assetId)] | |
582 | + | } | |
583 | + | } | |
584 | + | ||
585 | + | ||
586 | + | @Callable(i) | |
587 | + | func mintNft (totalNFT,issueMeta,receiveNFT) = if ((i.caller == this)) | |
588 | + | then { | |
589 | + | let receiveNFTAddy = Address(fromBase58String(receiveNFT)) | |
590 | + | let issueNFT = Issue(("SCONEX_" + toString((totalNFT + 1))), issueMeta, 1, 0, false) | |
591 | + | let idNFT = calculateAssetId(issueNFT) | |
592 | + | $Tuple2([issueNFT, ScriptTransfer(receiveNFTAddy, 1, idNFT)], toBase58String(idNFT)) | |
593 | + | } | |
594 | + | else throw("Only the dapp can mintNFT's") | |
595 | + | ||
596 | + | ||
597 | + | ||
598 | + | @Callable(i) | |
599 | + | func addArtwork (sha256Hash,name,description,tags,type,cidDisplay,entitlement) = { | |
600 | + | let t01774017781 = idCallerDate(i) | |
601 | + | let artId = t01774017781._1 | |
602 | + | let caller = t01774017781._2 | |
603 | + | let date = t01774017781._3 | |
604 | + | let validateArtwork = validateArtworkData(caller, cidDisplay, name, description, tags) | |
605 | + | if ((validateArtwork != "")) | |
606 | + | then throw("Something went wrong!") | |
607 | + | else { | |
608 | + | let t01817018212 = validatePayment(i) | |
609 | + | let amount = t01817018212._1 | |
610 | + | let assetId = t01817018212._2 | |
611 | + | if (!(isDefined(amount))) | |
612 | + | then throw("Something went wrong") | |
613 | + | else { | |
614 | + | let entryExist = getStringByKey(keyTxidByHashOwner(sha256Hash, caller)) | |
615 | + | if ((entryExist != "")) | |
616 | + | then throw("You already added it") | |
617 | + | else { | |
618 | + | let hashExist = getStringByKey(keyOwnerByHash(sha256Hash)) | |
619 | + | if ((hashExist != "")) | |
620 | + | then throw("Hash already registered") | |
621 | + | else [StringEntry(keyOwnerByHash(sha256Hash), caller), StringEntry(keyTxidByHashOwner(sha256Hash, caller), artId), IntegerEntry(keyDate(caller, artId), date), StringEntry(keyName(caller, artId), name), StringEntry(keyDesc(caller, artId), description), StringEntry(keyDisplayCid(caller, artId), cidDisplay), StringEntry(keyType(caller, artId), type), StringEntry(keyTags(caller, artId), tags), IntegerEntry(keyMaxMint(caller, artId), 0), IntegerEntry(keyIssued(caller, artId), 0), BooleanEntry(keyOnSale(caller, artId), false), StringEntry(keyHashByTxidAddr(caller, artId), sha256Hash), StringEntry(keyEntitlement(caller, artId), entitlement), ScriptTransfer(Address(fromBase58String(feeReceiver)), amount, assetId)] | |
622 | + | } | |
623 | + | } | |
624 | + | } | |
625 | + | } | |
626 | + | ||
627 | + | ||
628 | + | ||
629 | + | @Callable(i) | |
630 | + | func sellArtwork (artId,price,maxMint,assetId,auctionType,minBid,duration) = { | |
631 | + | let t02571425747 = idCallerDate(i) | |
632 | + | let id = t02571425747._1 | |
633 | + | let caller = t02571425747._2 | |
634 | + | let artworkName = getStringByKey(keyName(caller, artId)) | |
635 | + | if (!(containsElement([auctionType1, auctionType2], auctionType))) | |
636 | + | then throw("We dont know this auction type") | |
637 | + | else if ((artworkName == "")) | |
638 | + | then throw("This art doesn't match your account") | |
639 | + | else { | |
640 | + | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
641 | + | if (!(acceptedAssetIds(assetId))) | |
642 | + | then throw("Something went wrong!") | |
643 | + | else if (!(validateMinSell(assetId, price))) | |
644 | + | then throw("Something went wrong!") | |
645 | + | else { | |
646 | + | let checkUser = validateUser(caller) | |
647 | + | if ((checkUser != "")) | |
648 | + | then throw(checkUser) | |
649 | + | else { | |
650 | + | let amountSold = getIntegerByKey(keyIssued(caller, artId)) | |
651 | + | let maxCanSell = getIntegerByKey(keyMaxMint(caller, artId)) | |
652 | + | if ((maxMint > 10)) | |
653 | + | then throw("10 editions max per artwork") | |
654 | + | else if (if ((amountSold != 0)) | |
655 | + | then (amountSold == maxCanSell) | |
656 | + | else false) | |
657 | + | then throw("Max edition reached.") | |
658 | + | else if (if ((amountSold > 0)) | |
659 | + | then (maxCanSell != maxMint) | |
660 | + | else false) | |
661 | + | then throw("Cannot change maximum issuable anymore") | |
662 | + | else if (if ((bidNbr > 0)) | |
663 | + | then (maxCanSell != maxMint) | |
664 | + | else false) | |
665 | + | then throw("Cannot change maximum issuable with active orders") | |
666 | + | else { | |
667 | + | let sellStatus = if (if ((price > 0)) | |
668 | + | then (maxMint > 0) | |
669 | + | else false) | |
670 | + | then true | |
671 | + | else false | |
672 | + | let endHeight = (duration + height) | |
673 | + | [BooleanEntry(keyOnSale(caller, artId), sellStatus), IntegerEntry(keyPrice(caller, artId), price), IntegerEntry(keyMaxMint(caller, artId), maxMint), IntegerEntry(keyMinPrice(caller, artId), minBid), IntegerEntry(keyDuration(caller, artId), duration), IntegerEntry(keyEndHeight(caller, artId), endHeight), StringEntry(keyAssetIdAccepted(caller, artId), assetId), StringEntry(keyAuctionType(caller, artId), auctionType)] | |
674 | + | } | |
675 | + | } | |
676 | + | } | |
677 | + | } | |
678 | + | } | |
679 | + | ||
680 | + | ||
681 | + | ||
682 | + | @Callable(i) | |
683 | + | func buyArtwork (artId,issuer) = buyMint(i, artId, issuer, "", "", false) | |
684 | + | ||
685 | + | ||
686 | + | ||
687 | + | @Callable(i) | |
688 | + | func deleteEntry (entry) = { | |
689 | + | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
690 | + | if (containsElement(owners, caller)) | |
691 | + | then [DeleteEntry(entry)] | |
692 | + | else throw("no") | |
693 | + | } | |
694 | + | ||
695 | + | ||
696 | + | ||
697 | + | @Callable(i) | |
698 | + | func setBid (artId,issuer) = { | |
699 | + | let auctionType = getStringByKey(keyAuctionType(issuer, artId)) | |
700 | + | if ((auctionType == auctionType1)) | |
701 | + | then setBidNonTraditional(i, artId, issuer) | |
702 | + | else if ((auctionType == auctionType2)) | |
703 | + | then setBidTraditional(i, artId, issuer) | |
704 | + | else throw((("Unknown auction type :" + auctionType) + ", please contact the admins")) | |
705 | + | } | |
706 | + | ||
707 | + | ||
708 | + | ||
709 | + | @Callable(i) | |
710 | + | func acceptBid (artId,issuer,bidId,bidOwner) = { | |
711 | + | let auctionType = getStringByKey(keyAuctionType(issuer, artId)) | |
712 | + | if ((auctionType == auctionType1)) | |
713 | + | then acceptBidNonTraditional(i, artId, issuer, bidId, bidOwner) | |
714 | + | else if ((auctionType == auctionType2)) | |
715 | + | then acceptBidTraditional(i, artId, issuer, bidId, bidOwner) | |
716 | + | else throw((("Unknown auction type :" + auctionType) + ", please contact the admins")) | |
717 | + | } | |
718 | + | ||
719 | + | ||
720 | + | ||
721 | + | @Callable(i) | |
722 | + | func cancelBid (artId,issuer,bidId) = { | |
723 | + | let auctionType = getStringByKey(keyAuctionType(issuer, artId)) | |
724 | + | if ((auctionType == auctionType1)) | |
725 | + | then cancelBidImpl(i, artId, issuer, bidId) | |
726 | + | else cancelBidImplTraditional(i, artId, issuer, bidId) | |
727 | + | } | |
728 | + | ||
729 | + |
github/deemru/w8io/169f3d6 43.10 ms ◑