tx · DSAcTpaQdfnwGgFnSYFsGZYeoTsWB4dbhXAXC3VsdVb4

3Mz5wFCFSTfF4iW9me9EVrj4Ahm2VTCTsHZ:  -0.01400000 Waves

2019.06.23 12:36 [554515] smart account 3Mz5wFCFSTfF4iW9me9EVrj4Ahm2VTCTsHZ > SELF 0.00000000 Waves

{ "type": 13, "id": "DSAcTpaQdfnwGgFnSYFsGZYeoTsWB4dbhXAXC3VsdVb4", "fee": 1400000, "feeAssetId": null, "timestamp": 1561282636138, "version": 1, "sender": "3Mz5wFCFSTfF4iW9me9EVrj4Ahm2VTCTsHZ", "senderPublicKey": "55dGDbXbEiK5dkWmRvEkVpQP3ZxxA8qUV3xwxnBuD6Rg", "proofs": [ "3sLtfAGoecynmricF2ABgRenEqYzPPHnQmhVrFuSXz4ztgy37FyLuuRwHzwMdi6gpnqMqiLFWFavihZ3rfxKCtcr" ], "script": "base64:AAIDAAAAAAAAAAAAAAAeAAAAAAROT05FAgAAAARub25lAAAAAAZWT1RFUlMAAAAAAAAAAAMAAAAABlFVT1JVTQAAAAAAAAAAAgAAAAAGVk9USU5HAgAAAAZ2b3RpbmcAAAAABlJFVkVBTAIAAAAGcmV2ZWFsAAAAAAhGRUFUVVJFRAIAAAAIZmVhdHVyZWQAAAAACERFTElTVEVEAgAAAAhkZWxpc3RlZAAAAAAEd0VVUgEAAAAg+SHGy1pmNV9GZrG9FQtKAbSPH2Hck25AKl3UAeE+e4gBAAAACmdldEtleUl0ZW0AAAACAAAACHN1cHBsaWVyAAAABXRpdGxlCQABLAAAAAICAAAABWl0ZW1fCQACWAAAAAEJAAH3AAAAAQkAAZsAAAABCQABLAAAAAIFAAAACHN1cHBsaWVyBQAAAAV0aXRsZQEAAAASZ2V0S2V5SXRlbVN1cHBsaWVyAAAAAQAAAARpdGVtCQABLAAAAAIFAAAABGl0ZW0CAAAABl9vd25lcgEAAAAVZ2V0S2V5QmFsYW5jZVN1cHBsaWVyAAAAAQAAAARpdGVtCQABLAAAAAIFAAAAB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ACmN1cnJlbnRLZXkJAAJYAAAAAQgIBQAAAAFpAAAABmNhbGxlcgAAAAVieXRlcwQAAAANY3VycmVudEFtb3VudAQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzBQAAAApjdXJyZW50S2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAANJbnQEAAAAAWEFAAAAByRtYXRjaDAFAAAAAWEAAAAAAAAAAAAEAAAACW5ld0FNb3VudAkAAGUAAAACBQAAAA1jdXJyZW50QW1vdW50BQAAAAZhbW91bnQDCQAAZgAAAAIAAAAAAAAAAAAFAAAABmFtb3VudAkAAAIAAAABAgAAABhDYW4ndCB3ZCBuZWdhdGl2ZSBhbW91bnQDCQAAZgAAAAIAAAAAAAAAAAAFAAAACW5ld0FNb3VudAkAAAIAAAABAgAAAApub3QgZW5vdWdoCQEAAAAMU2NyaXB0UmVzdWx0AAAAAgkBAAAACFdyaXRlU2V0AAAAAQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgUAAAAKY3VycmVudEtleQUAAAAJbmV3QU1vdW50BQAAAANuaWwJAQAAAAtUcmFuc2ZlclNldAAAAAEJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwgFAAAAAWkAAAAGY2FsbGVyBQAAAAZhbW91bnQFAAAABHdFVVIFAAAAA25pbAAAAADFz9tF", "chainId": 84, "height": 554515, "spentComplexity": 0 } View: original | compacted Prev: XuBjMEQP8dRhCD9UXJfJhtueJQq1ZKGz2Ejv4uB5agz Next: 3WwJdvwomHk4fw5noNCvYWZNDEbx55cZqpdAEuZD5X25 Diff:
OldNewDifferences
1414 let FEATURED = "featured"
1515
1616 let DELISTED = "delisted"
17+
18+let wEUR = base58'HmWPZDMJ6zq2QCcpCMucVQtQuMGkCTkz37J5qjvUwJe3'
1719
1820 func getKeyItem (supplier,title) = ("item_" + toBase58String(sha256(toBytes((supplier + title)))))
1921
155157
156158
157159 @Callable(i)
158-func withdraw () = {
160+func withdrawO () = {
159161 let supplierAddress = toBase58String(i.caller.bytes)
160162 let balance = getValueBalanceSupplier(supplierAddress)
161163 if ((0 >= balance))
216218 }
217219
218220
221+
222+@Callable(i)
223+func deposit () = {
224+ let pmt = extract(i.payment)
225+ if ((pmt.assetId != wEUR))
226+ then throw("HmWPZDMJ6zq2QCcpCMucVQtQuMGkCTkz37J5qjvUwJe3 only at moment")
227+ else {
228+ let currentKey = toBase58String(i.caller.bytes)
229+ let currentAmount = match getInteger(this, currentKey) {
230+ case a: Int =>
231+ a
232+ case _ =>
233+ 0
234+ }
235+ let newAMount = (currentAmount + pmt.amount)
236+ WriteSet([DataEntry(currentKey, newAMount)])
237+ }
238+ }
239+
240+
241+
242+@Callable(i)
243+func withdraw (amount) = {
244+ let currentKey = toBase58String(i.caller.bytes)
245+ let currentAmount = match getInteger(this, currentKey) {
246+ case a: Int =>
247+ a
248+ case _ =>
249+ 0
250+ }
251+ let newAMount = (currentAmount - amount)
252+ if ((0 > amount))
253+ then throw("Can't wd negative amount")
254+ else if ((0 > newAMount))
255+ then throw("not enough")
256+ else ScriptResult(WriteSet([DataEntry(currentKey, newAMount)]), TransferSet([ScriptTransfer(i.caller, amount, wEUR)]))
257+ }
258+
259+
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let NONE = "none"
55
66 let VOTERS = 3
77
88 let QUORUM = 2
99
1010 let VOTING = "voting"
1111
1212 let REVEAL = "reveal"
1313
1414 let FEATURED = "featured"
1515
1616 let DELISTED = "delisted"
17+
18+let wEUR = base58'HmWPZDMJ6zq2QCcpCMucVQtQuMGkCTkz37J5qjvUwJe3'
1719
1820 func getKeyItem (supplier,title) = ("item_" + toBase58String(sha256(toBytes((supplier + title)))))
1921
2022
2123 func getKeyItemSupplier (item) = (item + "_owner")
2224
2325
2426 func getKeyBalanceSupplier (item) = (item + "_balance")
2527
2628
2729 func getKeyItemPrice (item) = (item + "_price")
2830
2931
3032 func getKeyItemData (item) = (item + "_data")
3133
3234
3335 func getKeyUserItemCounter (user,item) = (((item + "_") + user) + "_cnt")
3436
3537
3638 func getStrByKey (key) = {
3739 let str = match getString(this, key) {
3840 case a: String =>
3941 a
4042 case _ =>
4143 NONE
4244 }
4345 str
4446 }
4547
4648
4749 func getNumberByKey (key) = {
4850 let num = match getInteger(this, key) {
4951 case a: Int =>
5052 a
5153 case _ =>
5254 0
5355 }
5456 num
5557 }
5658
5759
5860 func getValueItemSupplier (item) = getStrByKey(getKeyItemSupplier(item))
5961
6062
6163 func getValueItemPrice (item) = getNumberByKey(getKeyItemPrice(item))
6264
6365
6466 func getValueUserItemCounter (user,item) = getNumberByKey(getKeyUserItemCounter(user, item))
6567
6668
6769 func getValueBalanceSupplier (account) = getNumberByKey(getKeyBalanceSupplier(account))
6870
6971
7072 func getKeyCommit (item,user) = (((item + "_") + user) + "_commit")
7173
7274
7375 func getValueCommit (item,user) = getStrByKey(getKeyCommit(item, user))
7476
7577
7678 func getKeyCommitsCount (item) = (item + "_comcnt")
7779
7880
7981 func getValueCommitsCount (item) = getNumberByKey(getKeyCommitsCount(item))
8082
8183
8284 func getKeyReveal (item,user) = (((item + "_") + user) + "_reveal")
8385
8486
8587 func getValueReveal (item,user) = getStrByKey(getKeyReveal(item, user))
8688
8789
8890 func getKeyItemStatus (item) = (item + "_status")
8991
9092
9193 func getValueItemStatus (item) = getStrByKey(getKeyItemStatus(item))
9294
9395
9496 func getKeyVoteCount (item,vote) = ((item + "_res:") + vote)
9597
9698
9799 func getValueVoteCount (item,vote) = getNumberByKey(getKeyVoteCount(item, vote))
98100
99101
100102 @Callable(i)
101103 func purchaseOld (type) = {
102104 let pmt = extract(i.payment)
103105 if (isDefined(pmt.assetId))
104106 then throw("can use WAVES only at the moment")
105107 else {
106108 let customerAddress = toBase58String(i.caller.bytes)
107109 let price = match getInteger(this, (("item_" + type) + "_coupon_price")) {
108110 case a: Int =>
109111 a
110112 case _ =>
111113 0
112114 }
113115 if ((price > pmt.amount))
114116 then throw("purschase amount cannot be less than item price")
115117 else if ((pmt.amount > price))
116118 then throw("purchase amount cannot be higher than item price")
117119 else WriteSet([DataEntry(((("status:purchase_item_" + type) + "_customer_") + customerAddress), "confirmed"), DataEntry(((("price:purchase_item_" + type) + "_customer_") + customerAddress), price)])
118120 }
119121 }
120122
121123
122124
123125 @Callable(i)
124126 func addItem (title,price,data) = {
125127 let supplierAddress = toBase58String(i.caller.bytes)
126128 let item = getKeyItem(supplierAddress, title)
127129 if ((0 >= price))
128130 then throw("purchase amount cannot be less than item price")
129131 else if ((getValueItemSupplier(item) != NONE))
130132 then throw("an items is already exist")
131133 else WriteSet([DataEntry(getKeyItemSupplier(item), supplierAddress), DataEntry(getKeyItemPrice(item), price), DataEntry(getKeyItemData(item), data)])
132134 }
133135
134136
135137
136138 @Callable(i)
137139 func purchase (item) = {
138140 let pmt = extract(i.payment)
139141 if (isDefined(pmt.assetId))
140142 then throw("WAVES tokens only at the moment")
141143 else {
142144 let userAddress = toBase58String(i.caller.bytes)
143145 let price = getValueItemPrice(item)
144146 let supplierAddress = getValueItemSupplier(item)
145147 if ((price > pmt.amount))
146148 then throw("purchase amount cannot be less than item price")
147149 else if ((pmt.amount > price))
148150 then throw("purchase amount cannot be higher than item price")
149151 else if ((supplierAddress == NONE))
150152 then throw("supplier does not exist")
151153 else WriteSet([DataEntry(getKeyUserItemCounter(userAddress, item), (getValueUserItemCounter(userAddress, item) + 1)), DataEntry(getKeyBalanceSupplier(supplierAddress), (getValueBalanceSupplier(supplierAddress) + pmt.amount))])
152154 }
153155 }
154156
155157
156158
157159 @Callable(i)
158-func withdraw () = {
160+func withdrawO () = {
159161 let supplierAddress = toBase58String(i.caller.bytes)
160162 let balance = getValueBalanceSupplier(supplierAddress)
161163 if ((0 >= balance))
162164 then throw("insufficient balance")
163165 else ScriptResult(WriteSet([DataEntry(getKeyBalanceSupplier(supplierAddress), 0)]), TransferSet([ScriptTransfer(addressFromStringValue(supplierAddress), balance, unit)]))
164166 }
165167
166168
167169
168170 @Callable(i)
169171 func voteCommit (item,hash) = {
170172 let user = toBase58String(i.caller.bytes)
171173 let commits = getValueCommitsCount(item)
172174 let status = getValueItemStatus(item)
173175 if ((commits >= VOTERS))
174176 then throw("max votes")
175177 else if ((getValueCommit(item, user) != NONE))
176178 then throw("already participated")
177179 else if ((getKeyItemSupplier(item) == NONE))
178180 then throw("item not exist")
179181 else if (if ((status != NONE))
180182 then (status != VOTING)
181183 else false)
182184 then throw("voting not possible")
183185 else WriteSet([DataEntry(getKeyCommit(item, user), hash), DataEntry(getKeyCommitsCount(item), (commits + 1)), DataEntry(getKeyItemStatus(item), if ((commits == VOTERS))
184186 then REVEAL
185187 else VOTING)])
186188 }
187189
188190
189191
190192 @Callable(i)
191193 func voteReveal (item,vote,salt) = {
192194 let user = toBase58String(i.caller.bytes)
193195 let status = getValueItemStatus(item)
194196 let newVoteCount = (getValueVoteCount(item, vote) + 1)
195197 if ((toBase58String(sha256(toBytes((vote + salt)))) != getValueCommit(item, user)))
196198 then throw("reveal data is not valid")
197199 else if ((VOTERS > getValueCommitsCount(item)))
198200 then throw("max num of voters not reached")
199201 else if ((getValueReveal(item, user) != NONE))
200202 then throw("user has already participated")
201203 else if (if ((status != VOTING))
202204 then (status != REVEAL)
203205 else false)
204206 then throw("wrong status")
205207 else if (if ((vote != FEATURED))
206208 then (vote != DELISTED)
207209 else false)
208210 then throw("wrong vote")
209211 else if (if ((status == FEATURED))
210212 then true
211213 else (status == DELISTED))
212214 then throw("vote finished")
213215 else WriteSet([DataEntry(getKeyReveal(item, user), vote), DataEntry(getKeyVoteCount(item, vote), newVoteCount), DataEntry(getKeyItemStatus(item), if ((newVoteCount >= QUORUM))
214216 then vote
215217 else REVEAL)])
216218 }
217219
218220
221+
222+@Callable(i)
223+func deposit () = {
224+ let pmt = extract(i.payment)
225+ if ((pmt.assetId != wEUR))
226+ then throw("HmWPZDMJ6zq2QCcpCMucVQtQuMGkCTkz37J5qjvUwJe3 only at moment")
227+ else {
228+ let currentKey = toBase58String(i.caller.bytes)
229+ let currentAmount = match getInteger(this, currentKey) {
230+ case a: Int =>
231+ a
232+ case _ =>
233+ 0
234+ }
235+ let newAMount = (currentAmount + pmt.amount)
236+ WriteSet([DataEntry(currentKey, newAMount)])
237+ }
238+ }
239+
240+
241+
242+@Callable(i)
243+func withdraw (amount) = {
244+ let currentKey = toBase58String(i.caller.bytes)
245+ let currentAmount = match getInteger(this, currentKey) {
246+ case a: Int =>
247+ a
248+ case _ =>
249+ 0
250+ }
251+ let newAMount = (currentAmount - amount)
252+ if ((0 > amount))
253+ then throw("Can't wd negative amount")
254+ else if ((0 > newAMount))
255+ then throw("not enough")
256+ else ScriptResult(WriteSet([DataEntry(currentKey, newAMount)]), TransferSet([ScriptTransfer(i.caller, amount, wEUR)]))
257+ }
258+
259+

github/deemru/w8io/026f985 
36.26 ms