phpScheduleIt
May 23, 2013, 12:34:09 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: phpScheduleIt 2.4.2 has been released!
 
   Home   Help Login Register  
Pages: [1]
  Print  
Author Topic: Hide reservation table fields based on scheduleID  (Read 800 times)
zaky
Newbie
*

Karma: 0
Posts: 17


« on: May 24, 2010, 03:40:33 AM »

Hello,
I am using phpscheduleit in our laboratory to schedule  samples testing and prototype making activities. These two activities are our two schedules and the tests equipments/ tasks are our resources.People will ask us to test samples or make a prototypes and the information requested on these two activities are differents.
I can add/read /show additional fields to the reservation table . When making a reservation how to show only the fields related to a given schedule?
I think I should modify reserve.template.php using an if statement in the function print_basic_panel.  How the structure of the if statement should be?
I would appreciate any pointer you might be able to give.

Once again thank you for this great software!
Logged
Nick
Administrator
Hero Member
*****

Karma: 15
Posts: 5419


WWW
« Reply #1 on: May 24, 2010, 02:27:33 PM »

On the project page on SourceForge there is a document on adding new fields.  Take a look there to see if that helps.
Logged
zaky
Newbie
*

Karma: 0
Posts: 17


« Reply #2 on: May 26, 2010, 04:04:11 PM »

Hello,
I tried
if(!$scheduletitle = 'Test Equipments') {
   print_testare($res->get_testare(), $res->type);
   }
also
if(!$scheduleid = 'sc14bf947e266ff6') {
   print_testare($res->get_testare(), $res->type);
   }
but whatever the schedule I choose, the field doesn't show. What may be the problem?

But the code below shows the the else option
 if ($resid=''&$scheduleid = 'sc14bf947e266ff6')
    {
   print_testare($res->get_testare(), $res->type);
   }
   else
   {
   print_specimen($res->get_specimen(), $res->type);
        }
Any suggestion?
« Last Edit: May 26, 2010, 04:42:20 PM by zaky » Logged
zaky
Newbie
*

Karma: 0
Posts: 17


« Reply #3 on: May 31, 2010, 07:46:10 AM »

if ($res->scheduleid == 'sc1423642970aa9f') solved  my problem.

Once again thanks for this great app.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2006-2007, Simple Machines Valid XHTML 1.0! Valid CSS!