tx · 2A97KP4hDuDkMijpJ6n11H2xNJGvq8pSu2ZpUT7DUDQV

3N5NeYt7iWYDG4j3VR5iQXTZnjtbht2Z31k:  -0.01000000 Waves

2019.09.20 12:47 [684477] smart account 3N5NeYt7iWYDG4j3VR5iQXTZnjtbht2Z31k > SELF 0.00000000 Waves

{ "type": 13, "id": "2A97KP4hDuDkMijpJ6n11H2xNJGvq8pSu2ZpUT7DUDQV", "fee": 1000000, "feeAssetId": null, "timestamp": 1568972846163, "version": 1, "sender": "3N5NeYt7iWYDG4j3VR5iQXTZnjtbht2Z31k", "senderPublicKey": "7TX4vGpU3zQwPHBdYyWqos3HYCSJxNTubBS2TUM7vi8t", "proofs": [ "5NHeXDvG4fXN9jCkje3rgX23o3Jqq26L2ksoyGUHbWASQrjnQiE8AkQofAffugf6CjeM9Rr5JUaP7N1Yn7U6VtHg" ], "script": "base64:AAIDAAAAAAAAAAAAAAArAQAAABNnZXRFeHRBZGRyZXNzT3JhY2xlAAAAAAkBAAAAB2V4dHJhY3QAAAABCQEAAAARYWRkcmVzc0Zyb21TdHJpbmcAAAABAgAAACMzTjdqZVVoOTU1WEVWdWpyeXN0MjR0WEt6Vm0yZlhXc1pEUwAAAAALQkxBQ0tMSVNURUQCAAAACWJsYWNrbGlzdAAAAAALb3duZXJQdWJLZXkBAAAAIF/xOFgBKMQdYTG4DR5LuJpB1sdqfPhiOnS9nibBTwJ1AAAAAAROT05FAgAAAARub25lAAAAAAZDTE9TRUQCAAAABWNsb3NlAAAAAAZPUEVORUQCAAAABG9wZW4BAAAADmdldE51bWJlckJ5S2V5AAAAAQAAAANrZXkEAAAAA251bQQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQAAAAAAAAAAAAUAAAADbnVtAQAAAAtnZXRTdHJCeUtleQAAAAEAAAADa2V5BAAAAANzdHIEAAAAByRt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mcpAAAAAQUAAAAEdXNlcgUAAAAHYmFsYW5jZQUAAAAEdW5pdAUAAAADbmlsAAAAAQAAAAJ0eAEAAAAGdmFyaWZ5AAAAAAQAAAAHJG1hdGNoMAUAAAACdHgDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAFFNldFNjcmlwdFRyYW5zYWN0aW9uBAAAAAFzBQAAAAckbWF0Y2gwCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAUAAAALb3duZXJQdWJLZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAD0RhdGFUcmFuc2FjdGlvbgQAAAABZAUAAAAHJG1hdGNoMAYDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAE1RyYW5zZmVyVHJhbnNhY3Rpb24EAAAAAXQFAAAAByRtYXRjaDAJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAABQAAAAtvd25lclB1YktleQd9TA0b", "chainId": 84, "height": 684477, "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'7TX4vGpU3zQwPHBdYyWqos3HYCSJxNTubBS2TUM7vi8t'
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,data) = ("propose_" + toBase58String(sha256(toBytes(((contributor + outline) + data)))))
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) = (toBase58String(sha256(toBytes(account))) + "_mealpolicy")
103+
104+
105+func getValueMealpolicyUser (account) = getStrByKey(getKeyMealpolicyUser(account))
106+
107+
108+func getKeySexUser (account) = (toBase58String(sha256(toBytes(account))) + "_sex")
109+
110+
111+func getValueSexUser (account) = getStrByKey(getKeySexUser(account))
112+
113+
114+func getKeyAgeUser (account) = (toBase58String(sha256(toBytes(account))) + "_age")
115+
116+
117+func getValueAgeUser (account) = getNumberByKey(getKeyAgeUser(account))
118+
119+
120+func getKeyHobbyUser (account) = (toBase58String(sha256(toBytes(account))) + "_hobby")
121+
122+
123+func getValueHobbyUser (account) = getStrByKey(getKeyHobbyUser(account))
124+
125+
126+func getKeyAreaUser (account) = (toBase58String(sha256(toBytes(account))) + "_area")
127+
128+
129+func getValueAreaUser (account) = getStrByKey(getKeyAreaUser(account))
130+
131+
132+func getKeyBalanceUser (account) = (toBase58String(sha256(toBytes(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, data)
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/026f985 
27.29 ms