Chad is a simple voting service. It has two perspectives; a user perspective & an administration perspective. The user perspective is the default one, which allows a user to vote for a particular poll, as well as view the results of a poll. In addition, in the administration perspective, an authorized administrator can;
Only one vote per poll is allowed for a particular IP address , and the poll results can be compared using the bar graphs and the relevant percentages of votes each choice has received. If you try voting again using the same IP you will be directed to the poll results page, also including the line, "We have already received a vote for this poll from your IP address. Hence you are not eligible for voting" below the results graph.
To build the samples you need the Apache Ant build tool.
WSO2WSAS_HOME/samples/Chad
ant
at the command prompt.
Now you will have the Chad service deployed on WSO2 WSAS. You can check this by going to the AJAX based Management Console and clicking on the "Manage Services" link on the left menu. If you see the Chad service listed here, then you know for sure that Chad is active/deployed.
You can run the client using a Web browser interface.
You can got to the WSO2 WSAS Management Console, sign in, then click on "Manage Services" link on the left menu. As Chad service is already deployed you will see the service listed on the page. Click on "Chad" service link and you will go to a "Service Management" page of Chad. You should be able to see a sub menu titled "Application GUI" here. This sub menu will take you to the Web based UI of the Chad application. (See User Guide for details for details)
Vote types available are 'Single Choice' where one can only vote for a single choice and 'Multiple Choice' where one can vote for one or more choices.
Note: Once a poll is created it is automatically open for voting. Voting is open until explicitly closed using stop option
To see Poll results click on the particular poll listed on any of the Polls lists pages. You will get a page as shown below.
Using the Stop action you can close voting after which one cannot vote for that particular poll. Once stopped, the Start link will appear under 'Actions' column replacing both Stop and Vote action links.
Start action reopens a poll for voting.
Vote action will take you to a page as shown below from which one can vote for his/her preferred choice. This can happen for either a single type vote or a multiple type vote .
For single type vote:
For multiple type vote: