CC-3722: Create loading indicator for AJAX call when calculating Show length
- done
This commit is contained in:
parent
cf4101cdcd
commit
c9df8e8b15
|
@ -46,6 +46,7 @@
|
|||
</dt>
|
||||
<dd id="add_show_duration-element">
|
||||
<?php echo $this->element->getElement('add_show_duration') ?>
|
||||
<img id="icon-loader-small" src="/css/images/loader-small.gif" style="vertical-align:middle; display:none;"/>
|
||||
</dd>
|
||||
<?php if($this->element->getElement('add_show_duration')->hasErrors()){ ?>
|
||||
<ul class='errors'>
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 673 B |
|
@ -460,9 +460,12 @@ function setAddShowEvents() {
|
|||
})
|
||||
|
||||
function calculateDuration(endDateTime, startDateTime){
|
||||
var duration;
|
||||
var loadingIcon = $('#icon-loader-small');
|
||||
|
||||
loadingIcon.show();
|
||||
$.post("/Schedule/calculate-duration", {startTime: startDateTime, endTime: endDateTime}, function(data){
|
||||
$('#add_show_duration').val(JSON.parse(data));
|
||||
loadingIcon.hide();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue