Code Monkey home page Code Monkey logo

au.com.agileware.elections's People

Contributors

agileware-justin avatar agilewarealok avatar jaapjansma avatar kathyreid avatar mlutfy avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

au.com.agileware.elections's Issues

Nominations process feature request

I would love the ability to open nominations to one member group (say, our executive council) and then open the resulting election to another group (our full membership). Would it be possible/desirable to have each phase controlled by a separate group permission?

` Undefined array key "groupName"` (Elections broken on CiviCRM >=5.47)

As of this morning my CiviCRM cron jobs are returning the following line:

[PHP Warning] Undefined array key "groupName" at /var/www/html/wp-content/uploads/civicrm/ext/au.com.agileware.elections-master/elections.php:513

Any ideas what might be going on here, and how I might debug it? Thanks!

PHP: 8.0.30
CiviCRM: 5.65.2
Elections: 1.2.3

Election Page Error - The website encountered an unexpected error. Please try again later

Hello,
I am running Drupal 9.5.10
with CIVICRM version 5.64.0
Elections: Version 1.2.3

After the Election has been created and the page becomes visible the following error is seen on the page:

Test Election

This Election is currently in the Nominations phase.

You can submit nominations for this Election using the button below, and see existing nominations for each position. If you have been nominated for any positions, you can see these and have the option of withdrawing them. Nominations that require one or persons to second them will also be marked as such โ€“ press the "Need second" button to add your nominations

Nominations will close on September 4th, 2023 12:00 PM (GMT+00:00)

Existing Nominations
Nominations for President
The website encountered an unexpected error. Please try again later.

On viewing the Drupal logs the following error is seen in the logs:


Location https://example.com.com/civicrm/elections/view?eid=2
Referrer https://example.com.com/civicrm/elections
Message TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in include() (line 29 of /var/www/vhosts/example.com/private/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php)
#0 /var/www/vhosts/example.com/vendor/civicrm/civicrm-packages/Smarty/Smarty.class.php(1914): include()
#1 /var/www/vhosts/example.com/private/civicrm/templates_c/en_US/%%AB/ABE/ABE5D1F1%%ViewElection.tpl.php(44): Smarty->_smarty_include()
#2 /var/www/vhosts/example.com/vendor/civicrm/civicrm-packages/Smarty/Smarty.class.php(1914): include('...')
#3 /var/www/vhosts/example.com/private/civicrm/templates_c/en_US/%%F7/F77/F77C7890%%CMSPrint.tpl.php(67): Smarty->_smarty_include()
#4 /var/www/vhosts/example.com/vendor/civicrm/civicrm-packages/Smarty/Smarty.class.php(1914): include('...')
#5 /var/www/vhosts/example.com/private/civicrm/templates_c/en_US/%%2B/2BD/2BD99720%%drupal8.tpl.php(6): Smarty->_smarty_include()
#6 /var/www/vhosts/example.com/vendor/civicrm/civicrm-packages/Smarty/Smarty.class.php(1273): include('...')
#7 /var/www/vhosts/example.com/vendor/civicrm/civicrm-core/CRM/Core/Smarty.php(205): Smarty->fetch()
#8 /var/www/vhosts/example.com/vendor/civicrm/civicrm-core/CRM/Core/Page.php(261): CRM_Core_Smarty->fetch()
#9 /var/www/vhosts/example.com/sites/default/files/civicrm/ext/au.com.agileware.elections/CRM/Elections/Page/Base.php(47): CRM_Core_Page->run()
#10 /var/www/vhosts/example.com/sites/default/files/civicrm/ext/au.com.agileware.elections/CRM/Elections/Page/ViewElection.php(66): CRM_Elections_Page_Base->run()
#11 /var/www/vhosts/example.com/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(319): CRM_Elections_Page_ViewElection->run()
#12 /var/www/vhosts/example.com/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(69): CRM_Core_Invoke::runItem()
#13 /var/www/vhosts/example.com/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(36): CRM_Core_Invoke::_invoke()
#14 /var/www/vhosts/example.com/modules/contrib/civicrm/src/Civicrm.php(88): CRM_Core_Invoke::invoke()
#15 /var/www/vhosts/example.com/modules/contrib/civicrm/src/Controller/CivicrmController.php(83): Drupal\civicrm\Civicrm->invoke()
#16 [internal function]: Drupal\civicrm\Controller\CivicrmController->main()
#17 /var/www/vhosts/example.com/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#18 /var/www/vhosts/example.com/core/lib/Drupal/Core/Render/Renderer.php(580): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber{closure}()
#19 /var/www/vhosts/example.com/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(121): Drupal\Core\Render\Renderer->executeInRenderContext()
#20 /var/www/vhosts/example.com/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()
#21 /var/www/vhosts/example.com/vendor/symfony/http-kernel/HttpKernel.php(169): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber{closure}()
#22 /var/www/vhosts/example.com/vendor/symfony/http-kernel/HttpKernel.php(81): Symfony\Component\HttpKernel\HttpKernel->handleRaw()
#23 /var/www/vhosts/example.com/core/lib/Drupal/Core/StackMiddleware/Session.php(58): Symfony\Component\HttpKernel\HttpKernel->handle()
#24 /var/www/vhosts/example.com/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(48): Drupal\Core\StackMiddleware\Session->handle()
#25 /var/www/vhosts/example.com/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle()
#26 /var/www/vhosts/example.com/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass()
#27 /var/www/vhosts/example.com/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(48): Drupal\page_cache\StackMiddleware\PageCache->handle()
#28 /var/www/vhosts/example.com/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(51): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()
#29 /var/www/vhosts/example.com/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()
#30 /var/www/vhosts/example.com/core/lib/Drupal/Core/DrupalKernel.php(718): Stack\StackedHttpKernel->handle()
#31 /var/www/vhosts/example.com/index.php(19): Drupal\Core\DrupalKernel->handle()
#32 {main}

