Hello. I got problem when I try to make rule using ROLE_EXPIRE module.
I created rule and choose event "User has logged in". After this I tried to add Action and I was expecting form. But nothing appears when page load finished. So I go to the reports and looked recent log.
The log message was :
Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'role_expire_rules_action_set_role_expire_form' not found or invalid function name in FacesExtendable->__call() (line 123 of /path/to/drupal7/sites/all/modules/rules/includes/faces.inc).
I've attached screenshot of the result when I try to add ROLE_EXPIRE action to the rule.
It seems role_expire.rules.inc is including 'role_expire_rules_action_set_role_expire_form' but drupal cant find it ?
Help me for this.
| Comment | File | Size | Author |
|---|---|---|---|
| #20 | ss.jpg | 56.26 KB | jtibbles |
| #7 | 1370262--role-expire-rules-2--7.patch | 7.21 KB | alexiswatson |
| #6 | 1370262--role-expire-rules-2--5.patch | 4.24 KB | alexiswatson |
| #3 | Capture1_3.JPG | 23.53 KB | earth1 |
| #3 | Capture2_1.JPG | 29.88 KB | earth1 |
Comments
Comment #1
togsbayar commentedComment #3
earth1 commentedversion 6.x-1.11
Hello. I have a problem when I try to make a rule using ROLE_EXPIRE module.
Role expiration date/time is today's date (Capture1_3.JPG). The correct date is (Capture2_1.JPG).
Thank you,
Comment #4
ryan88 commentedbump
Exact same problem. Any fixes?
Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'role_expire_rules_action_set_role_expire_form' not found or invalid function name in FacesExtendable->__call() (line 123 of public_html/sites/all/modules/rules/includes/faces.inc).
Using Drupal 7.10
Comment #5
alexiswatson commentedConfirmed the issue in 7.x-1.0-beta2 (EDIT: also in the latest 7.x-1.0-dev), with the same UI behavior as above and the following logged to watchdog:
@3: Just a few quick tips for navigating the issue queues. First, your issue doesn't seem related to this one: you'll have much better luck creating your own issue after searching the issue queue to see if someone else already opened one with the problem you describe. Also, the "Assigned" field is only used when you want to take ownership of an issue, either the whole thing or the next step. The Issue Queue Handbook explains all this and more.
Comment #6
alexiswatson commentedTurns out the rules plugin was still written for Rules 1.0, and needed a rewrite. Updated this in the following patch. If the client requires them, I might add a few more actions and conditions in future patches. Note that strtotime is already called on the stored date value by the time the set action fires.
Review and feedback welcome!
Comment #7
alexiswatson commentedAdded two more actions that the client needed: one for setting a role's expiry to the latest expiry of roles attached to a given user, and another for adding an extension to an existing expiry based on a relative timespan rather than simply setting it (relative dates are otherwise relative to time()). Very handy for managing role subscriptions via Drupal Commerce!
Comment #8
manischewitzbacon commentedpatched and tested and happy - if you're ever in portland, OR davidwatson, I'll buy you a beer
Comment #9
ptmkenny commentedI tried to apply the patch in #7 using the following command:
git apply -v 1370262--role-expire-rules-2--7.patch
But I experienced the following error:
L7:role_expire patrick$ git apply -v 1370262--role-expire-rules-2--7.patch
1370262--role-expire-rules-2--7.patch:136: trailing whitespace.
* Action: Set expire time for role to longest attached to this user. Defaults
1370262--role-expire-rules-2--7.patch:143: trailing whitespace.
$this_ts = role_expire_get_user_role_expiry_time($account->uid, $id);
Checking patch role_expire/role_expire.rules.inc...
error: role_expire/role_expire.rules.inc: No such file or directory
Comment #10
user654 commented.
Comment #11
user654 commented.
Comment #12
stewsnoozeDrupal uses git now. You should probably try to commit it using git apply -v [patch-name.patch] however I doubt it will apply as the patch is out of date.
Comment #13
stewsnoozeI take that back. This patch may still apply
Comment #14
user654 commented.
Comment #15
alexiswatson commentedWhen and where are you seeing the error messages? Having more information and steps to duplicate the problem would help greatly.
By the way, d.o patches are -p1 now, not -p0, to be more compatible with git.
Comment #16
user654 commented.
Comment #17
stewsnoozeCommitted to GIT 7.x-1.x Thanks davidwatson
Comment #19
Marc Storms commentedI installed role_expire-7.x-1.0-beta2.tar and changed the role_expire.rules.inc with
http://drupalcode.org/project/role_expire.git/blob/0c3c0f19923f42977ad43...
Unfortunately I am receiving an "Unknown action role_expire_rules_action_extend_role_expire."
and the log messages read like
Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'role_expire_rules_action_set_role_expire_form' not found or invalid function name in FacesExtendable->__call() (line 123 of /home/abrainfo/www/sites/all/modules/rules/includes/faces.inc).
Comment #20
jtibbles commentedUsing Commerce Kickstat 7.x-2.7. Added Role Expire module. Have a rule that switches users to a particular role on purchase. That role then needs an expiry date set. Using rules I choose any of the role expire options (already patched the dropdown using previously recommended patches, however this issue was present before the patch). The UI then goes blank (see attached
Also setting expiry times through "roles" didn't seem to work either, but atleast it let me fill in the details, even though those details are ignored.
Comment #21
alexiswatson commentedHi jtibbles,
First, welcome! Generally speaking, issues remain closed unless the fix itself was incomplete. If the issue was already present before the patch and doesn't seem to be related, you'll probably have better luck opening a new issue if one doesn't match your exact problem. All this and more can be found in the issue queue documentation.