Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Workflow Install error


Go to End


3 Posts   1833 Views

Avatar
KS

Community Member, 10 Posts

12 October 2010 at 9:33am

I installed legacydatetimefields. I placed CMS Workflow-v1.0-rc4 in the root directory. Put the two-step decorators in the mysite\_config.php when I run the dev/build?flush=all I see (in green) where it builds tables etc.. I see(in blue) where the fieldmember.classname gets changed.

Then I run into a big USER NOTICE

[User Notice] Group::addToGroupByName is deprecated. Please use $member->addToGroupByCode($groupcode)

Source

177 }
178
179 return $labels;
180 }
181
182 /**
183 * @deprecated 2.5
184 */
185 public static function addToGroupByName($member, $groupcode) {
186 user_error('Group::addToGroupByName is deprecated. Please use $member->addToGroupByCode($groupcode)', E_USER_NOTICE);
187
188 return $member->addToGroupByCode($groupcode);
189 }
190
191 /**
192 * Overloaded getter.

I can rebuild without cmsworkflow and get it working again but a reinstall does not show the same errors yet I can not edit the pages in the cms after that.

Any Ideas?

Thank you,

KS

Avatar
Willr

Forum Moderator, 5523 Posts

12 October 2010 at 2:46pm

Its simply a user error. Try the latest trunk release of cmsworkflow to see if its been fixed already. If it hasn't then please raise this as a bug on open.silverstripe.org. It's a simply matter of changing Group::addToGroupByName($member, 'foo'); to $member->addToGroupByCode('foo');

Avatar
KS

Community Member, 10 Posts

13 October 2010 at 5:11am

I started from scratch and found that it was me that was the problem. I didn't follow the instructions on the cms-workflow readme. I only put the two step decorators in the _config.php. Do that and the whole thing will be corrupt. You have to do all of the decorators.

Thanks,
KS