tx · EjNWTXavRbUh9P3twmQDF3yGkDpqP8QMygUqfmW7iNPs

3N2kVUxYqFz4rHNgnVr7ffhsnC7DptJ1BzH:  -0.01000000 Waves

2023.04.23 04:49 [2546557] smart account 3N2kVUxYqFz4rHNgnVr7ffhsnC7DptJ1BzH > SELF 0.00000000 Waves

{ "type": 13, "id": "EjNWTXavRbUh9P3twmQDF3yGkDpqP8QMygUqfmW7iNPs", "fee": 1000000, "feeAssetId": null, "timestamp": 1682214625858, "version": 2, "chainId": 84, "sender": "3N2kVUxYqFz4rHNgnVr7ffhsnC7DptJ1BzH", "senderPublicKey": "8cCvpHrqwPyT7CYYANjtE4ZUgLzCDCqFDMVAX5RRZMPN", "proofs": [ "3wCRWNtfjf7bHiP9Rd3VYJ1xbkMPjebFn9RA6GQxePa2HsvXvf9r5xR8i9phnDkWq7Y2fpWBRChHTz4e9ymvmZJ4" ], "script": "base64:BgJNCAISBwoFCAgICAgSDAoKCAgICAgICAgICBIECgIICBIMCgoICAgICAgICAgIEggKBggICAgICBIDCgEIEgMKAQgSBAoCCAgSBAoCCAgFABBhZG1pbl93YWxsZXRfb25lAiMzTXBEZkRUMzU5cVNTbU5GWm5NZW9QUXB5SkEyVTFLNTF1NQAQYWRtaW5fd2FsbGV0X3R3bwIjM04zRENuZ2ppZGl2a0piVEp3RlRFdmJZUlRmZkNXVkJMQ0wAEmFkbWluX3dhbGxldF90aHJlZQIjM044eDltYjQ4MWkyazZjRzdROVhVVjNlNW56aDFtZHpzTnkBFGNoZWNrX2FkbWluc193YWxsZXRzAQt1c2VyX3dhbGxldAMDAwkAAAIFC3VzZXJfd2FsbGV0BRBhZG1pbl93YWxsZXRfb25lBgkAAAIFC3VzZXJfd2FsbGV0BRBhZG1pbl93YWxsZXRfdHdvBgkAAAIFC3VzZXJfd2FsbGV0BRJhZG1pbl93YWxsZXRfdGhyZWUGBwENdHJ5R2V0SW50ZWdlcgEDa2V5BAckbWF0Y2gwCQCaCAIFBHRoaXMFA2tleQMJAA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", "height": 2546557, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 5anrxs2uvATurPbsEwXJxJZYAY9aP55fQDXqqhr4cLVr Next: none Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let admin_wallet_one = "3MpDfDT359qSSmNFZnMeoPQpyJA2U1K51u5"
55
66 let admin_wallet_two = "3N3DCngjidivkJbTJwFTEvbYRTffCWVBLCL"
77
88 let admin_wallet_three = "3N8x9mb481i2k6cG7Q9XUV3e5nzh1mdzsNy"
99
1010 func check_admins_wallets (user_wallet) = if (if (if ((user_wallet == admin_wallet_one))
1111 then true
1212 else (user_wallet == admin_wallet_two))
1313 then true
1414 else (user_wallet == admin_wallet_three))
1515 then true
1616 else false
1717
1818
1919 func tryGetInteger (key) = match getInteger(this, key) {
2020 case b: Int =>
2121 b
2222 case _ =>
2323 0
2424 }
2525
2626
2727 @Callable(i)
2828 func add_blog (publisher,titel,arweave_tx_id,signature,blog_cover) = if (if ((toString(i.caller) == publisher))
2929 then true
3030 else check_admins_wallets(toString(i.caller)))
3131 then {
3232 let tx_id = toBase58String(i.transactionId)
3333 let block = lastBlock
3434 let publish_time = block.timestamp
3535 let blog_id = tryGetInteger((("user_" + publisher) + "_blog_id"))
3636 let new_blog_id = (blog_id + 1)
3737 [StringEntry((("blog_" + tx_id) + "_publisher"), publisher), StringEntry((("blog_" + tx_id) + "_arweave_tx_id"), arweave_tx_id), StringEntry((("blog_" + tx_id) + "_signature"), signature), StringEntry((("blog_" + tx_id) + "_blog_cover"), blog_cover), StringEntry((("blog_" + tx_id) + "_titel"), titel), StringEntry(((("user_" + publisher) + "_blog") + toString(new_blog_id)), tx_id), IntegerEntry((("user_" + publisher) + "_blog_id"), new_blog_id), IntegerEntry((("blog_" + tx_id) + "_publish_time"), publish_time)]
3838 }
3939 else throw("ERRROR !, add_blog, MESSAGE: sorry you are not allow to invoke this funaction")
4040
4141
4242
4343 @Callable(i)
4444 func add_story (publisher,titel,arweave_tx_id,signature,story_cover,description,tags,language,categorys,status) = if (if ((toString(i.caller) == publisher))
4545 then true
4646 else check_admins_wallets(toString(i.caller)))
4747 then {
4848 let tx_id = toBase58String(i.transactionId)
4949 let block = lastBlock
5050 let publish_time = block.timestamp
5151 let story_id = tryGetInteger((("user_" + publisher) + "_story_id"))
5252 let new_story_id = (story_id + 1)
5353 [StringEntry((("story_" + tx_id) + "_publisher"), publisher), StringEntry((("story_" + tx_id) + "_arweave_tx_id"), arweave_tx_id), StringEntry((("story_" + tx_id) + "_signature"), signature), StringEntry((("story_" + tx_id) + "_story_cover"), story_cover), StringEntry((("story_" + tx_id) + "_titel"), titel), StringEntry((("story_" + tx_id) + "_description"), description), StringEntry((("story_" + tx_id) + "_tags"), tags), StringEntry((("story_" + tx_id) + "_language"), language), StringEntry((("story_" + tx_id) + "_categorys"), categorys), StringEntry((("story_" + tx_id) + "_status"), status), StringEntry(((("user_" + publisher) + "_story") + toString(new_story_id)), tx_id), IntegerEntry((("user_" + publisher) + "_story_id"), new_story_id), IntegerEntry((("story_" + tx_id) + "_publish_time"), publish_time)]
5454 }
5555 else throw("ERRROR !, add_story, MESSAGE: sorry you are not allow to invoke this funaction")
5656
5757
5858
5959 @Callable(i)
6060 func add_chapter (story_tx_id,chapter_arweave_tx_id) = {
6161 let last_chapter_id = tryGetInteger((("story_" + story_tx_id) + "_last_chapter_id"))
6262 let tx_id = toBase58String(i.transactionId)
6363 let block = lastBlock
6464 let publish_time = block.timestamp
6565 [StringEntry(((("story_" + story_tx_id) + "_chapter_") + toString(last_chapter_id)), tx_id), StringEntry((("chapter_" + tx_id) + "_arweave_tx_id"), chapter_arweave_tx_id), StringEntry((("chapter_" + tx_id) + "_story_tx_id"), story_tx_id), IntegerEntry((("chapter_" + tx_id) + "_id"), last_chapter_id), IntegerEntry((("story_" + story_tx_id) + "_last_chapter_id"), (last_chapter_id + 1)), IntegerEntry((("chapter_" + tx_id) + "_publish_time"), publish_time)]
6666 }
6767
6868
6969
7070 @Callable(i)
7171 func set_user_data (wallet,name,image_link,cover_link,bio,google_analytics,twitter,telegram,yandex_analytics,notes) = if (if ((toString(i.caller) == wallet))
7272 then true
7373 else check_admins_wallets(toString(i.caller)))
7474 then [StringEntry((("user_" + wallet) + "_joined"), "yes"), StringEntry((("user_" + wallet) + "_name"), name), StringEntry((("user_" + wallet) + "_imageLink"), image_link), StringEntry((("user_" + wallet) + "_coverLink"), cover_link), StringEntry((("user_" + wallet) + "_bio"), bio), StringEntry((("user_" + wallet) + "_googleAnalytics"), google_analytics), StringEntry((("user_" + wallet) + "_yandexAnalytics"), yandex_analytics), StringEntry((("user_" + wallet) + "_twitter"), twitter), StringEntry((("user_" + wallet) + "_telegram"), telegram), StringEntry((("user_" + wallet) + "_notes"), notes)]
7575 else throw("ERRROR !, set_user_data, MESSAGE: sorry you are not allow to invoke this funaction")
7676
7777
7878
7979 @Callable(i)
8080 func set_verified_user (wallet,name,twitter,telegram,email,notes) = if (check_admins_wallets(toString(i.caller)))
8181 then [StringEntry((("user_" + wallet) + "_verified"), "yes"), StringEntry((("user_" + wallet) + "_verified_name"), name), StringEntry((("user_" + wallet) + "_verified_twitter"), twitter), StringEntry((("user_" + wallet) + "_verified_telegram"), telegram), StringEntry((("user_" + wallet) + "_verified_notes"), notes)]
8282 else throw("ERRROR !, set_verified_user, MESSAGE: sorry you are not allow to invoke this funaction")
8383
8484
8585
8686 @Callable(i)
8787 func follow_user (wallet) = {
8888 let caller = toString(i.caller)
8989 [StringEntry(((("user_" + wallet) + "_followed_by_") + caller), "yes"), StringEntry(((("user_" + caller) + "_follow_") + wallet), "yes")]
9090 }
9191
9292
9393
9494 @Callable(i)
9595 func un_follow_user (wallet) = {
9696 let caller = toString(i.caller)
9797 [DeleteEntry(((("user_" + wallet) + "_followed_by_") + caller)), DeleteEntry(((("user_" + caller) + "_follow_") + wallet))]
9898 }
9999
100100
101101
102102 @Callable(i)
103103 func add_blog_to_favorites (wallet,blog_tx_id) = if (if ((toString(i.caller) == wallet))
104104 then true
105105 else check_admins_wallets(toString(i.caller)))
106106 then {
107107 let id = tryGetInteger((("blog_" + blog_tx_id) + "_favorite_id"))
108108 let user_id = tryGetInteger((("user_" + wallet) + "_favorite_id"))
109109 [StringEntry(((("user_" + wallet) + "_blog_favorite_") + toString(user_id)), blog_tx_id), StringEntry(((("blog_" + blog_tx_id) + "_favorite_") + toString(id)), wallet), IntegerEntry((("blog_" + blog_tx_id) + "_favorite_id"), (id + 1)), IntegerEntry((("user_" + wallet) + "_favorite_id"), (user_id + 1))]
110110 }
111111 else throw("ERRROR !, add_to_favorites, MESSAGE: sorry you are not allow to invoke this funaction")
112112
113113
114114
115115 @Callable(i)
116116 func add_story_to_favorites (wallet,story_tx_id) = if (if ((toString(i.caller) == wallet))
117117 then true
118118 else check_admins_wallets(toString(i.caller)))
119119 then {
120120 let id = tryGetInteger((("story_" + story_tx_id) + "_favorite_id"))
121121 let user_id = tryGetInteger((("user_" + wallet) + "_favorite_id"))
122122 [StringEntry(((("user_" + wallet) + "_story_favorite_") + toString(user_id)), story_tx_id), StringEntry(((("story_" + story_tx_id) + "_favorite_") + toString(id)), wallet), IntegerEntry((("story_" + story_tx_id) + "_favorite_id"), (id + 1)), IntegerEntry((("user_" + wallet) + "_favorite_id"), (user_id + 1))]
123123 }
124124 else throw("ERRROR !, add_to_favorites, MESSAGE: sorry you are not allow to invoke this funaction")
125125
126126
127127 @Verifier(tx)
128128 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
129129

github/deemru/w8io/169f3d6 
27.82 ms