tx · Bv5yu3dy4FgVTRBGYHQdfn5deuyut25WyTwUPCKC41UK

3Mpwj347hnPHjU5ed4Dn1T64SBodhEyV3bm:  -0.01000000 Waves

2019.09.18 20:39 [682029] smart account 3Mpwj347hnPHjU5ed4Dn1T64SBodhEyV3bm > SELF 0.00000000 Waves

{ "type": 13, "id": "Bv5yu3dy4FgVTRBGYHQdfn5deuyut25WyTwUPCKC41UK", "fee": 1000000, "feeAssetId": null, "timestamp": 1568828409713, "version": 1, "sender": "3Mpwj347hnPHjU5ed4Dn1T64SBodhEyV3bm", "senderPublicKey": "EWiT7rqNUEAvTn4owsD2ydnNAC861rW6rfLzG3zfHSYB", "proofs": [ "4PuDcZeh6C2X2CwZ14GjxXBFjnRkK8Ntr4xxq1fNBVdwWiQTiGiyPQEjQ19h1t6mfzu8AaQksXERmGevcKzK6a77" ], "script": "base64:AAIDAAAAAAAAAAAAAAArAQAAABNnZXRFeHRBZGRyZXNzT3JhY2xlAAAAAAkBAAAAB2V4dHJhY3QAAAABCQEAAAARYWRkcmVzc0Zyb21TdHJpbmcAAAABAgAAACMzTjdqZVVoOTU1WEVWdWpyeXN0MjR0WEt6Vm0yZlhXc1pEUwAAAAALQkxBQ0tMSVNURUQCAAAACWJsYWNrbGlzdAAAAAALb3duZXJQdWJLZXkBAAAAIMjEpDsPgY9hgAzslF92ibQn3T9tfOenjF+oRhXyK3QUAAAAAAROT05FAgAAAARub25lAAAAAAZDTE9TRUQCAAAABWNsb3NlAAAAAAZPUEVORUQCAAAABG9wZW4BAAAADmdldE51bWJlckJ5S2V5AAAAAQAAAANrZXkEAAAAA251bQQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQAAAAAAAAAAAAUAAAADbnVtAQAAAAtnZXRTdHJCeUtleQAAAAEAAAADa2V5BAAAAANzdHIEAAAAByRtYXRjaDAJAAQ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AAAAAAAAAAABQAAAAtvd25lclB1YktleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAPRGF0YVRyYW5zYWN0aW9uBAAAAAFkBQAAAAckbWF0Y2gwBgMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAATVHJhbnNmZXJUcmFuc2FjdGlvbgQAAAABdAUAAAAHJG1hdGNoMAkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAFAAAAC293bmVyUHViS2V5B9LIk5g=", "chainId": 84, "height": 682029, "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
OldNewDifferences
1-# no script
1+{-# STDLIB_VERSION 3 #-}
2+{-# SCRIPT_TYPE ACCOUNT #-}
3+{-# CONTENT_TYPE DAPP #-}
4+func getExtAddressOracle () = extract(addressFromString("3N7jeUh955XEVujryst24tXKzVm2fXWsZDS"))
5+
6+
7+let BLACKLISTED = "blacklist"
8+
9+let ownerPubKey = base58'EWiT7rqNUEAvTn4owsD2ydnNAC861rW6rfLzG3zfHSYB'
10+
11+let NONE = "none"
12+
13+let CLOSED = "close"
14+
15+let OPENED = "open"
16+
17+func getNumberByKey (key) = {
18+ let num = match getInteger(this, key) {
19+ case a: Int =>
20+ a
21+ case _ =>
22+ 0
23+ }
24+ num
25+ }
26+
27+
28+func getStrByKey (key) = {
29+ let str = match getString(this, key) {
30+ case a: String =>
31+ a
32+ case _ =>
33+ NONE
34+ }
35+ str
36+ }
37+
38+
39+func getKeyRoom (roomer,title,data) = ("room_" + toBase58String(sha256(toBytes(((roomer + title) + data)))))
40+
41+
42+func getKeyRoomPrize (room) = (room + "_prize")
43+
44+
45+func getValueRoomPrize (room) = getNumberByKey(getKeyRoomPrize(room))
46+
47+
48+func getKeyRoomRoomer (room) = (room + "_roomer")
49+
50+
51+func getValueRoomRoomer (room) = getStrByKey(getKeyRoomRoomer(room))
52+
53+
54+func getKeyRoomLimit (room) = (room + "_limit")
55+
56+
57+func getValueRoomLimit (room) = getNumberByKey(getKeyRoomLimit(room))
58+
59+
60+func getKeyRoomStatus (room) = (room + "_status")
61+
62+
63+func getValueRoomStatus (room) = getStrByKey(getKeyRoomStatus(room))
64+
65+
66+func getKeyRoomData (room) = (room + "_data")
67+
68+
69+func getValueRoomData (room) = getStrByKey(getKeyRoomData(room))
70+
71+
72+func getKeyPropose (contributor,outline) = ("propose_" + toBase58String(sha256(toBytes((contributor + outline)))))
73+
74+
75+func getKeyProposeContributor (propose) = (propose + "_contributor")
76+
77+
78+func getValueProposeContributor (propose) = getStrByKey(getKeyProposeContributor(propose))
79+
80+
81+func getKeyProposeData (propose) = (propose + "_data")
82+
83+
84+func getValueProposeData (propose) = getStrByKey(getKeyProposeData(propose))
85+
86+
87+func getKeyAdoption (room,propose) = ("adoption_" + toBase58String(sha256(toBytes((room + propose)))))
88+
89+
90+func getKeyAdoptionWinner (adoption) = (adoption + "_winner")
91+
92+
93+func getValueAdoptionWinner (adoption) = getStrByKey(getKeyAdoptionWinner(adoption))
94+
95+
96+func getKeyAdoptionPrize (adoption) = (adoption + "_prize")
97+
98+
99+func getValueAdoptionPrize (adoption) = getStrByKey(getKeyAdoptionPrize(adoption))
100+
101+
102+func getKeyMealpolicyUser (account) = (account + "_mealpolicy")
103+
104+
105+func getValueMealpolicyUser (account) = getStrByKey(getKeyMealpolicyUser(account))
106+
107+
108+func getKeySexUser (account) = (account + "_sex")
109+
110+
111+func getValueSexUser (account) = getStrByKey(getKeySexUser(account))
112+
113+
114+func getKeyAgeUser (account) = (account + "_age")
115+
116+
117+func getValueAgeUser (account) = getNumberByKey(getKeyAgeUser(account))
118+
119+
120+func getKeyHobbyUser (account) = (account + "_hobby")
121+
122+
123+func getValueHobbyUser (account) = getStrByKey(getKeyHobbyUser(account))
124+
125+
126+func getKeyAreaUser (account) = (account + "_area")
127+
128+
129+func getValueAreaUser (account) = getStrByKey(getKeyAreaUser(account))
130+
131+
132+func getKeyBalanceUser (account) = (account + "_balance")
133+
134+
135+func getValueBalanceUser (account) = getNumberByKey(getKeyBalanceUser(account))
136+
137+
138+func getExtKeyUserBlackListStatus (account) = (account + "_blacklisted")
139+
140+
141+func getExtValueUserBlackListStatus (oracle,account) = {
142+ let str = match getString(oracle, getExtKeyUserBlackListStatus(account)) {
143+ case a: String =>
144+ a
145+ case _ =>
146+ NONE
147+ }
148+ str
149+ }
150+
151+
152+@Callable(i)
153+func setUser (account,mealpolicy,sex,age,hobby,area) = WriteSet([DataEntry(getKeyMealpolicyUser(account), mealpolicy), DataEntry(getKeySexUser(account), sex), DataEntry(getKeyAgeUser(account), age), DataEntry(getKeyHobbyUser(account), hobby), DataEntry(getKeyAreaUser(account), area)])
154+
155+
156+
157+@Callable(i)
158+func createRoom (title,data,now,duration) = {
159+ let pmt = extract(i.payment)
160+ if (isDefined(pmt.assetId))
161+ then throw("can use WAVES only at the moment")
162+ else {
163+ let roomer = toBase58String(i.caller.bytes)
164+ let room = getKeyRoom(roomer, title, data)
165+ let prize = pmt.amount
166+ let oracle = getExtAddressOracle()
167+ let roomerVerify = getExtValueUserBlackListStatus(oracle, roomer)
168+ let limit = (now + duration)
169+ if ((0 >= prize))
170+ then throw("prize cannot be negative amount")
171+ else if ((360 >= duration))
172+ then throw("duration cannot be less than 6hours")
173+ else if ((getValueRoomRoomer(room) != NONE))
174+ then throw("the room is already exist")
175+ else if ((roomerVerify == BLACKLISTED))
176+ then throw("your request was denied")
177+ else WriteSet([DataEntry(getKeyRoomPrize(room), prize), DataEntry(getKeyRoomRoomer(room), roomer), DataEntry(getKeyRoomLimit(room), limit), DataEntry(getKeyRoomStatus(room), OPENED), DataEntry(getKeyRoom(roomer, title, data), data)])
178+ }
179+ }
180+
181+
182+
183+@Callable(i)
184+func closeRoom (room) = {
185+ let roomer = getValueRoomRoomer(room)
186+ let prize = getValueRoomPrize(room)
187+ if ((roomer != toBase58String(i.caller.bytes)))
188+ then throw("you cannot close this Room")
189+ else if ((getValueRoomStatus(room) == CLOSED))
190+ then throw("this Room has already closed")
191+ else ScriptResult(WriteSet([DataEntry(getKeyRoomStatus(room), CLOSED)]), TransferSet([ScriptTransfer(addressFromStringValue(roomer), prize, unit)]))
192+ }
193+
194+
195+
196+@Callable(i)
197+func createProposal (room,data,outline,now) = {
198+ let contributor = toBase58String(i.caller.bytes)
199+ let oracle = getExtAddressOracle()
200+ let contributorVerify = getExtValueUserBlackListStatus(oracle, contributor)
201+ let propose = getKeyPropose(contributor, outline)
202+ let roomer = getValueRoomRoomer(room)
203+ let limit = getValueRoomLimit(room)
204+ if ((data == NONE))
205+ then throw("your proposal is empty")
206+ else if ((roomer == NONE))
207+ then throw("room does not exist")
208+ else if ((now >= limit))
209+ then throw("propose to this room is already closed")
210+ else if ((contributorVerify == BLACKLISTED))
211+ then throw("your request was denied")
212+ else if ((getValueRoomStatus(room) == CLOSED))
213+ then throw("this Room has already closed")
214+ else WriteSet([DataEntry(getKeyProposeContributor(propose), contributor), DataEntry(getKeyProposeData(propose), data)])
215+ }
216+
217+
218+
219+@Callable(i)
220+func createAdoption (room,propose) = {
221+ let adoption = getKeyAdoption(room, propose)
222+ let prize = getValueRoomPrize(room)
223+ let winner = getValueProposeContributor(propose)
224+ let roomer = getValueRoomRoomer(room)
225+ if ((roomer != toBase58String(i.caller.bytes)))
226+ then throw("only the Room's owner can do this transaction")
227+ else if ((winner == NONE))
228+ then throw("the winner doesn't exist")
229+ else if ((getValueAdoptionWinner(adoption) != NONE))
230+ then throw("you have already do the adoption")
231+ else if ((getValueRoomStatus(room) == CLOSED))
232+ then throw("this Room has already closed")
233+ else WriteSet([DataEntry(getKeyBalanceUser(winner), (getValueBalanceUser(winner) + prize)), DataEntry(getKeyAdoptionWinner(adoption), winner), DataEntry(getKeyAdoptionPrize(adoption), prize), DataEntry(getKeyRoomStatus(room), CLOSED)])
234+ }
235+
236+
237+
238+@Callable(i)
239+func withdraw () = {
240+ let user = toBase58String(i.caller.bytes)
241+ let balance = getValueBalanceUser(user)
242+ if ((0 >= balance))
243+ then throw("you have nothing to withdraw")
244+ else ScriptResult(WriteSet([DataEntry(getKeyBalanceUser(user), 0)]), TransferSet([ScriptTransfer(addressFromStringValue(user), balance, unit)]))
245+ }
246+
247+
248+@Verifier(tx)
249+func varify () = match tx {
250+ case s: SetScriptTransaction =>
251+ sigVerify(tx.bodyBytes, tx.proofs[0], ownerPubKey)
252+ case d: DataTransaction =>
253+ true
254+ case t: TransferTransaction =>
255+ sigVerify(tx.bodyBytes, tx.proofs[0], ownerPubKey)
256+ case _ =>
257+ false
258+}
259+

github/deemru/w8io/169f3d6 
86.36 ms