Groups
Groups
Sign in
Groups
Groups
CFWheels
Conversations
About
Send feedback
Help
default FindAll / FindOne where clause
16 views
Skip to first unread message
George
unread,
May 22, 2013, 10:02:15 PM
5/22/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to cfwh...@googlegroups.com
Is there a way to the equivalent of a BeforeFind() in the model INIT to manipulate a where clause before it goes to the database?
I want to have (foo = "xxx") as the default and if there is a where statement already, then I want ((currentWhereSQL) and (foo = "xxx"))
Adam Chapman
unread,
May 22, 2013, 10:37:33 PM
5/22/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to cfwh...@googlegroups.com
Perhaps the DefaultScope plugin will help?
http://cfwheels.org/plugins/listing/23
Regards,
Adam
George
unread,
May 22, 2013, 11:35:09 PM
5/22/13
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to cfwh...@googlegroups.com
That might help me find a solution. It won't solve the problem cause I want my default added to the value that is passed in. But that is a good start.
Reply all
Reply to author
Forward
0 new messages