tx · ERn1r7yVZGrP31ycuv6gQap9c2DYq66PEYC8zjj6dw4k

3MyBtJnMg6n7m1sDczbrijVyosLnRh4FFbc:  -0.04000000 Waves

2022.07.11 14:45 [2135034] smart account 3MyBtJnMg6n7m1sDczbrijVyosLnRh4FFbc > SELF 0.00000000 Waves

{ "type": 13, "id": "ERn1r7yVZGrP31ycuv6gQap9c2DYq66PEYC8zjj6dw4k", "fee": 4000000, "feeAssetId": null, "timestamp": 1657539970215, "version": 1, "sender": "3MyBtJnMg6n7m1sDczbrijVyosLnRh4FFbc", "senderPublicKey": "H3EzJ6fSm7jHKo92xYdNTXaaQYKj9z5q2DJFovRDLJpf", "proofs": [ "4ptutVp3aT9bWeJWA3A2rTE2zyYNGhm2cUrKxTP35waxoGejcjGM1c9KPgfL1Y1wwNWnggmzd5ydKS3dJ3TzJCoV" ], "script": "base64:AAIFAAAAAAAAACQIAhIECgIICBIECgIIARIDCgEIEgUKAwgBCBIDCgEIEgMKAQgAAAAJAAAAAANTRVACAAAAAl9fAQAAABFrZXlDb250cm9sQWRkcmVzcwAAAAACAAAAHCVzJXNfX2NvbmZpZ19fY29udHJvbEFkZHJlc3MBAAAADmtleVJlc3RBZGRyZXNzAAAAAAIAAAAZJXMlc19fY29uZmlnX19yZXN0QWRkcmVzcwEAAAAMZ2V0U3RyT3JGYWlsAAAAAQAAAANrZXkJAQAAABN2YWx1ZU9yRXJyb3JNZXNzYWdlAAAAAgkABB0AAAACBQAAAAR0aGlzBQAAAANrZXkJAAEsAAAAAgkAASwAAAACAgAAAA9NYW5kYXRvcnkgdGhpcy4FAAAAA2tleQIAAAAPIGlzIG5vdCBkZWZpbmVkAQAAABBnZXRBZGRyZXNzT3JGYWlsAAAAAQAAAANrZXkJAQAAABN2YWx1ZU9yRXJyb3JNZXNzYWdlAAAAAgkABCYAAAABCQEAAAAMZ2V0U3RyT3JGYWlsAAAAAQUAAAADa2V5CQABLAAAAAICAAAAH2ZhaWwgdG8gcGFyc2UgYWRkcmVzc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AABSRmMF8xAAAAAgkBAAAABSRmMF8xAAAAAgkBAAAABSRmMF8xAAAAAgkBAAAABSRmMF8xAAAAAgkBAAAABSRmMF8xAAAAAgkBAAAABSRmMF8xAAAAAgkBAAAABSRmMF8xAAAAAgUAAAAFJGFjYzAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAIAAAAAAAAAAAMAAAAAAAAAAAQAAAAAAAAAAAUAAAAAAAAAAAYAAAAAAAAAAAcAAAAAAAAAAAgAAAAAAAAAAAkAAAAAAAAAAAoJAAUUAAAAAgUAAAADbmlsCQEAAAALcHJvZHVjZUpzb24AAAABBQAAAA5pbnZva2VzUmVzdWx0cwAAAACUxmgW", "chainId": 84, "height": 2135034, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: FHyT84G87XCHwkuN9rtemCuVBhaFtUxgKJ3xKCDcwioG Next: 8YptqF3vp7GuUqgbALUMN6ba46xctqbzkUBN56bE18Z5 Diff:
OldNewDifferences
9191 let gnsbtInfo = asString(invoke(restAcc, "gnsbtInfoREADONLY", [userAddressStrOpt, 0], nil))
9292 let neutrinoStats = asString(invoke(restAcc, "neutrinoStatsREADONLY", nil, nil))
9393 let surfBuy = asString(invoke(restAcc, "buySurfREADONLY", [userAddressStrOpt, amount, assetIdStr], nil))
94- $Tuple2(nil, produceJson(["gnsbtInfoREADONLY", gnsbtInfo, "neutrinoStatsREADONLY", neutrinoStats, "buySurfREADONLY", surfBuy]))
94+ let neutrinoCfg = asString(invoke(restAcc, "neutrinoConfigREADONLY", nil, nil))
95+ $Tuple2(nil, produceJson(["gnsbtInfoREADONLY", gnsbtInfo, "neutrinoStatsREADONLY", neutrinoStats, "buySurfREADONLY", surfBuy, "neutrinoConfigREADONLY", neutrinoCfg]))
9596 }
9697
9798
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SEP = "__"
55
66 func keyControlAddress () = "%s%s__config__controlAddress"
77
88
99 func keyRestAddress () = "%s%s__config__restAddress"
1010
1111
1212 func getStrOrFail (key) = valueOrErrorMessage(getString(this, key), (("Mandatory this." + key) + " is not defined"))
1313
1414
1515 func getAddressOrFail (key) = valueOrErrorMessage(addressFromString(getStrOrFail(key)), ("fail to parse address for this." + key))
1616
1717
1818 func asString (val) = match val {
1919 case valStr: String =>
2020 valStr
2121 case _ =>
2222 throw("fail to cast into String")
2323 }
2424
2525
2626 func produceJson (strMap) = {
2727 let indexes = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]
2828 let length = size(strMap)
2929 if (((length % 2) != 0))
3030 then throw("only even args size is accepeted")
3131 else if ((length > size(indexes)))
3232 then throw(("strMap length is greater then " + toString(size(indexes))))
3333 else {
3434 func produceJson (jsonAccum,nextIdx) = if (if (((nextIdx % 2) == 0))
3535 then (length >= (nextIdx + 1))
3636 else false)
3737 then (((((jsonAccum + "
3838 \"") + strMap[nextIdx]) + "\": \"") + strMap[(nextIdx + 1)]) + "\",")
3939 else jsonAccum
4040
4141 let preJsonResult = {
4242 let $l = indexes
4343 let $s = size($l)
4444 let $acc0 = ""
4545 func $f0_1 ($a,$i) = if (($i >= $s))
4646 then $a
4747 else produceJson($a, $l[$i])
4848
4949 func $f0_2 ($a,$i) = if (($i >= $s))
5050 then $a
5151 else throw("List size exceeds 20")
5252
5353 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20)
5454 }
5555 (("{" + dropRight(preJsonResult, 1)) + "}")
5656 }
5757 }
5858
5959
6060 let controlAcc = getAddressOrFail(keyControlAddress())
6161
6262 let restAcc = getAddressOrFail(keyRestAddress())
6363
6464 @Callable(i)
6565 func constructor (controlAddress58,restAddress58) = if ((i.caller != this))
6666 then throw("not authorized")
6767 else [StringEntry(keyControlAddress(), controlAddress58), StringEntry(keyRestAddress(), restAddress58)]
6868
6969
7070
7171 @Callable(i)
7272 func stakeNsbtPageREADONLY (userAddressStrOpt,nsbtAmtDiff) = {
7373 let gnsbtInfo = asString(invoke(restAcc, "gnsbtInfoREADONLY", [userAddressStrOpt, nsbtAmtDiff], nil))
7474 let swapInfo = asString(invoke(restAcc, "swapInfoREADONLY", [userAddressStrOpt], nil))
7575 $Tuple2(nil, produceJson(["gnsbtInfoREADONLY", gnsbtInfo, "swapInfoREADONLY", swapInfo]))
7676 }
7777
7878
7979
8080 @Callable(i)
8181 func buyNsbtPageREADONLY (userAddressStrOpt) = {
8282 let gnsbtInfo = asString(invoke(restAcc, "gnsbtInfoREADONLY", [userAddressStrOpt, 0], nil))
8383 let neutrinoStats = asString(invoke(restAcc, "neutrinoStatsREADONLY", nil, nil))
8484 $Tuple2(nil, produceJson(["gnsbtInfoREADONLY", gnsbtInfo, "neutrinoStatsREADONLY", neutrinoStats]))
8585 }
8686
8787
8888
8989 @Callable(i)
9090 func buySurfPageREADONLY (userAddressStrOpt,amount,assetIdStr) = {
9191 let gnsbtInfo = asString(invoke(restAcc, "gnsbtInfoREADONLY", [userAddressStrOpt, 0], nil))
9292 let neutrinoStats = asString(invoke(restAcc, "neutrinoStatsREADONLY", nil, nil))
9393 let surfBuy = asString(invoke(restAcc, "buySurfREADONLY", [userAddressStrOpt, amount, assetIdStr], nil))
94- $Tuple2(nil, produceJson(["gnsbtInfoREADONLY", gnsbtInfo, "neutrinoStatsREADONLY", neutrinoStats, "buySurfREADONLY", surfBuy]))
94+ let neutrinoCfg = asString(invoke(restAcc, "neutrinoConfigREADONLY", nil, nil))
95+ $Tuple2(nil, produceJson(["gnsbtInfoREADONLY", gnsbtInfo, "neutrinoStatsREADONLY", neutrinoStats, "buySurfREADONLY", surfBuy, "neutrinoConfigREADONLY", neutrinoCfg]))
9596 }
9697
9798
9899
99100 @Callable(i)
100101 func walletPageREADONLY (userAddressStr) = {
101102 let walletInfo = asString(invoke(restAcc, "walletInfoREADONLY", [userAddressStr], nil))
102103 $Tuple2(nil, produceJson(["walletInfoREADONLY", walletInfo]))
103104 }
104105
105106
106107
107108 @Callable(i)
108109 func genericREADONLY (payload) = {
109110 let funcsIndexes = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
110111 let paramIndexes = [1, 3, 5, 7, 9, 11]
111112 let payloadArr = split(payload, SEP)
112113 let payloadSize = size(payloadArr)
113114 func invokesAgregator (accum,funcIdx) = if ((funcIdx >= payloadSize))
114115 then accum
115116 else {
116117 let call = payloadArr[funcIdx]
117118 let callArr = split(call, "+")
118119 let address = addressFromStringValue(callArr[0])
119120 let funcName = callArr[1]
120121 let paramsArr = split(callArr[2], ":")
121122 let paramsSize = size(paramsArr)
122123 func paramsAgregator (paramsAcc,paramIdx) = if ((paramIdx >= paramsSize))
123124 then paramsAcc
124125 else {
125126 let p = if ((paramsArr[(paramIdx - 1)] == "s"))
126127 then paramsArr[paramIdx]
127128 else parseIntValue(paramsArr[paramIdx])
128129 (paramsAcc :+ p)
129130 }
130131
131132 let params = {
132133 let $l = paramIndexes
133134 let $s = size($l)
134135 let $acc0 = nil
135136 func $f0_1 ($a,$i) = if (($i >= $s))
136137 then $a
137138 else paramsAgregator($a, $l[$i])
138139
139140 func $f0_2 ($a,$i) = if (($i >= $s))
140141 then $a
141142 else throw("List size exceeds 6")
142143
143144 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6)
144145 }
145146 let result = asString(invoke(address, funcName, params, nil))
146147 (accum ++ [funcName, result])
147148 }
148149
149150 let invokesResults = {
150151 let $l = funcsIndexes
151152 let $s = size($l)
152153 let $acc0 = nil
153154 func $f0_1 ($a,$i) = if (($i >= $s))
154155 then $a
155156 else invokesAgregator($a, $l[$i])
156157
157158 func $f0_2 ($a,$i) = if (($i >= $s))
158159 then $a
159160 else throw("List size exceeds 10")
160161
161162 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
162163 }
163164 $Tuple2(nil, produceJson(invokesResults))
164165 }
165166
166167

github/deemru/w8io/026f985 
37.46 ms