Exclusion of records listed based upon felid choice
5 posts by 2 authors in: Forums > CMS Builder
Last Post: October 13, 2011 (RSS)
By nmsinc - October 12, 2011
Thanks
nmsinc
Re: [nmsinc] Exclusion of records listed based upon felid choice
What would you like to trigger this action with?
A check box in the user account record?
Are you using the membership plugin?
Jerry Kornbluth
Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php
Re: [gkornbluth] Exclusion of records listed based upon felid choice
By nmsinc - October 12, 2011
- Received[/#000000]
- In Route[/#000000]
- Working[/#000000]
- Finished [/#000000]
[/#000000]
These types are selected from a record submitted by a user. The admin dispatches and updates the record accordingly by selecting the current status for the drop down on the record-posting page. I have a listing page that lists all records entered and [/#000000]I need to exclude all records marked ‘Finished’ from the listing page![/#000000]
[/#000000]
Hope this helps?[/#000000]
Re: [nmsinc] Exclusion of records listed based upon felid choice
By gkornbluth - October 12, 2011 - edited: October 13, 2011
I'm not sure how
One approach would be to use a simple if statement as a criteria screen.
Something like:
<?php foreach ($your_tableRecords as $record): ?>
<?php if (!$record['your_field'] == "Finished"): ?> ...your code...
<?php endif ?>
<?php endforeach; ?>
Or
<?php foreach ($your_tableRecords as $record): ?>
<?php if ($record['your_field'] == "Received"): ?> ...your code for action 1...
<?php elseif ($record['your_field'] == "In Route"): ?>...your code for action 2...
<?php elseif ($record['your_field'] == "Working"): ?>...your code for action 3...
<?php else: ?> ...your code for action 4...
<?php endif ?>
<?php endforeach; ?>
If that doesn't quite fit the bill, there's a lot more on If statements in my CMSB cookbook at http://www.thecmsbcookbook.com
Hope that helps sort things out.
Jerry Kornbluth
Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php
Re: [gkornbluth] Exclusion of records listed based upon felid choice
By nmsinc - October 13, 2011 - edited: October 13, 2011
That worked with a little tweeking!