airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ndo...@apache.org
Subject [1/2] airavata-php-gateway git commit: AIRAVATA-1632 + Job Description added to experiments
Date Tue, 28 Apr 2015 20:56:46 GMT
Repository: airavata-php-gateway
Updated Branches:
  refs/heads/master 3c8448d34 -> 39a110e04


AIRAVATA-1632 + Job Description added to experiments


Project: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/repo
Commit: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/commit/8fc1cf41
Tree: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/tree/8fc1cf41
Diff: http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/diff/8fc1cf41

Branch: refs/heads/master
Commit: 8fc1cf4194f8c5fec475b16028fdac493bc47370
Parents: 9f593e0
Author: Nipurn Doshi <nipunhere@gmail.com>
Authored: Tue Apr 28 16:55:12 2015 -0400
Committer: Nipurn Doshi <nipunhere@gmail.com>
Committed: Tue Apr 28 16:55:12 2015 -0400

----------------------------------------------------------------------
 app/controllers/ExperimentController.php     |  4 ++++
 app/libraries/utilities.php                  | 16 +++++++++++++++-
 app/views/partials/experiment-info.blade.php | 22 ++++++++++++++++++++++
 3 files changed, 41 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/blob/8fc1cf41/app/controllers/ExperimentController.php
----------------------------------------------------------------------
diff --git a/app/controllers/ExperimentController.php b/app/controllers/ExperimentController.php
index 7bdce1f..69abd00 100755
--- a/app/controllers/ExperimentController.php
+++ b/app/controllers/ExperimentController.php
@@ -74,6 +74,9 @@ class ExperimentController extends BaseController {
 		{
 			$project = Utilities::get_project($experiment->projectID);
 			$expVal = Utilities::get_experiment_values( $experiment, $project);
+			$jobDetails = Utilities::get_job_details( $experiment->experimentID);
+			$transferDetails = Utilities::get_transfer_details( $experiment->experimentID);
+			//var_dump( $jobDetails); exit;
 			// User should not clone or edit a failed experiment. Only create clones of it.
 			if( $expVal["experimentStatusString"] == "FAILED")
 				$expVal["editable"] = false;
@@ -86,6 +89,7 @@ class ExperimentController extends BaseController {
 										"expId" => Input::get("expId"),
 										"experiment" => $experiment,
 										"project" => $project,
+										"jobDetails" => $jobDetails,
 										"expVal" => $expVal
 						);
 

http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/blob/8fc1cf41/app/libraries/utilities.php
----------------------------------------------------------------------
diff --git a/app/libraries/utilities.php b/app/libraries/utilities.php
index 946abdd..a456673 100644
--- a/app/libraries/utilities.php
+++ b/app/libraries/utilities.php
@@ -1147,10 +1147,13 @@ public static function clone_experiment($expId)
 public static function cancel_experiment($expId)
 {
     $airavataclient = Session::get("airavataClient");
+    $app_config = Utilities::read_config();
+
+
 
     try
     {
-        $airavataclient->terminateExperiment($expId);
+        $airavataclient->terminateExperiment($expId, $app_config["credential-store-token"]);
 
         Utilities::print_success_message("Experiment canceled!");
     }
@@ -2092,6 +2095,17 @@ public static function read_config( $fileName = null){
     return $wsis_config;
 
 }
+
+public static function get_job_details( $experimentId){
+    $airavataclient = Session::get("airavataClient");
+    return $airavataclient->getJobDetails( $experimentId);
+}
+
+public static function get_transfer_details( $experimentId){
+    $airavataclient = Session::get("airavataClient");
+    return $airavataclient->getDataTransferDetails( $experimentId);
+}
+
 }
 
 ?>

http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/blob/8fc1cf41/app/views/partials/experiment-info.blade.php
----------------------------------------------------------------------
diff --git a/app/views/partials/experiment-info.blade.php b/app/views/partials/experiment-info.blade.php
index 21c8031..90c7ae7 100644
--- a/app/views/partials/experiment-info.blade.php
+++ b/app/views/partials/experiment-info.blade.php
@@ -47,6 +47,28 @@
         </tr>
         ';
         ?>
+
+        @if( isset($dashboard))
+        <tr>
+            <td><strong>Working Dir</strong></td>
+
+            <?php
+            foreach($jobDetails as $job) echo '
+                <td>' . $job->workingDir . '</td>
+            ';
+            ?>
+        </tr>
+         <tr>
+            <td><strong>Job Description</strong></td>
+
+            <?php
+            foreach($jobDetails as $job) echo '
+                <td>' . $job->jobDescription . '</td>
+            ';
+            ?>
+        </tr>
+        @endif
+
         <tr>
             <td><strong>Creation time</strong></td>
             <td><?php echo $expVal["experimentCreationTime"]; ?></td>


Mime
View raw message