From f688bd4660c7e3159fab94d529a5b94197f5f35f Mon Sep 17 00:00:00 2001 From: prashant Date: Sun, 11 Oct 2015 16:51:38 +0530 Subject: Initial repo --- lab_details.inc | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100755 lab_details.inc (limited to 'lab_details.inc') diff --git a/lab_details.inc b/lab_details.inc new file mode 100755 index 0000000..59898da --- /dev/null +++ b/lab_details.inc @@ -0,0 +1,40 @@ +fields('lab_migration_proposal'); + $query->condition('approval_status', 3); + $result = $query->execute(); + //$result = db_query($query); + $proposal_rows = array(); + $i=1; + while($row = $result->fetchObject()) { + $approval_date=date("Y", $row->approval_date); + $preference_rows[] = array($i, $row->university , l($row->lab_title,"lab_migration_run/".$row->id),$approval_date); + $i++; + } + $preference_header = array('No','Institute', 'Lab', 'Year'); + $output = theme('table', array('header' => $preference_header, 'rows' => $preference_rows)); + return $output; + } + + function lab_migration_labs_progress_all() { + $page_content = ""; + //$query = "SELECT * FROM {lab_migration_proposal} WHERE approval_status = 1 and solution_status = 2"; + $query = db_select('lab_migration_proposal'); + $query->fields('lab_migration_proposal'); + $query->condition('approval_status', 1); + $query->condition('solution_status', 2); + $result = $query->execute(); + //$result = db_query($query); + $page_content .= "
    "; + while($row = $result->fetchObject()) { + $page_content .= "
  1. "; + $page_content .= $row->university . " ({$row->lab_title})"; + $page_content .= "
  2. "; + } + $page_content .= "
"; + return $page_content; + } +?> -- cgit