tx · BL6WzUzS4V8iZKh2LgsAyKSWESevFWsYFikKHAZPw6cB 3N2me6psvxFDQgqi18wBLSt6cRxWWEiMEt2: -0.01000000 Waves 2021.03.18 18:11 [1443337] smart account 3N2me6psvxFDQgqi18wBLSt6cRxWWEiMEt2 > SELF 0.00000000 Waves
{ "type": 13, "id": "BL6WzUzS4V8iZKh2LgsAyKSWESevFWsYFikKHAZPw6cB", "fee": 1000000, "feeAssetId": null, "timestamp": 1616080339478, "version": 2, "chainId": 84, "sender": "3N2me6psvxFDQgqi18wBLSt6cRxWWEiMEt2", "senderPublicKey": "DuyN9NT6MPnqGAZBnw2ExqZAiE6fsKkhu1wwAmxqhane", "proofs": [ "EiJARZNGGQSc5vGB4VSDMHZPbbVQNKXwuRdRRuCaZSNfms3kfVGaL1wkw3yodnTsjsyJqLgAL9rDR7pbko9WVCQ" ], "script": "base64:AAIEAAAAAAAAADwIAhIDCgEIEgQKAggIEgYKBAgICAESBAoCCAgSBAoCCAgSBgoECAgBCBIFCgMICAgSBAoCCAgSBAoCCAgAAAADAAAAAAtFTVRQWVNUUklORwIAAAAAAQAAABBnZXRTdHJpbmdGcm9tS2V5AAAAAQAAAANrZXkEAAAAByRtYXRjaDAJAAQdAAAAAgUAAAAEdGhpcwUAAAADa2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAAZTdHJpbmcEAAAAA3N0cgUAAAAHJG1hdGNoMAUAAAADc3RyBQAAAAtFTVRQWVNUUklORwEAAAANaXNWYWxpZFNlbmRlcgAAAAEAAAAGc2VuZGVyBAAAABVlbnRyeUZvclNlbmRlckFkZHJlc3MJAQAAABBnZXRTdHJpbmdGcm9tS2V5AAAAAQUAAAAGc2VuZGVyAwkAAAAAAAACBQAAABVlbnRyeUZvclNlbmRlckFkZHJlc3MFAAAAC0VNVFBZU1RSSU5HBwYAAAAJAAAAAWkBAAAAB2FkZFVzZXIAAAABAAAABG5hbWUEAAAABnNlbmRlcgkAAlgAAAABCAgFAAAAAWkAAAAG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8FAAAAEnJlcXVpcmVtZW50QWRkcmVzcwIAAAALX3Rhc2tTdGF0dXMCAAAABkNMT1NFRAUAAAADbmlsCQAAAgAAAAECAAAAKVNlbmRlciBub3QgYWxsb3dlZCB0byBjaGFuZ2UgdGFzayBzdGF0dXMhAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAQAAAAHJG1hdGNoMAUAAAACdHgHBOJQIg==", "height": 1443337, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 4 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let EMTPYSTRING = "" | |
5 | + | ||
6 | + | func getStringFromKey (key) = match getString(this, key) { | |
7 | + | case str: String => | |
8 | + | str | |
9 | + | case _ => | |
10 | + | EMTPYSTRING | |
11 | + | } | |
12 | + | ||
13 | + | ||
14 | + | func isValidSender (sender) = { | |
15 | + | let entryForSenderAddress = getStringFromKey(sender) | |
16 | + | if ((entryForSenderAddress == EMTPYSTRING)) | |
17 | + | then false | |
18 | + | else true | |
19 | + | } | |
20 | + | ||
21 | + | ||
22 | + | @Callable(i) | |
23 | + | func addUser (name) = { | |
24 | + | let sender = toBase58String(i.caller.bytes) | |
25 | + | if (isValidSender(sender)) | |
26 | + | then [StringEntry((toBase58String(i.transactionId) + "_user"), name)] | |
27 | + | else throw("Sender not allowed to add users!") | |
28 | + | } | |
29 | + | ||
30 | + | ||
31 | + | ||
32 | + | @Callable(i) | |
33 | + | func addRequirement (requirement,requirementDescription) = { | |
34 | + | let sender = toBase58String(i.caller.bytes) | |
35 | + | if (isValidSender(sender)) | |
36 | + | then [StringEntry((toBase58String(i.transactionId) + "_requirementName"), requirement), StringEntry((toBase58String(i.transactionId) + "_requirementDescription"), requirementDescription)] | |
37 | + | else throw("Sender not allowed to add users!") | |
38 | + | } | |
39 | + | ||
40 | + | ||
41 | + | ||
42 | + | @Callable(i) | |
43 | + | func addMilestone (milestone,estimatedDate,createdDate,price) = { | |
44 | + | let sender = toBase58String(i.caller.bytes) | |
45 | + | if (isValidSender(sender)) | |
46 | + | then [StringEntry((toBase58String(i.transactionId) + "_milestoneDef"), milestone), StringEntry((toBase58String(i.transactionId) + "_milestoneEstimatedDate"), estimatedDate), StringEntry((toBase58String(i.transactionId) + "_milestoneCreatedDate"), createdDate), IntegerEntry((toBase58String(i.transactionId) + "_milestonePrice"), price)] | |
47 | + | else throw("Sender not allowed to add users!") | |
48 | + | } | |
49 | + | ||
50 | + | ||
51 | + | ||
52 | + | @Callable(i) | |
53 | + | func setMilestoneRequirementRelation (milestoneTransactionId,requirementTransactionId) = { | |
54 | + | let sender = toBase58String(i.caller.bytes) | |
55 | + | if (isValidSender(sender)) | |
56 | + | then [StringEntry((((toBase58String(i.transactionId) + "_milestone_") + milestoneTransactionId) + "_requirement"), requirementTransactionId)] | |
57 | + | else throw("Sender not allowed to add users!") | |
58 | + | } | |
59 | + | ||
60 | + | ||
61 | + | ||
62 | + | @Callable(i) | |
63 | + | func addAcceptanceCriteria (requirementAddress,acceptanceCriteria) = { | |
64 | + | let sender = toBase58String(i.caller.bytes) | |
65 | + | if (isValidSender(sender)) | |
66 | + | then [StringEntry((((toBase58String(i.transactionId) + "_requirement_") + requirementAddress) + "_acceptancecriteria"), acceptanceCriteria)] | |
67 | + | else throw("Sender not allowed to add users!") | |
68 | + | } | |
69 | + | ||
70 | + | ||
71 | + | ||
72 | + | @Callable(i) | |
73 | + | func addCommit (requirementAddress,taskAddress,amountCodeRows,createdAt) = { | |
74 | + | let sender = toBase58String(i.caller.bytes) | |
75 | + | if (isValidSender(sender)) | |
76 | + | then [IntegerEntry((((((((toBase58String(i.transactionId) + "_requirement_") + requirementAddress) + "_task_") + taskAddress) + "_user_") + sender) + "_commitRows"), amountCodeRows), StringEntry((((((((toBase58String(i.transactionId) + "_requirement_") + requirementAddress) + "_task_") + taskAddress) + "_user_") + sender) + "_commitCreated"), createdAt)] | |
77 | + | else throw("Sender not allowed to add commits!") | |
78 | + | } | |
79 | + | ||
80 | + | ||
81 | + | ||
82 | + | @Callable(i) | |
83 | + | func addTask (requirementAddress,taskname,taskdescrription) = { | |
84 | + | let sender = toBase58String(i.caller.bytes) | |
85 | + | if (isValidSender(sender)) | |
86 | + | then [StringEntry((((toBase58String(i.transactionId) + "_requirement_") + requirementAddress) + "_taskName"), taskname), StringEntry((((toBase58String(i.transactionId) + "_requirement_") + requirementAddress) + "_taskDescription"), taskdescrription), StringEntry((((toBase58String(i.transactionId) + "_requirement_") + requirementAddress) + "_taskStatus"), "OPEN")] | |
87 | + | else throw("Sender not allowed to add task!") | |
88 | + | } | |
89 | + | ||
90 | + | ||
91 | + | ||
92 | + | @Callable(i) | |
93 | + | func changeTasksStatusToInProgress (requirementAddress,taskAddress) = { | |
94 | + | let sender = toBase58String(i.caller.bytes) | |
95 | + | if (isValidSender(sender)) | |
96 | + | then [StringEntry((((taskAddress + "_requirement_") + requirementAddress) + "_taskStatus"), "IN PROGRESS")] | |
97 | + | else throw("Sender not allowed to add users!") | |
98 | + | } | |
99 | + | ||
100 | + | ||
101 | + | ||
102 | + | @Callable(i) | |
103 | + | func changeTasksStatusClosed (requirementAddress,taskAddress) = { | |
104 | + | let sender = toBase58String(i.caller.bytes) | |
105 | + | if (isValidSender(sender)) | |
106 | + | then [StringEntry((((taskAddress + "_requirement_") + requirementAddress) + "_taskStatus"), "CLOSED")] | |
107 | + | else throw("Sender not allowed to change task status!") | |
108 | + | } | |
109 | + | ||
110 | + | ||
111 | + | @Verifier(tx) | |
112 | + | func verify () = match tx { | |
113 | + | case _ => | |
114 | + | false | |
115 | + | } | |
116 | + |
github/deemru/w8io/03bedc9 17.71 ms ◑![]()