Button missing on "Submit Nominations" page in CiviCRM Elections extension

Trying to use the Election extension to CiviCRM. Version 5.50, under WP 6.2.2, and Election version 1.2.3. Issue: on the "View and Submit Nominations" page, there shall be a Button for nomination of candidates. This button does not exist on our version.

We run a test site for trial work. We have not activated "Outgoing email" on this server.

Do you have a suggestion for the solution of this issue. Needed for us to proceed with the election function later on our production site!

Referenda

Our elections sometimes include matters aside from the election of people, such as bylaws changes, on which we need an up-or-down vote from our membership. I'd love to see such referenda supported within the extension.

Unable to create nominations during election

CMS: Wordpress 5.9
CiviCRM Version: 5.45.2
Elections Version: 1.2.2

Wordpress and CiviCRM are running in a Docker container based on Ubuntu

When viewing the "Elections Page" for my newly created election, I am seeing PHP errors:

Nominations for President
Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 29
There are no existing nominations

Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 94
Nominations for 1st Vice-President
Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 29
There are no existing nominations

Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 94
Nominations for 2nd Vice-President
Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 29
There are no existing nominations

Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 94
Nominations for Secretary
Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 29
There are no existing nominations

Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 94
Nominations for Treasurer
Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 29
There are no existing nominations

Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 94
Nominations for Board Member
Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 29
There are no existing nominations

Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/wp-content/uploads/civicrm/templates_c/en_US/%%63/633/6330B7D7%%nominations.tpl.php on line 94

And when trying to submit a nomination, I get the following:
image

CiviCRM_API3_Exception: "Nomination cannot be added for deleted election."

#0 /var/www/html/wp-content/uploads/civicrm/ext/au.com.agileware.elections/CRM/Elections/Form/CreateElectionNomination.php(151): civicrm_api3("ElectionNomination", "create", (Array:3))
#1 /var/www/html/wp-content/uploads/civicrm/ext/au.com.agileware.elections/CRM/Elections/Form/CreateElectionNomination.php(166): CRM_Elections_Form_CreateElectionNomination->getNominationId((Array:8))
#2 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php(565): CRM_Elections_Form_CreateElectionNomination->postProcess()
#3 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Core/QuickForm/Action/Submit.php(56): CRM_Core_Form->mainProcess()
#4 /var/www/html/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Submit->perform(Object(CRM_Elections_Form_CreateElectionNomination), "submit")
#5 /var/www/html/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Elections_Form_CreateElectionNomination), "submit")
#6 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Core/Controller.php(353): HTML_QuickForm_Page->handle("submit")
#7 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Utils/Wrapper.php(98): CRM_Core_Controller->run()
#8 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(292): CRM_Utils_Wrapper->run("CRM_Elections_Form_CreateElectionNomination", "Create Election Nomination", (Array:0))
#9 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(69): CRM_Core_Invoke::runItem((Array:13))
#10 /var/www/html/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(36): CRM_Core_Invoke::_invoke((Array:4))
#11 /var/www/html/wp-content/plugins/civicrm/civicrm.php(1169): CRM_Core_Invoke::invoke((Array:4))
#12 /var/www/html/wp-includes/class-wp-hook.php(307): CiviCRM_For_WordPress->invoke("")
#13 /var/www/html/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters("", (Array:1))
#14 /var/www/html/wp-includes/plugin.php(474): WP_Hook->do_action((Array:1))
#15 /var/www/html/wp-admin/admin.php(259): do_action("toplevel_page_CiviCRM")
#16 {main}
 Sorry, due to an error, we are unable to fulfill your request at the moment. You may want to contact your administrator or service provider with more details about what action you were performing when this occurred.
Nomination cannot be added for deleted election.
Return to home page.

Potential For Double Voting

WordPress v6.2.2 CiviCRM v5.63.2

In the instant case, we have a Board of Directors whom total 7. We are green across the dashboard. It operates as expected through the Nomination cycle. As the screenshot demonstrates, though, it gives the option to Nominate again. I did verify that it allows such to be submitted at least to the screen where you would submit again with all the fields and dropdowns. I didn't want to compromise the election so I simply did not execute a second submission. In fact, using WP User Switch, I can resubmit through any valid Board Member. I am the only Admin and it happens with me, as well, ergo I presume it is a bug.

This is the screenshot documenting it: https://imgur.com/a/VFzLvJ8

Accepting nominations

This is exciting. An election extension is just what we need.

Can't figure something out though. How does a nominee accept a nomination? I was able to nominate myself, and then accept my own nomination. However I tried to accept a different person's nomination by using the Drupal masquerade feature, but access is denied. Is there a secret URL or token passed, or what?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.