show: function() {
this.hideAll();
+ this.initTabs();
$(this.window_id).setStyle({'display' : 'block'});
$$('div[id=' + this.window_id + '] input[type="submit"]').each(function(el) {
el.observe('click', function() {
is_progress: function() {
return $(this.progress_id).getStyle('display') == 'block';
},
+
+ initTabs: function() {
+ var show_elements = [];
+ var element;
+ var tabs = $$('div[id=' + this.window_id + '] span.tab');
+ tabs.each(function(el) {
+ element = el.readAttribute('rel');
+ show_elements.push($(element));
+ el.observe('click', function() {
+ show_elements.invoke('hide');
+ tabs.invoke('removeClassName', 'tab_active');
+ el.addClassName('tab_active');
+ var show_el = $(el.readAttribute('rel'));
+ $(show_el).show();
+ }.bind(this));
+ }.bind(this));
+ },
+
+ switchTab: function(tab_rel) {
+ var tabs = $$('div[id=' + this.window_id + '] span.tab');
+ tabs.each(function(el) {
+ element = el.readAttribute('rel');
+ if (element == tab_rel) {
+ el.addClassName('tab_active');
+ } else {
+ el.removeClassName('tab_active');
+ }
+ $(element).hide();
+ });
+ $(tab_rel).show();
+ },
+
openConfigurationWindow: function(slideWindowObj) {
if(this.is_progress() === false) {
this.progress(true);
msgid "Add"
msgstr "Add"
+msgid "Actions"
+msgstr "Actions"
+
msgid "Add"
msgstr "Dodaj"
+msgid "Actions"
+msgstr "Akcje"
+
<%@ MasterClass="Application.Portlets.ConfigurationPanel"%>
<com:TContent ID="ConfigurationWindowContent">
<com:TActivePanel DefaultButton="Apply">
- <strong><%[ Client name: ]%> <com:TActiveLabel ID="ClientName" /><com:TActiveLabel ID="ClientIdentifier" Visible="false" /></strong><br />
- <com:TActiveLabel ID="ClientDescription" Style="font-style: italic; font-size: 12px"/>
- <hr />
- <com:TValidationSummary
- ID="ValidationSummary"
- CssClass="validation-error-summary"
- ValidationGroup="ClientGroup"
- AutoUpdate="true"
- Display="Dynamic"
- HeaderText="<%[ There is not possible to run selected action because: ]%>" />
- <div class="text small"><%[ Console status ]%></div>
- <div class="field-full" style="min-height: 172px">
- <com:TActiveTextBox ID="ShowClient" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 162px; font-size: 11px;" ReadOnly="true" />
- </div>
- <div class="button">
- <com:BActiveButton ID="Status" Text="<%[ Status ]%>" ClientSide.OnSuccess="ConfigurationWindow.getObj('ClientWindow').progress(false);" OnClick="status" />
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="FileRetention" Text="<%[ File retention (in days): ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="FileRetention" MaxLength="14" AutoPostBack="false" CssClass="textbox-auto" Text="" />
- <com:TActiveCustomValidator ID="FileRetentionValidator" ValidationGroup="ClientGroup" ControlToValidate="FileRetention" ErrorMessage="<%[ File retention value must be positive integer or zero. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="fileRetentionValidator" />
+ <h4><%[ Client name: ]%> <com:TActiveLabel ID="ClientName" /><com:TActiveLabel ID="ClientIdentifier" Visible="false" /></h4>
+ <com:TActiveLabel ID="ClientDescription" CssClass="description" />
+ <span class="text tab tab_active" rel="client_actions_tab"><%[ Actions ]%></span>
+ <span class="text tab" rel="client_console_tab"><%[ Console status ]%></span>
+ <hr class="tabs" />
+ <div id="client_actions_tab">
+ <com:TValidationSummary
+ ID="ValidationSummary"
+ CssClass="validation-error-summary"
+ ValidationGroup="ClientGroup"
+ AutoUpdate="true"
+ Display="Dynamic"
+ HeaderText="<%[ There is not possible to run selected action because: ]%>" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="FileRetention" Text="<%[ File retention (in days): ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="FileRetention" MaxLength="14" AutoPostBack="false" CssClass="textbox-auto" Text="" />
+ <com:TActiveCustomValidator ID="FileRetentionValidator" ValidationGroup="ClientGroup" ControlToValidate="FileRetention" ErrorMessage="<%[ File retention value must be positive integer or zero. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="fileRetentionValidator" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="JobRetention" Text="<%[ Job retention (in days): ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="JobRetention" MaxLength="14" AutoPostBack="false" CssClass="textbox-auto" Text="" />
- <com:TActiveCustomValidator ID="JobRetentionValidator" ValidationGroup="ClientGroup" ControlToValidate="JobRetention" ErrorMessage="<%[ Job retention value must be positive integer or zero. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="jobRetentionValidator" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="JobRetention" Text="<%[ Job retention (in days): ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="JobRetention" MaxLength="14" AutoPostBack="false" CssClass="textbox-auto" Text="" />
+ <com:TActiveCustomValidator ID="JobRetentionValidator" ValidationGroup="ClientGroup" ControlToValidate="JobRetention" ErrorMessage="<%[ Job retention value must be positive integer or zero. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="jobRetentionValidator" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="AutoPrune" Text="<%[ AutoPrune: ]%>" /></div>
- <div class="field"><com:TActiveCheckBox ID="AutoPrune" AutoPostBack="false" /></div>
- </div>
- <com:TCallback ID="ReloadClients" OnCallback="Page.ClientWindow.prepareData" ClientSide.OnComplete="SlideWindow.getObj('ClientWindow').setLoadRequest();" />
- <script type="text/javascript">
- var client_callback_func = function() {
- var mainForm = Prado.Validation.getForm();
- var callback = <%=$this->ReloadClients->ActiveControl->Javascript%>;
- if (Prado.Validation.managers[mainForm].getValidatorsWithError('ClientGroup').length == 0) {
- callback.dispatch();
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="AutoPrune" Text="<%[ AutoPrune: ]%>" /></div>
+ <div class="field"><com:TActiveCheckBox ID="AutoPrune" AutoPostBack="false" /></div>
+ </div>
+ <com:TCallback ID="ReloadClients" OnCallback="Page.ClientWindow.prepareData" ClientSide.OnComplete="SlideWindow.getObj('ClientWindow').setLoadRequest();" />
+ <script type="text/javascript">
+ var client_callback_func = function() {
+ var mainForm = Prado.Validation.getForm();
+ var callback = <%=$this->ReloadClients->ActiveControl->Javascript%>;
+ if (Prado.Validation.managers[mainForm].getValidatorsWithError('ClientGroup').length == 0) {
+ callback.dispatch();
+ }
}
- }
- </script>
- <div class="button">
- <com:BActiveButton ValidationGroup="ClientGroup" OnClick="apply" CausesValidation="true" ID="Apply" Text="<%[ Apply ]%>" ClientSide.OnSuccess="ConfigurationWindow.getObj('ClientWindow').progress(false);client_callback_func();" />
+ </script>
+ <div class="button">
+ <com:BActiveButton ID="Status" Text="<%[ Status ]%>" OnClick="status">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('ClientWindow').progress(false);
+ ConfigurationWindow.getObj('ClientWindow').switchTab('client_console_tab');
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ <com:BActiveButton ValidationGroup="ClientGroup" OnClick="apply" CausesValidation="true" ID="Apply" Text="<%[ Apply ]%>">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('ClientWindow').progress(false);
+ client_callback_func();
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ </div>
+ </div>
+ <div id="client_console_tab" style="display: none">
+ <div class="field-full">
+ <com:TActiveTextBox ID="ShowClient" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 475px" ReadOnly="true" />
+ </div>
</div>
</com:TActivePanel>
</com:TContent>
$this->Priority->Text = ($jobdata->priorjobid == 0) ? self::DEFAULT_JOB_PRIORITY : $jobdata->priorjobid;
$this->DeleteButton->Visible = true;
$this->CancelButton->Visible = $this->RefreshStart->Value = in_array($jobdata->jobstatus, $runningJobStates);
+ $this->Run->Display = 'Dynamic';
+ $this->EstimateLine->Display = 'Dynamic';
+ $this->Status->Visible = true;
}
public function status($sender, $param) {
public function delete($sender, $param) {
$this->Application->getModule('api')->remove(array('jobs', $this->JobID->Text));
+ $this->Status->Visible = false;
+ $this->Run->Display = 'None';
$this->DeleteButton->Visible = false;
+ $this->EstimateLine->Display = 'None';
}
public function cancel($sender, $param) {
$this->Application->getModule('api')->set(array('jobs', 'cancel', $this->JobID->Text), array('a' => 'b'));
$this->CancelButton->Visible = false;
+ $this->status(null, null);
}
public function run_again($sender, $param) {
<%@ MasterClass="Application.Portlets.ConfigurationPanel"%>
<com:TContent ID="ConfigurationWindowContent">
<com:TActivePanel DefaultButton="Run">
- <strong><%[ Job name: ]%> <com:TActiveLabel ID="JobName" /><com:TActiveLabel ID="JobID" Visible="false" /></strong>
- <hr />
- <com:TValidationSummary
- ID="ValidationSummary"
- CssClass="validation-error-summary"
- ValidationGroup="JobGroup"
- AutoUpdate="true"
- Display="Dynamic"
- />
- <div class="line">
- <div class="text"><com:TLabel ForControl="Level" Text="<%[ Level: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Level" AutoPostBack="false" CssClass="textbox-auto">
- <prop:Attributes.onchange>
- var job_to_verify = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
- var verify_options = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
- var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
- var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
- var accurate = $('<%=$this->AccurateLine->ClientID%>');
- var estimate = $('<%=$this->EstimateLine->ClientID%>');
- var verify_current_opt = $('<%=$this->JobToVerifyOptions->ClientID%>').value;
- if(/^(<%=implode('|', $this->jobToVerify)%>)$/.test(this.value)) {
- accurate.hide();
- estimate.hide();
- verify_options.show();
- job_to_verify.show();
- if (verify_current_opt == 'jobid') {
+ <h4><%[ Job name: ]%> <com:TActiveLabel ID="JobName" /><com:TActiveLabel ID="JobID" Visible="false" /></h4>
+ <span class="text tab tab_active" rel="job_actions_tab"><%[ Actions ]%></span>
+ <span class="text tab" rel="job_console_tab"><%[ Console status ]%></span>
+ <hr class="tabs" />
+ <div id="job_actions_tab">
+ <com:TValidationSummary
+ ID="ValidationSummary"
+ CssClass="validation-error-summary"
+ ValidationGroup="JobGroup"
+ AutoUpdate="true"
+ Display="Dynamic"
+ />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Level" Text="<%[ Level: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Level" AutoPostBack="false" CssClass="textbox-auto">
+ <prop:Attributes.onchange>
+ var job_to_verify = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
+ var verify_options = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
+ var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
+ var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
+ var accurate = $('<%=$this->AccurateLine->ClientID%>');
+ var estimate = $('<%=$this->EstimateLine->ClientID%>');
+ var verify_current_opt = $('<%=$this->JobToVerifyOptions->ClientID%>').value;
+ if(/^(<%=implode('|', $this->jobToVerify)%>)$/.test(this.value)) {
+ accurate.hide();
+ estimate.hide();
+ verify_options.show();
+ job_to_verify.show();
+ if (verify_current_opt == 'jobid') {
+ verify_by_job_name.hide();
+ verify_by_jobid.show();
+ } else if (verify_current_opt == 'jobname') {
+ verify_by_job_name.show();
+ verify_by_jobid.hide();
+ }
+ } else if (job_to_verify.visible()) {
+ job_to_verify.hide();
+ verify_options.hide();
verify_by_job_name.hide();
- verify_by_jobid.show();
- } else if (verify_current_opt == 'jobname') {
- verify_by_job_name.show();
verify_by_jobid.hide();
+ accurate.show();
+ estimate.show();
}
- } else if (job_to_verify.visible()) {
- job_to_verify.hide();
- verify_options.hide();
- verify_by_job_name.hide();
- verify_by_jobid.hide();
- accurate.show();
- estimate.show();
- }
- </prop:Attributes.onchange>
- </com:TActiveDropDownList>
- </div>
- </div>
- <com:TActivePanel ID="JobToVerifyOptionsLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="JobToVerifyOptions" Text="<%[ Verify option: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="JobToVerifyOptions" AutoPostBack="false" CssClass="textbox-auto">
- <prop:Attributes.onchange>
- var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
- var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
- if (this.value == 'jobname') {
- verify_by_jobid.hide();
- verify_by_job_name.show();
- } else if (this.value == 'jobid') {
- verify_by_job_name.hide();
- verify_by_jobid.show();
- } else {
- verify_by_job_name.hide();
- verify_by_jobid.hide();
- }
- </prop:Attributes.onchange>
- </com:TActiveDropDownList>
+ </prop:Attributes.onchange>
+ </com:TActiveDropDownList>
+ </div>
</div>
- </com:TActivePanel>
- <com:TActivePanel ID="JobToVerifyJobNameLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="JobToVerifyJobName" Text="<%[ Job to Verify: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="JobToVerifyJobName" AutoPostBack="false" CssClass="textbox-auto" />
- </div>
- </com:TActivePanel>
- <com:TActivePanel ID="JobToVerifyJobIdLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="JobToVerifyJobId" Text="<%[ JobId to Verify: ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="JobToVerifyJobId" CssClass="textbox-auto" AutoPostBack="false" />
- <com:TActiveCustomValidator ID="JobToVerifyJobIdValidator" ValidationGroup="JobGroup" ControlToValidate="JobToVerifyJobId" ErrorMessage="<%[ JobId to Verify value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="jobIdToVerifyValidator" />
+ <com:TActivePanel ID="JobToVerifyOptionsLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="JobToVerifyOptions" Text="<%[ Verify option: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="JobToVerifyOptions" AutoPostBack="false" CssClass="textbox-auto">
+ <prop:Attributes.onchange>
+ var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
+ var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
+ if (this.value == 'jobname') {
+ verify_by_jobid.hide();
+ verify_by_job_name.show();
+ } else if (this.value == 'jobid') {
+ verify_by_job_name.hide();
+ verify_by_jobid.show();
+ } else {
+ verify_by_job_name.hide();
+ verify_by_jobid.hide();
+ }
+ </prop:Attributes.onchange>
+ </com:TActiveDropDownList>
+ </div>
+ </com:TActivePanel>
+ <com:TActivePanel ID="JobToVerifyJobNameLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="JobToVerifyJobName" Text="<%[ Job to Verify: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="JobToVerifyJobName" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
+ </com:TActivePanel>
+ <com:TActivePanel ID="JobToVerifyJobIdLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="JobToVerifyJobId" Text="<%[ JobId to Verify: ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="JobToVerifyJobId" CssClass="textbox-auto" AutoPostBack="false" />
+ <com:TActiveCustomValidator ID="JobToVerifyJobIdValidator" ValidationGroup="JobGroup" ControlToValidate="JobToVerifyJobId" ErrorMessage="<%[ JobId to Verify value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="jobIdToVerifyValidator" />
+ </div>
+ </com:TActivePanel>
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Client" Text="<%[ Client: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Client" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </com:TActivePanel>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Client" Text="<%[ Client: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Client" AutoPostBack="false" CssClass="textbox-auto" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="FileSet" Text="<%[ FileSet: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="FileSet" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="FileSet" Text="<%[ FileSet: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="FileSet" AutoPostBack="false" CssClass="textbox-auto" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Pool" Text="<%[ Pool: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Pool" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Pool" Text="<%[ Pool: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Pool" AutoPostBack="false" CssClass="textbox-auto" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Storage" Text="<%[ Storage: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Storage" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Storage" Text="<%[ Storage: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Storage" AutoPostBack="false" CssClass="textbox-auto" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Priority" Text="<%[ Priority: ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="Priority" CssClass="textbox-auto" AutoPostBack="false" />
+ <com:TActiveCustomValidator ID="PriorityValidator" ValidationGroup="JobGroup" ControlToValidate="Priority" ErrorMessage="<%[ Priority value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="priorityValidator" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Priority" Text="<%[ Priority: ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="Priority" CssClass="textbox-auto" AutoPostBack="false" />
- <com:TActiveCustomValidator ID="PriorityValidator" ValidationGroup="JobGroup" ControlToValidate="Priority" ErrorMessage="<%[ Priority value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="priorityValidator" />
+ <com:TActivePanel ID="AccurateLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="Accurate" Text="<%[ Accurate: ]%>" /></div>
+ <div class="field"><com:TActiveCheckBox ID="Accurate" AutoPostBack="false" /></div>
+ </com:TActivePanel>
+ <com:TCallback ID="ReloadJobs" OnCallback="Page.JobWindow.prepareData" ClientSide.OnComplete="SlideWindow.getObj('JobWindow').setLoadRequest(); job_callback_duration = new Date().getTime();" />
+ <script type="text/javascript">
+ var job_callback_duration;
+ var job_callback_func = function() {
+ /*
+ * Check if Job list window is open and if any checkbox from actions is not checked.
+ * If yes, then is possible to refresh Job list window.
+ */
+ if(SlideWindow.getObj('JobWindow').isWindowOpen() === true && SlideWindow.getObj('JobWindow').areActionsOpen() === false) {
+ var mainForm = Prado.Validation.getForm();
+ var callback = <%=$this->ReloadJobs->ActiveControl->Javascript%>;
+ if (Prado.Validation.managers[mainForm].getValidatorsWithError('JobGroup').length == 0) {
+ SlideWindow.getObj('JobWindow').markAllChecked(false);
+ callback.dispatch();
+ }
+ }
+ }
+ </script>
+ <div class="button">
+ <com:BActiveButton ID="Status" Text="<%[ Job status ]%>" CausesValidation="false" OnClick="status" CssClass="bbutton">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('JobWindow').progress(false);
+ job_callback_func();
+ ConfigurationWindow.getObj('JobWindow').switchTab('job_console_tab');
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ <com:TActiveLabel ID="DeleteButton">
+ <com:BActiveButton ID="Delete" Text="<%[ Delete job ]%>" CausesValidation="false" OnClick="delete" CssClass="bbutton">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('JobWindow').progress(false);
+ job_callback_func();
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ </com:TActiveLabel>
+ <com:TActiveLabel ID="CancelButton">
+ <com:BActiveButton ID="Cancel" Text="<%[ Cancel job ]%>" CausesValidation="false" OnClick="cancel" CssClass="bbutton">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('JobWindow').progress(false);
+ job_callback_func();
+ ConfigurationWindow.getObj('JobWindow').switchTab('job_console_tab');
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ </com:TActiveLabel>
+ <com:TActivePanel ID="EstimateLine" CssClass="button_line">
+ <com:BActiveButton ID="Estimate" Text="<%[ Estimate job ]%>" OnClick="estimate" CssClass="bbutton">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('JobWindow').progress(false);
+ ConfigurationWindow.getObj('JobWindow').switchTab('job_console_tab');
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ </com:TActivePanel>
+ <com:BActiveButton ID="Run" Text="<%[ Run job again ]%>" ValidationGroup="JobGroup" CausesValidation="true" OnClick="run_again">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('JobWindow').progress(false);
+ job_callback_func();
+ oMonitor();
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
</div>
</div>
- <com:TCallback ID="ReloadJobs" OnCallback="Page.JobWindow.prepareData" ClientSide.OnComplete="SlideWindow.getObj('JobWindow').setLoadRequest(); job_callback_duration = new Date().getTime();" />
- <script type="text/javascript">
- var job_callback_duration;
- var job_callback_func = function() {
- /*
- * Check if Job list window is open and if any checkbox from actions is not checked.
- * If yes, then is possible to refresh Job list window.
- */
- if(SlideWindow.getObj('JobWindow').isWindowOpen() === true && SlideWindow.getObj('JobWindow').areActionsOpen() === false) {
- var mainForm = Prado.Validation.getForm();
- var callback = <%=$this->ReloadJobs->ActiveControl->Javascript%>;
- if (Prado.Validation.managers[mainForm].getValidatorsWithError('JobGroup').length == 0) {
- SlideWindow.getObj('JobWindow').markAllChecked(false);
+ <div id="job_console_tab" style="display: none">
+ <com:TCallback ID="RefreshStatus" OnCallback="status" ClientSide.OnComplete="job_callback_duration = new Date().getTime();" />
+ <script type="text/javascript">
+ var status_prev = false;
+ var status_callback_func = function() {
+ if($('<%=$this->getID()%>configuration').visible() && ($('<%=$this->RefreshStart->ClientID%>').value === 'true' || status_prev === true)) {
+ status_prev = ($('<%=$this->RefreshStart->ClientID%>').value === 'true');
+ var callback = <%=$this->RefreshStatus->ActiveControl->Javascript%>;
callback.dispatch();
+ } else {
+ status_prev = false;
}
}
- }
- </script>
- <div class="button">
- <com:BActiveButton ID="Status" Text="<%[ Job status ]%>" CausesValidation="false" OnClick="status" ClientSide.OnSuccess="ConfigurationWindow.getObj('JobWindow').progress(false);job_callback_func();" CssClass="bbutton" />
- <com:TActiveLabel ID="DeleteButton"><com:BActiveButton ID="Delete" Text="<%[ Delete job ]%>" CausesValidation="false" OnClick="delete" ClientSide.OnSuccess="ConfigurationWindow.getObj('JobWindow').progress(false);job_callback_func();" CssClass="bbutton" /> </com:TActiveLabel>
- <com:TActiveLabel ID="CancelButton"><com:BActiveButton ID="Cancel" Text="<%[ Cancel job ]%>" CausesValidation="false" OnClick="cancel" ClientSide.OnSuccess="ConfigurationWindow.getObj('JobWindow').progress(false);job_callback_func();" CssClass="bbutton" /> </com:TActiveLabel>
- <com:BActiveButton ID="Run" Text="<%[ Run job again ]%>" ValidationGroup="JobGroup" CausesValidation="true" OnClick="run_again" ClientSide.OnSuccess="ConfigurationWindow.getObj('JobWindow').progress(false);job_callback_func();oMonitor();"/>
- </div>
- <com:TCallback ID="RefreshStatus" OnCallback="status" ClientSide.OnComplete="job_callback_duration = new Date().getTime();" />
- <script type="text/javascript">
- var status_prev = false;
- var status_callback_func = function() {
- if($('<%=$this->getID()%>configuration').visible() && ($('<%=$this->RefreshStart->ClientID%>').value === 'true' || status_prev === true)) {
- status_prev = ($('<%=$this->RefreshStart->ClientID%>').value === 'true');
- var callback = <%=$this->RefreshStatus->ActiveControl->Javascript%>;
- callback.dispatch();
- } else {
- status_prev = false;
- }
- }
- </script>
- <com:TActiveHiddenField ID="RefreshStart" />
- <div class="text small"><%[ Console status ]%></div>
- <div class="field-full" style="min-height: 166px">
- <com:TActiveTextBox ID="Estimation" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 145px" ReadOnly="true" />
+ </script>
+ <com:TActiveHiddenField ID="RefreshStart" />
+ <div class="field-full" style="min-height: 166px;">
+ <com:TActiveTextBox ID="Estimation" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 475px" ReadOnly="true" />
+ </div>
</div>
- <com:TActivePanel ID="AccurateLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="Accurate" Text="<%[ Accurate: ]%>" /></div>
- <div class="field"><com:TActiveCheckBox ID="Accurate" AutoPostBack="false" /></div>
- </com:TActivePanel>
- <com:TActivePanel ID="EstimateLine" CssClass="button">
- <com:BActiveButton ID="Estimate" Text="<%[ Estimate job ]%>" OnClick="estimate" ClientSide.OnSuccess="ConfigurationWindow.getObj('JobWindow').progress(false);job_callback_func();" />
- </com:TActivePanel>
</com:TActivePanel>
</com:TContent>
<%@ MasterClass="Application.Portlets.ConfigurationPanel"%>
<com:TContent ID="ConfigurationWindowContent">
<com:TActivePanel DefaultButton="Run">
- <strong><%[ Job name: ]%> <com:TActiveLabel ID="JobName" /><com:TActiveLabel ID="JobID" Visible="false" /></strong>
- <hr />
- <com:TValidationSummary
- ID="ValidationSummary"
- CssClass="validation-error-summary"
- ValidationGroup="JobRunGroup"
- AutoUpdate="true"
- Display="Dynamic"
- HeaderText="<%[ There is not possible to run selected action because: ]%>" />
- <div class="line">
- <div class="text"><com:TLabel ForControl="Level" Text="<%[ Level: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Level" AutoPostBack="false" CssClass="textbox-auto">
- <prop:Attributes.onchange>
- var job_to_verify = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
- var verify_options = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
- var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
- var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
- var accurate = $('<%=$this->AccurateLine->ClientID%>');
- var estimate = $('<%=$this->EstimateLine->ClientID%>');
- var verify_current_opt = $('<%=$this->JobToVerifyOptions->ClientID%>').value;
- if(/^(<%=implode('|', $this->jobToVerify)%>)$/.test(this.value)) {
- accurate.hide();
- estimate.hide();
- verify_options.show();
- job_to_verify.show();
- if (verify_current_opt == 'jobid') {
+ <h4><%[ Job name: ]%> <com:TActiveLabel ID="JobName" /><com:TActiveLabel ID="JobID" Visible="false" /></h4>
+ <span class="text tab tab_active" rel="jobrun_actions_tab"><%[ Actions ]%></span>
+ <span class="text tab" rel="jobrun_console_tab"><%[ Console status ]%></span>
+ <hr class="tabs" />
+ <div id="jobrun_actions_tab">
+ <com:TValidationSummary
+ ID="ValidationSummary"
+ CssClass="validation-error-summary"
+ ValidationGroup="JobRunGroup"
+ AutoUpdate="true"
+ Display="Dynamic"
+ HeaderText="<%[ There is not possible to run selected action because: ]%>" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Level" Text="<%[ Level: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Level" AutoPostBack="false" CssClass="textbox-auto">
+ <prop:Attributes.onchange>
+ var job_to_verify = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
+ var verify_options = $('<%=$this->JobToVerifyOptionsLine->ClientID%>');
+ var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
+ var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
+ var accurate = $('<%=$this->AccurateLine->ClientID%>');
+ var estimate = $('<%=$this->EstimateLine->ClientID%>');
+ var verify_current_opt = $('<%=$this->JobToVerifyOptions->ClientID%>').value;
+ if(/^(<%=implode('|', $this->jobToVerify)%>)$/.test(this.value)) {
+ accurate.hide();
+ estimate.hide();
+ verify_options.show();
+ job_to_verify.show();
+ if (verify_current_opt == 'jobid') {
+ verify_by_job_name.hide();
+ verify_by_jobid.show();
+ } else if (verify_current_opt == 'jobname') {
+ verify_by_job_name.show();
+ verify_by_jobid.hide();
+ }
+ } else if (job_to_verify.visible()) {
+ job_to_verify.hide();
+ verify_options.hide();
verify_by_job_name.hide();
- verify_by_jobid.show();
- } else if (verify_current_opt == 'jobname') {
- verify_by_job_name.show();
verify_by_jobid.hide();
+ accurate.show();
+ estimate.show();
}
- } else if (job_to_verify.visible()) {
- job_to_verify.hide();
- verify_options.hide();
- verify_by_job_name.hide();
- verify_by_jobid.hide();
- accurate.show();
- estimate.show();
- }
- </prop:Attributes.onchange>
- </com:TActiveDropDownList>
- </div>
- </div>
- <com:TActivePanel ID="JobToVerifyOptionsLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="JobToVerifyOptions" Text="<%[ Verify option: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="JobToVerifyOptions" AutoPostBack="false" CssClass="textbox-auto">
- <prop:Attributes.onchange>
- var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
- var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
- if (this.value == 'jobname') {
- verify_by_jobid.hide();
- verify_by_job_name.show();
- } else if (this.value == 'jobid') {
- verify_by_job_name.hide();
- verify_by_jobid.show();
- } else {
- verify_by_job_name.hide();
- verify_by_jobid.hide();
- }
- </prop:Attributes.onchange>
- </com:TActiveDropDownList>
+ </prop:Attributes.onchange>
+ </com:TActiveDropDownList>
+ </div>
</div>
- </com:TActivePanel>
- <com:TActivePanel ID="JobToVerifyJobNameLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="JobToVerifyJobName" Text="<%[ Job to Verify: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="JobToVerifyJobName" AutoPostBack="false" CssClass="textbox-auto" />
+ <com:TActivePanel ID="JobToVerifyOptionsLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="JobToVerifyOptions" Text="<%[ Verify option: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="JobToVerifyOptions" AutoPostBack="false" CssClass="textbox-auto">
+ <prop:Attributes.onchange>
+ var verify_by_job_name = $('<%=$this->JobToVerifyJobNameLine->ClientID%>');
+ var verify_by_jobid = $('<%=$this->JobToVerifyJobIdLine->ClientID%>');
+ if (this.value == 'jobname') {
+ verify_by_jobid.hide();
+ verify_by_job_name.show();
+ } else if (this.value == 'jobid') {
+ verify_by_job_name.hide();
+ verify_by_jobid.show();
+ } else {
+ verify_by_job_name.hide();
+ verify_by_jobid.hide();
+ }
+ </prop:Attributes.onchange>
+ </com:TActiveDropDownList>
+ </div>
+ </com:TActivePanel>
+ <com:TActivePanel ID="JobToVerifyJobNameLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="JobToVerifyJobName" Text="<%[ Job to Verify: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="JobToVerifyJobName" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
+ </com:TActivePanel>
+ <com:TActivePanel ID="JobToVerifyJobIdLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="JobToVerifyJobId" Text="<%[ JobId to Verify: ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="JobToVerifyJobId" CssClass="textbox-auto" AutoPostBack="false" />
+ <com:TActiveCustomValidator ID="JobToVerifyJobIdValidator" ValidationGroup="JobRunGroup" ControlToValidate="JobToVerifyJobId" ErrorMessage="<%[ JobId to Verify value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="jobIdToVerifyValidator" />
+ </div>
+ </com:TActivePanel>
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Client" Text="<%[ Client: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Client" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </com:TActivePanel>
- <com:TActivePanel ID="JobToVerifyJobIdLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="JobToVerifyJobId" Text="<%[ JobId to Verify: ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="JobToVerifyJobId" CssClass="textbox-auto" AutoPostBack="false" />
- <com:TActiveCustomValidator ID="JobToVerifyJobIdValidator" ValidationGroup="JobRunGroup" ControlToValidate="JobToVerifyJobId" ErrorMessage="<%[ JobId to Verify value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="jobIdToVerifyValidator" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="FileSet" Text="<%[ FileSet: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="FileSet" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </com:TActivePanel>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Client" Text="<%[ Client: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Client" AutoPostBack="false" CssClass="textbox-auto" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Pool" Text="<%[ Pool: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Pool" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="FileSet" Text="<%[ FileSet: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="FileSet" AutoPostBack="false" CssClass="textbox-auto" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Storage" Text="<%[ Storage: ]%>" /></div>
+ <div class="field">
+ <com:TActiveDropDownList ID="Storage" AutoPostBack="false" CssClass="textbox-auto" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Pool" Text="<%[ Pool: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Pool" AutoPostBack="false" CssClass="textbox-auto" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Priority" Text="<%[ Priority: ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="Priority" CssClass="textbox-auto" AutoPostBack="false" />
+ <com:TActiveCustomValidator ID="PriorityValidator" ValidationGroup="JobRunGroup" ControlToValidate="Priority" ErrorMessage="<%[ Priority value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="priorityValidator" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Storage" Text="<%[ Storage: ]%>" /></div>
- <div class="field">
- <com:TActiveDropDownList ID="Storage" AutoPostBack="false" CssClass="textbox-auto" />
+ <com:TPanel ID="AccurateLine" CssClass="line">
+ <div class="text"><com:TLabel ForControl="Accurate" Text="<%[ Accurate: ]%>" /></div>
+ <div class="field"><com:TActiveCheckBox ID="Accurate" AutoPostBack="false" /></div>
+ </com:TPanel>
+ <com:TCallback ID="ReloadRunJobs" OnCallback="Page.JobRunWindow.prepareData" ClientSide.OnComplete="RunSlideWindow.getObj('JobRunWindow').setLoadRequest();" />
+ <script type="text/javascript">
+ var jobrun_callback_func = function() {
+ var mainForm = Prado.Validation.getForm();
+ var callback = <%=$this->ReloadRunJobs->ActiveControl->Javascript%>;
+ if (Prado.Validation.managers[mainForm].getValidatorsWithError('JobRunGroup').length == 0) {
+ callback.dispatch();
+ }
+ }
+ </script>
+ <div class="button">
+ <com:BActiveButton ID="Run" Text="<%[ Run job ]%>" ValidationGroup="JobRunGroup" CausesValidation="true" OnClick="run_job">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('JobRunWindow').progress(false);
+ jobrun_callback_func();
+ if (Prado.Validation.isValid(Prado.Validation.getForm(), 'JobRunGroup') === true) {
+ ConfigurationWindow.getObj('JobRunWindow').switchTab('jobrun_console_tab');
+ }
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ <com:TPanel ID="EstimateLine" CssClass="button_line">
+ <com:BActiveButton ID="Estimate" Text="<%[ Estimate job ]%>" OnClick="estimate">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('JobRunWindow').progress(false);
+ jobrun_callback_func();
+ oMonitor();
+ if (Prado.Validation.isValid(Prado.Validation.getForm(), 'JobRunGroup') === true) {
+ ConfigurationWindow.getObj('JobRunWindow').switchTab('jobrun_console_tab');
+ }
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ </com:TPanel>
</div>
</div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Priority" Text="<%[ Priority: ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="Priority" CssClass="textbox-auto" AutoPostBack="false" />
- <com:TActiveCustomValidator ID="PriorityValidator" ValidationGroup="JobRunGroup" ControlToValidate="Priority" ErrorMessage="<%[ Priority value must be integer greather than 0. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="priorityValidator" />
+ <div id="jobrun_console_tab" style="display: none">
+ <div class="field-full">
+ <com:TActiveTextBox ID="Estimation" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 475px;" ReadOnly="true" />
</div>
</div>
- <com:TCallback ID="ReloadRunJobs" OnCallback="Page.JobRunWindow.prepareData" ClientSide.OnComplete="RunSlideWindow.getObj('JobRunWindow').setLoadRequest();" />
- <script type="text/javascript">
- var jobrun_callback_func = function() {
- var mainForm = Prado.Validation.getForm();
- var callback = <%=$this->ReloadRunJobs->ActiveControl->Javascript%>;
- if (Prado.Validation.managers[mainForm].getValidatorsWithError('JobRunGroup').length == 0) {
- callback.dispatch();
- }
- }
- </script>
- <div class="button">
- <com:BActiveButton ID="Run" Text="<%[ Run job ]%>" ValidationGroup="JobRunGroup" CausesValidation="true" OnClick="run_job" ClientSide.OnSuccess="ConfigurationWindow.getObj('JobRunWindow').progress(false);jobrun_callback_func();"/>
- </div>
- <div class="text small"><%[ Console status ]%></div>
- <div class="field-full" style="min-height: 90px">
- <com:TActiveTextBox ID="Estimation" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 116px; font-size: 11px;" ReadOnly="true" />
- </div>
- <com:TPanel ID="AccurateLine" CssClass="line">
- <div class="text"><com:TLabel ForControl="Accurate" Text="<%[ Accurate: ]%>" /></div>
- <div class="field"><com:TActiveCheckBox ID="Accurate" AutoPostBack="false" /></div>
- </com:TPanel>
- <com:TPanel ID="EstimateLine" CssClass="button">
- <com:Application.Portlets.BActiveButton ID="Estimate" Text="<%[ Estimate job ]%>" OnClick="estimate" ClientSide.OnSuccess="ConfigurationWindow.getObj('JobRunWindow').progress(false);jobrun_callback_func();oMonitor();" />
- </com:TPanel>
</com:TActivePanel>
</com:TContent>
}
public function umount($sender, $param) {
- $isValid = $this->DriveValidator->IsValid === true && $this->SlotValidator->IsValid === true;
+ $isValid = $this->DriveValidator->IsValid === true;
if($isValid === false) {
return;
}
}
public function release($sender, $param) {
- $release = $this->Application->getModule('api')->get(array('storages', 'release', $this->StorageID->Text))->output;
+ $isValid = $this->DriveValidator->IsValid === true;
+ if($isValid === false) {
+ return;
+ }
+ $drive = ($this->AutoChanger->Visible === true) ? intval($this->Drive->Text) : 0;
+ $release = $this->Application->getModule('api')->get(array('storages', 'release', $this->StorageID->Text, $drive))->output;
$this->ShowStorage->Text = implode(PHP_EOL, $release);
}
<%@ MasterClass="Application.Portlets.ConfigurationPanel"%>
<com:TContent ID="ConfigurationWindowContent">
- <strong><%[ Storage name: ]%> <com:TActiveLabel ID="StorageName" /><com:TActiveLabel ID="StorageID" Visible="false" /></strong>
- <hr />
- <com:TValidationSummary
- ID="ValidationSummary"
- CssClass="validation-error-summary"
- ValidationGroup="AutoChangerGroup"
- AutoUpdate="true"
- Display="Dynamic"
- HeaderText="<%[ There is not possible to run selected action because: ]%>" />
- <div class="text small"><%[ Console status ]%></div>
- <div class="field-full">
- <com:TActiveTextBox ID="ShowStorage" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 190px" ReadOnly="true" />
- </div>
- <com:TActivePanel ID="AutoChanger" Visible="false" Style="margin-bottom: 10px">
- <div class="line">
- <div class="text"><com:TLabel ForControl="Drive" Text="<%[ Drive number: ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="Drive" AutoPostBack="false" Text="0" MaxLength="3" CssClass="textbox-short" />
- <com:TActiveCustomValidator ID="DriveValidator" ValidationGroup="AutoChangerGroup" ControlToValidate="Drive" ErrorMessage="<%[ Drive number must be integer. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="driveValidator" />
+ <h4><%[ Storage name: ]%> <com:TActiveLabel ID="StorageName" /><com:TActiveLabel ID="StorageID" Visible="false" /></h4>
+ <span class="text tab tab_active" rel="storage_actions_tab"><%[ Actions ]%></span>
+ <span class="text tab" rel="storage_console_tab"><%[ Console status ]%></span>
+ <hr class="tabs" />
+ <div id="storage_actions_tab">
+ <com:TValidationSummary
+ ID="ValidationSummary"
+ CssClass="validation-error-summary"
+ ValidationGroup="AutoChangerGroup"
+ AutoUpdate="true"
+ Display="Dynamic"
+ HeaderText="<%[ There is not possible to run selected action because: ]%>" />
+ <com:TActivePanel ID="AutoChanger" Visible="false" Style="margin-bottom: 10px">
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Drive" Text="<%[ Drive number: ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="Drive" AutoPostBack="false" Text="0" MaxLength="3" CssClass="textbox-short" />
+ <com:TActiveCustomValidator ID="DriveValidator" ValidationGroup="AutoChangerGroup" ControlToValidate="Drive" ErrorMessage="<%[ Drive number must be integer. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="driveValidator" />
+ </div>
</div>
- </div>
- <div class="line">
- <div class="text"><com:TLabel ForControl="Slot" Text="<%[ Slot number: ]%>" /></div>
- <div class="field">
- <com:TActiveTextBox ID="Slot" AutoPostBack="false" Text="0" MaxLength="3" CssClass="textbox-short" />
- <com:TActiveCustomValidator ID="SlotValidator" ValidationGroup="AutoChangerGroup" ControlToValidate="Slot" ErrorMessage="<%[ Slot number must be integer. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="slotValidator" />
+ <div class="line">
+ <div class="text"><com:TLabel ForControl="Slot" Text="<%[ Slot number: ]%>" /></div>
+ <div class="field">
+ <com:TActiveTextBox ID="Slot" AutoPostBack="false" Text="0" MaxLength="3" CssClass="textbox-short" />
+ <com:TActiveCustomValidator ID="SlotValidator" ValidationGroup="AutoChangerGroup" ControlToValidate="Slot" ErrorMessage="<%[ Slot number must be integer. ]%>" ControlCssClass="validation-error" Display="None" OnServerValidate="slotValidator" />
+ </div>
</div>
+ </com:TActivePanel>
+ <div class="button-center">
+ <com:BActiveButton ID="Mount" OnClick="mount" ValidationGroup="AutoChangerGroup" CausesValidation="true" Text="<%[ Mount ]%>">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('StorageWindow').progress(false);
+ if (Prado.Validation.isValid(Prado.Validation.getForm(), 'AutoChangerGroup') === true) {
+ ConfigurationWindow.getObj('StorageWindow').switchTab('storage_console_tab');
+ }
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ <com:BActiveButton ID="Release" OnClick="release" Text="<%[ Release ]%>" ValidationGroup="AutoChangerGroup" CausesValidation="true">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('StorageWindow').progress(false);
+ if (Prado.Validation.isValid(Prado.Validation.getForm(), 'AutoChangerGroup') === true) {
+ ConfigurationWindow.getObj('StorageWindow').switchTab('storage_console_tab');
+ }
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ <com:BActiveButton ID="Umount" OnClick="umount" ValidationGroup="AutoChangerGroup" CausesValidation="true" Text="<%[ Umount ]%>">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('StorageWindow').progress(false);
+ if (Prado.Validation.isValid(Prado.Validation.getForm(), 'AutoChangerGroup') === true) {
+ ConfigurationWindow.getObj('StorageWindow').switchTab('storage_console_tab');
+ }
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ <com:BActiveButton ID="Status" OnClick="status" Text="<%[ Status ]%>">
+ <prop:ClientSide.OnSuccess>
+ ConfigurationWindow.getObj('StorageWindow').progress(false);
+ ConfigurationWindow.getObj('StorageWindow').switchTab('storage_console_tab');
+ </prop:ClientSide.OnSuccess>
+ </com:BActiveButton>
+ </div>
+ </div>
+ <div id="storage_console_tab" style="display: none">
+ <div class="field-full">
+ <com:TActiveTextBox ID="ShowStorage" TextMode="MultiLine" CssClass="textbox-auto" Style="height: 475px" ReadOnly="true" />
</div>
- </com:TActivePanel>
- <div class="button-center">
- <com:BActiveButton ID="Mount" OnClick="mount" ValidationGroup="AutoChangerGroup" CausesValidation="true" Text="<%[ Mount ]%>" ClientSide.OnSuccess="ConfigurationWindow.getObj('StorageWindow').progress(false);" />
- <com:BActiveButton ID="Release" OnClick="release" Text="<%[ Release ]%>" ClientSide.OnSuccess="ConfigurationWindow.getObj('StorageWindow').progress(false);" />
- <com:BActiveButton ID="Umount" OnClick="umount" ValidationGroup="AutoChangerGroup" CausesValidation="true" Text="<%[ Umount ]%>" ClientSide.OnSuccess="ConfigurationWindow.getObj('StorageWindow').progress(false);" />
- <com:BActiveButton ID="Status" OnClick="status" Text="<%[ Status ]%>" ClientSide.OnSuccess="ConfigurationWindow.getObj('StorageWindow').progress(false);" />
</div>
</com:TContent>
cursor: pointer;
display: inline-block;
width: auto;
- margin: 0 8px;
+ margin: 5px 8px;
padding: 0 18px;
min-width: 65px;
border-radius: 4px;
padding-left: 12px;
}
-div.button {
+div.button, div.button_line {
text-align: right;
margin: 3px 2px 5px 0;
}
+div.button_line {
+ display: inline;
+}
+
div.button-center {
text-align: center;
margin: 5px 0;
border: 0;
}
+.description {
+ display: inline-block;
+ font-style: italic;
+ font-size: 12px;
+ padding: 4px 0;
+}
+
fieldset {
margin-bottom: 15px;
font-size: 14px;
border: none;
}
-div.small {
- font-size: 12px;
+h4 {
+ margin: 6px 0;
+}
+
+hr.tabs {
+ margin-top: 0;
+ background-color: black; /* Firefox and Opera */
+ border-color: black; /* Chrome and Safari */
+ color: black; /* IE 7+ */
+ clear: both;
+}
+
+span.tab, span.tab_active {
+ font-size: 13px;
+ font-weight: bold;
text-align: center;
width: 130px;
background-color: rgb(115, 143, 172);
border-left: 1px solid black;
border-right: 1px solid black;
border-top: 1px solid black;
- margin: 3px 0;
+ padding: 4px;
+ cursor: pointer;
+}
+
+span.tab_active {
+ background-color: rgb(163, 180, 197);
}
#graphs {