tx · EB5E3XbRok1yGfrr3ZN98HmssW9jTzEgxBNrdPzVPvyQ

3N2EM5HFgf6UMBnvcJX3Cegmozwdv1iDeq2:  -0.01500000 Waves

2019.09.29 16:22 [697779] smart account 3N2EM5HFgf6UMBnvcJX3Cegmozwdv1iDeq2 > SELF 0.00000000 Waves

{ "type": 13, "id": "EB5E3XbRok1yGfrr3ZN98HmssW9jTzEgxBNrdPzVPvyQ", "fee": 1500000, "feeAssetId": null, "timestamp": 1569763370972, "version": 1, "sender": "3N2EM5HFgf6UMBnvcJX3Cegmozwdv1iDeq2", "senderPublicKey": "8y2Uc9uYf5gRD6Dzm1aC73zYe3LZvtVDUVAnAhNdN2mg", "proofs": [ "2Lqcqj7Kiv1nZirByKuLbtHoQZhhU7rEzN6WFQQKDRLPnXuiNv4TrMkNpGoGLQDuYrVGUspcJ6Mt3Kn7NwvnvXYR" ], "script": "base64:AAIDAAAAAAAAAD8IARIDCgEIEgMKAQgSBQoDAQEIEgQKAggBEgQKAggIEgQKAggBEgMKAQgSAwoBCBIECgIICBIDCgEIEgMKAQgAAAAjAAAAAANkYXkAAAAAAAAABaAAAAAABVdBVkVTBQAAAAR1bml0AAAAAAR3QlRDAQAAACBs+mr/xe2qjAt/tSqT0qIML4KC23R6BIxT+/0TH3Og/wAAAAAEd0VVUgEAAAAg7BZhBF97kSFBBjs38+fX1Pjz08YOqoCX85C/0PoVupkAAAAABHdVU0QBAAAAIN0cvQHwz3UFMHgHsqi2OJjRRd1cH7ozWuNAb/pmWXD9AAAAAAlzdGF0ZU9wZW4CAAAABk9wZW5lZAAAAAAOc3RhdGVTdWdnZXN0ZWQCAAAACVN1Z2dlc3RlZAAAAAALc3RhdGVDYW5jZWwCAAAACENhbmNlbGVkAAAAAA9zdGF0ZUluUHJvZ3Jlc3MCAAAACkluUHJvZ3Jlc3MAAAAAEXN0YXRlV2FpdDRDb25maXJtAgAAABNXYWl0Rm9yQ29uZmlybWF0aW9uAAAAAA1zdGF0ZUNvbXBsZXR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zCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAIBQAAAAJ0eAAAAA9zZW5kZXJQdWJsaWNLZXkEAAAAByRtYXRjaDAFAAAAAnR4AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAABNUcmFuc2ZlclRyYW5zYWN0aW9uBAAAAAN0dHgFAAAAByRtYXRjaDAGAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAABRTZXRTY3JpcHRUcmFuc2FjdGlvbgQAAAADc3R4BQAAAAckbWF0Y2gwBgcHJ5u+KQ==", "chainId": 84, "height": 697779, "spentComplexity": 0 } View: original | compacted Prev: CvwrnBQyiABCgLwSjiYZVqzJyRy4wxXsaFABh8Xj8ox4 Next: 2e9DKsK2rCgq7KyhbBeoM1SoEcKyMyJnYUdRVYYa4JP5 Diff:
OldNewDifferences
4242 let ambassador5 = base58'1'
4343
4444 func AuctionIdDataKey (auctionId) = (auctionId + "_AuctionData")
45-
46-
47-func getDataList (auctionId) = {
48- let getDataString = getString(this, auctionId)
49- let a = match getDataString {
50- case a: String =>
51- a
52- case _ =>
53- throw("AuctionId was not found")
54- }
55- split(a, "_")
56- }
57-
58-
59-func getDisputeDataList (auctionId) = {
60- let keyDisputeData = ((auctionId + "_") + stateDispute)
61- let getDisputeDataString = getString(this, keyDisputeData)
62- let a = match getDisputeDataString {
63- case a: String =>
64- a
65- case _ =>
66- throw("Dispute data was not found")
67- }
68- split(a, "/")
69- }
7045
7146
7247 func AssetNameToBase58 (auctionAssetName) = if ((auctionAssetName == "WAVES"))
12196 }
12297
12398
99+func createAuctionPriceCheck (pmtAmount) = if ((pmtAmount > 0))
100+ then pmtAmount
101+ else throw("Amount must be higher then 0")
102+
103+
104+func getAuctionState (auctionId) = {
105+ let valueState = getString(this, (auctionId + "_State"))
106+ match valueState {
107+ case a: String =>
108+ a
109+ case _ =>
110+ throw("Auction State was not found")
111+ }
112+ }
113+
114+
115+func getAuctionClientPub (auctionId) = {
116+ let valueClient = getString(this, (auctionId + "_Client"))
117+ let a = match valueClient {
118+ case a: String =>
119+ a
120+ case _ =>
121+ throw("Auction Client was not found")
122+ }
123+ fromBase58String(a)
124+ }
125+
126+
127+func getAuctionStartTime (auctionId) = {
128+ let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
129+ match valueAuctionStart {
130+ case a: Int =>
131+ a
132+ case _ =>
133+ throw("Auction Start time was not found")
134+ }
135+ }
136+
137+
138+func getAuctionDurationTime (auctionId) = {
139+ let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
140+ match valueauctionDuration {
141+ case a: Int =>
142+ a
143+ case _ =>
144+ throw("Auction duration time was not found")
145+ }
146+ }
147+
148+
149+func getAuctionJobPerformanceTime (auctionId) = {
150+ let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
151+ match valueBlocksForExecution {
152+ case a: Int =>
153+ a
154+ case _ =>
155+ throw("Auction job performance time was not found")
156+ }
157+ }
158+
159+
160+func getAuctionAssetName (auctionId) = {
161+ let valueAssetName = getString(this, (auctionId + "_AssetName"))
162+ match valueAssetName {
163+ case a: String =>
164+ a
165+ case _ =>
166+ throw("Auction asset name was not found")
167+ }
168+ }
169+
170+
171+func getAuctionPrice (auctionId) = {
172+ let valuePrice = getInteger(this, (auctionId + "_Price"))
173+ match valuePrice {
174+ case a: Int =>
175+ a
176+ case _ =>
177+ throw("Auction price was not found")
178+ }
179+ }
180+
181+
182+func getAuctionFreelancerPub (auctionId) = {
183+ let valueClient = getString(this, (auctionId + "_Freelancer"))
184+ let a = match valueClient {
185+ case a: String =>
186+ a
187+ case _ =>
188+ throw("Auction Client was not found")
189+ }
190+ fromBase58String(a)
191+ }
192+
193+
124194 @Callable(i)
125195 func freelancerSignUp (info) = {
126196 let userPublicKey = toBase58String(i.callerPublicKey)
149219 let auctionClient = toBase58String(i.callerPublicKey)
150220 let pmt = extract(i.payment)
151221 let pmtAmount = pmt.amount
152- let auctionPrice = if ((pmtAmount > 0))
153- then pmtAmount
154- else throw("Amount must be higher then 0")
222+ let auctionPrice = createAuctionPriceCheck(pmtAmount)
155223 let auctionStart = height
156224 let auctionDurationBlocks = (auctionDurationDays * day)
157225 let blocksForExecution = (jobExecutionDays * day)
174242 func makeBid (auctionId,betPrice) = {
175243 let callerPub = toBase58String(i.callerPublicKey)
176244 let betTime = height
177- let auctionState = {
178- let valueState = getString(this, (auctionId + "_State"))
179- match valueState {
180- case a: String =>
181- a
182- case _ =>
183- throw("Auction State was not found")
184- }
185- }
186- let auctionInfo = {
187- let valueAuctionInfo = getString(this, (auctionId + "_Info"))
188- match valueAuctionInfo {
189- case a: String =>
190- a
191- case _ =>
192- throw("Auction info was not found")
193- }
194- }
195- let auctionClient = {
196- let valueClient = getString(this, (auctionId + "_Client"))
197- let a = match valueClient {
198- case a: String =>
199- a
200- case _ =>
201- throw("Auction Client was not found")
202- }
203- fromBase58String(a)
204- }
205- let auctionStart = {
206- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
207- match valueAuctionStart {
208- case a: Int =>
209- a
210- case _ =>
211- throw("Auction Start time was not found")
212- }
213- }
214- let auctionDuration = {
215- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
216- match valueauctionDuration {
217- case a: Int =>
218- a
219- case _ =>
220- throw("Auction duration time was not found")
221- }
222- }
223- let auctionBlocksForExecution = {
224- let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
225- match valueBlocksForExecution {
226- case a: Int =>
227- a
228- case _ =>
229- throw("Auction job performance time was not found")
230- }
231- }
232- let auctionAssetName = {
233- let valueAssetName = getString(this, (auctionId + "_AssetName"))
234- match valueAssetName {
235- case a: String =>
236- a
237- case _ =>
238- throw("Auction asset name was not found")
239- }
240- }
241- let auctionPrice = {
242- let valuePrice = getInteger(this, (auctionId + "_Price"))
243- match valuePrice {
244- case a: Int =>
245- a
246- case _ =>
247- throw("Auction price was not found")
248- }
249- }
245+ let auctionState = getAuctionState(auctionId)
246+ let auctionClient = getAuctionClientPub(auctionId)
247+ let auctionStart = getAuctionStartTime(auctionId)
248+ let auctionDuration = getAuctionDurationTime(auctionId)
249+ let auctionBlocksForExecution = getAuctionJobPerformanceTime(auctionId)
250+ let auctionAssetName = getAuctionAssetName(auctionId)
251+ let auctionPrice = getAuctionPrice(auctionId)
250252 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
251253 let newFreelancer = freelancerIsRegistered(callerPub)
252254 let dAppCommission = ((auctionPrice * 3) / 100)
280282 }
281283 else throw("Incorrect auction state")
282284 else if ((auctionState == stateOpen))
283- then WriteSet([DataEntry(((auctionId + "_Bid_") + newFreelancer), betPrice), DataEntry((auctionId + "_State"), stateSuggested), DataEntry((auctionId + "_LowestBidderPub"), callerPub), DataEntry((auctionId + callerPub), betPrice)])
285+ then WriteSet([DataEntry(((auctionId + "_Bid_") + newFreelancer), betPrice), DataEntry((auctionId + "_State"), stateSuggested), DataEntry((auctionId + "_LowestBidderPub"), callerPub)])
284286 else if ((auctionState == stateSuggested))
285287 then {
286288 let currentLowestBidderPub = {
315317 func chooseFreelancer (auctionId,freelancerPub) = {
316318 let callerPub = extract(i.callerPublicKey)
317319 let betTime = height
318- let auctionState = {
319- let valueState = getString(this, (auctionId + "_State"))
320- match valueState {
321- case a: String =>
322- a
323- case _ =>
324- throw("Auction State was not found")
325- }
326- }
327- let auctionClient = {
328- let valueClient = getString(this, (auctionId + "_Client"))
329- let a = match valueClient {
330- case a: String =>
331- a
332- case _ =>
333- throw("Auction Client was not found")
334- }
335- fromBase58String(a)
336- }
337- let auctionStart = {
338- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
339- match valueAuctionStart {
340- case a: Int =>
341- a
342- case _ =>
343- throw("Auction Start time was not found")
344- }
345- }
346- let auctionDuration = {
347- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
348- match valueauctionDuration {
349- case a: Int =>
350- a
351- case _ =>
352- throw("Auction duration time was not found")
353- }
354- }
355- let auctionAssetName = {
356- let valueAssetName = getString(this, (auctionId + "_AssetName"))
357- match valueAssetName {
358- case a: String =>
359- a
360- case _ =>
361- throw("Auction asset name was not found")
362- }
363- }
364- let auctionPrice = {
365- let valuePrice = getInteger(this, (auctionId + "_Price"))
366- match valuePrice {
367- case a: Int =>
368- a
369- case _ =>
370- throw("Auction price was not found")
371- }
372- }
320+ let auctionState = getAuctionState(auctionId)
321+ let auctionClient = getAuctionClientPub(auctionId)
322+ let auctionStart = getAuctionStartTime(auctionId)
323+ let auctionDuration = getAuctionDurationTime(auctionId)
324+ let auctionAssetName = getAuctionAssetName(auctionId)
325+ let auctionPrice = getAuctionPrice(auctionId)
373326 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
374327 let freelancerBidAmount = {
375328 let keyFreelancerBid = ((auctionId + "_Bid_") + freelancerPub)
381334 throw("Freelancer's bet was not found")
382335 }
383336 }
384- let dAppCommission = ((auctionPrice * 3) / 100)
385- let amountDifference = ((auctionPrice - freelancerBidAmount) - dAppCommission)
337+ let dAppCommission = ((freelancerBidAmount * 3) / 100)
386338 let auctionTimeisOver = timeCheck(betTime, auctionStart, auctionDuration)
387339 if ((callerPub == auctionClient))
388340 then if (auctionTimeisOver)
389341 then if ((auctionState == stateOpen))
390342 then {
391- let newPrice = (auctionPrice - dAppCommission)
392- let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, newPrice)
393- ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateCancel), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), newPrice, auctionAssetId58)]))
343+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
344+ ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateCancel), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), (auctionPrice - dAppCommission), auctionAssetId58)]))
394345 }
395346 else if ((auctionState == stateSuggested))
396347 then {
412363 throw("Auction lowest bid was not found")
413364 }
414365 }
415- WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), auctionLowestBidder), DataEntry((auctionId + "_Price"), newAuctionPrice)])
366+ let amountDifference = (auctionPrice - newAuctionPrice)
367+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, amountDifference)
368+ ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), auctionLowestBidder), DataEntry((auctionId + "_Price"), newAuctionPrice), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), amountDifference, auctionAssetId58)]))
416369 }
417370 else throw("Incorrect auction state")
418371 else {
425378 throw("Error: Incorrect freelancerPub")
426379 }
427380 }
428- let setNewPrice = {
381+ let newAuctionPrice = {
429382 let freelancerBid = getInteger(this, ((auctionId + "_Bid_") + freelancerPub))
430383 match freelancerBid {
431384 case a: Int =>
434387 throw("Auction lowest bidder was not found")
435388 }
436389 }
437- let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, setNewPrice)
438- ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), setNewFreelancer), DataEntry((auctionId + "_Price"), setNewPrice), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), amountDifference, auctionAssetId58)]))
390+ let amountDifference = (auctionPrice - freelancerBidAmount)
391+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, amountDifference)
392+ ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), setNewFreelancer), DataEntry((auctionId + "_Price"), newAuctionPrice), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), (amountDifference - dAppCommission), auctionAssetId58)]))
439393 }
440394 else throw("Only auction customer can choose a freelancer")
441395 }
445399 @Callable(i)
446400 func increaseExecutionTime (auctionId,executionDays) = {
447401 let caller = extract(i.callerPublicKey)
448- let auctionState = {
449- let valueState = getString(this, (auctionId + "_State"))
450- match valueState {
451- case a: String =>
452- a
453- case _ =>
454- throw("Auction State was not found")
455- }
456- }
457- let auctionClient = {
458- let valueClient = getString(this, (auctionId + "_Client"))
459- let a = match valueClient {
460- case a: String =>
461- a
462- case _ =>
463- throw("Auction Client was not found")
464- }
465- fromBase58String(a)
466- }
467- let auctionExecutionTime = {
468- let valueBlocksForExecution = getInteger(this, (auctionId + "JobPerformance"))
469- match valueBlocksForExecution {
470- case a: Int =>
471- a
472- case _ =>
473- throw("Auction job performance time was not found")
474- }
475- }
402+ let auctionState = getAuctionState(auctionId)
403+ let auctionClient = getAuctionClientPub(auctionId)
404+ let auctionBlocksForExecution = getAuctionJobPerformanceTime(auctionId)
476405 let newAuctionExecutionTime = {
477406 let newAuctionBlocksForExecution = (executionDays * day)
478- if ((newAuctionBlocksForExecution > auctionExecutionTime))
407+ if ((newAuctionBlocksForExecution > auctionBlocksForExecution))
479408 then newAuctionBlocksForExecution
480409 else throw("New execution time must more than current execution time")
481410 }
495424 @Callable(i)
496425 func cancelAuction (auctionId) = {
497426 let callerPub = extract(i.callerPublicKey)
498- let auctionState = {
499- let valueState = getString(this, (auctionId + "_State"))
500- match valueState {
501- case a: String =>
502- a
503- case _ =>
504- throw("Auction State was not found")
505- }
506- }
507- let auctionClient = {
508- let valueClient = getString(this, (auctionId + "_Client"))
509- let a = match valueClient {
510- case a: String =>
511- a
512- case _ =>
513- throw("Auction Client was not found")
514- }
515- fromBase58String(a)
516- }
427+ let auctionState = getAuctionState(auctionId)
428+ let auctionClient = getAuctionClientPub(auctionId)
429+ let auctionAssetName = getAuctionAssetName(auctionId)
430+ let auctionPrice = getAuctionPrice(auctionId)
431+ let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
432+ let dAppCommission = ((auctionPrice * 3) / 100)
433+ let amountWithoutComm = (auctionPrice - dAppCommission)
434+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
517435 let callerIsClient = if ((callerPub == auctionClient))
518436 then true
519- else throw("Auction can be canceled only by owner.")
437+ else throw("Auction can be canceled only by auction owner.")
520438 if (callerIsClient)
521439 then if ((auctionState == stateOpen))
522- then WriteSet([DataEntry((auctionId + "_State"), stateCancel)])
440+ then ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateCancel), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), amountWithoutComm, auctionAssetId58)]))
523441 else throw("Incorrect auction state.")
524442 else throw("Only Client can cancel auction")
525443 }
529447 @Callable(i)
530448 func openDispute (auctionId) = {
531449 let caller = extract(i.callerPublicKey)
532- let auctionState = {
533- let valueState = getString(this, (auctionId + "_State"))
534- match valueState {
535- case a: String =>
536- a
537- case _ =>
538- throw("Auction State was not found")
539- }
540- }
541- let auctionClient = {
542- let valueClient = getString(this, (auctionId + "_Client"))
543- let a = match valueClient {
544- case a: String =>
545- a
546- case _ =>
547- throw("Auction Client was not found")
548- }
549- fromBase58String(a)
550- }
551- let auctionFreelancer = {
552- let valueClient = getString(this, (auctionId + "_Freelancer"))
553- let a = match valueClient {
554- case a: String =>
555- a
556- case _ =>
557- throw("Auction Client was not found")
558- }
559- fromBase58String(a)
560- }
450+ let auctionState = getAuctionState(auctionId)
451+ let auctionClient = getAuctionClientPub(auctionId)
452+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
561453 if (if ((auctionState == stateOpen))
562454 then true
563455 else (auctionState == stateSuggested))
574466 @Callable(i)
575467 func voteDispute (auctionId,vote) = {
576468 let callerPub = extract(i.callerPublicKey)
577- let auctionState = {
578- let valueState = getString(this, (auctionId + "_State"))
579- match valueState {
580- case a: String =>
581- a
582- case _ =>
583- throw("Auction State was not found")
584- }
585- }
586- let auctionClient = {
587- let valueClient = getString(this, (auctionId + "_Client"))
588- let a = match valueClient {
589- case a: String =>
590- a
591- case _ =>
592- throw("Auction Client was not found")
593- }
594- fromBase58String(a)
595- }
596- let auctionAssetName = {
597- let valueAssetName = getString(this, (auctionId + "_AssetName"))
598- match valueAssetName {
599- case a: String =>
600- a
601- case _ =>
602- throw("Auction asset name was not found")
603- }
604- }
605- let auctionPrice = {
606- let valuePrice = getInteger(this, (auctionId + "_Price"))
607- match valuePrice {
608- case a: Int =>
609- a
610- case _ =>
611- throw("Auction price was not found")
612- }
613- }
614- let auctionFreelancer = {
615- let valueClient = getString(this, (auctionId + "_Freelancer"))
616- let a = match valueClient {
617- case a: String =>
618- a
619- case _ =>
620- throw("Auction Client was not found")
621- }
622- fromBase58String(a)
623- }
469+ let auctionState = getAuctionState(auctionId)
470+ let auctionClient = getAuctionClientPub(auctionId)
471+ let auctionAssetName = getAuctionAssetName(auctionId)
472+ let auctionPrice = getAuctionPrice(auctionId)
473+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
624474 let comission = ((auctionPrice * 3) / 100)
625475 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
626476 let callerIsAmbassador = if (if (if (if (if ((callerPub == ambassador1))
693543 let paymentWithoutComm = if ((disputeWinner == auctionClient))
694544 then auctionPrice
695545 else (auctionPrice - comission)
696- let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, paymentWithoutComm)
546+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
697547 ScriptResult(WriteSet([DataEntry((auctionId + "_DisputeVotes"), (votesNumber + 1)), DataEntry((auctionId + "_State"), stateDisputeResolved), DataEntry(((auctionId + "_DiputeVote_") + callerIsAmbassador), newVote), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(disputeWinner), paymentWithoutComm, auctionAssetId58)]))
698548 }
699549 else WriteSet([DataEntry((auctionId + "_DisputeVotes"), (votesNumber + 1)), DataEntry(((auctionId + "_DiputeVote_") + callerIsAmbassador), newVote)])
705555 @Callable(i)
706556 func workHandOver (auctionId) = {
707557 let callerPub = extract(i.callerPublicKey)
708- let auctionState = {
709- let valueState = getString(this, (auctionId + "_State"))
710- match valueState {
711- case a: String =>
712- a
713- case _ =>
714- throw("Auction State was not found")
715- }
716- }
717- let auctionStart = {
718- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
719- match valueAuctionStart {
720- case a: Int =>
721- a
722- case _ =>
723- throw("Auction Start time was not found")
724- }
725- }
726- let auctionDuration = {
727- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
728- match valueauctionDuration {
729- case a: Int =>
730- a
731- case _ =>
732- throw("Auction duration time was not found")
733- }
734- }
735- let auctionExecutionTime = {
736- let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
737- match valueBlocksForExecution {
738- case a: Int =>
739- a
740- case _ =>
741- throw("Auction job performance time was not found")
742- }
743- }
744- let auctionFreelancer = {
745- let valueClient = getString(this, (auctionId + "_Freelancer"))
746- let a = match valueClient {
747- case a: String =>
748- a
749- case _ =>
750- throw("Auction Client was not found")
751- }
752- fromBase58String(a)
753- }
558+ let auctionState = getAuctionState(auctionId)
559+ let auctionStart = getAuctionStartTime(auctionId)
560+ let auctionDuration = getAuctionDurationTime(auctionId)
561+ let auctionBlocksForExecution = getAuctionJobPerformanceTime(auctionId)
562+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
754563 let currentTime = height
755564 let freelancerPubCheck = if ((callerPub == auctionFreelancer))
756565 then callerPub
757566 else throw("Only a freelancer can indicate that the work is done")
758- let timeIsOver = ((currentTime - auctionStart) > auctionExecutionTime)
567+ let timeIsOver = ((currentTime - auctionStart) > auctionBlocksForExecution)
759568 if ((auctionState == stateInProgress))
760569 then if (timeIsOver)
761570 then WriteSet([DataEntry((auctionId + "_State"), stateDispute), DataEntry((auctionId + "_DisputeVotes"), "0")])
768577 @Callable(i)
769578 func acceptWork (auctionId) = {
770579 let callerPub = extract(i.callerPublicKey)
771- let auctionState = {
772- let valueState = getString(this, (auctionId + "_State"))
773- match valueState {
774- case a: String =>
775- a
776- case _ =>
777- throw("Auction State was not found")
778- }
779- }
780- let auctionClient = {
781- let valueClient = getString(this, (auctionId + "_Client"))
782- let a = match valueClient {
783- case a: String =>
784- a
785- case _ =>
786- throw("Auction Client was not found")
787- }
788- fromBase58String(a)
789- }
790- let auctionStart = {
791- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
792- match valueAuctionStart {
793- case a: Int =>
794- a
795- case _ =>
796- throw("Auction Start time was not found")
797- }
798- }
799- let auctionDuration = {
800- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
801- match valueauctionDuration {
802- case a: Int =>
803- a
804- case _ =>
805- throw("Auction duration time was not found")
806- }
807- }
808- let auctionExecutionTime = {
809- let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
810- match valueBlocksForExecution {
811- case a: Int =>
812- a
813- case _ =>
814- throw("Auction job performance time was not found")
815- }
816- }
817- let auctionAssetName = {
818- let valueAssetName = getString(this, (auctionId + "_AssetName"))
819- match valueAssetName {
820- case a: String =>
821- a
822- case _ =>
823- throw("Auction asset name was not found")
824- }
825- }
826- let auctionPrice = {
827- let valuePrice = getInteger(this, (auctionId + "_Price"))
828- match valuePrice {
829- case a: Int =>
830- a
831- case _ =>
832- throw("Auction price was not found")
833- }
834- }
835- let auctionFreelancer = {
836- let valueClient = getString(this, (auctionId + "_Freelancer"))
837- let a = match valueClient {
838- case a: String =>
839- a
840- case _ =>
841- throw("Auction Client was not found")
842- }
843- fromBase58String(a)
844- }
580+ let auctionState = getAuctionState(auctionId)
581+ let auctionClient = getAuctionClientPub(auctionId)
582+ let auctionStart = getAuctionStartTime(auctionId)
583+ let auctionDuration = getAuctionDurationTime(auctionId)
584+ let auctionAssetName = getAuctionAssetName(auctionId)
585+ let auctionPrice = getAuctionPrice(auctionId)
586+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
845587 let dAppCommission = ((auctionPrice * 3) / 100)
846588 let amountWithoutComm = (auctionPrice - dAppCommission)
847589 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
590+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
848591 let newRating = {
849592 let valueRating = getInteger(this, (toBase58String(auctionFreelancer) + "_Rating"))
850593 let currentRating = match valueRating {
857600 }
858601 if ((callerPub == auctionClient))
859602 then if ((auctionState == stateWait4Confirm))
860- then ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateComplete), DataEntry((toBase58String(auctionFreelancer) + "_Rating"), newRating)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionFreelancer), amountWithoutComm, auctionAssetId58)]))
603+ then ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateComplete), DataEntry((toBase58String(auctionFreelancer) + "_Rating"), newRating), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionFreelancer), amountWithoutComm, auctionAssetId58)]))
861604 else throw(("Incorrect state. Must be: " + stateWait4Confirm))
862605 else throw("Only auction customer can use this function")
863606 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let day = 1440
55
66 let WAVES = unit
77
88 let wBTC = base58'8LQW8f7P5d5PZM7GtZEBgaqRPGSzS3DfPuiXrURJ4AJS'
99
1010 let wEUR = base58'Gtb1WRznfchDnTh37ezoDTJ4wcoKaRsKqKjJjy7nm2zU'
1111
1212 let wUSD = base58'Ft8X1v1LTa1ABafufpaCWyVj8KkaxUWE6xBhW6sNFJck'
1313
1414 let stateOpen = "Opened"
1515
1616 let stateSuggested = "Suggested"
1717
1818 let stateCancel = "Canceled"
1919
2020 let stateInProgress = "InProgress"
2121
2222 let stateWait4Confirm = "WaitForConfirmation"
2323
2424 let stateComplete = "Completed"
2525
2626 let stateDispute = "Dispute"
2727
2828 let stateDisputeResolved = "DisputeResolved"
2929
3030 let client = "CMR"
3131
3232 let freelancer = "FL"
3333
3434 let ambassador1 = base58'1'
3535
3636 let ambassador2 = base58'1'
3737
3838 let ambassador3 = base58'1'
3939
4040 let ambassador4 = base58'1'
4141
4242 let ambassador5 = base58'1'
4343
4444 func AuctionIdDataKey (auctionId) = (auctionId + "_AuctionData")
45-
46-
47-func getDataList (auctionId) = {
48- let getDataString = getString(this, auctionId)
49- let a = match getDataString {
50- case a: String =>
51- a
52- case _ =>
53- throw("AuctionId was not found")
54- }
55- split(a, "_")
56- }
57-
58-
59-func getDisputeDataList (auctionId) = {
60- let keyDisputeData = ((auctionId + "_") + stateDispute)
61- let getDisputeDataString = getString(this, keyDisputeData)
62- let a = match getDisputeDataString {
63- case a: String =>
64- a
65- case _ =>
66- throw("Dispute data was not found")
67- }
68- split(a, "/")
69- }
7045
7146
7247 func AssetNameToBase58 (auctionAssetName) = if ((auctionAssetName == "WAVES"))
7348 then WAVES
7449 else if ((auctionAssetName == "BTC"))
7550 then wBTC
7651 else if ((auctionAssetName == "EUR"))
7752 then wEUR
7853 else if ((auctionAssetName == "USD"))
7954 then wUSD
8055 else throw("Incorrect Asset Id")
8156
8257
8358 func timeCheck (currentTime,startTime,expirationTime) = ((currentTime - startTime) > expirationTime)
8459
8560
8661 func increaseFreezedBalance (pmtAssetName,auctionPrice) = {
8762 let keyFreezedFunds = getInteger(this, (pmtAssetName + "_Freezed"))
8863 let currentFreezedBalance = match keyFreezedFunds {
8964 case a: Int =>
9065 a
9166 case _ =>
9267 0
9368 }
9469 (currentFreezedBalance + auctionPrice)
9570 }
9671
9772
9873 func decreaseFreezedBalance (pmtAssetName,auctionPrice) = {
9974 let keyFreezedFunds = getInteger(this, (pmtAssetName + "_Freezed"))
10075 let currentFreezedBalance = match keyFreezedFunds {
10176 case a: Int =>
10277 a
10378 case _ =>
10479 0
10580 }
10681 let a = (currentFreezedBalance - auctionPrice)
10782 if ((a > 0))
10883 then a
10984 else throw("Freezed amount couldn't be less than 0")
11085 }
11186
11287
11388 func freelancerIsRegistered (callerPub) = {
11489 let freelancerIsRegistered = getString(this, (callerPub + "_Freelancer"))
11590 match freelancerIsRegistered {
11691 case a: String =>
11792 callerPub
11893 case _ =>
11994 throw("Only registered users can make bets")
12095 }
12196 }
12297
12398
99+func createAuctionPriceCheck (pmtAmount) = if ((pmtAmount > 0))
100+ then pmtAmount
101+ else throw("Amount must be higher then 0")
102+
103+
104+func getAuctionState (auctionId) = {
105+ let valueState = getString(this, (auctionId + "_State"))
106+ match valueState {
107+ case a: String =>
108+ a
109+ case _ =>
110+ throw("Auction State was not found")
111+ }
112+ }
113+
114+
115+func getAuctionClientPub (auctionId) = {
116+ let valueClient = getString(this, (auctionId + "_Client"))
117+ let a = match valueClient {
118+ case a: String =>
119+ a
120+ case _ =>
121+ throw("Auction Client was not found")
122+ }
123+ fromBase58String(a)
124+ }
125+
126+
127+func getAuctionStartTime (auctionId) = {
128+ let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
129+ match valueAuctionStart {
130+ case a: Int =>
131+ a
132+ case _ =>
133+ throw("Auction Start time was not found")
134+ }
135+ }
136+
137+
138+func getAuctionDurationTime (auctionId) = {
139+ let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
140+ match valueauctionDuration {
141+ case a: Int =>
142+ a
143+ case _ =>
144+ throw("Auction duration time was not found")
145+ }
146+ }
147+
148+
149+func getAuctionJobPerformanceTime (auctionId) = {
150+ let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
151+ match valueBlocksForExecution {
152+ case a: Int =>
153+ a
154+ case _ =>
155+ throw("Auction job performance time was not found")
156+ }
157+ }
158+
159+
160+func getAuctionAssetName (auctionId) = {
161+ let valueAssetName = getString(this, (auctionId + "_AssetName"))
162+ match valueAssetName {
163+ case a: String =>
164+ a
165+ case _ =>
166+ throw("Auction asset name was not found")
167+ }
168+ }
169+
170+
171+func getAuctionPrice (auctionId) = {
172+ let valuePrice = getInteger(this, (auctionId + "_Price"))
173+ match valuePrice {
174+ case a: Int =>
175+ a
176+ case _ =>
177+ throw("Auction price was not found")
178+ }
179+ }
180+
181+
182+func getAuctionFreelancerPub (auctionId) = {
183+ let valueClient = getString(this, (auctionId + "_Freelancer"))
184+ let a = match valueClient {
185+ case a: String =>
186+ a
187+ case _ =>
188+ throw("Auction Client was not found")
189+ }
190+ fromBase58String(a)
191+ }
192+
193+
124194 @Callable(i)
125195 func freelancerSignUp (info) = {
126196 let userPublicKey = toBase58String(i.callerPublicKey)
127197 let alreadyRegistered = getString(this, (userPublicKey + "_Freelancer"))
128198 if (isDefined(alreadyRegistered))
129199 then throw("User already registered")
130200 else WriteSet([DataEntry((userPublicKey + "_Freelancer"), info)])
131201 }
132202
133203
134204
135205 @Callable(i)
136206 func clientSignUp (info) = {
137207 let userPublicKey = toBase58String(i.callerPublicKey)
138208 let alreadyRegistered = getString(this, (userPublicKey + "_Client"))
139209 if (isDefined(alreadyRegistered))
140210 then throw("User already registered")
141211 else WriteSet([DataEntry((userPublicKey + "_Client"), info)])
142212 }
143213
144214
145215
146216 @Callable(i)
147217 func createAuction (jobExecutionDays,auctionDurationDays,auctionInfo) = {
148218 let auctionId = toBase58String(i.transactionId)
149219 let auctionClient = toBase58String(i.callerPublicKey)
150220 let pmt = extract(i.payment)
151221 let pmtAmount = pmt.amount
152- let auctionPrice = if ((pmtAmount > 0))
153- then pmtAmount
154- else throw("Amount must be higher then 0")
222+ let auctionPrice = createAuctionPriceCheck(pmtAmount)
155223 let auctionStart = height
156224 let auctionDurationBlocks = (auctionDurationDays * day)
157225 let blocksForExecution = (jobExecutionDays * day)
158226 let pmtAssetName = if (!(isDefined(pmt.assetId)))
159227 then "WAVES"
160228 else if ((pmt.assetId == wBTC))
161229 then "BTC"
162230 else if ((pmt.assetId == wEUR))
163231 then "EUR"
164232 else if ((pmt.assetId == wUSD))
165233 then "USD"
166234 else throw("AssetId is incorrect")
167235 let newFreezedBalance = increaseFreezedBalance(pmtAssetName, auctionPrice)
168236 WriteSet([DataEntry((auctionId + "_State"), stateOpen), DataEntry((auctionId + "_Info"), auctionInfo), DataEntry((auctionId + "_Client"), auctionClient), DataEntry((auctionId + "_AuctionStart"), auctionStart), DataEntry((auctionId + "_AuctionDuration"), auctionDurationBlocks), DataEntry((auctionId + "_JobPerformance"), blocksForExecution), DataEntry((auctionId + "_AssetName"), pmtAssetName), DataEntry((auctionId + "_Price"), auctionPrice), DataEntry((pmtAssetName + "_Freezed"), newFreezedBalance)])
169237 }
170238
171239
172240
173241 @Callable(i)
174242 func makeBid (auctionId,betPrice) = {
175243 let callerPub = toBase58String(i.callerPublicKey)
176244 let betTime = height
177- let auctionState = {
178- let valueState = getString(this, (auctionId + "_State"))
179- match valueState {
180- case a: String =>
181- a
182- case _ =>
183- throw("Auction State was not found")
184- }
185- }
186- let auctionInfo = {
187- let valueAuctionInfo = getString(this, (auctionId + "_Info"))
188- match valueAuctionInfo {
189- case a: String =>
190- a
191- case _ =>
192- throw("Auction info was not found")
193- }
194- }
195- let auctionClient = {
196- let valueClient = getString(this, (auctionId + "_Client"))
197- let a = match valueClient {
198- case a: String =>
199- a
200- case _ =>
201- throw("Auction Client was not found")
202- }
203- fromBase58String(a)
204- }
205- let auctionStart = {
206- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
207- match valueAuctionStart {
208- case a: Int =>
209- a
210- case _ =>
211- throw("Auction Start time was not found")
212- }
213- }
214- let auctionDuration = {
215- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
216- match valueauctionDuration {
217- case a: Int =>
218- a
219- case _ =>
220- throw("Auction duration time was not found")
221- }
222- }
223- let auctionBlocksForExecution = {
224- let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
225- match valueBlocksForExecution {
226- case a: Int =>
227- a
228- case _ =>
229- throw("Auction job performance time was not found")
230- }
231- }
232- let auctionAssetName = {
233- let valueAssetName = getString(this, (auctionId + "_AssetName"))
234- match valueAssetName {
235- case a: String =>
236- a
237- case _ =>
238- throw("Auction asset name was not found")
239- }
240- }
241- let auctionPrice = {
242- let valuePrice = getInteger(this, (auctionId + "_Price"))
243- match valuePrice {
244- case a: Int =>
245- a
246- case _ =>
247- throw("Auction price was not found")
248- }
249- }
245+ let auctionState = getAuctionState(auctionId)
246+ let auctionClient = getAuctionClientPub(auctionId)
247+ let auctionStart = getAuctionStartTime(auctionId)
248+ let auctionDuration = getAuctionDurationTime(auctionId)
249+ let auctionBlocksForExecution = getAuctionJobPerformanceTime(auctionId)
250+ let auctionAssetName = getAuctionAssetName(auctionId)
251+ let auctionPrice = getAuctionPrice(auctionId)
250252 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
251253 let newFreelancer = freelancerIsRegistered(callerPub)
252254 let dAppCommission = ((auctionPrice * 3) / 100)
253255 let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
254256 let auctionTimeisOver = timeCheck(betTime, auctionStart, auctionDuration)
255257 if (auctionTimeisOver)
256258 then if ((auctionState == stateOpen))
257259 then ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateCancel), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), (auctionPrice - dAppCommission), auctionAssetId58)]))
258260 else if ((auctionState == stateSuggested))
259261 then {
260262 let auctionLowestBidder = {
261263 let valueLowestBidder = getString(this, (auctionId + "_LowestBidderPub"))
262264 match valueLowestBidder {
263265 case a: String =>
264266 a
265267 case _ =>
266268 throw("Auction lowest bidder was not found")
267269 }
268270 }
269271 let newAuctionPrice = {
270272 let valueNewAuctionPrice = getInteger(this, ((auctionId + "_Bid_") + auctionLowestBidder))
271273 match valueNewAuctionPrice {
272274 case a: Int =>
273275 a
274276 case _ =>
275277 throw("Auction lowest bid was not found")
276278 }
277279 }
278280 let amountDifference = ((auctionPrice - newAuctionPrice) - dAppCommission)
279281 ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), auctionLowestBidder), DataEntry((auctionId + "_Price"), newAuctionPrice)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), amountDifference, auctionAssetId58)]))
280282 }
281283 else throw("Incorrect auction state")
282284 else if ((auctionState == stateOpen))
283- then WriteSet([DataEntry(((auctionId + "_Bid_") + newFreelancer), betPrice), DataEntry((auctionId + "_State"), stateSuggested), DataEntry((auctionId + "_LowestBidderPub"), callerPub), DataEntry((auctionId + callerPub), betPrice)])
285+ then WriteSet([DataEntry(((auctionId + "_Bid_") + newFreelancer), betPrice), DataEntry((auctionId + "_State"), stateSuggested), DataEntry((auctionId + "_LowestBidderPub"), callerPub)])
284286 else if ((auctionState == stateSuggested))
285287 then {
286288 let currentLowestBidderPub = {
287289 let lowestBidder = getString(this, (auctionId + "_LowestBidderPub"))
288290 match lowestBidder {
289291 case a: String =>
290292 a
291293 case _ =>
292294 throw("Auction lowest bidder was not found")
293295 }
294296 }
295297 let newLowestBidderPub = {
296298 let valueCurrentLowestBid = getInteger(this, ((auctionId + "_Bid_") + currentLowestBidderPub))
297299 let currentLowestBid = match valueCurrentLowestBid {
298300 case a: Int =>
299301 a
300302 case _ =>
301303 throw("Auction lowest bid was not found")
302304 }
303305 if ((currentLowestBid > betPrice))
304306 then newFreelancer
305307 else currentLowestBidderPub
306308 }
307309 WriteSet([DataEntry((auctionId + "_LowestBidderPub"), newLowestBidderPub), DataEntry(((auctionId + "_Bid_") + newFreelancer), betPrice)])
308310 }
309311 else throw(((((("Incorrect jobId state. Now: " + auctionState) + ", must be: ") + stateOpen) + " or ") + stateSuggested))
310312 }
311313
312314
313315
314316 @Callable(i)
315317 func chooseFreelancer (auctionId,freelancerPub) = {
316318 let callerPub = extract(i.callerPublicKey)
317319 let betTime = height
318- let auctionState = {
319- let valueState = getString(this, (auctionId + "_State"))
320- match valueState {
321- case a: String =>
322- a
323- case _ =>
324- throw("Auction State was not found")
325- }
326- }
327- let auctionClient = {
328- let valueClient = getString(this, (auctionId + "_Client"))
329- let a = match valueClient {
330- case a: String =>
331- a
332- case _ =>
333- throw("Auction Client was not found")
334- }
335- fromBase58String(a)
336- }
337- let auctionStart = {
338- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
339- match valueAuctionStart {
340- case a: Int =>
341- a
342- case _ =>
343- throw("Auction Start time was not found")
344- }
345- }
346- let auctionDuration = {
347- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
348- match valueauctionDuration {
349- case a: Int =>
350- a
351- case _ =>
352- throw("Auction duration time was not found")
353- }
354- }
355- let auctionAssetName = {
356- let valueAssetName = getString(this, (auctionId + "_AssetName"))
357- match valueAssetName {
358- case a: String =>
359- a
360- case _ =>
361- throw("Auction asset name was not found")
362- }
363- }
364- let auctionPrice = {
365- let valuePrice = getInteger(this, (auctionId + "_Price"))
366- match valuePrice {
367- case a: Int =>
368- a
369- case _ =>
370- throw("Auction price was not found")
371- }
372- }
320+ let auctionState = getAuctionState(auctionId)
321+ let auctionClient = getAuctionClientPub(auctionId)
322+ let auctionStart = getAuctionStartTime(auctionId)
323+ let auctionDuration = getAuctionDurationTime(auctionId)
324+ let auctionAssetName = getAuctionAssetName(auctionId)
325+ let auctionPrice = getAuctionPrice(auctionId)
373326 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
374327 let freelancerBidAmount = {
375328 let keyFreelancerBid = ((auctionId + "_Bid_") + freelancerPub)
376329 let valueFreelacerBid = getInteger(this, keyFreelancerBid)
377330 match valueFreelacerBid {
378331 case a: Int =>
379332 a
380333 case _ =>
381334 throw("Freelancer's bet was not found")
382335 }
383336 }
384- let dAppCommission = ((auctionPrice * 3) / 100)
385- let amountDifference = ((auctionPrice - freelancerBidAmount) - dAppCommission)
337+ let dAppCommission = ((freelancerBidAmount * 3) / 100)
386338 let auctionTimeisOver = timeCheck(betTime, auctionStart, auctionDuration)
387339 if ((callerPub == auctionClient))
388340 then if (auctionTimeisOver)
389341 then if ((auctionState == stateOpen))
390342 then {
391- let newPrice = (auctionPrice - dAppCommission)
392- let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, newPrice)
393- ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateCancel), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), newPrice, auctionAssetId58)]))
343+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
344+ ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateCancel), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), (auctionPrice - dAppCommission), auctionAssetId58)]))
394345 }
395346 else if ((auctionState == stateSuggested))
396347 then {
397348 let auctionLowestBidder = {
398349 let valueLowestBidder = getString(this, (auctionId + "_LowestBidderPub"))
399350 match valueLowestBidder {
400351 case a: String =>
401352 a
402353 case _ =>
403354 throw("Auction lowest bidder was not found")
404355 }
405356 }
406357 let newAuctionPrice = {
407358 let valueNewAuctionPrice = getInteger(this, ((auctionId + "_Bid_") + auctionLowestBidder))
408359 match valueNewAuctionPrice {
409360 case a: Int =>
410361 a
411362 case _ =>
412363 throw("Auction lowest bid was not found")
413364 }
414365 }
415- WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), auctionLowestBidder), DataEntry((auctionId + "_Price"), newAuctionPrice)])
366+ let amountDifference = (auctionPrice - newAuctionPrice)
367+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, amountDifference)
368+ ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), auctionLowestBidder), DataEntry((auctionId + "_Price"), newAuctionPrice), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), amountDifference, auctionAssetId58)]))
416369 }
417370 else throw("Incorrect auction state")
418371 else {
419372 let setNewFreelancer = {
420373 let newFreelancer = getInteger(this, ((auctionId + "_Bid_") + freelancerPub))
421374 match newFreelancer {
422375 case a: Int =>
423376 freelancerPub
424377 case _ =>
425378 throw("Error: Incorrect freelancerPub")
426379 }
427380 }
428- let setNewPrice = {
381+ let newAuctionPrice = {
429382 let freelancerBid = getInteger(this, ((auctionId + "_Bid_") + freelancerPub))
430383 match freelancerBid {
431384 case a: Int =>
432385 a
433386 case _ =>
434387 throw("Auction lowest bidder was not found")
435388 }
436389 }
437- let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, setNewPrice)
438- ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), setNewFreelancer), DataEntry((auctionId + "_Price"), setNewPrice), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), amountDifference, auctionAssetId58)]))
390+ let amountDifference = (auctionPrice - freelancerBidAmount)
391+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, amountDifference)
392+ ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateInProgress), DataEntry((auctionId + "_Freelancer"), setNewFreelancer), DataEntry((auctionId + "_Price"), newAuctionPrice), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), (amountDifference - dAppCommission), auctionAssetId58)]))
439393 }
440394 else throw("Only auction customer can choose a freelancer")
441395 }
442396
443397
444398
445399 @Callable(i)
446400 func increaseExecutionTime (auctionId,executionDays) = {
447401 let caller = extract(i.callerPublicKey)
448- let auctionState = {
449- let valueState = getString(this, (auctionId + "_State"))
450- match valueState {
451- case a: String =>
452- a
453- case _ =>
454- throw("Auction State was not found")
455- }
456- }
457- let auctionClient = {
458- let valueClient = getString(this, (auctionId + "_Client"))
459- let a = match valueClient {
460- case a: String =>
461- a
462- case _ =>
463- throw("Auction Client was not found")
464- }
465- fromBase58String(a)
466- }
467- let auctionExecutionTime = {
468- let valueBlocksForExecution = getInteger(this, (auctionId + "JobPerformance"))
469- match valueBlocksForExecution {
470- case a: Int =>
471- a
472- case _ =>
473- throw("Auction job performance time was not found")
474- }
475- }
402+ let auctionState = getAuctionState(auctionId)
403+ let auctionClient = getAuctionClientPub(auctionId)
404+ let auctionBlocksForExecution = getAuctionJobPerformanceTime(auctionId)
476405 let newAuctionExecutionTime = {
477406 let newAuctionBlocksForExecution = (executionDays * day)
478- if ((newAuctionBlocksForExecution > auctionExecutionTime))
407+ if ((newAuctionBlocksForExecution > auctionBlocksForExecution))
479408 then newAuctionBlocksForExecution
480409 else throw("New execution time must more than current execution time")
481410 }
482411 if ((caller == auctionClient))
483412 then if (if (if ((auctionState == stateOpen))
484413 then true
485414 else (auctionState == stateSuggested))
486415 then true
487416 else (auctionState == stateInProgress))
488417 then WriteSet([DataEntry((auctionId + "_JobPerformance"), newAuctionExecutionTime)])
489418 else throw("Incorrect state")
490419 else throw("Only Client can increase execution time")
491420 }
492421
493422
494423
495424 @Callable(i)
496425 func cancelAuction (auctionId) = {
497426 let callerPub = extract(i.callerPublicKey)
498- let auctionState = {
499- let valueState = getString(this, (auctionId + "_State"))
500- match valueState {
501- case a: String =>
502- a
503- case _ =>
504- throw("Auction State was not found")
505- }
506- }
507- let auctionClient = {
508- let valueClient = getString(this, (auctionId + "_Client"))
509- let a = match valueClient {
510- case a: String =>
511- a
512- case _ =>
513- throw("Auction Client was not found")
514- }
515- fromBase58String(a)
516- }
427+ let auctionState = getAuctionState(auctionId)
428+ let auctionClient = getAuctionClientPub(auctionId)
429+ let auctionAssetName = getAuctionAssetName(auctionId)
430+ let auctionPrice = getAuctionPrice(auctionId)
431+ let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
432+ let dAppCommission = ((auctionPrice * 3) / 100)
433+ let amountWithoutComm = (auctionPrice - dAppCommission)
434+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
517435 let callerIsClient = if ((callerPub == auctionClient))
518436 then true
519- else throw("Auction can be canceled only by owner.")
437+ else throw("Auction can be canceled only by auction owner.")
520438 if (callerIsClient)
521439 then if ((auctionState == stateOpen))
522- then WriteSet([DataEntry((auctionId + "_State"), stateCancel)])
440+ then ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateCancel), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionClient), amountWithoutComm, auctionAssetId58)]))
523441 else throw("Incorrect auction state.")
524442 else throw("Only Client can cancel auction")
525443 }
526444
527445
528446
529447 @Callable(i)
530448 func openDispute (auctionId) = {
531449 let caller = extract(i.callerPublicKey)
532- let auctionState = {
533- let valueState = getString(this, (auctionId + "_State"))
534- match valueState {
535- case a: String =>
536- a
537- case _ =>
538- throw("Auction State was not found")
539- }
540- }
541- let auctionClient = {
542- let valueClient = getString(this, (auctionId + "_Client"))
543- let a = match valueClient {
544- case a: String =>
545- a
546- case _ =>
547- throw("Auction Client was not found")
548- }
549- fromBase58String(a)
550- }
551- let auctionFreelancer = {
552- let valueClient = getString(this, (auctionId + "_Freelancer"))
553- let a = match valueClient {
554- case a: String =>
555- a
556- case _ =>
557- throw("Auction Client was not found")
558- }
559- fromBase58String(a)
560- }
450+ let auctionState = getAuctionState(auctionId)
451+ let auctionClient = getAuctionClientPub(auctionId)
452+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
561453 if (if ((auctionState == stateOpen))
562454 then true
563455 else (auctionState == stateSuggested))
564456 then throw("Incorrect auction state for dispute opening")
565457 else if (if ((caller == auctionClient))
566458 then true
567459 else (caller == auctionFreelancer))
568460 then WriteSet([DataEntry((auctionId + "_State"), stateDispute), DataEntry((auctionId + "_DisputeVotes"), 0)])
569461 else throw("Only customer and freelancer can open dispute")
570462 }
571463
572464
573465
574466 @Callable(i)
575467 func voteDispute (auctionId,vote) = {
576468 let callerPub = extract(i.callerPublicKey)
577- let auctionState = {
578- let valueState = getString(this, (auctionId + "_State"))
579- match valueState {
580- case a: String =>
581- a
582- case _ =>
583- throw("Auction State was not found")
584- }
585- }
586- let auctionClient = {
587- let valueClient = getString(this, (auctionId + "_Client"))
588- let a = match valueClient {
589- case a: String =>
590- a
591- case _ =>
592- throw("Auction Client was not found")
593- }
594- fromBase58String(a)
595- }
596- let auctionAssetName = {
597- let valueAssetName = getString(this, (auctionId + "_AssetName"))
598- match valueAssetName {
599- case a: String =>
600- a
601- case _ =>
602- throw("Auction asset name was not found")
603- }
604- }
605- let auctionPrice = {
606- let valuePrice = getInteger(this, (auctionId + "_Price"))
607- match valuePrice {
608- case a: Int =>
609- a
610- case _ =>
611- throw("Auction price was not found")
612- }
613- }
614- let auctionFreelancer = {
615- let valueClient = getString(this, (auctionId + "_Freelancer"))
616- let a = match valueClient {
617- case a: String =>
618- a
619- case _ =>
620- throw("Auction Client was not found")
621- }
622- fromBase58String(a)
623- }
469+ let auctionState = getAuctionState(auctionId)
470+ let auctionClient = getAuctionClientPub(auctionId)
471+ let auctionAssetName = getAuctionAssetName(auctionId)
472+ let auctionPrice = getAuctionPrice(auctionId)
473+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
624474 let comission = ((auctionPrice * 3) / 100)
625475 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
626476 let callerIsAmbassador = if (if (if (if (if ((callerPub == ambassador1))
627477 then true
628478 else (callerPub == ambassador2))
629479 then true
630480 else (callerPub == ambassador3))
631481 then true
632482 else (callerPub == ambassador4))
633483 then true
634484 else (callerPub == ambassador5))
635485 then toBase58String(callerPub)
636486 else throw("Only defined ambassadors can vote in disputes")
637487 let newVote = if (if ((vote == client))
638488 then true
639489 else (vote == freelancer))
640490 then vote
641491 else throw(((("Vote is incorrect. Must be: " + client) + " or ") + freelancer))
642492 let newVoter = {
643493 let keyVoter = ((auctionId + "_DiputeVote_") + callerIsAmbassador)
644494 let valueVoter = getString(this, keyVoter)
645495 match valueVoter {
646496 case a: String =>
647497 throw("User already voted")
648498 case _ =>
649499 callerIsAmbassador
650500 }
651501 }
652502 let votesNumber = {
653503 let valueVotesNumber = getInteger(this, (auctionId + "_DisputeVotes"))
654504 match valueVotesNumber {
655505 case a: Int =>
656506 a
657507 case _ =>
658508 throw("VotesNumber was not found")
659509 }
660510 }
661511 if ((auctionState == stateDispute))
662512 then if ((votesNumber == 4))
663513 then {
664514 let disputeWinner = {
665515 let ambassador1Vote = getString(this, ((auctionId + "_DiputeVote_") + toBase58String(ambassador1)))
666516 let ambassador2Vote = getString(this, ((auctionId + "_DiputeVote_") + toBase58String(ambassador2)))
667517 let ambassador3Vote = getString(this, ((auctionId + "_DiputeVote_") + toBase58String(ambassador3)))
668518 let ambassador4Vote = getString(this, ((auctionId + "_DiputeVote_") + toBase58String(ambassador4)))
669519 let ambassador5Vote = getString(this, ((auctionId + "_DiputeVote_") + toBase58String(ambassador5)))
670520 let v1 = if ((ambassador1Vote == client))
671521 then 1
672522 else 0
673523 let v2 = if ((ambassador2Vote == client))
674524 then 1
675525 else 0
676526 let v3 = if ((ambassador3Vote == client))
677527 then 1
678528 else 0
679529 let v4 = if ((ambassador4Vote == client))
680530 then 1
681531 else 0
682532 let v5 = if ((ambassador5Vote == client))
683533 then 1
684534 else 0
685535 let currentVote = if ((newVote == client))
686536 then 1
687537 else 0
688538 let votesForClient = (((((v1 + v2) + v3) + v4) + v5) + currentVote)
689539 if ((votesForClient > 2))
690540 then auctionClient
691541 else auctionFreelancer
692542 }
693543 let paymentWithoutComm = if ((disputeWinner == auctionClient))
694544 then auctionPrice
695545 else (auctionPrice - comission)
696- let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, paymentWithoutComm)
546+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
697547 ScriptResult(WriteSet([DataEntry((auctionId + "_DisputeVotes"), (votesNumber + 1)), DataEntry((auctionId + "_State"), stateDisputeResolved), DataEntry(((auctionId + "_DiputeVote_") + callerIsAmbassador), newVote), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(disputeWinner), paymentWithoutComm, auctionAssetId58)]))
698548 }
699549 else WriteSet([DataEntry((auctionId + "_DisputeVotes"), (votesNumber + 1)), DataEntry(((auctionId + "_DiputeVote_") + callerIsAmbassador), newVote)])
700550 else throw(("Incorrect state. Must be: " + stateDispute))
701551 }
702552
703553
704554
705555 @Callable(i)
706556 func workHandOver (auctionId) = {
707557 let callerPub = extract(i.callerPublicKey)
708- let auctionState = {
709- let valueState = getString(this, (auctionId + "_State"))
710- match valueState {
711- case a: String =>
712- a
713- case _ =>
714- throw("Auction State was not found")
715- }
716- }
717- let auctionStart = {
718- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
719- match valueAuctionStart {
720- case a: Int =>
721- a
722- case _ =>
723- throw("Auction Start time was not found")
724- }
725- }
726- let auctionDuration = {
727- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
728- match valueauctionDuration {
729- case a: Int =>
730- a
731- case _ =>
732- throw("Auction duration time was not found")
733- }
734- }
735- let auctionExecutionTime = {
736- let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
737- match valueBlocksForExecution {
738- case a: Int =>
739- a
740- case _ =>
741- throw("Auction job performance time was not found")
742- }
743- }
744- let auctionFreelancer = {
745- let valueClient = getString(this, (auctionId + "_Freelancer"))
746- let a = match valueClient {
747- case a: String =>
748- a
749- case _ =>
750- throw("Auction Client was not found")
751- }
752- fromBase58String(a)
753- }
558+ let auctionState = getAuctionState(auctionId)
559+ let auctionStart = getAuctionStartTime(auctionId)
560+ let auctionDuration = getAuctionDurationTime(auctionId)
561+ let auctionBlocksForExecution = getAuctionJobPerformanceTime(auctionId)
562+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
754563 let currentTime = height
755564 let freelancerPubCheck = if ((callerPub == auctionFreelancer))
756565 then callerPub
757566 else throw("Only a freelancer can indicate that the work is done")
758- let timeIsOver = ((currentTime - auctionStart) > auctionExecutionTime)
567+ let timeIsOver = ((currentTime - auctionStart) > auctionBlocksForExecution)
759568 if ((auctionState == stateInProgress))
760569 then if (timeIsOver)
761570 then WriteSet([DataEntry((auctionId + "_State"), stateDispute), DataEntry((auctionId + "_DisputeVotes"), "0")])
762571 else WriteSet([DataEntry((auctionId + "_State"), stateWait4Confirm)])
763572 else throw("Auction state is incorrect")
764573 }
765574
766575
767576
768577 @Callable(i)
769578 func acceptWork (auctionId) = {
770579 let callerPub = extract(i.callerPublicKey)
771- let auctionState = {
772- let valueState = getString(this, (auctionId + "_State"))
773- match valueState {
774- case a: String =>
775- a
776- case _ =>
777- throw("Auction State was not found")
778- }
779- }
780- let auctionClient = {
781- let valueClient = getString(this, (auctionId + "_Client"))
782- let a = match valueClient {
783- case a: String =>
784- a
785- case _ =>
786- throw("Auction Client was not found")
787- }
788- fromBase58String(a)
789- }
790- let auctionStart = {
791- let valueAuctionStart = getInteger(this, (auctionId + "_AuctionStart"))
792- match valueAuctionStart {
793- case a: Int =>
794- a
795- case _ =>
796- throw("Auction Start time was not found")
797- }
798- }
799- let auctionDuration = {
800- let valueauctionDuration = getInteger(this, (auctionId + "_AuctionDuration"))
801- match valueauctionDuration {
802- case a: Int =>
803- a
804- case _ =>
805- throw("Auction duration time was not found")
806- }
807- }
808- let auctionExecutionTime = {
809- let valueBlocksForExecution = getInteger(this, (auctionId + "_JobPerformance"))
810- match valueBlocksForExecution {
811- case a: Int =>
812- a
813- case _ =>
814- throw("Auction job performance time was not found")
815- }
816- }
817- let auctionAssetName = {
818- let valueAssetName = getString(this, (auctionId + "_AssetName"))
819- match valueAssetName {
820- case a: String =>
821- a
822- case _ =>
823- throw("Auction asset name was not found")
824- }
825- }
826- let auctionPrice = {
827- let valuePrice = getInteger(this, (auctionId + "_Price"))
828- match valuePrice {
829- case a: Int =>
830- a
831- case _ =>
832- throw("Auction price was not found")
833- }
834- }
835- let auctionFreelancer = {
836- let valueClient = getString(this, (auctionId + "_Freelancer"))
837- let a = match valueClient {
838- case a: String =>
839- a
840- case _ =>
841- throw("Auction Client was not found")
842- }
843- fromBase58String(a)
844- }
580+ let auctionState = getAuctionState(auctionId)
581+ let auctionClient = getAuctionClientPub(auctionId)
582+ let auctionStart = getAuctionStartTime(auctionId)
583+ let auctionDuration = getAuctionDurationTime(auctionId)
584+ let auctionAssetName = getAuctionAssetName(auctionId)
585+ let auctionPrice = getAuctionPrice(auctionId)
586+ let auctionFreelancer = getAuctionFreelancerPub(auctionId)
845587 let dAppCommission = ((auctionPrice * 3) / 100)
846588 let amountWithoutComm = (auctionPrice - dAppCommission)
847589 let auctionAssetId58 = AssetNameToBase58(auctionAssetName)
590+ let newFreezedBalance = decreaseFreezedBalance(auctionAssetName, auctionPrice)
848591 let newRating = {
849592 let valueRating = getInteger(this, (toBase58String(auctionFreelancer) + "_Rating"))
850593 let currentRating = match valueRating {
851594 case a: Int =>
852595 a
853596 case _ =>
854597 0
855598 }
856599 (currentRating + 1)
857600 }
858601 if ((callerPub == auctionClient))
859602 then if ((auctionState == stateWait4Confirm))
860- then ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateComplete), DataEntry((toBase58String(auctionFreelancer) + "_Rating"), newRating)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionFreelancer), amountWithoutComm, auctionAssetId58)]))
603+ then ScriptResult(WriteSet([DataEntry((auctionId + "_State"), stateComplete), DataEntry((toBase58String(auctionFreelancer) + "_Rating"), newRating), DataEntry((auctionAssetName + "_Freezed"), newFreezedBalance)]), TransferSet([ScriptTransfer(addressFromPublicKey(auctionFreelancer), amountWithoutComm, auctionAssetId58)]))
861604 else throw(("Incorrect state. Must be: " + stateWait4Confirm))
862605 else throw("Only auction customer can use this function")
863606 }
864607
865608
866609 @Verifier(tx)
867610 func verify () = if (sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey))
868611 then match tx {
869612 case ttx: TransferTransaction =>
870613 true
871614 case stx: SetScriptTransaction =>
872615 true
873616 case _ =>
874617 false
875618 }
876619 else false
877620

github/deemru/w8io/169f3d6 
86.68 ms