Is there an updated code for CC6? I have a dozen users that submit work orders via CF6. I am trying to set this up so that each submitter will only see their submitted record. In the database I have it setup to store the user id. But for the life of me I just cannot figure exactly where to put the code below. In CC6 I have the General tab, the Events, Views, Functions, Locales, Permissions. Does the code below go in the Functions tab with function of Read Data in the Where conditions box? If so, what is the next step?
1054 Unknown column 'Article.172' in 'where clause'
172 is an actual user id.
Again, in this event I am trying to get a user to see only his records. Any detailed help is appreciated!
<?php $user = \JFactory::getUser(); return array('model_id.user_id' => $user->id); ?>I am setting this up in the read data function named "read_myarticles" with a model name Article and placing the code below in the Where conditions box:
<?php $user = \JFactory::getUser(); return array('Article.user_id' => $user->id); ?>In my Events tab I have an event named myorders and there I use
{fn:read_myarticles}I end up with on the preview:
1054 Unknown column 'Article.172' in 'where clause'
172 is an actual user id.
Again, in this event I am trying to get a user to see only his records. Any detailed help is appreciated!