Plugin providing election services.
More...
Detailed Description
Plugin providing election services.
- Author
- Edward Plainview edwar.nosp@m.d.pl.nosp@m.ainvi.nosp@m.ew@s.nosp@m.verig.nosp@m.edem.nosp@m.okrat.nosp@m.erna.nosp@m..se
- Changelog
- 1.1
- Added participant query function
Constructor & Destructor Documentation
| SD_Meeting_Tool_elections::__construct |
( |
| ) |
|
Member Function Documentation
| SD_Meeting_Tool_elections::activate |
( |
| ) |
|
Overridable activation function.
It's here in case plugins need a common activation method in the future.
Reimplemented from SD_Meeting_Tool_Base.
| SD_Meeting_Tool_elections::admin |
( |
| ) |
|
| SD_Meeting_Tool_elections::admin_edit |
( |
| ) |
|
| SD_Meeting_Tool_elections::admin_electoral_register |
( |
| ) |
|
| SD_Meeting_Tool_elections::admin_overview |
( |
| ) |
|
| SD_Meeting_Tool_elections::admin_query_register |
( |
| ) |
|
Queries the voting status of a participant.
| SD_Meeting_Tool_elections::admin_register |
( |
| ) |
|
| SD_Meeting_Tool_elections::admin_results |
( |
| ) |
|
| SD_Meeting_Tool_elections::ajax_sd_mt_elections |
( |
| ) |
|
| SD_Meeting_Tool_elections::calculate_electoral_register |
( |
|
$SD_Meeting_Tool_Election | ) |
|
| SD_Meeting_Tool_elections::display_election_graph |
( |
|
$election | ) |
|
|
private |
Display a results graph for an election.
- Parameters
-
- Returns
- A HTML string containing the results graph for the election.
| SD_Meeting_Tool_elections::display_election_nonvoters |
( |
|
$election | ) |
|
|
private |
Display who should have, but did not vote in an election.
- Parameters
-
- Returns
- A HTML string showing non-voters.
| SD_Meeting_Tool_elections::display_election_statistics |
( |
|
$election | ) |
|
|
private |
Display voting statistics for an election.
- Parameters
-
- Returns
- A HTML string containing the voting statistics for the election.
| SD_Meeting_Tool_elections::display_election_voters |
( |
|
$election | ) |
|
|
private |
Display who voted in an election.
- Parameters
-
- Returns
- A HTML string showing who voted in the election.
| SD_Meeting_Tool_elections::display_electoral_register |
( |
|
$SD_Meeting_Tool_Election | ) |
|
Display an electoral register.
- Parameters
-
- Returns
- A HTML string containing all the info about the electoral register of an election.
| SD_Meeting_Tool_elections::election_sql_to_object |
( |
|
$sql | ) |
|
|
private |
| SD_Meeting_Tool_elections::generate_electoral_register |
( |
|
$SD_Meeting_Tool_Election | ) |
|
Generate an electoral register for an election.
Will empty and refill the may_vote list.
- Parameters
-
- Returns
- An HTML message.
| SD_Meeting_Tool_elections::maybe_create_list |
( |
|
$post_value, |
|
|
|
$new_list_name |
|
) |
| |
Decide, from the post value, whether to create a list.
- Parameters
-
| string | $post_value | Either 'create', to create a list or just a number. |
| string | $new_list_name | The name of the new list, if it is to be created. |
- Returns
- Either the newly-created list's ID, or the integerized value from the post.
| SD_Meeting_Tool_elections::maybe_finish_election |
( |
|
$SD_Meeting_Tool_Election | ) |
|
|
private |
Decide whether to finish this election.
It's time to finish when all eligible voters have voted.
- Parameters
-
- Returns
- The election in return, maybe in a finished state.
| SD_Meeting_Tool_elections::query_participant |
( |
|
$SD_Meeting_Tool_Election, |
|
|
|
$participant_id |
|
) |
| |
Queries the voting status of a participant.
Returns what would happen if the participant were to join / leave the electoral register.
- Parameters
-
| SD_Meeting_Tool_Election | $SD_Meeting_Tool_Election | The election on which to base the query. |
| int | $participant_id | ID of participant to query. |
- Returns
- A HTML string containing a message() or error().
| SD_Meeting_Tool_elections::register_finish |
( |
|
$election | ) |
|
Display a query box allowing the user to finish the election.
- Parameters
-
| SD_Meeting_Tool_elections::register_manual_votes |
( |
|
$election | ) |
|
Register votes in a manual election.
- Parameters
-
| SD_Meeting_Tool_elections::register_voter_options |
( |
|
$election | ) |
|
Shows the register UI of an election.
- Parameters
-
| SD_Meeting_Tool_elections::register_votes |
( |
|
$election | ) |
|
Register votes in an election.
- Parameters
-
| SD_Meeting_Tool_elections::sd_mt_admin_menu |
( |
|
$menus | ) |
|
| SD_Meeting_Tool_elections::sd_mt_delete_election |
( |
|
$SD_Meeting_Tool_Election | ) |
|
Delete an election.
- Parameters
-
| SD_Meeting_Tool_elections::sd_mt_get_all_elections |
( |
| ) |
|
| SD_Meeting_Tool_elections::sd_mt_get_election |
( |
|
$id | ) |
|
Retrieves an election.
- Parameters
-
| int | $id | The ID of the election to retrieve. |
- Returns
- The SD_Meeting_Tool_Election object, or FALSE if no election with this ID was found.
| SD_Meeting_Tool_elections::sd_mt_update_election |
( |
|
$SD_Meeting_Tool_Election | ) |
|
Update an election.
- Parameters
-
| SD_Meeting_Tool_elections::shortcode_display_election_graph |
( |
|
$attr | ) |
|
Shows the graph of a completed election.
- Attributes
- id Election ID. Required.
- Parameters
-
| array | $attr | Attributes array. |
- Returns
- Election HTML string to display.
| SD_Meeting_Tool_elections::shortcode_display_election_statistics |
( |
|
$attr | ) |
|
Shows the statistics of a completed election.
- Attributes
- id Election ID. Required.
- Parameters
-
| array | $attr | Attributes array. |
- Returns
- Election HTML string to display.
| SD_Meeting_Tool_elections::uninstall |
( |
| ) |
|
The documentation for this class was generated from the following file: