tx · 6zcV3u2C5MRvwQSRvRLFGoHPKD3VyG1hz8RHSxocFiJ7

3MxVYj6ScMArhAamy7nB6b342kh1Pso1LTn:  -0.00800000 Waves

2023.03.22 19:42 [2501473] smart account 3MxVYj6ScMArhAamy7nB6b342kh1Pso1LTn > SELF 0.00000000 Waves

{ "type": 13, "id": "6zcV3u2C5MRvwQSRvRLFGoHPKD3VyG1hz8RHSxocFiJ7", "fee": 800000, "feeAssetId": null, "timestamp": 1679503361914, "version": 2, "chainId": 84, "sender": "3MxVYj6ScMArhAamy7nB6b342kh1Pso1LTn", "senderPublicKey": "CZeucjRLCKrkiP9zuj9KbLe23Wv9DywFzHBqNDnte51B", "proofs": [ "4dhyK71CM69Pi6vEaHQDxc4rk1tMNNphZq6JKvUDsswhVuLNkMHdRba7fZ6wCvBxrfWYkDC1eeHVnuEt4sQkBYog" ], "script": "base64:BgJKCAISBAoCCAgSBAoCCAESAwoBCBIGCgQICAgIEgUKAwgICBIDCgECEgQKAggBEgMKAQgSBgoECAEBARIECgIBARIDCgEBEgMKAQEXAA5jb2xsZWN0aW9uTmFtZQkBEUBleHRyTmF0aXZlKDEwNTgpAQIOY29sbGVjdGlvbk5hbWUABnN5bWJvbAkBEUBleHRyTmF0aXZlKDEwNTgpAQIGc3ltYm9sAAtkZXNjcmlwdGlvbgkBEUBleHRyTmF0aXZlKDEwNTgpAQILZGVzY3JpcHRpb24AC3RvdGFsQW1vdW50CQERQGV4dHJOYXRpdmUoMTA1NSkBAgt0b3RhbEFtb3VudAAHYmFzZVVSSQkBEUBleHRyTmF0aXZlKDEwNTgpAQIHYmFzZVVSSQAIZEFwcEpzb24JAQdBZGRyZXNzAQkA2QQBAiMzTXJHYVpWUmhrbkVHZkhKMTl0dFVQTm5EUm9GcWNIaFZONwAMdG9rZW5QYXltZW50CQERQGV4dHJOYXRpdmUoMTA1NykBAgx0b2tlblBheW1lbnQAEXRva2VuUGF5bWVudEFzc2V0CQETdmFsdWVPckVycm9yTWVzc2FnZQI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C2dldExlbmRDb3N0AQUGbGVuZElkBQNuaWwAWMz1/g==", "height": 2501473, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 8AiSkdmrXgbmFcy87nQZf8UaMohXacCJ1xcW8T94VV8v Next: JE2iVTtWZxEePjgtizVPrBdSnUnHnmznA1d9xw22Lh5J Diff:
OldNewDifferences
6666 }
6767
6868
69-func getLendCost (lendId) = valueOrElse(getIntegerValue(("lend-cost-" + toString(lendId))), 0)
69+func getLendCost (lendId) = valueOrElse(getInteger(("lend-cost-" + toString(lendId))), 0)
7070
7171
7272 func onlyInternal (caller) = if ((caller == this))
7575
7676
7777 func reducerGetDeleteEntry (accum,next) = {
78- let $t021642214 = accum
79- let deletions = $t021642214._1
80- let current = $t021642214._2
81- let maxCount = $t021642214._3
82- let lendId = $t021642214._4
78+ let $t021592209 = accum
79+ let deletions = $t021592209._1
80+ let current = $t021592209._2
81+ let maxCount = $t021592209._3
82+ let lendId = $t021592209._4
8383 if ((maxCount > current))
8484 then $Tuple3((deletions :+ DeleteEntry(((("lend-rent-" + lendId) + "-") + toString(current)))), (current + 1), maxCount)
8585 else accum
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let collectionName = getStringValue("collectionName")
55
66 let symbol = getStringValue("symbol")
77
88 let description = getStringValue("description")
99
1010 let totalAmount = getIntegerValue("totalAmount")
1111
1212 let baseURI = getStringValue("baseURI")
1313
1414 let dAppJson = Address(fromBase58String("3MrGaZVRhknEGfHJ19ttUPNnDRoFqcHhVN7"))
1515
1616 let tokenPayment = getBinaryValue("tokenPayment")
1717
1818 let tokenPaymentAsset = valueOrErrorMessage(assetInfo(getBinaryValue("tokenPayment")), "token payment asset doesn't connect")
1919
2020 let lendCount = getIntegerValue("lendCount")
2121
2222 let lendCurrentCount = getIntegerValue("lendCurrentCount")
2323
2424 func parseIdtoAsset (assetId) = valueOrErrorMessage(assetInfo(fromBase58String(assetId)), "Can't find asset by asset id")
2525
2626
2727 func transferOrNot (to,amount,assetId) = if ((to == this))
2828 then StringEntry("smth", "smth")
2929 else ScriptTransfer(to, amount, assetId)
3030
3131
3232 func getLendJson (lendId) = {
3333 let lendIdString = toString(lendId)
3434 getStringValue(("lend-" + lendIdString))
3535 }
3636
3737
3838 func getKey (lendJson,key) = {
3939 let timeUnitSeconds = {
4040 let @ = invoke(dAppJson, "readByJSONKey", [lendJson, key], nil)
4141 if ($isInstanceOf(@, "String"))
4242 then @
4343 else throw(($getType(@) + " couldn't be cast to String"))
4444 }
4545 if ((timeUnitSeconds == timeUnitSeconds))
4646 then timeUnitSeconds
4747 else throw("Strict value is not equal to itself.")
4848 }
4949
5050
5151 func getRentCount (lendId) = {
5252 let lendIdString = toString(lendId)
5353 getIntegerValue(("lend-rentCount-" + lendIdString))
5454 }
5555
5656
5757 func calcLendCost (lendId,timeUnitSeconds) = {
5858 let lendJson = getLendJson(lendId)
5959 let timeUnitPriceString = getKey(lendJson, "timeUnitPrice")
6060 if ((timeUnitPriceString == timeUnitPriceString))
6161 then {
6262 let timeUnitPrice = parseIntValue(timeUnitPriceString)
6363 (timeUnitSeconds * timeUnitPrice)
6464 }
6565 else throw("Strict value is not equal to itself.")
6666 }
6767
6868
69-func getLendCost (lendId) = valueOrElse(getIntegerValue(("lend-cost-" + toString(lendId))), 0)
69+func getLendCost (lendId) = valueOrElse(getInteger(("lend-cost-" + toString(lendId))), 0)
7070
7171
7272 func onlyInternal (caller) = if ((caller == this))
7373 then unit
7474 else throw("Only internal call")
7575
7676
7777 func reducerGetDeleteEntry (accum,next) = {
78- let $t021642214 = accum
79- let deletions = $t021642214._1
80- let current = $t021642214._2
81- let maxCount = $t021642214._3
82- let lendId = $t021642214._4
78+ let $t021592209 = accum
79+ let deletions = $t021592209._1
80+ let current = $t021592209._2
81+ let maxCount = $t021592209._3
82+ let lendId = $t021592209._4
8383 if ((maxCount > current))
8484 then $Tuple3((deletions :+ DeleteEntry(((("lend-rent-" + lendId) + "-") + toString(current)))), (current + 1), maxCount)
8585 else accum
8686 }
8787
8888
8989 func checkAssetOwner (caller,assetId) = if ((assetBalance(caller, fromBase58String(assetId)) == 1))
9090 then unit
9191 else throw("Only asset owner")
9292
9393
9494 func checkPayment (payments,amount) = if ((payments[0].amount >= amount))
9595 then unit
9696 else throw("amount less then need")
9797
9898
9999 func checkAssetExists (assetId) = if (valueOrElse(getBoolean(assetId), false))
100100 then throw("this token already use")
101101 else unit
102102
103103
104104 func checkLendOwner (caller,lendId) = if ((getKey(getLendJson(lendId), "owner") != toString(caller)))
105105 then throw("you haven't perms")
106106 else unit
107107
108108
109109 @Callable(i)
110110 func setString (_key,_value) = valueOrElse(onlyInternal(i.caller), [StringEntry(_key, _value)])
111111
112112
113113
114114 @Callable(i)
115115 func setInt (_key,_value) = valueOrElse(onlyInternal(i.caller), [IntegerEntry(_key, _value)])
116116
117117
118118
119119 @Callable(i)
120120 func deleteEntry (_key) = valueOrElse(onlyInternal(i.caller), [DeleteEntry(_key)])
121121
122122
123123
124124 @Callable(i)
125125 func init (_collectionName,_symbol,_description,_baseURI) = valueOrElse(onlyInternal(i.caller), [StringEntry("collectionName", _collectionName), StringEntry("symbol", _symbol), StringEntry("description", _description), IntegerEntry("totalAmount", 0), StringEntry("baseURI", _baseURI)])
126126
127127
128128
129129 @Callable(i)
130130 func setUser (assetId,user,expires) = {
131131 let res = invoke(dAppJson, "makeJSON", [["user", "expires"], [user, expires]], nil)
132132 if ((res == res))
133133 then $Tuple2([StringEntry(("userOf-" + assetId), {
134134 let @ = res
135135 if ($isInstanceOf(@, "String"))
136136 then @
137137 else throw(($getType(@) + " couldn't be cast to String"))
138138 })], res)
139139 else throw("Strict value is not equal to itself.")
140140 }
141141
142142
143143
144144 @Callable(i)
145145 func setTokenPayment (assetBinary) = valueOrElse(onlyInternal(i.caller), [BinaryEntry("tokenPayment", assetBinary)])
146146
147147
148148
149149 @Callable(i)
150150 func mintTokens (to,amount) = {
151151 let reisue = Reissue(tokenPayment, amount, true)
152152 let toAddress = Address(fromBase58String(to))
153153 let transfer = transferOrNot(toAddress, amount, tokenPayment)
154154 if ((transfer == transfer))
155155 then [transfer, reisue]
156156 else throw("Strict value is not equal to itself.")
157157 }
158158
159159
160160
161161 @Callable(i)
162162 func mintNFT (to) = {
163163 let tokenId = (totalAmount + 1)
164164 let tokenIdString = toString(tokenId)
165165 let preName = ((symbol + "#") + tokenIdString)
166166 let name = if ((16 >= size(preName)))
167167 then preName
168168 else tokenIdString
169169 let tokenURI = (baseURI + tokenIdString)
170170 let json = {
171171 let @ = invoke(dAppJson, "makeJSON", [["tokenURI"], [tokenURI]], nil)
172172 if ($isInstanceOf(@, "String"))
173173 then @
174174 else throw(($getType(@) + " couldn't be cast to String"))
175175 }
176176 let asset = Issue(name, json, 1, 0, false, unit, height)
177177 let assetId = calculateAssetId(asset)
178178 let toAddress = Address(fromBase58String(to))
179179 let transfer = transferOrNot(toAddress, 1, assetId)
180180 if ((transfer == transfer))
181181 then [asset, transfer, IntegerEntry("totalAmount", tokenId), StringEntry(name, tokenURI)]
182182 else throw("Strict value is not equal to itself.")
183183 }
184184
185185
186186
187187 @Callable(i)
188188 func initLend (assetId,timeUnitSeconds,timeUnitPrice,timeUnitCount) = valueOrElse(checkAssetOwner(i.caller, assetId), valueOrElse(checkAssetExists(assetId), {
189189 let asset = parseIdtoAsset(assetId)
190190 let tokenURI = {
191191 let @ = invoke(dAppJson, "readByJSONKey", [asset.description, "tokenURI"], nil)
192192 if ($isInstanceOf(@, "String"))
193193 then @
194194 else throw(($getType(@) + " couldn't be cast to String"))
195195 }
196196 if ((tokenURI == tokenURI))
197197 then {
198198 let lendJson = {
199199 let @ = invoke(dAppJson, "makeJSON", [["supportedInterface", "assetdId", "tokenURI", "owner", "timeUnitSeconds", "timeUnitPrice", "timeUnitCount", "startTimestamp", "endTimestamp", "deposit", "claimed"], ["0", assetId, tokenURI, toString(i.caller), toString(timeUnitSeconds), toString(timeUnitPrice), toString(timeUnitCount), toString(lastBlock.timestamp), toString((lastBlock.timestamp + (timeUnitSeconds * timeUnitCount))), "0", "0"]], nil)
200200 if ($isInstanceOf(@, "String"))
201201 then @
202202 else throw(($getType(@) + " couldn't be cast to String"))
203203 }
204204 if ((lendJson == lendJson))
205205 then {
206206 let lendIdString = toString(lendCount)
207207 [IntegerEntry("lendCount", (lendCount + 1)), IntegerEntry("lendCurrentCount", (lendCurrentCount + 1)), IntegerEntry(("lend-rentCount-" + lendIdString), 0), StringEntry(("lend-" + lendIdString), lendJson), BooleanEntry(assetId, true)]
208208 }
209209 else throw("Strict value is not equal to itself.")
210210 }
211211 else throw("Strict value is not equal to itself.")
212212 }))
213213
214214
215215
216216 @Callable(i)
217217 func initRent (lendId,timeUnitCount) = valueOrElse(checkPayment(i.payments, calcLendCost(lendId, timeUnitCount)), {
218218 let lendIdString = toString(lendId)
219219 let lendJson = getStringValue(("lend-" + lendIdString))
220220 let rentId = getRentCount(lendId)
221221 let rentIdString = toString(rentId)
222222 let timeUnitSeconds = {
223223 let @ = invoke(dAppJson, "readByJSONKey", [lendJson, "timeUnitSeconds"], nil)
224224 if ($isInstanceOf(@, "String"))
225225 then @
226226 else throw(($getType(@) + " couldn't be cast to String"))
227227 }
228228 if ((timeUnitSeconds == timeUnitSeconds))
229229 then {
230230 let timeUnitSecondsInt = parseIntValue(timeUnitSeconds)
231231 if ((timeUnitSecondsInt == timeUnitSecondsInt))
232232 then {
233233 let rentJson = {
234234 let @ = invoke(dAppJson, "makeJSON", [["customer", "timeUnitCount", "startTimestamp", "endTimestamp", "closed"], [toString(i.caller), toString(timeUnitCount), toString(lastBlock.timestamp), toString((lastBlock.timestamp + (timeUnitSecondsInt * timeUnitCount))), "0"]], nil)
235235 if ($isInstanceOf(@, "String"))
236236 then @
237237 else throw(($getType(@) + " couldn't be cast to String"))
238238 }
239239 if ((rentJson == rentJson))
240240 then [IntegerEntry(("lend-rentCount-" + lendIdString), (rentId + 1)), StringEntry(((("lend-rent-" + lendIdString) + "-") + rentIdString), rentJson), IntegerEntry(("lend-cost-" + lendIdString), (calcLendCost(lendId, timeUnitCount) + getLendCost(lendId)))]
241241 else throw("Strict value is not equal to itself.")
242242 }
243243 else throw("Strict value is not equal to itself.")
244244 }
245245 else throw("Strict value is not equal to itself.")
246246 })
247247
248248
249249
250250 @Callable(i)
251251 func closeLend (lendId) = valueOrElse(checkLendOwner(i.caller, lendId), {
252252 let lendIdString = toString(lendId)
253253 let txListRaw = [DeleteEntry(("lend-" + lendIdString)), DeleteEntry(("lend-rentCount-" + lendIdString)), IntegerEntry("lendCurrentCount", (lendCurrentCount - 1)), DeleteEntry(("lend-cost-" + lendIdString)), ScriptTransfer(i.caller, getLendCost(lendId), tokenPayment)]
254254 txListRaw
255255 })
256256
257257
258258
259259 @Callable(i)
260260 func test (lendId) = [IntegerEntry("Debug", getLendCost(lendId))]
261261
262262

github/deemru/w8io/169f3d6 
39.46 ms