tx · 6Rves9b77nNNdiPQadB7YZUBaVVqckYwnNSPXR6Sm3fs 3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY: -0.01400000 Waves 2021.12.13 14:18 [1832412] smart account 3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY > SELF 0.00000000 Waves
{ "type": 13, "id": "6Rves9b77nNNdiPQadB7YZUBaVVqckYwnNSPXR6Sm3fs", "fee": 1400000, "feeAssetId": null, "timestamp": 1639394318818, "version": 2, "chainId": 84, "sender": "3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY", "senderPublicKey": "J9DCtJJxJBWZdtDR12BA1U94Q3cZzMi4R6k5hYkAzmzC", "proofs": [ "2JCd8ezx3gWaeA39MU84kbzoD2r3LwPaYXPmEkicBbhhZ3ZrWmQKDyi9tfhtAj5JQ57t4NyoDk36QugjnGmMFkyQ" ], "script": "base64:AAIFAAAAAAAAAFQIAhIOCgwICAgICAgICAgICAgSDQoLCAgICAgICAgICAgSBgoECAgICBIECgIICBIHCgUIAQEIARIECgIICBIECgIICBIGCgQICAgIEgYKBAgICAgAAABHAAAAAAh1bml0VGVzdAcAAAAACW9yYWNsZUZlZQkBAAAABXZhbHVlAAAAAQkABCYAAAABAgAAACMzTjJzNVJ0YUhQQmVuQ3N4MkVDY29GUmJZSHgzbm9aaFhXMQAAAAAIc2lnbkRhcHAJAQAAAAV2YWx1ZQAAAAEJAAQmAAAAAQIAAAAjM05DMjhoU2l2cm1zVFVYYVlEMXg2TDM2Mko0WnBVbm9UZEIAAAAAC2ZlZVJlY2VpdmVyAgAAACMzTjFFNnRYZGRSb1ZhUmZROWRRM3ZnNUxhVzJmc2Q4SEt1YgAAAAAIdXNlckRhcHADBQAAAAh1bml0VGVzdAkBAAAABXZhbHVlAAAAAQkABCYAAAABAgAAACMzTXQ0UkdNRXlqU1dZQW9jVFBxZDU1d2RIUVFCM1BVMlVDbQkBAAAABXZhbHVlAAAAAQkABCYAAAABAgAAACMzTjh4WGFZakUyN0FhNzlkNW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XJuTW9uZXlUbwkBAAAADXBhcnNlSW50VmFsdWUAAAABCQABkQAAAAIFAAAACmJpZERhdGFBcnIAAAAAAAAAAAEFAAAAB2Fzc2V0SWQFAAAAA25pbAAAAADij7Kv", "height": 1832412, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CH9pLBHaZidKNNdTU4VZrcyQAUWvuVehNE6NpoNArzfn Next: GNsKB5a6Aon6bv6eCFXUTNx8sNBzXEWes2DFMkRyRRKi Diff:
Old | New | Differences | |
---|---|---|---|
129 | 129 | func keyType (caller,artId) = ((("art_type_" + artId) + "_") + caller) | |
130 | 130 | ||
131 | 131 | ||
132 | + | func keyNote (caller,artId) = ((("art_note_" + artId) + "_") + caller) | |
133 | + | ||
134 | + | ||
135 | + | func keyCrawler (caller,artId) = ((("art_crawler_" + artId) + "_") + caller) | |
136 | + | ||
137 | + | ||
132 | 138 | func keyPrice (caller,artId) = ((("art_price_" + artId) + "_") + caller) | |
133 | 139 | ||
134 | 140 | ||
233 | 239 | ||
234 | 240 | ||
235 | 241 | func validatePayment (i) = { | |
236 | - | let $ | |
237 | - | let payment = $ | |
238 | - | let amount = $ | |
242 | + | let $t091939229 = isPayment(i) | |
243 | + | let payment = $t091939229._1 | |
244 | + | let amount = $t091939229._2 | |
239 | 245 | let assetId = if (if (isDefined(payment.assetId)) | |
240 | 246 | then (payment.assetId == signAssetId) | |
241 | 247 | else false) | |
258 | 264 | ||
259 | 265 | ||
260 | 266 | func validatePriceAssetId (i,priceAssetId,artworkPrice) = { | |
261 | - | let $ | |
262 | - | let payment = $ | |
263 | - | let amount = $ | |
267 | + | let $t098229858 = isPayment(i) | |
268 | + | let payment = $t098229858._1 | |
269 | + | let amount = $t098229858._2 | |
264 | 270 | let assetId = if (!(isDefined(payment.assetId))) | |
265 | 271 | then unit | |
266 | 272 | else if (if ((size(priceAssetId) > 0)) | |
347 | 353 | ||
348 | 354 | ||
349 | 355 | func buyMint (i,artId,issuer,bidId,bidOwner) = { | |
350 | - | let $ | |
351 | - | let id = $ | |
352 | - | let caller = $ | |
353 | - | let date = $ | |
356 | + | let $t01208312140 = idCallerDate(i) | |
357 | + | let id = $t01208312140._1 | |
358 | + | let caller = $t01208312140._2 | |
359 | + | let date = $t01208312140._3 | |
354 | 360 | let isBid = if (if (if ((toBase58String(i.caller.bytes) == issuer)) | |
355 | 361 | then (bidOwner != "") | |
356 | 362 | else false) | |
406 | 412 | then throw(checkUser) | |
407 | 413 | else { | |
408 | 414 | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + bidOwner) + "_") + bidId) | |
409 | - | let $ | |
415 | + | let $t01389114047 = if (isBid) | |
410 | 416 | then getPriceAssetIdFromBid(bidDataKey) | |
411 | 417 | else validatePriceAssetId(i, priceAssetId, artworkPrice) | |
412 | - | let amount = $ | |
413 | - | let assetId = $ | |
418 | + | let amount = $t01389114047._1 | |
419 | + | let assetId = $t01389114047._2 | |
414 | 420 | let isWhitelisted = checkWhitelist(issuer) | |
415 | 421 | let cut = if ((isWhitelisted > height)) | |
416 | 422 | then 0 | |
466 | 472 | ||
467 | 473 | ||
468 | 474 | @Callable(i) | |
469 | - | func addArtwork (sha256Hash,signID,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence) = { | |
470 | - | let $ | |
471 | - | let artId = $ | |
472 | - | let caller = $ | |
473 | - | let date = $ | |
475 | + | func addArtwork (sha256Hash,signID,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler) = { | |
476 | + | let $t01667516716 = idCallerDate(i) | |
477 | + | let artId = $t01667516716._1 | |
478 | + | let caller = $t01667516716._2 | |
479 | + | let date = $t01667516716._3 | |
474 | 480 | if (!(validateHash(sha256Hash))) | |
475 | 481 | then throw("Hash should be 64 characters maximum") | |
476 | 482 | else { | |
477 | - | let $ | |
478 | - | let licenceCID = $ | |
479 | - | let licenceHash = $ | |
483 | + | let $t01681716886 = setLIcence(cidLicence, sha256Licence) | |
484 | + | let licenceCID = $t01681716886._1 | |
485 | + | let licenceHash = $t01681716886._2 | |
480 | 486 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags) | |
481 | 487 | if ((validateArtwork != "")) | |
482 | 488 | then throw("Something went wrong!") | |
483 | 489 | else { | |
484 | - | let $ | |
485 | - | let amount = $ | |
486 | - | let assetId = $ | |
490 | + | let $t01710517147 = validatePayment(i) | |
491 | + | let amount = $t01710517147._1 | |
492 | + | let assetId = $t01710517147._2 | |
487 | 493 | if (!(isDefined(amount))) | |
488 | 494 | then throw("Something went wrong") | |
489 | 495 | else { | |
498 | 504 | let isSignCertified = checkSignCertificate(signID, caller, sha256Hash) | |
499 | 505 | if (!(isSignCertified)) | |
500 | 506 | then throw("Sign Certificate not found for this address.") | |
501 | - | 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(keyExportCid(caller, artId), cidExport), StringEntry(keyExportHash(caller, artId), sha256Export), StringEntry(keyLicenceHash(caller, artId), licenceHash), StringEntry(keyLicenceCid(caller, artId), licenceCID), StringEntry(keyType(caller, artId), type), StringEntry(keyTags(caller, artId), tags), IntegerEntry(keyMaxMint(caller, artId), 0), StringEntry(keySignID(caller, artId), signID), IntegerEntry(keyIssued(caller, artId), 0), BooleanEntry(keyOnSale(caller, artId), false), StringEntry(keyidBySignid(caller, signID), artId), StringEntry(keyHashByTxidAddr(caller, artId), sha256Hash), ScriptTransfer(Address(fromBase58String(feeReceiver)), amount, assetId)] | |
507 | + | 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(keyExportCid(caller, artId), cidExport), StringEntry(keyExportHash(caller, artId), sha256Export), StringEntry(keyLicenceHash(caller, artId), licenceHash), StringEntry(keyLicenceCid(caller, artId), licenceCID), StringEntry(keyType(caller, artId), type), StringEntry(keyTags(caller, artId), tags), IntegerEntry(keyMaxMint(caller, artId), 0), StringEntry(keySignID(caller, artId), signID), IntegerEntry(keyIssued(caller, artId), 0), BooleanEntry(keyOnSale(caller, artId), false), StringEntry(keyidBySignid(caller, signID), artId), StringEntry(keyHashByTxidAddr(caller, artId), sha256Hash), StringEntry(keyCrawler(caller, artId), crawler), ScriptTransfer(Address(fromBase58String(feeReceiver)), amount, assetId)] | |
502 | 508 | } | |
503 | 509 | } | |
504 | 510 | } | |
509 | 515 | ||
510 | 516 | ||
511 | 517 | @Callable(i) | |
512 | - | func updateArtwork (txid,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence) = if (!(dappRunning)) | |
518 | + | func updateArtwork (txid,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler) = if (!(dappRunning)) | |
513 | 519 | then throw(maintenanceMSG) | |
514 | 520 | else { | |
515 | 521 | let caller = toBase58String(i.caller.bytes) | |
516 | - | let $ | |
517 | - | let licenceCID = $ | |
518 | - | let licenceHash = $ | |
522 | + | let $t01987919948 = setLIcence(cidLicence, sha256Licence) | |
523 | + | let licenceCID = $t01987919948._1 | |
524 | + | let licenceHash = $t01987919948._2 | |
519 | 525 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags) | |
520 | 526 | if ((validateArtwork != "")) | |
521 | 527 | then throw("Something went wrong!") | |
528 | 534 | if ((flag == "ILLEGAL")) | |
529 | 535 | then throw("Cannot update ILLEGAL artwork") | |
530 | 536 | else if (!(isArtMinted(caller, txid))) | |
531 | - | then [StringEntry(keyName(caller, txid), name), StringEntry(keyDesc(caller, txid), description), StringEntry(keyDisplayCid(caller, txid), cidDisplay), StringEntry(keyExportCid(caller, txid), cidExport), StringEntry(keyExportHash(caller, txid), sha256Export), StringEntry(keyLicenceCid(caller, txid), licenceCID), StringEntry(keyLicenceHash(caller, txid), licenceHash), StringEntry(keyTags(caller, txid), tags), StringEntry(keyType(caller, txid), type)] | |
537 | + | then [StringEntry(keyName(caller, txid), name), StringEntry(keyDesc(caller, txid), description), StringEntry(keyDisplayCid(caller, txid), cidDisplay), StringEntry(keyExportCid(caller, txid), cidExport), StringEntry(keyExportHash(caller, txid), sha256Export), StringEntry(keyLicenceCid(caller, txid), licenceCID), StringEntry(keyLicenceHash(caller, txid), licenceHash), StringEntry(keyTags(caller, txid), tags), StringEntry(keyType(caller, txid), type), StringEntry(keyCrawler(caller, txid), crawler)] | |
532 | 538 | else throw("Already minted") | |
533 | 539 | } | |
534 | 540 | } | |
538 | 544 | ||
539 | 545 | @Callable(i) | |
540 | 546 | func flagArtwork (artId,addr,flag,note) = { | |
541 | - | let $ | |
542 | - | let id = $ | |
543 | - | let caller = $ | |
547 | + | let $t02137321406 = idCallerDate(i) | |
548 | + | let id = $t02137321406._1 | |
549 | + | let caller = $t02137321406._2 | |
544 | 550 | if (containsElement([chris, toString(this)], caller)) | |
545 | - | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", " | |
546 | - | then [StringEntry(keyFlag(addr, artId), flag), StringEntry(( | |
551 | + | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
552 | + | then [StringEntry(keyFlag(addr, artId), flag), StringEntry(keyNote(addr, artId), note)] | |
547 | 553 | else throw(("Unknow status " + flag)) | |
548 | 554 | else throw("You are not allowed") | |
549 | 555 | } | |
552 | 558 | ||
553 | 559 | @Callable(i) | |
554 | 560 | func deleteArtwork (artId,addr) = { | |
555 | - | let $ | |
556 | - | let id = $ | |
557 | - | let caller = $ | |
561 | + | let $t02184221875 = idCallerDate(i) | |
562 | + | let id = $t02184221875._1 | |
563 | + | let caller = $t02184221875._2 | |
558 | 564 | let addrToUse = if (containsElement([chris, joep, toString(this)], caller)) | |
559 | 565 | then addr | |
560 | 566 | else caller | |
570 | 576 | if ((signID == "")) | |
571 | 577 | then throw("No SIGN ID matching") | |
572 | 578 | else { | |
573 | - | let dataToDelete = [DeleteEntry(keyDate(addrToUse, artId)), DeleteEntry(keyName(addrToUse, artId)), DeleteEntry(keyDesc(addrToUse, artId)), DeleteEntry(keyDisplayCid(addrToUse, artId)), DeleteEntry(keyExportCid(addrToUse, artId)), DeleteEntry(keyExportHash(addrToUse, artId)), DeleteEntry(keyLicenceHash(addrToUse, artId)), DeleteEntry(keyLicenceCid(addrToUse, artId)), DeleteEntry(keyType(addrToUse, artId)), DeleteEntry(keyTags(addrToUse, artId)), DeleteEntry(keyMaxMint(addrToUse, artId)), DeleteEntry(keySignID(addrToUse, artId)), DeleteEntry(keyIssued(addrToUse, artId)), DeleteEntry(keyOnSale(addrToUse, artId)), DeleteEntry(keyFlag( | |
579 | + | let dataToDelete = [DeleteEntry(keyDate(addrToUse, artId)), DeleteEntry(keyName(addrToUse, artId)), DeleteEntry(keyDesc(addrToUse, artId)), DeleteEntry(keyDisplayCid(addrToUse, artId)), DeleteEntry(keyExportCid(addrToUse, artId)), DeleteEntry(keyExportHash(addrToUse, artId)), DeleteEntry(keyLicenceHash(addrToUse, artId)), DeleteEntry(keyLicenceCid(addrToUse, artId)), DeleteEntry(keyType(addrToUse, artId)), DeleteEntry(keyTags(addrToUse, artId)), DeleteEntry(keyMaxMint(addrToUse, artId)), DeleteEntry(keySignID(addrToUse, artId)), DeleteEntry(keyIssued(addrToUse, artId)), DeleteEntry(keyOnSale(addrToUse, artId)), DeleteEntry(keyFlag(addrToUse, artId)), DeleteEntry(keyPrice(addrToUse, artId)), DeleteEntry(keyAssetIdAccepted(addrToUse, artId)), DeleteEntry(keyOwnerByHash(sha256Hash)), DeleteEntry(keyidBySignid(addrToUse, signID)), DeleteEntry(keyTxidByHashOwner(sha256Hash, addrToUse)), DeleteEntry(keyEndSale(addrToUse, artId)), DeleteEntry(keyNote(addrToUse, artId)), DeleteEntry(keyCrawler(addrToUse, artId))] | |
574 | 580 | if (!(isArtMinted(addrToUse, artId))) | |
575 | 581 | then if (!(dappRunning)) | |
576 | 582 | then throw(maintenanceMSG) | |
587 | 593 | ||
588 | 594 | @Callable(i) | |
589 | 595 | func sellArtwork (artId,price,maxMint,assetId,blockEnd) = { | |
590 | - | let $ | |
591 | - | let id = $ | |
592 | - | let caller = $ | |
596 | + | let $t02464824681 = idCallerDate(i) | |
597 | + | let id = $t02464824681._1 | |
598 | + | let caller = $t02464824681._2 | |
593 | 599 | let artworkName = getStringByKey(keyName(caller, artId)) | |
594 | 600 | if ((artworkName == "")) | |
595 | 601 | then throw("This art doesn't match your account") | |
596 | 602 | else { | |
597 | 603 | let flag = getStringByKey(keyFlag(caller, artId)) | |
598 | - | if (containsElement(["CHANGE_REQUIRED", " | |
604 | + | if (containsElement(["CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
599 | 605 | then throw("Flagged artwork") | |
600 | 606 | else { | |
601 | 607 | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
660 | 666 | ||
661 | 667 | @Callable(i) | |
662 | 668 | func setBid (artId,issuer) = { | |
663 | - | let $ | |
664 | - | let id = $ | |
665 | - | let caller = $ | |
666 | - | let date = $ | |
667 | - | let $ | |
668 | - | let payment = $ | |
669 | - | let amount = $ | |
669 | + | let $t02693826976 = idCallerDate(i) | |
670 | + | let id = $t02693826976._1 | |
671 | + | let caller = $t02693826976._2 | |
672 | + | let date = $t02693826976._3 | |
673 | + | let $t02698127017 = isPayment(i) | |
674 | + | let payment = $t02698127017._1 | |
675 | + | let amount = $t02698127017._2 | |
670 | 676 | let assetId = if (!(isDefined(payment.assetId))) | |
671 | 677 | then "WAVES" | |
672 | 678 | else toBase58String(value(payment.assetId)) | |
707 | 713 | ||
708 | 714 | @Callable(i) | |
709 | 715 | func cancelBid (artId,issuer,bidId,bidOwner) = { | |
710 | - | let $ | |
711 | - | let id = $ | |
712 | - | let caller = $ | |
713 | - | let date = $ | |
716 | + | let $t02844428503 = idCallerDate(i) | |
717 | + | let id = $t02844428503._1 | |
718 | + | let caller = $t02844428503._2 | |
719 | + | let date = $t02844428503._3 | |
714 | 720 | if (if ((caller != bidOwner)) | |
715 | 721 | then (caller != issuer) | |
716 | 722 | else false) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let unitTest = false | |
5 | 5 | ||
6 | 6 | let oracleFee = value(addressFromString("3N2s5RtaHPBenCsx2ECcoFRbYHx3noZhXW1")) | |
7 | 7 | ||
8 | 8 | let signDapp = value(addressFromString("3NC28hSivrmsTUXaYD1x6L362J4ZpUnoTdB")) | |
9 | 9 | ||
10 | 10 | let feeReceiver = "3N1E6tXddRoVaRfQ9dQ3vg5LaW2fsd8HKub" | |
11 | 11 | ||
12 | 12 | let userDapp = if (unitTest) | |
13 | 13 | then value(addressFromString("3Mt4RGMEyjSWYAocTPqd55wdHQQB3PU2UCm")) | |
14 | 14 | else value(addressFromString("3N8xXaYjE27Aa79d5hHrhHu9HaFoTBmhDEj")) | |
15 | 15 | ||
16 | 16 | let whitelistDapp = value(addressFromString("3N6BaV1dCB4zg43goNNHaCtvR13BcyJ5Gsq")) | |
17 | 17 | ||
18 | 18 | let signAssetId = base58'Gf9t8FA4H3ssoZPCwrg3KwUFCci8zuUFP9ssRsUY3s6a' | |
19 | 19 | ||
20 | 20 | let usdnAssetId = base58'25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT' | |
21 | 21 | ||
22 | 22 | let wavesAssetId = base58'' | |
23 | 23 | ||
24 | 24 | let chris = "3MsG6jPNCrVJUtYB7XJBxS7utWsXAf4n9Vp" | |
25 | 25 | ||
26 | 26 | let joep = "3Mzm4VLwsN9uZwbTMzPj3XuxV6kEfAR8UDN" | |
27 | 27 | ||
28 | 28 | let signCut = 7 | |
29 | 29 | ||
30 | 30 | let usdnWaveCut = 10 | |
31 | 31 | ||
32 | 32 | let defaultLicence = "bafybeifuyo4pqu54ismqgtb6e4h6kkvgx7zg4u3zibh2r7y6mb64i7bzza/licence.pdf" | |
33 | 33 | ||
34 | 34 | let defaultHashLicence = "a87758c354e30a9e78fb84fa3a0010a5090ab20df0be11ad45b5720cc187e639" | |
35 | 35 | ||
36 | 36 | let dappRunning = valueOrElse(getBoolean(userDapp, "conf_dapp_is_running"), true) | |
37 | 37 | ||
38 | 38 | let maintenanceMSG = valueOrElse(getString(userDapp, "conf_maintenance_msg"), "") | |
39 | 39 | ||
40 | 40 | let userSuspended = "SUSPENDED" | |
41 | 41 | ||
42 | 42 | let userRemoved = "REMOVED" | |
43 | 43 | ||
44 | 44 | let userUnregistered = "UNREGISTERED" | |
45 | 45 | ||
46 | 46 | let userAllowed = "ALLOWED" | |
47 | 47 | ||
48 | 48 | func getStringByKey (key) = valueOrElse(getString(this, key), "") | |
49 | 49 | ||
50 | 50 | ||
51 | 51 | func getIntegerByKeyFromOracle (key) = valueOrErrorMessage(getInteger(oracleFee, key), "Integer undefine or 0 in oracle") | |
52 | 52 | ||
53 | 53 | ||
54 | 54 | func getIntegerByKey (key) = valueOrElse(getInteger(this, key), 0) | |
55 | 55 | ||
56 | 56 | ||
57 | 57 | func checkWhitelist (key) = valueOrElse(getInteger(whitelistDapp, key), 0) | |
58 | 58 | ||
59 | 59 | ||
60 | 60 | func getBooleanByKey (key) = valueOrElse(getBoolean(this, key), false) | |
61 | 61 | ||
62 | 62 | ||
63 | 63 | let currentCertificationPrice = getIntegerByKeyFromOracle(("certification_fee_" + toBase58String(signAssetId))) | |
64 | 64 | ||
65 | 65 | func checkSignCertificate (signID,Owner,sha256Hash) = match getString(signDapp, ((("data_fc_" + signID) + "_") + Owner)) { | |
66 | 66 | case a: String => | |
67 | 67 | if (contains(a, sha256Hash)) | |
68 | 68 | then true | |
69 | 69 | else false | |
70 | 70 | case _ => | |
71 | 71 | false | |
72 | 72 | } | |
73 | 73 | ||
74 | 74 | ||
75 | 75 | func validateCID (cid) = if (contains(cid, "/")) | |
76 | 76 | then if (if ((76 > size(cid))) | |
77 | 77 | then (size(split(cid, "/")[0]) == 59) | |
78 | 78 | else false) | |
79 | 79 | then (16 > size(split(cid, "/")[1])) | |
80 | 80 | else false | |
81 | 81 | else false | |
82 | 82 | ||
83 | 83 | ||
84 | 84 | func validateHash (hash) = (size(hash) == 64) | |
85 | 85 | ||
86 | 86 | ||
87 | 87 | func keyUserStatus (caller) = ("user_status_" + caller) | |
88 | 88 | ||
89 | 89 | ||
90 | 90 | func keyDate (caller,artId) = ((("art_date_" + artId) + "_") + caller) | |
91 | 91 | ||
92 | 92 | ||
93 | 93 | func keyName (caller,artId) = ((("art_name_" + artId) + "_") + caller) | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | func keyDesc (caller,artId) = ((("art_desc_" + artId) + "_") + caller) | |
97 | 97 | ||
98 | 98 | ||
99 | 99 | func keyDisplayCid (caller,artId) = ((("art_display_cid_" + artId) + "_") + caller) | |
100 | 100 | ||
101 | 101 | ||
102 | 102 | func keyExportHash (caller,artId) = ((("art_export_hash_" + artId) + "_") + caller) | |
103 | 103 | ||
104 | 104 | ||
105 | 105 | func keyExportCid (caller,artId) = ((("art_export_cid_" + artId) + "_") + caller) | |
106 | 106 | ||
107 | 107 | ||
108 | 108 | func keyMaxMint (caller,artId) = ((("art_maxmint_" + artId) + "_") + caller) | |
109 | 109 | ||
110 | 110 | ||
111 | 111 | func keySignID (caller,artId) = ((("art_signid_" + artId) + "_") + caller) | |
112 | 112 | ||
113 | 113 | ||
114 | 114 | func keyIssued (caller,artId) = ((("art_issued_" + artId) + "_") + caller) | |
115 | 115 | ||
116 | 116 | ||
117 | 117 | func keyOnSale (caller,artId) = ((("art_onsale_" + artId) + "_") + caller) | |
118 | 118 | ||
119 | 119 | ||
120 | 120 | func keyLicenceHash (caller,artId) = ((("art_licence_hash_" + artId) + "_") + caller) | |
121 | 121 | ||
122 | 122 | ||
123 | 123 | func keyLicenceCid (caller,artId) = ((("art_licence_cid_" + artId) + "_") + caller) | |
124 | 124 | ||
125 | 125 | ||
126 | 126 | func keyTags (caller,artId) = ((("art_tags_" + artId) + "_") + caller) | |
127 | 127 | ||
128 | 128 | ||
129 | 129 | func keyType (caller,artId) = ((("art_type_" + artId) + "_") + caller) | |
130 | 130 | ||
131 | 131 | ||
132 | + | func keyNote (caller,artId) = ((("art_note_" + artId) + "_") + caller) | |
133 | + | ||
134 | + | ||
135 | + | func keyCrawler (caller,artId) = ((("art_crawler_" + artId) + "_") + caller) | |
136 | + | ||
137 | + | ||
132 | 138 | func keyPrice (caller,artId) = ((("art_price_" + artId) + "_") + caller) | |
133 | 139 | ||
134 | 140 | ||
135 | 141 | func keyEndSale (caller,artId) = ((("art_endsale_" + artId) + "_") + caller) | |
136 | 142 | ||
137 | 143 | ||
138 | 144 | func keyAssetIdAccepted (caller,artId) = ((("art_assetAccepted_" + artId) + "_") + caller) | |
139 | 145 | ||
140 | 146 | ||
141 | 147 | func keyFlag (caller,artId) = ((("art_flag_" + artId) + "_") + caller) | |
142 | 148 | ||
143 | 149 | ||
144 | 150 | func keyHashByTxidAddr (caller,txid) = ((("get_hashbytxidaddr_" + txid) + "_") + caller) | |
145 | 151 | ||
146 | 152 | ||
147 | 153 | func keyOwnerByHash (sha256Hash) = ("get_owner_by_hash_" + sha256Hash) | |
148 | 154 | ||
149 | 155 | ||
150 | 156 | func keyidBySignid (caller,signId) = ((("get_artidbysignid_" + signId) + "_") + caller) | |
151 | 157 | ||
152 | 158 | ||
153 | 159 | func keyTxidByHashOwner (sha256Hash,caller) = ("get_txid_by_hash_owner_" + toBase58String(sha256_16Kb(toBytes((sha256Hash + caller))))) | |
154 | 160 | ||
155 | 161 | ||
156 | 162 | func validateAllCID (cidDisplay,cidExport,cidLicence) = if (!(validateCID(cidDisplay))) | |
157 | 163 | then throw("Wrong Display CID") | |
158 | 164 | else if (!(validateCID(cidExport))) | |
159 | 165 | then throw("Wrong Export CID") | |
160 | 166 | else if (if ((cidLicence != "")) | |
161 | 167 | then !(validateCID(cidLicence)) | |
162 | 168 | else false) | |
163 | 169 | then throw("Wrong Licence CID") | |
164 | 170 | else true | |
165 | 171 | ||
166 | 172 | ||
167 | 173 | func validateAllHash (sha256Export,sha256Licence) = if (!(validateHash(sha256Export))) | |
168 | 174 | then throw("Export Hash 64 char. max") | |
169 | 175 | else if (!(validateHash(sha256Licence))) | |
170 | 176 | then throw("Licence Hash 64 char. max") | |
171 | 177 | else true | |
172 | 178 | ||
173 | 179 | ||
174 | 180 | func validateString (str,max) = if ((size(str) == 0)) | |
175 | 181 | then throw("Field cannot be is empty") | |
176 | 182 | else if ((size(str) > max)) | |
177 | 183 | then throw((str + " is too long")) | |
178 | 184 | else true | |
179 | 185 | ||
180 | 186 | ||
181 | 187 | func validateUser (caller) = { | |
182 | 188 | let userStatus = valueOrElse(getString(userDapp, keyUserStatus(caller)), userUnregistered) | |
183 | 189 | if (if ((userStatus == userUnregistered)) | |
184 | 190 | then true | |
185 | 191 | else (userStatus == userAllowed)) | |
186 | 192 | then "Register this account first with \"Account\" tab" | |
187 | 193 | else if ((userStatus == userSuspended)) | |
188 | 194 | then "Account suspended" | |
189 | 195 | else if ((userStatus == userRemoved)) | |
190 | 196 | then "Account removed" | |
191 | 197 | else "" | |
192 | 198 | } | |
193 | 199 | ||
194 | 200 | ||
195 | 201 | func setLIcence (cidLicence,sha256Licence) = { | |
196 | 202 | let cid = if ((size(cidLicence) == 0)) | |
197 | 203 | then defaultLicence | |
198 | 204 | else cidLicence | |
199 | 205 | let hash = if ((size(sha256Licence) == 0)) | |
200 | 206 | then defaultHashLicence | |
201 | 207 | else sha256Licence | |
202 | 208 | $Tuple2(cid, hash) | |
203 | 209 | } | |
204 | 210 | ||
205 | 211 | ||
206 | 212 | func validateArtworkData (caller,cidDisplay,cidExport,licenceCID,sha256Export,licenceHash,name,description,tags) = { | |
207 | 213 | let checkUser = validateUser(caller) | |
208 | 214 | if ((checkUser != "")) | |
209 | 215 | then throw(checkUser) | |
210 | 216 | else if ((size(cidDisplay) == 0)) | |
211 | 217 | then throw("Display CID cannot be empty") | |
212 | 218 | else if (!(validateAllCID(cidDisplay, cidExport, licenceCID))) | |
213 | 219 | then throw("Problem with CID") | |
214 | 220 | else if (!(validateAllHash(sha256Export, licenceHash))) | |
215 | 221 | then throw("Problem with Hashes") | |
216 | 222 | else if (!(validateString(name, 100))) | |
217 | 223 | then throw("100 Char. max name") | |
218 | 224 | else if (!(validateString(description, 1000))) | |
219 | 225 | then throw("1000 Char. max description") | |
220 | 226 | else if ((size(split(tags, ",")) > 5)) | |
221 | 227 | then throw("5 tags max.") | |
222 | 228 | else "" | |
223 | 229 | } | |
224 | 230 | ||
225 | 231 | ||
226 | 232 | func isPayment (i) = if ((size(i.payments) == 0)) | |
227 | 233 | then throw("No payment attached") | |
228 | 234 | else { | |
229 | 235 | let payment = value(i.payments[0]) | |
230 | 236 | let amount = value(payment.amount) | |
231 | 237 | $Tuple2(payment, amount) | |
232 | 238 | } | |
233 | 239 | ||
234 | 240 | ||
235 | 241 | func validatePayment (i) = { | |
236 | - | let $ | |
237 | - | let payment = $ | |
238 | - | let amount = $ | |
242 | + | let $t091939229 = isPayment(i) | |
243 | + | let payment = $t091939229._1 | |
244 | + | let amount = $t091939229._2 | |
239 | 245 | let assetId = if (if (isDefined(payment.assetId)) | |
240 | 246 | then (payment.assetId == signAssetId) | |
241 | 247 | else false) | |
242 | 248 | then payment.assetId | |
243 | 249 | else throw("Only SIGN token accepted as transaction fee") | |
244 | 250 | if ((amount != currentCertificationPrice)) | |
245 | 251 | then throw(("Payment amount should be " + toString(currentCertificationPrice))) | |
246 | 252 | else $Tuple2(amount, assetId) | |
247 | 253 | } | |
248 | 254 | ||
249 | 255 | ||
250 | 256 | func isArtMinted (addrToUse,artId) = match getInteger(this, keyIssued(addrToUse, artId)) { | |
251 | 257 | case b: Int => | |
252 | 258 | if ((b != 0)) | |
253 | 259 | then true | |
254 | 260 | else false | |
255 | 261 | case _ => | |
256 | 262 | false | |
257 | 263 | } | |
258 | 264 | ||
259 | 265 | ||
260 | 266 | func validatePriceAssetId (i,priceAssetId,artworkPrice) = { | |
261 | - | let $ | |
262 | - | let payment = $ | |
263 | - | let amount = $ | |
267 | + | let $t098229858 = isPayment(i) | |
268 | + | let payment = $t098229858._1 | |
269 | + | let amount = $t098229858._2 | |
264 | 270 | let assetId = if (!(isDefined(payment.assetId))) | |
265 | 271 | then unit | |
266 | 272 | else if (if ((size(priceAssetId) > 0)) | |
267 | 273 | then (toBase58String(value(payment.assetId)) == priceAssetId) | |
268 | 274 | else false) | |
269 | 275 | then payment.assetId | |
270 | 276 | else throw("Wrong asset id") | |
271 | 277 | if (if ((assetId == unit)) | |
272 | 278 | then (priceAssetId != "") | |
273 | 279 | else false) | |
274 | 280 | then throw("Wrong asset id") | |
275 | 281 | else if ((artworkPrice != amount)) | |
276 | 282 | then throw("Payment don't match") | |
277 | 283 | else $Tuple2(amount, assetId) | |
278 | 284 | } | |
279 | 285 | ||
280 | 286 | ||
281 | 287 | func acceptedAssetIds (assetId) = if (if (if (if ((assetId != toBase58String(signAssetId))) | |
282 | 288 | then (assetId != toBase58String(wavesAssetId)) | |
283 | 289 | else false) | |
284 | 290 | then (assetId != "WAVES") | |
285 | 291 | else false) | |
286 | 292 | then (assetId != toBase58String(usdnAssetId)) | |
287 | 293 | else false) | |
288 | 294 | then throw("Only SIGN, USDN or WAVES accepted") | |
289 | 295 | else true | |
290 | 296 | ||
291 | 297 | ||
292 | 298 | func validateMinSell (assetId,price) = { | |
293 | 299 | let minSellWaves = if (unitTest) | |
294 | 300 | then 10 | |
295 | 301 | else getIntegerByKeyFromOracle("waves_min_sell") | |
296 | 302 | let minSellUsdn = 1000000 | |
297 | 303 | let minSellSign = if (unitTest) | |
298 | 304 | then 1 | |
299 | 305 | else (currentCertificationPrice * 2) | |
300 | 306 | if (if (if (if (if ((assetId == toBase58String(usdnAssetId))) | |
301 | 307 | then (minSellUsdn > price) | |
302 | 308 | else false) | |
303 | 309 | then (price != 0) | |
304 | 310 | else false) | |
305 | 311 | then true | |
306 | 312 | else if (if ((assetId == toBase58String(signAssetId))) | |
307 | 313 | then (minSellSign > price) | |
308 | 314 | else false) | |
309 | 315 | then (price != 0) | |
310 | 316 | else false) | |
311 | 317 | then true | |
312 | 318 | else if (if (if ((assetId == toBase58String(wavesAssetId))) | |
313 | 319 | then true | |
314 | 320 | else (assetId == "WAVES")) | |
315 | 321 | then (minSellWaves > price) | |
316 | 322 | else false) | |
317 | 323 | then (price != 0) | |
318 | 324 | else false) | |
319 | 325 | then throw("Wrong minimum sell price") | |
320 | 326 | else true | |
321 | 327 | } | |
322 | 328 | ||
323 | 329 | ||
324 | 330 | func getBidAssetId (assetId) = if ((assetId == "WAVES")) | |
325 | 331 | then unit | |
326 | 332 | else fromBase58String(assetId) | |
327 | 333 | ||
328 | 334 | ||
329 | 335 | func getPriceAssetIdFromBid (bidDataKey) = { | |
330 | 336 | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
331 | 337 | if ((bidData == "")) | |
332 | 338 | then throw("Bid not found") | |
333 | 339 | else { | |
334 | 340 | let bidDataArr = split(bidData, "_") | |
335 | 341 | let bidAmount = parseIntValue(bidDataArr[1]) | |
336 | 342 | let bidAssetId = getBidAssetId(bidDataArr[0]) | |
337 | 343 | if ((0 >= bidAmount)) | |
338 | 344 | then throw("Wrong amount") | |
339 | 345 | else $Tuple2(bidAmount, bidAssetId) | |
340 | 346 | } | |
341 | 347 | } | |
342 | 348 | ||
343 | 349 | ||
344 | 350 | func idCallerDate (i) = if (!(dappRunning)) | |
345 | 351 | then throw(maintenanceMSG) | |
346 | 352 | else $Tuple3(toBase58String(i.transactionId), toBase58String(i.caller.bytes), lastBlock.timestamp) | |
347 | 353 | ||
348 | 354 | ||
349 | 355 | func buyMint (i,artId,issuer,bidId,bidOwner) = { | |
350 | - | let $ | |
351 | - | let id = $ | |
352 | - | let caller = $ | |
353 | - | let date = $ | |
356 | + | let $t01208312140 = idCallerDate(i) | |
357 | + | let id = $t01208312140._1 | |
358 | + | let caller = $t01208312140._2 | |
359 | + | let date = $t01208312140._3 | |
354 | 360 | let isBid = if (if (if ((toBase58String(i.caller.bytes) == issuer)) | |
355 | 361 | then (bidOwner != "") | |
356 | 362 | else false) | |
357 | 363 | then (bidId != "") | |
358 | 364 | else false) | |
359 | 365 | then true | |
360 | 366 | else false | |
361 | 367 | let blockEnd = getIntegerByKey(keyEndSale(caller, artId)) | |
362 | 368 | if (if (if ((blockEnd != 0)) | |
363 | 369 | then (height >= blockEnd) | |
364 | 370 | else false) | |
365 | 371 | then !(isBid) | |
366 | 372 | else false) | |
367 | 373 | then throw("Sale ended.") | |
368 | 374 | else { | |
369 | 375 | let callerIsIssuer = (toBase58String(i.caller.bytes) == issuer) | |
370 | 376 | let totalNFT = getIntegerByKey("total_nft_issued") | |
371 | 377 | let signID = getStringByKey(keySignID(issuer, artId)) | |
372 | 378 | let artworkName = getStringByKey(keyName(issuer, artId)) | |
373 | 379 | if ((artworkName == "")) | |
374 | 380 | then throw("Art doesn't exist") | |
375 | 381 | else { | |
376 | 382 | let isOnSale = getBooleanByKey(keyOnSale(issuer, artId)) | |
377 | 383 | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
378 | 384 | let artworkPrice = if (callerIsIssuer) | |
379 | 385 | then (currentCertificationPrice * 2) | |
380 | 386 | else getIntegerByKey(keyPrice(issuer, artId)) | |
381 | 387 | let priceAssetId = if (callerIsIssuer) | |
382 | 388 | then toBase58String(signAssetId) | |
383 | 389 | else getStringByKey(keyAssetIdAccepted(issuer, artId)) | |
384 | 390 | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
385 | 391 | if (if (if (!(isBid)) | |
386 | 392 | then !(callerIsIssuer) | |
387 | 393 | else false) | |
388 | 394 | then if (if ((0 >= artworkPrice)) | |
389 | 395 | then true | |
390 | 396 | else !(isOnSale)) | |
391 | 397 | then true | |
392 | 398 | else (0 >= maxCanSell) | |
393 | 399 | else false) | |
394 | 400 | then throw("Art not for sale") | |
395 | 401 | else if (if (if (!(isBid)) | |
396 | 402 | then callerIsIssuer | |
397 | 403 | else false) | |
398 | 404 | then (0 >= maxCanSell) | |
399 | 405 | else false) | |
400 | 406 | then throw("Max issuable not set") | |
401 | 407 | else { | |
402 | 408 | let checkUser = validateUser(issuer) | |
403 | 409 | if (if (isBid) | |
404 | 410 | then (checkUser != "") | |
405 | 411 | else false) | |
406 | 412 | then throw(checkUser) | |
407 | 413 | else { | |
408 | 414 | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + bidOwner) + "_") + bidId) | |
409 | - | let $ | |
415 | + | let $t01389114047 = if (isBid) | |
410 | 416 | then getPriceAssetIdFromBid(bidDataKey) | |
411 | 417 | else validatePriceAssetId(i, priceAssetId, artworkPrice) | |
412 | - | let amount = $ | |
413 | - | let assetId = $ | |
418 | + | let amount = $t01389114047._1 | |
419 | + | let assetId = $t01389114047._2 | |
414 | 420 | let isWhitelisted = checkWhitelist(issuer) | |
415 | 421 | let cut = if ((isWhitelisted > height)) | |
416 | 422 | then 0 | |
417 | 423 | else if ((assetId == signAssetId)) | |
418 | 424 | then signCut | |
419 | 425 | else usdnWaveCut | |
420 | 426 | let amountForSign = fraction(amount, cut, 100) | |
421 | 427 | let amountForCreator = (amount - amountForSign) | |
422 | 428 | if ((amountSold == maxCanSell)) | |
423 | 429 | then throw("Art sold out") | |
424 | 430 | else { | |
425 | 431 | let newAmountSold = (amountSold + 1) | |
426 | 432 | let issueMeta = ((((((((((("Creator: " + issuer) + ", | |
427 | 433 | ArtID: ") + artId) + ", | |
428 | 434 | SignID: ") + signID) + ", | |
429 | 435 | Artwork name: ") + artworkName) + ", | |
430 | 436 | Issue: ") + toString(newAmountSold)) + "/") + toString(maxCanSell)) | |
431 | 437 | let issueNFT = Issue(("SA_" + toString((totalNFT + 1))), issueMeta, 1, 0, false) | |
432 | 438 | let idNFT = calculateAssetId(issueNFT) | |
433 | 439 | let sellStatus = if (if ((newAmountSold == maxCanSell)) | |
434 | 440 | then true | |
435 | 441 | else !(isOnSale)) | |
436 | 442 | then false | |
437 | 443 | else true | |
438 | 444 | let receiveNFT = if (if (if ((caller == issuer)) | |
439 | 445 | then (bidOwner != "") | |
440 | 446 | else false) | |
441 | 447 | then (bidId != "") | |
442 | 448 | else false) | |
443 | 449 | then addressFromStringValue(bidOwner) | |
444 | 450 | else i.caller | |
445 | 451 | let assetIdBid = if (!(isDefined(assetId))) | |
446 | 452 | then "WAVES" | |
447 | 453 | else toBase58String(value(assetId)) | |
448 | 454 | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
449 | 455 | let bidDelOld = DeleteEntry((bidDataKey + "_OPEN")) | |
450 | 456 | let bidUpdate = StringEntry((bidDataKey + "_CLOSED"), ((bidData + "_") + toString(date))) | |
451 | 457 | let soldKey = ((((((("art_sold_" + toString(newAmountSold)) + "_of_") + toString(maxCanSell)) + "_") + artId) + "_") + issuer) | |
452 | 458 | let soldValue = if (!(isBid)) | |
453 | 459 | then ((((((((((caller + "_") + toString(date)) + "_") + id) + "_") + toString(artworkPrice)) + "_") + priceAssetId) + "_") + toBase58String(idNFT)) | |
454 | 460 | else ((((((((((toString(receiveNFT) + "_") + toString(date)) + "_") + id) + "_") + toString(amount)) + "_") + assetIdBid) + "_") + toBase58String(idNFT)) | |
455 | 461 | let soldData = StringEntry(soldKey, soldValue) | |
456 | 462 | let buyRes = [IntegerEntry(keyIssued(issuer, artId), newAmountSold), StringEntry(("nft_" + toBase58String(idNFT)), soldKey), IntegerEntry("total_nft_issued", (totalNFT + 1)), IntegerEntry(keyEndSale(issuer, artId), 0), BooleanEntry(keyOnSale(issuer, artId), sellStatus), issueNFT, ScriptTransfer(Address(fromBase58String(issuer)), amountForCreator, assetId), ScriptTransfer(Address(fromBase58String(feeReceiver)), amountForSign, assetId), ScriptTransfer(receiveNFT, 1, idNFT)] | |
457 | 463 | if (isBid) | |
458 | 464 | then [soldData, bidUpdate, bidDelOld] :: buyRes | |
459 | 465 | else soldData :: buyRes | |
460 | 466 | } | |
461 | 467 | } | |
462 | 468 | } | |
463 | 469 | } | |
464 | 470 | } | |
465 | 471 | } | |
466 | 472 | ||
467 | 473 | ||
468 | 474 | @Callable(i) | |
469 | - | func addArtwork (sha256Hash,signID,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence) = { | |
470 | - | let $ | |
471 | - | let artId = $ | |
472 | - | let caller = $ | |
473 | - | let date = $ | |
475 | + | func addArtwork (sha256Hash,signID,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler) = { | |
476 | + | let $t01667516716 = idCallerDate(i) | |
477 | + | let artId = $t01667516716._1 | |
478 | + | let caller = $t01667516716._2 | |
479 | + | let date = $t01667516716._3 | |
474 | 480 | if (!(validateHash(sha256Hash))) | |
475 | 481 | then throw("Hash should be 64 characters maximum") | |
476 | 482 | else { | |
477 | - | let $ | |
478 | - | let licenceCID = $ | |
479 | - | let licenceHash = $ | |
483 | + | let $t01681716886 = setLIcence(cidLicence, sha256Licence) | |
484 | + | let licenceCID = $t01681716886._1 | |
485 | + | let licenceHash = $t01681716886._2 | |
480 | 486 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags) | |
481 | 487 | if ((validateArtwork != "")) | |
482 | 488 | then throw("Something went wrong!") | |
483 | 489 | else { | |
484 | - | let $ | |
485 | - | let amount = $ | |
486 | - | let assetId = $ | |
490 | + | let $t01710517147 = validatePayment(i) | |
491 | + | let amount = $t01710517147._1 | |
492 | + | let assetId = $t01710517147._2 | |
487 | 493 | if (!(isDefined(amount))) | |
488 | 494 | then throw("Something went wrong") | |
489 | 495 | else { | |
490 | 496 | let entryExist = getStringByKey(keyTxidByHashOwner(sha256Hash, caller)) | |
491 | 497 | if ((entryExist != "")) | |
492 | 498 | then throw("You already added it") | |
493 | 499 | else { | |
494 | 500 | let hashExist = getStringByKey(keyOwnerByHash(sha256Hash)) | |
495 | 501 | if ((hashExist != "")) | |
496 | 502 | then throw("Hash already registered") | |
497 | 503 | else { | |
498 | 504 | let isSignCertified = checkSignCertificate(signID, caller, sha256Hash) | |
499 | 505 | if (!(isSignCertified)) | |
500 | 506 | then throw("Sign Certificate not found for this address.") | |
501 | - | 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(keyExportCid(caller, artId), cidExport), StringEntry(keyExportHash(caller, artId), sha256Export), StringEntry(keyLicenceHash(caller, artId), licenceHash), StringEntry(keyLicenceCid(caller, artId), licenceCID), StringEntry(keyType(caller, artId), type), StringEntry(keyTags(caller, artId), tags), IntegerEntry(keyMaxMint(caller, artId), 0), StringEntry(keySignID(caller, artId), signID), IntegerEntry(keyIssued(caller, artId), 0), BooleanEntry(keyOnSale(caller, artId), false), StringEntry(keyidBySignid(caller, signID), artId), StringEntry(keyHashByTxidAddr(caller, artId), sha256Hash), ScriptTransfer(Address(fromBase58String(feeReceiver)), amount, assetId)] | |
507 | + | 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(keyExportCid(caller, artId), cidExport), StringEntry(keyExportHash(caller, artId), sha256Export), StringEntry(keyLicenceHash(caller, artId), licenceHash), StringEntry(keyLicenceCid(caller, artId), licenceCID), StringEntry(keyType(caller, artId), type), StringEntry(keyTags(caller, artId), tags), IntegerEntry(keyMaxMint(caller, artId), 0), StringEntry(keySignID(caller, artId), signID), IntegerEntry(keyIssued(caller, artId), 0), BooleanEntry(keyOnSale(caller, artId), false), StringEntry(keyidBySignid(caller, signID), artId), StringEntry(keyHashByTxidAddr(caller, artId), sha256Hash), StringEntry(keyCrawler(caller, artId), crawler), ScriptTransfer(Address(fromBase58String(feeReceiver)), amount, assetId)] | |
502 | 508 | } | |
503 | 509 | } | |
504 | 510 | } | |
505 | 511 | } | |
506 | 512 | } | |
507 | 513 | } | |
508 | 514 | ||
509 | 515 | ||
510 | 516 | ||
511 | 517 | @Callable(i) | |
512 | - | func updateArtwork (txid,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence) = if (!(dappRunning)) | |
518 | + | func updateArtwork (txid,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler) = if (!(dappRunning)) | |
513 | 519 | then throw(maintenanceMSG) | |
514 | 520 | else { | |
515 | 521 | let caller = toBase58String(i.caller.bytes) | |
516 | - | let $ | |
517 | - | let licenceCID = $ | |
518 | - | let licenceHash = $ | |
522 | + | let $t01987919948 = setLIcence(cidLicence, sha256Licence) | |
523 | + | let licenceCID = $t01987919948._1 | |
524 | + | let licenceHash = $t01987919948._2 | |
519 | 525 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags) | |
520 | 526 | if ((validateArtwork != "")) | |
521 | 527 | then throw("Something went wrong!") | |
522 | 528 | else { | |
523 | 529 | let entryExist = getStringByKey(keyName(caller, txid)) | |
524 | 530 | if ((entryExist == "")) | |
525 | 531 | then throw("Entry not found") | |
526 | 532 | else { | |
527 | 533 | let flag = getStringByKey(keyFlag(caller, txid)) | |
528 | 534 | if ((flag == "ILLEGAL")) | |
529 | 535 | then throw("Cannot update ILLEGAL artwork") | |
530 | 536 | else if (!(isArtMinted(caller, txid))) | |
531 | - | then [StringEntry(keyName(caller, txid), name), StringEntry(keyDesc(caller, txid), description), StringEntry(keyDisplayCid(caller, txid), cidDisplay), StringEntry(keyExportCid(caller, txid), cidExport), StringEntry(keyExportHash(caller, txid), sha256Export), StringEntry(keyLicenceCid(caller, txid), licenceCID), StringEntry(keyLicenceHash(caller, txid), licenceHash), StringEntry(keyTags(caller, txid), tags), StringEntry(keyType(caller, txid), type)] | |
537 | + | then [StringEntry(keyName(caller, txid), name), StringEntry(keyDesc(caller, txid), description), StringEntry(keyDisplayCid(caller, txid), cidDisplay), StringEntry(keyExportCid(caller, txid), cidExport), StringEntry(keyExportHash(caller, txid), sha256Export), StringEntry(keyLicenceCid(caller, txid), licenceCID), StringEntry(keyLicenceHash(caller, txid), licenceHash), StringEntry(keyTags(caller, txid), tags), StringEntry(keyType(caller, txid), type), StringEntry(keyCrawler(caller, txid), crawler)] | |
532 | 538 | else throw("Already minted") | |
533 | 539 | } | |
534 | 540 | } | |
535 | 541 | } | |
536 | 542 | ||
537 | 543 | ||
538 | 544 | ||
539 | 545 | @Callable(i) | |
540 | 546 | func flagArtwork (artId,addr,flag,note) = { | |
541 | - | let $ | |
542 | - | let id = $ | |
543 | - | let caller = $ | |
547 | + | let $t02137321406 = idCallerDate(i) | |
548 | + | let id = $t02137321406._1 | |
549 | + | let caller = $t02137321406._2 | |
544 | 550 | if (containsElement([chris, toString(this)], caller)) | |
545 | - | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", " | |
546 | - | then [StringEntry(keyFlag(addr, artId), flag), StringEntry(( | |
551 | + | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
552 | + | then [StringEntry(keyFlag(addr, artId), flag), StringEntry(keyNote(addr, artId), note)] | |
547 | 553 | else throw(("Unknow status " + flag)) | |
548 | 554 | else throw("You are not allowed") | |
549 | 555 | } | |
550 | 556 | ||
551 | 557 | ||
552 | 558 | ||
553 | 559 | @Callable(i) | |
554 | 560 | func deleteArtwork (artId,addr) = { | |
555 | - | let $ | |
556 | - | let id = $ | |
557 | - | let caller = $ | |
561 | + | let $t02184221875 = idCallerDate(i) | |
562 | + | let id = $t02184221875._1 | |
563 | + | let caller = $t02184221875._2 | |
558 | 564 | let addrToUse = if (containsElement([chris, joep, toString(this)], caller)) | |
559 | 565 | then addr | |
560 | 566 | else caller | |
561 | 567 | let entryExist = valueOrErrorMessage(getStringByKey(keyName(addrToUse, artId)), "No art matching for this address") | |
562 | 568 | if ((entryExist == "")) | |
563 | 569 | then throw("No art matching for this address") | |
564 | 570 | else { | |
565 | 571 | let sha256Hash = getStringByKey(keyHashByTxidAddr(addrToUse, artId)) | |
566 | 572 | if ((sha256Hash == "")) | |
567 | 573 | then throw("No art hash matching for this address") | |
568 | 574 | else { | |
569 | 575 | let signID = getStringByKey(keySignID(addrToUse, artId)) | |
570 | 576 | if ((signID == "")) | |
571 | 577 | then throw("No SIGN ID matching") | |
572 | 578 | else { | |
573 | - | let dataToDelete = [DeleteEntry(keyDate(addrToUse, artId)), DeleteEntry(keyName(addrToUse, artId)), DeleteEntry(keyDesc(addrToUse, artId)), DeleteEntry(keyDisplayCid(addrToUse, artId)), DeleteEntry(keyExportCid(addrToUse, artId)), DeleteEntry(keyExportHash(addrToUse, artId)), DeleteEntry(keyLicenceHash(addrToUse, artId)), DeleteEntry(keyLicenceCid(addrToUse, artId)), DeleteEntry(keyType(addrToUse, artId)), DeleteEntry(keyTags(addrToUse, artId)), DeleteEntry(keyMaxMint(addrToUse, artId)), DeleteEntry(keySignID(addrToUse, artId)), DeleteEntry(keyIssued(addrToUse, artId)), DeleteEntry(keyOnSale(addrToUse, artId)), DeleteEntry(keyFlag( | |
579 | + | let dataToDelete = [DeleteEntry(keyDate(addrToUse, artId)), DeleteEntry(keyName(addrToUse, artId)), DeleteEntry(keyDesc(addrToUse, artId)), DeleteEntry(keyDisplayCid(addrToUse, artId)), DeleteEntry(keyExportCid(addrToUse, artId)), DeleteEntry(keyExportHash(addrToUse, artId)), DeleteEntry(keyLicenceHash(addrToUse, artId)), DeleteEntry(keyLicenceCid(addrToUse, artId)), DeleteEntry(keyType(addrToUse, artId)), DeleteEntry(keyTags(addrToUse, artId)), DeleteEntry(keyMaxMint(addrToUse, artId)), DeleteEntry(keySignID(addrToUse, artId)), DeleteEntry(keyIssued(addrToUse, artId)), DeleteEntry(keyOnSale(addrToUse, artId)), DeleteEntry(keyFlag(addrToUse, artId)), DeleteEntry(keyPrice(addrToUse, artId)), DeleteEntry(keyAssetIdAccepted(addrToUse, artId)), DeleteEntry(keyOwnerByHash(sha256Hash)), DeleteEntry(keyidBySignid(addrToUse, signID)), DeleteEntry(keyTxidByHashOwner(sha256Hash, addrToUse)), DeleteEntry(keyEndSale(addrToUse, artId)), DeleteEntry(keyNote(addrToUse, artId)), DeleteEntry(keyCrawler(addrToUse, artId))] | |
574 | 580 | if (!(isArtMinted(addrToUse, artId))) | |
575 | 581 | then if (!(dappRunning)) | |
576 | 582 | then throw(maintenanceMSG) | |
577 | 583 | else dataToDelete | |
578 | 584 | else if (containsElement([chris, toString(this)], caller)) | |
579 | 585 | then dataToDelete | |
580 | 586 | else throw("Art already minted, you cannot delete it") | |
581 | 587 | } | |
582 | 588 | } | |
583 | 589 | } | |
584 | 590 | } | |
585 | 591 | ||
586 | 592 | ||
587 | 593 | ||
588 | 594 | @Callable(i) | |
589 | 595 | func sellArtwork (artId,price,maxMint,assetId,blockEnd) = { | |
590 | - | let $ | |
591 | - | let id = $ | |
592 | - | let caller = $ | |
596 | + | let $t02464824681 = idCallerDate(i) | |
597 | + | let id = $t02464824681._1 | |
598 | + | let caller = $t02464824681._2 | |
593 | 599 | let artworkName = getStringByKey(keyName(caller, artId)) | |
594 | 600 | if ((artworkName == "")) | |
595 | 601 | then throw("This art doesn't match your account") | |
596 | 602 | else { | |
597 | 603 | let flag = getStringByKey(keyFlag(caller, artId)) | |
598 | - | if (containsElement(["CHANGE_REQUIRED", " | |
604 | + | if (containsElement(["CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
599 | 605 | then throw("Flagged artwork") | |
600 | 606 | else { | |
601 | 607 | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
602 | 608 | if ((0 > blockEnd)) | |
603 | 609 | then throw("Negative end") | |
604 | 610 | else if (if ((blockEnd > 0)) | |
605 | 611 | then if ((maxMint != 1)) | |
606 | 612 | then true | |
607 | 613 | else (price != 0) | |
608 | 614 | else false) | |
609 | 615 | then throw("Timed offer only allowed for unique edition and offer only") | |
610 | 616 | else { | |
611 | 617 | let baseHeight = if ((blockEnd == 0)) | |
612 | 618 | then 0 | |
613 | 619 | else height | |
614 | 620 | if (!(acceptedAssetIds(assetId))) | |
615 | 621 | then throw("Something went wrong!") | |
616 | 622 | else if (!(validateMinSell(assetId, price))) | |
617 | 623 | then throw("Something went wrong!") | |
618 | 624 | else { | |
619 | 625 | let checkUser = validateUser(caller) | |
620 | 626 | if ((checkUser != "")) | |
621 | 627 | then throw(checkUser) | |
622 | 628 | else { | |
623 | 629 | let amountSold = getIntegerByKey(keyIssued(caller, artId)) | |
624 | 630 | let maxCanSell = getIntegerByKey(keyMaxMint(caller, artId)) | |
625 | 631 | if ((maxMint > 100)) | |
626 | 632 | then throw("100 editions max per artwork") | |
627 | 633 | else if (if ((amountSold != 0)) | |
628 | 634 | then (amountSold == maxCanSell) | |
629 | 635 | else false) | |
630 | 636 | then throw("Max edition reached.") | |
631 | 637 | else if (if ((amountSold > 0)) | |
632 | 638 | then (maxCanSell != maxMint) | |
633 | 639 | else false) | |
634 | 640 | then throw("Cannot change maximum issuable anymore") | |
635 | 641 | else if (if ((bidNbr > 0)) | |
636 | 642 | then (maxCanSell != maxMint) | |
637 | 643 | else false) | |
638 | 644 | then throw("Cannot change maximum issuable with active orders") | |
639 | 645 | else { | |
640 | 646 | let sellStatus = if (if ((price > 0)) | |
641 | 647 | then (maxMint > 0) | |
642 | 648 | else false) | |
643 | 649 | then true | |
644 | 650 | else false | |
645 | 651 | [BooleanEntry(keyOnSale(caller, artId), sellStatus), IntegerEntry(keyPrice(caller, artId), price), IntegerEntry(keyMaxMint(caller, artId), maxMint), StringEntry(keyAssetIdAccepted(caller, artId), assetId), IntegerEntry(keyEndSale(caller, artId), (baseHeight + blockEnd))] | |
646 | 652 | } | |
647 | 653 | } | |
648 | 654 | } | |
649 | 655 | } | |
650 | 656 | } | |
651 | 657 | } | |
652 | 658 | } | |
653 | 659 | ||
654 | 660 | ||
655 | 661 | ||
656 | 662 | @Callable(i) | |
657 | 663 | func buyArtwork (artId,issuer) = buyMint(i, artId, issuer, "", "") | |
658 | 664 | ||
659 | 665 | ||
660 | 666 | ||
661 | 667 | @Callable(i) | |
662 | 668 | func setBid (artId,issuer) = { | |
663 | - | let $ | |
664 | - | let id = $ | |
665 | - | let caller = $ | |
666 | - | let date = $ | |
667 | - | let $ | |
668 | - | let payment = $ | |
669 | - | let amount = $ | |
669 | + | let $t02693826976 = idCallerDate(i) | |
670 | + | let id = $t02693826976._1 | |
671 | + | let caller = $t02693826976._2 | |
672 | + | let date = $t02693826976._3 | |
673 | + | let $t02698127017 = isPayment(i) | |
674 | + | let payment = $t02698127017._1 | |
675 | + | let amount = $t02698127017._2 | |
670 | 676 | let assetId = if (!(isDefined(payment.assetId))) | |
671 | 677 | then "WAVES" | |
672 | 678 | else toBase58String(value(payment.assetId)) | |
673 | 679 | let blockEnd = getIntegerByKey(keyEndSale(issuer, artId)) | |
674 | 680 | if (if ((blockEnd != 0)) | |
675 | 681 | then (height >= blockEnd) | |
676 | 682 | else false) | |
677 | 683 | then throw("Sale ended.") | |
678 | 684 | else { | |
679 | 685 | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
680 | 686 | if (!(acceptedAssetIds(assetId))) | |
681 | 687 | then throw("asset not accepted") | |
682 | 688 | else if (!(validateMinSell(assetId, amount))) | |
683 | 689 | then throw("Wrong min sell") | |
684 | 690 | else { | |
685 | 691 | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
686 | 692 | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
687 | 693 | if ((0 >= maxCanSell)) | |
688 | 694 | then throw("No max edition set for this artwork") | |
689 | 695 | else if ((amountSold >= maxCanSell)) | |
690 | 696 | then throw("Sold out, you cannot bid") | |
691 | 697 | else [StringEntry((((((((("bid_" + artId) + "_") + issuer) + "_") + caller) + "_") + id) + "_OPEN"), ((((assetId + "_") + toString(amount)) + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr + 1))] | |
692 | 698 | } | |
693 | 699 | } | |
694 | 700 | } | |
695 | 701 | ||
696 | 702 | ||
697 | 703 | ||
698 | 704 | @Callable(i) | |
699 | 705 | func acceptBid (artId,issuer,bidId,bidOwner) = { | |
700 | 706 | let caller = toBase58String(i.caller.bytes) | |
701 | 707 | if ((caller != issuer)) | |
702 | 708 | then throw("You cannot do this action") | |
703 | 709 | else buyMint(i, artId, issuer, bidId, bidOwner) | |
704 | 710 | } | |
705 | 711 | ||
706 | 712 | ||
707 | 713 | ||
708 | 714 | @Callable(i) | |
709 | 715 | func cancelBid (artId,issuer,bidId,bidOwner) = { | |
710 | - | let $ | |
711 | - | let id = $ | |
712 | - | let caller = $ | |
713 | - | let date = $ | |
716 | + | let $t02844428503 = idCallerDate(i) | |
717 | + | let id = $t02844428503._1 | |
718 | + | let caller = $t02844428503._2 | |
719 | + | let date = $t02844428503._3 | |
714 | 720 | if (if ((caller != bidOwner)) | |
715 | 721 | then (caller != issuer) | |
716 | 722 | else false) | |
717 | 723 | then throw("You cannot do this action") | |
718 | 724 | else { | |
719 | 725 | let returnMoneyTo = if ((caller == issuer)) | |
720 | 726 | then bidOwner | |
721 | 727 | else caller | |
722 | 728 | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
723 | 729 | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + bidOwner) + "_") + bidId) | |
724 | 730 | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
725 | 731 | if ((bidData == "")) | |
726 | 732 | then throw("Bid not found") | |
727 | 733 | else { | |
728 | 734 | let bidDataArr = split(bidData, "_") | |
729 | 735 | let assetId = getBidAssetId(bidDataArr[0]) | |
730 | 736 | let bidStatus = "CANCELED" | |
731 | 737 | [DeleteEntry((bidDataKey + "_OPEN")), StringEntry(((bidDataKey + "_") + bidStatus), ((bidData + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr - 1)), ScriptTransfer(Address(fromBase58String(returnMoneyTo)), parseIntValue(bidDataArr[1]), assetId)] | |
732 | 738 | } | |
733 | 739 | } | |
734 | 740 | } | |
735 | 741 | ||
736 | 742 |
github/deemru/w8io/026f985 118.48 ms ◑