Closed (fixed)
Project:
Business Rules
Version:
8.x-1.0-alpha10
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
7 Dec 2017 at 15:46 UTC
Updated:
27 Aug 2018 at 10:04 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
cocq commentedComment #3
d.novikov commentedThere are 2 issues with the module:
handler_settingsindexAttaching the patch that hopefully fixes both ones. Please check!
Comment #4
mrsmile commentedd.novikov,
could you please explain me how can I apply the patch?
Currently I have the similiar issue
thanks
Comment #5
mrsmile commentedHi guys!
I tested this attached patch and I can say that it works (for first look)
you can find patched module in attach
thanks to d.novikov
Comment #6
socialnicheguru commentedgit apply (patch name)
Comment #7
socialnicheguru commentedThe patch addresses the initial issue.
It allows the code to continue to a new error below.
1. Create a rule
2. Create a condition. This case the condition is comparing a field in an entity.
I saved the condition without completing it
3. I added the condition to the rule I created
I then get the error below.
there is a comparison at line 158 in business_rules/src/Plugin/BusinessRulesCondition/DataComparison.php:
there should be an option if "$date_to_compare" is NULL or empty. IE someone has not finished the rule.
I found that the field that I was using was defined but the data_to_compare was not.
field = field_my_address
data to compate =
When I saved content or did 'drush cr' I get:
Error: Call to a member function get() on null in drupal-8.4.4/html/modules/download/business_rules/src/Plugin/BusinessRulesCondition/DataComparison.php on line 164
#0 drupal-8.4.4/html/modules/download/business_rules/src/Entity/Condition.php(225): Drupal\business_rules\Plugin\BusinessRulesCondition\DataComparison->process(Object(Drupal\business_rules\Entity\Condition), Object(Drupal\business_rules\Events\BusinessRulesEvent))
Comment #8
joao sausen commentedUsing this patch in a project and I can confirm that it works.
Comment #9
dan_metille commentedFor me, patch #3 helps fixing the module, but I'm indeed still unable to work with more than one field on the entity edit form. (I'm using the dev version).
Any help would be welcome.
Comment #10
yseki commentedFixed on version alpha11.
PluginBase in Drupal 8.5 does not bring the value of configuration['handler_settings'] as in previous version.
Comment #11
dan_metille commentedDid not worked on alpha15. Switched to dev version with patch #3.
Comment #12
dan_metille commentedComment #14
yseki commentedI've made some mistake with GIT.
It's fixed on DEV now.
Thanks
Comment #15
tudxndvn commentedHi @yuriseki : I am trying create node Job with taxonomy: State and City. I folllowed : https://www.drupal.org/docs/8/modules/business-rules/advanced-usage/depe.... I work all step of it and it show state normal. But I don't know config Business Rules for change list value City when changed state . Can you tell me how to config Business Rules about: Rule , Action, Condititon.. My skype : batngodaisu. You can add my skype or reply me in this thread. Thank you
Comment #17
lule75 commentedI am trying to add an action to a condition but this is what i get.. I am using https://www.drupal.org/project/business_rules/releases/8.x-1.0-beta1
Fatal error: Call to a member function toString() on null in C:\xampp\htdocs\...\modules\business_rules\src\Form\ConditionForm.php on line 228
please help.. thank you in advance
Comment #18
tudxndvn commentedcool, it work for me. Thank @yuriseki. But i have a new question. I have 3 taxonomy : location, sub-region and region. When i update value of location , i want to fill automatic value of region and sub-region . Can we use Business Rules for this case. Thank you. Cheers!