electora-vote / electora-app

Decentralized Voting Application - leveraging the power of zk-proofs, conditions based decryption, and decentralized storage
https://app.electora.eu/
8 stars 2 forks source link

Prevent users from submitting votes after the endtime and add status to ballot page #106

Closed sweep-ai[bot] closed 1 year ago

sweep-ai[bot] commented 1 year ago

Description

This PR addresses the following issues:

To prevent users from submitting votes after the endtime, the Cast Vote Button in the client_code/forms/routes/ballot/Read/form_template.yaml file has been modified. It now checks if the current time is greater than the ballot's end time and disables the button if it is.

To add a status to the ballot page, the client_code/forms/routes/ballot/Index/__init__.py file has been modified. A new field has been added to the ballot object to store the status of the ballot. The ballot display logic has been updated to include the new status field. The status is displayed in a color that depends on the status. For example, if the ballot has ended, the status is displayed in red.

Summary of Changes

Fixes #92.


To checkout this PR branch, run the following command in your terminal:

git checkout sweep_prevent-votes-after-endtime

🎉 Latest improvements to Sweep:


💡 To get Sweep to edit this pull request, you can:

what-the-diff[bot] commented 1 year ago

PR Summary

meatballs commented 1 year ago

It uses a walrus which skulpt doesn't support.