tx · 4nhaxZM7y4xrMDrbxkEcbVR2cLhjEcziFVytLtDVaSUn
3NCWFHDzdPHZC6636ZkMLNDup9mjpbTLs7h: -0.05000000 Waves
2023.03.27 10:25 [2508079] smart account 3NCWFHDzdPHZC6636ZkMLNDup9mjpbTLs7h > SELF 0.00000000 Waves
{
"type": 13,
"id": "4nhaxZM7y4xrMDrbxkEcbVR2cLhjEcziFVytLtDVaSUn",
"fee": 5000000,
"feeAssetId": null,
"timestamp": 1679901934620,
"version": 2,
"chainId": 84,
"sender": "3NCWFHDzdPHZC6636ZkMLNDup9mjpbTLs7h",
"senderPublicKey": "3z8Q6Zu3KppVmn6fJJvrLc1Wo3krVHSvfaNcerm82md2",
"proofs": [
"5z1tazL3tYqr6KRzSahrHEaCaPHMTu3arYK27YHv8FPRVZATpMYyRUoBwL3doPUZcMegFfV5mU1FRKBdvRaxMPjy"
],
"script": "base64:BgIECAISAAcADGNvbnRyYWN0RmlsZQIJcmViYWxhbmNlAA9rZXlzVGFyZ2V0UmF0aW8CDyVzX190YXJnZXRSYXRpbwAUa2V5QWRkaXRpb25hbEJhbGFuY2UCGyVzX19hZGRpdHRpb25hbFdhdmVzQmFsYW5jZQAYa2V5U1dhdmVzQWRkaXRpb25CYWxhbmNlAhElc19fc1dhdmVzQmFsYW5jZQAQa2V5U1dhdmVzQXNzZXRJZAIRJXNfX3NXYXZlc0Fzc2V0SWQAD2tleVByb3h5QWRkcmVzcwIQJXNfX3Byb3h5QWRkcmVzcwEaZ2V0QWRkaXRpb25hbEJhbGFuY2VPclplcm8ABBFhZGRpdGlvbmFsQmFsYW5jZQkBEUBleHRyTmF0aXZlKDEwNTApAgUEdGhpcwUUa2V5QWRkaXRpb25hbEJhbGFuY2UEByRtYXRjaDAFEWFkZGl0aW9uYWxCYWxhbmNlAwkAAQIFByRtYXRjaDACA0ludAQDYmFsBQckbWF0Y2gwBQNiYWwAAAEBaQENcmV0dXJuQmFsYW5jZQAJAJQKAgUDbmlsCQBkAggJAO8HAQUEdGhpcwdyZWd1bGFyCQEaZ2V0QWRkaXRpb25hbEJhbGFuY2VPclplcm8AAPppojo=",
"height": 2508079,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: A3jPEWp8p3Q6MQ9w3nAebdfeSFPXebMqf6hEUzN3V7RC
Next: 2UTREQJdDQs8jDE9FDMFWNyX5eAJ1jw1oSaYXXRuzFks
Diff:
Old | New | | Differences |
---|
7 | 7 | | |
---|
8 | 8 | | let keyAdditionalBalance = "%s__addittionalWavesBalance" |
---|
9 | 9 | | |
---|
10 | | - | let keySWavesAdditionBlance = "%s__sWavesBalance" |
---|
| 10 | + | let keySWavesAdditionBalance = "%s__sWavesBalance" |
---|
| 11 | + | |
---|
| 12 | + | let keySWavesAssetId = "%s__sWavesAssetId" |
---|
11 | 13 | | |
---|
12 | 14 | | let keyProxyAddress = "%s__proxyAddress" |
---|
| 15 | + | |
---|
| 16 | + | func getAdditionalBalanceOrZero () = { |
---|
| 17 | + | let additionalBalance = getIntegerValue(this, keyAdditionalBalance) |
---|
| 18 | + | match additionalBalance { |
---|
| 19 | + | case bal: Int => |
---|
| 20 | + | bal |
---|
| 21 | + | case _ => |
---|
| 22 | + | 0 |
---|
| 23 | + | } |
---|
| 24 | + | } |
---|
| 25 | + | |
---|
| 26 | + | |
---|
| 27 | + | @Callable(i) |
---|
| 28 | + | func returnBalance () = $Tuple2(nil, (wavesBalance(this).regular + getAdditionalBalanceOrZero())) |
---|
13 | 29 | | |
---|
14 | 30 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 6 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | 4 | | let contractFile = "rebalance" |
---|
5 | 5 | | |
---|
6 | 6 | | let keysTargetRatio = "%s__targetRatio" |
---|
7 | 7 | | |
---|
8 | 8 | | let keyAdditionalBalance = "%s__addittionalWavesBalance" |
---|
9 | 9 | | |
---|
10 | | - | let keySWavesAdditionBlance = "%s__sWavesBalance" |
---|
| 10 | + | let keySWavesAdditionBalance = "%s__sWavesBalance" |
---|
| 11 | + | |
---|
| 12 | + | let keySWavesAssetId = "%s__sWavesAssetId" |
---|
11 | 13 | | |
---|
12 | 14 | | let keyProxyAddress = "%s__proxyAddress" |
---|
| 15 | + | |
---|
| 16 | + | func getAdditionalBalanceOrZero () = { |
---|
| 17 | + | let additionalBalance = getIntegerValue(this, keyAdditionalBalance) |
---|
| 18 | + | match additionalBalance { |
---|
| 19 | + | case bal: Int => |
---|
| 20 | + | bal |
---|
| 21 | + | case _ => |
---|
| 22 | + | 0 |
---|
| 23 | + | } |
---|
| 24 | + | } |
---|
| 25 | + | |
---|
| 26 | + | |
---|
| 27 | + | @Callable(i) |
---|
| 28 | + | func returnBalance () = $Tuple2(nil, (wavesBalance(this).regular + getAdditionalBalanceOrZero())) |
---|
13 | 29 | | |
---|
14 | 30 | | |
---|