tx · 9KZSD55Cmj5y4rdvJkwdE1vPoGaxeArEir7akxfiNEjA

3N5net4nzSeeqxPfGZrvVvnGavsinipQHbE:  -1.00000000 Waves

2019.02.28 14:34 [515226] smart asset 3N5net4nzSeeqxPfGZrvVvnGavsinipQHbE > SELF 0.00000000 !SmartAsset

{ "type": 15, "id": "9KZSD55Cmj5y4rdvJkwdE1vPoGaxeArEir7akxfiNEjA", "fee": 100000000, "feeAssetId": null, "timestamp": 1551353626372, "version": 1, "sender": "3N5net4nzSeeqxPfGZrvVvnGavsinipQHbE", "senderPublicKey": "416z9d8DQDy5MPTqDhvReRBaPb19gEyVRWvHcewpP6Nc", "proofs": [ "53tdYd86XGxtHiVTZ4cAW2LePXMuvbxxNKJhzfgT5FJEkm8orfkgcnJsZUc5WC9JsEfFxpdjRHfLtcxJQuDzCi3E" ], "assetId": "AYX9YEMMV5TJNg5KaRLiztnzvhyC44ZX3QTscTK6pDYi", "script": "base64:AQa3b8tH", "chainId": 84, "height": 515226, "spentComplexity": 0 } View: original | compacted Prev: FZJ6V2tmoiy2UB74SsjsGhGVebz6HLrYW3DAk7eCuAAD Next: GWkdmHarT8vrYv1xQzj6tHeCbZ7gHbwUjLJrAxZYos9D Full:
OldNewDifferences
11 {-# STDLIB_VERSION 1 #-}
22 {-# CONTENT_TYPE EXPRESSION #-}
3-let minimumWavesBalance = 1000000000
4-let moveTimeInBlocks = 5000
5-let minimalFeeToMove = 10000000
6-let minimalFeeToBurn = 50000000
7-match tx {
8- case t: TransferTransaction =>
9- let txId = t.attachment
10- let currentRecipientWavesBalance = wavesBalance(t.recipient)
11- let transaction = transactionById(extract(t.assetId))
12- match transaction {
13- case issueTx: IssueTransaction =>
14- let transactionByIssuer = (t.senderPublicKey == issueTx.senderPublicKey)
15- if (transactionByIssuer)
16- then if ((minimumWavesBalance > currentRecipientWavesBalance))
17- then throw("Current balance is less than minimalWavesBalance")
18- else true
19- else if ((32 > size(t.attachment)))
20- then throw("Attachment should contain transaction id ")
21- else {
22- let receiveTx = transactionById(txId)
23- match receiveTx {
24- case recTx: MassTransferTransaction|TransferTransaction =>
25- let receivedBlockNumber = extract(transactionHeightById(recTx.id))
26- let receivedAssetInLastNBlocks = if ((moveTimeInBlocks >= (height - receivedBlockNumber)))
27- then (t.assetId == recTx.assetId)
28- else false
29- let feeMore1Waves = (t.fee >= minimalFeeToMove)
30- if (if (!(receivedAssetInLastNBlocks))
31- then !(feeMore1Waves)
32- else false)
33- then throw("You got potato long time ago, now you have to pay 1 WAVES fee")
34- else if (receivedAssetInLastNBlocks)
35- then true
36- else feeMore1Waves
37- case _ =>
38- throw("Receive tx should be a transfer")
39- }
40- }
41- case _ =>
42- throw("Not issue tx")
43- }
44- case burn: BurnTransaction =>
45- if ((minimalFeeToBurn > burn.fee))
46- then throw("You have to pay 5 WAVES to burn this token")
47- else true
48- case mass: SetAssetScriptTransaction|MassTransferTransaction =>
49- let transaction = transactionById(extract(mass.assetId))
50- match transaction {
51- case issueTx: IssueTransaction =>
52- (mass.senderPublicKey == issueTx.senderPublicKey)
53- case _ =>
54- throw("Bad issue tx type")
55- }
56- case _ =>
57- throw("You only can transfer this token")
58-}
3+true

github/deemru/w8io/6500d08 
39.63 ms