Skip to content
Permalink
Browse files
fixing merge conflixt
  • Loading branch information
scnakandala committed Jun 11, 2015
1 parent de69764 commit aa4d3b4997c9d5a39245c92e8c285eb33088ddc8
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 52 deletions.
@@ -121,6 +121,7 @@
'Illuminate\Validation\ValidationServiceProvider',
'Illuminate\View\ViewServiceProvider',
'Illuminate\Workbench\WorkbenchServiceProvider',
'Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider',
'Wsis\WsisServiceProvider',
'Airavata\AiravataServiceProvider',
),
@@ -665,13 +665,18 @@ public static function get_experiment_values($experiment, $project, $forSearch =
* @param $experiment
* @return null
*/
public static function get_job_status($experiment)
public static function get_job_status(Experiment $experiment)
{
$jobStatus = Airavata::getJobStatuses($experiment->experimentID);

if ($jobStatus) {
$jobName = array_keys($jobStatus);
$jobState = JobState::$__names[$jobStatus[$jobName[0]]->jobState];
//$jobStatus = Airavata::getJobStatuses($experiment->experimentID);
if(!empty($experiment->workflowNodeDetailsList)){
if(!empty($experiment->workflowNodeDetailsList[0]->taskDetailsList)){
if(!empty($experiment->workflowNodeDetailsList[0]->taskDetailsList[0]->jobDetailsList)){
$jobStatus = $experiment->workflowNodeDetailsList[0]->taskDetailsList[0]->jobDetailsList[0]->jobStatus;
}
}
}
if (isset($jobStatus)) {
$jobState = JobState::$__names[$jobStatus->jobState];
} else {
$jobState = null;
}
@@ -399,6 +399,10 @@ class="icon-time"></i>2015-04-17 15:21:21</span> &ndash; <a href="">Airavata to
{{ HTML::script('js/flot/jquery.flot.resize.js')}}
{{ HTML::script('js/flot/jquery.flot.pie.js')}}
{{ HTML::script('js/flot/flot-data.js')}}

{{ HTML::script('js/moment.js')}}
{{ HTML::script('js/datetimepicker.js')}}

<script>
//make first tab of accordion open by default.
@@ -440,7 +444,7 @@ class="icon-time"></i>2015-04-17 15:21:21</span> &ndash; <a href="">Airavata to
//Experiment stages are under development.
$(".tree").parent().addClass("hide");
/* making datetimepicker work for exp search */
/* making datetimepicker work for exp stat search */
$('#datetimepicker9').datetimepicker({
pick12HourFormat: false
@@ -455,19 +459,5 @@ class="icon-time"></i>2015-04-17 15:21:21</span> &ndash; <a href="">Airavata to
$('#datetimepicker9').data("DateTimePicker").setMaxDate(e.date);
});
/* selecting creation time */
$("#search-key").on("change", function () {
if (this.value == "creation-time") {
$(".search-text-block").addClass("hide");
$(".select-dates").removeClass("hide");
$("#search-value").removeAttr("required");
}
else {
$(".search-text-block").removeClass("hide");
$(".select-dates").addClass("hide");
$("#search-value").attr("required");
}
});
</script>
@stop
@@ -6,7 +6,7 @@

@section('content')

<div class="container" style="max-width: 750px;">
<div class="container" style="max-width: 80%;">


<h1>Project Summary</h1>
@@ -38,30 +38,51 @@
echo '<th>Application</th>';
echo '<th>Compute Resource</th>';
echo '<th>Time</th>';
echo '<th>Status</th>';
echo '<th>Experiment Status</th>';
echo '<th>Job Status</th>';
echo '</tr>';
foreach ($experiments as $experiment) {
$expValues = ExperimentUtilities::get_experiment_values($experiment, ProjectUtilities::get_project($experiment->projectID), true);
$expValues["jobState"] = ExperimentUtilities::get_job_status($experiment);
$applicationInterface = AppUtilities::get_application_interface($experiment->applicationId);
echo '<tr>';
echo '<td>';
switch ($expValues["experimentStatusString"]) {
case 'CANCELING':
case 'CANCELED':
case 'UNKNOWN':
$textClass = 'text-warning';
break;
case 'FAILED':
$textClass = 'text-danger';
break;
case 'COMPLETED':
$textClass = 'text-success';
break;
default:
$textClass = 'text-info';
break;
}
switch ($expValues["experimentStatusString"]) {
case 'SCHEDULED':
case 'LAUNCHED':
case 'EXECUTING':
case 'CANCELING':
case 'COMPLETED':
echo $experiment->name;
echo '<a class="' . $textClass . '" href="' . URL::to('/') . '/experiment/summary?expId=' .
$experiment->experimentID . '">' . $experiment->name . '</a>';
break;
default:
echo $experiment->name .
' <a href="edit?expId=' .
echo '<a class="' . $textClass . '" href="' . URL::to('/') . '/experiment/summary?expId=' .
$experiment->experimentID . '">' . $experiment->name . '</a>' .
' <a href="' . URL::to('/') . '/experiment/edit?expId=' .
$experiment->experimentID .
'" title="Edit"><span class="glyphicon glyphicon-pencil"></span></a>';
break;
@@ -77,32 +98,12 @@
echo '<td class="time" unix-time="' . $expValues["experimentTimeOfStateChange"] . '"></td>';
switch ($expValues["experimentStatusString"]) {
case 'CANCELING':
case 'CANCELED':
case 'UNKNOWN':
$textClass = 'text-warning';
break;
case 'FAILED':
$textClass = 'text-danger';
break;
case 'COMPLETED':
$textClass = 'text-success';
break;
default:
$textClass = 'text-info';
break;
}
echo '<td><a class="' .
$textClass .
'" href="' . URL::to('/') . '/experiment/summary?expId=' .
$experiment->experimentID .
'">' .
$expValues["experimentStatusString"] .
'</a></td>';
echo '<td>'. $expValues["experimentStatusString"] . '</td>';
if ($expValues["jobState"]) echo '
<td>' . $expValues["jobState"] . '</td>';
else
echo '<td></td>';
echo '</tr>';
}
@@ -5,7 +5,8 @@
"license": "MIT",
"require": {
"laravel/framework": "4.2.*",
"apache/thrift": "1.0.*@dev"
"apache/thrift": "1.0.*@dev",
"barryvdh/laravel-ide-helper": "1.*"
},
"autoload": {
"classmap": [
@@ -18,10 +19,12 @@
"scripts": {
"post-install-cmd": [
"php artisan clear-compiled",
"php artisan ide-helper:generate",
"php artisan optimize"
],
"post-update-cmd": [
"php artisan clear-compiled",
"php artisan ide-helper:generate",
"php artisan optimize"
],
"post-create-project-cmd": [

0 comments on commit aa4d3b4

Please sign in to comment.