diff --git a/airtime_mvc/public/js/airtime/playlist/smart_blockbuilder.js b/airtime_mvc/public/js/airtime/playlist/smart_blockbuilder.js index 047882080..780a7b12d 100644 --- a/airtime_mvc/public/js/airtime/playlist/smart_blockbuilder.js +++ b/airtime_mvc/public/js/airtime/playlist/smart_blockbuilder.js @@ -90,18 +90,26 @@ function setSmartBlockEvents() { var item_to_hide; var prev; var index; - //remove error message from current row, if any var error_element = curr.find('span[class="errors sp-errors"]'); if (error_element.is(':visible')) { error_element.remove(); } + /* In the case that there is only one element we need to remove the + * date_select drop down. + */ + + if (count == 0) { + disableAndHideDateTimeDropdown(curr.find(':first-child'), index); + } + /* assign next row to current row for all rows below and including * the row getting removed */ + + for (var i=0; i