mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2026-01-11 15:16:07 +01:00
2020-08-28 Fred Gleason <fredg@paravelsystems.com>
* Added sanity checks for Air and Expiration datetimes to the 'Editing Item' dialog in rdcastmanager(1). Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
@@ -334,6 +334,23 @@ void EditCast::okData()
|
||||
{
|
||||
QString err_msg;
|
||||
|
||||
//
|
||||
// Sanity Checks
|
||||
//
|
||||
if(cast_item_expiration_box->currentItem()) {
|
||||
if(cast_item_effective_edit->dateTime()>
|
||||
cast_item_expiration_edit->dateTime()) {
|
||||
QMessageBox::warning(this,"RDCastManager - "+tr("Error"),
|
||||
tr("Item expiration cannot be prior to Air Date/Time!"));
|
||||
return;
|
||||
}
|
||||
if(cast_item_expiration_edit->dateTime()<QDateTime::currentDateTime()) {
|
||||
QMessageBox::warning(this,"RDCastManager - "+tr("Error"),
|
||||
tr("Item expiration must be in the future!"));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
cast_cast->setItemTitle(cast_item_title_edit->text());
|
||||
cast_cast->setItemAuthor(cast_item_author_edit->text());
|
||||
cast_cast->setItemCategory(cast_item_category_edit->text());
|
||||
|
||||
Reference in New Issue
Block a user