2017-11-07 Fred Gleason <fredg@paravelsystems.com>

* Renamed the 'ORIGIN' column to 'INGEST' in the cut list widget
	in the 'Record' dialog in rdlibrary(1).
	* Added a 'SOURCE' column to the  cut list widget in the 'Record'
	dialog in rdlibrary(1).
This commit is contained in:
Fred Gleason 2017-11-07 11:44:21 -05:00
parent d9c03cb5dc
commit 94f0e1a9ea
11 changed files with 240 additions and 142 deletions

View File

@ -16320,3 +16320,8 @@
2017-11-07 Fred Gleason <fredg@paravelsystems.com>
* Added the ability to delete multiple logs simultaneously in
rdlogedit(1).
2017-11-07 Fred Gleason <fredg@paravelsystems.com>
* Renamed the 'ORIGIN' column to 'INGEST' in the cut list widget
in the 'Record' dialog in rdlibrary(1).
* Added a 'SOURCE' column to the cut list widget in the 'Record'
dialog in rdlibrary(1).

View File

@ -2,7 +2,7 @@
//
// The audio cart editor for RDLibrary.
//
// (C) Copyright 2002-2004,2016 Fred Gleason <fredg@paravelsystems.com>
// (C) Copyright 2002-2004,2016-2017 Fred Gleason <fredg@paravelsystems.com>
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License version 2 as
@ -153,30 +153,35 @@ AudioCart::AudioCart(AudioControls *controls,RDCart *cart,QString *path,
rdcart_cut_list->addColumn(tr("# OF PLAYS"));
rdcart_cut_list->setColumnAlignment(4,Qt::AlignHCenter);
rdcart_cut_list->addColumn(tr("ORIGIN"));
rdcart_cut_list->addColumn(tr("SOURCE"));
rdcart_cut_list->setColumnAlignment(5,Qt::AlignHCenter);
rdcart_cut_list->addColumn(tr("OUTCUE"));
rdcart_cut_list->setColumnAlignment(6,Qt::AlignLeft);
rdcart_cut_list->addColumn(tr("START DATE"));
rdcart_cut_list->addColumn(tr("INGEST"));
rdcart_cut_list->setColumnAlignment(6,Qt::AlignHCenter);
rdcart_cut_list->addColumn(tr("OUTCUE"));
rdcart_cut_list->setColumnAlignment(7,Qt::AlignLeft);
rdcart_cut_list->addColumn(tr("END DATE"));
rdcart_cut_list->addColumn(tr("START DATE"));
rdcart_cut_list->setColumnAlignment(8,Qt::AlignLeft);
rdcart_cut_list->addColumn(tr("DAYPART START"));
rdcart_cut_list->addColumn(tr("END DATE"));
rdcart_cut_list->setColumnAlignment(9,Qt::AlignLeft);
rdcart_cut_list->addColumn(tr("DAYPART END"));
rdcart_cut_list->addColumn(tr("DAYPART START"));
rdcart_cut_list->setColumnAlignment(10,Qt::AlignLeft);
rdcart_cut_list->addColumn(tr("NAME"));
rdcart_cut_list->addColumn(tr("DAYPART END"));
rdcart_cut_list->setColumnAlignment(11,Qt::AlignLeft);
rdcart_cut_list->addColumn(tr("SHA1"));
rdcart_cut_list->addColumn(tr("NAME"));
rdcart_cut_list->setColumnAlignment(12,Qt::AlignLeft);
rdcart_cut_list->addColumn(tr("SHA1"));
rdcart_cut_list->setColumnAlignment(13,Qt::AlignLeft);
RefreshList();
//
@ -284,7 +289,7 @@ void AudioCart::changeCutScheduling(int sched)
RDListViewItem *item=(RDListViewItem *)rdcart_cut_list->firstChild();
while(item!=NULL) {
sql=QString("select PLAY_ORDER,WEIGHT from CUTS where ")+
"CUT_NAME=\""+item->text(11)+"\"";
"CUT_NAME=\""+item->text(12)+"\"";
q=new RDSqlQuery(sql);
if(q->first()) {
item->setText(0,QString().sprintf("%d",q->value(sched).toInt()));
@ -314,7 +319,7 @@ void AudioCart::addCutData()
}
rdcart_cut_list->clearSelection();
RDListViewItem *item=new RDListViewItem(rdcart_cut_list);
item->setText(11,next_name);
item->setText(12,next_name);
RefreshLine(item);
rdcart_cut_list->setSelected(item,true);
rdcart_cut_list->ensureItemVisible(item);
@ -383,7 +388,7 @@ void AudioCart::deleteCutData()
// Check Clipboard
//
if(cut_clipboard!=NULL) {
if(item->text(11)==cut_clipboard->cutName()) {
if(item->text(12)==cut_clipboard->cutName()) {
if(QMessageBox::question(this,tr("Empty Clipboard"),
tr("Deleting this cut will also empty the clipboard.\nDo you still want to proceed?"),QMessageBox::Yes,QMessageBox::No)==
QMessageBox::No) {
@ -447,7 +452,7 @@ void AudioCart::copyCutData()
if(cut_clipboard!=NULL) {
delete cut_clipboard;
}
cut_clipboard=new RDCut(item->text(11));
cut_clipboard=new RDCut(item->text(12));
paste_cut_button->setEnabled(rdcart_modification_allowed);
}
@ -462,7 +467,7 @@ void AudioCart::extEditorCutData()
}
QString cmd=rdstation_conf->editorPath();
cmd.replace("%f",RDCut::pathName(rdcart_cut_list->currentItem()->text(11)));
cmd.replace("%f",RDCut::pathName(rdcart_cut_list->currentItem()->text(12)));
// FIXME: other replace commands to match: lib/rdcart_dialog.cpp editorData()
// These substitions should be documented (maybe a text file),
// ex: %f = cart_cut filename
@ -492,7 +497,7 @@ void AudioCart::pasteCutData()
paste_cut_button->setDisabled(true);
return;
}
if(QFile::exists(RDCut::pathName(item->text(11)))) {
if(QFile::exists(RDCut::pathName(item->text(12)))) {
if(QMessageBox::warning(this,tr("Audio Exists"),
tr("This will overwrite the existing recording.\nDo you want to proceed?"),
QMessageBox::Yes,
@ -501,7 +506,7 @@ void AudioCart::pasteCutData()
}
}
cut_clipboard->connect(this,SLOT(copyProgressData(const QVariant &)));
cut_clipboard->copyTo(rdstation_conf,lib_user,item->text(11),lib_config);
cut_clipboard->copyTo(rdstation_conf,lib_user,item->text(12),lib_config);
cut_clipboard->disconnect(this,SLOT(copyProgressData(const QVariant &)));
rdcart_cart->updateLength(rdcart_controls->enforce_length_box->isChecked(),
QTime().msecsTo(rdcart_controls->
@ -520,7 +525,7 @@ void AudioCart::editCutData()
if((item=SelectedCuts(&cutnames))==NULL) {
return;
}
QString cutname=item->text(11);
QString cutname=item->text(12);
if(!RDAudioExists(cutname)) {
QMessageBox::information(this,"RDLibrary",
tr("No audio is present in the cut!"));
@ -549,7 +554,7 @@ void AudioCart::recordCutData()
if((item=SelectedCuts(&cutnames))==NULL) {
return;
}
QString cutname=item->text(11);
QString cutname=item->text(12);
RecordCut *cut=new RecordCut(rdcart_cart,cutname,rdcart_use_weighting,this);
cut->exec();
delete cut;
@ -578,7 +583,7 @@ void AudioCart::ripCutData()
if((item=SelectedCuts(&cutnames))==NULL) {
return;
}
cutname=item->text(11);
cutname=item->text(12);
RDCddbRecord *rec=new RDCddbRecord();
CdRipper *ripper=new CdRipper(cutname,rec,rdlibrary_conf,rdcart_profile_rip);
if((track=ripper->exec(&title,&artist,&album))>=0) {
@ -616,7 +621,7 @@ void AudioCart::importCutData()
if((item=SelectedCuts(&cutnames))==NULL) {
return;
}
cutname=item->text(11);
cutname=item->text(12);
RDSettings settings;
rdlibrary_conf->getSettings(&settings);
RDImportAudio *import=new RDImportAudio(cutname,rdcart_import_path,
@ -702,7 +707,7 @@ RDListViewItem *AudioCart::SelectedCuts(std::vector<QString> *cutnames)
RDListViewItem *item=(RDListViewItem *)rdcart_cut_list->firstChild();
while(item!=NULL) {
if(item->isSelected()) {
cutnames->push_back(item->text(11));
cutnames->push_back(item->text(12));
ret=item;
}
item=(RDListViewItem *)item->nextSibling();
@ -741,7 +746,7 @@ void AudioCart::RefreshList()
}
}
else {
switch(ValidateCut(q,10,RDCart::NeverValid,current_datetime)) {
switch(ValidateCut(q,12,RDCart::NeverValid,current_datetime)) {
case RDCart::NeverValid:
l->setBackgroundColor(RD_CART_ERROR_COLOR);
if(pass==0) {
@ -750,8 +755,8 @@ void AudioCart::RefreshList()
break;
case RDCart::ConditionallyValid:
if((!q->value(11).isNull())&&
(q->value(11).toDateTime()<current_datetime)) {
if((!q->value(13).isNull())&&
(q->value(13).toDateTime()<current_datetime)) {
l->setBackgroundColor(RD_CART_ERROR_COLOR);
}
else {
@ -787,37 +792,47 @@ void AudioCart::RefreshList()
l->setText(3,tr("Never"));
}
l->setText(4,q->value(5).toString());
if(!q->value(6).toDateTime().isNull()) {
l->setText(5,q->value(7).toString()+" - "+
q->value(6).toDateTime().toString("M/d/yy hh:mm:ss"));
QString user=q->value(8).toString()+"@";
if(q->value(8).toString().isEmpty()) {
user="";
}
l->setText(6,q->value(8).toString());
if(!q->value(12).toDateTime().isNull()) {
l->setText(7,q->value(12).toDateTime().toString("M/d/yyyy hh:mm:ss"));
if(q->value(9).toString().isEmpty()) {
l->setText(5,"["+tr("unknown")+"]");
}
else {
l->setText(7,tr("None"));
l->setText(5,user+q->value(9).toString());
}
if(!q->value(13).toDateTime().isNull()) {
l->setText(8,q->value(13).toDateTime().toString("M/d/yyyy hh:mm:ss"));
if(!q->value(6).toDateTime().isNull()) {
l->setText(6,q->value(7).toString()+" - "+
q->value(6).toDateTime().toString("M/d/yy hh:mm:ss"));
}
l->setText(7,q->value(10).toString());
if(!q->value(14).toDateTime().isNull()) {
l->setText(8,q->value(14).toDateTime().toString("M/d/yyyy hh:mm:ss"));
}
else {
l->setText(8,tr("None"));
}
if(!q->value(15).isNull()) {
l->setText(9,q->value(14).toTime().toString("hh:mm:ss"));
l->setText(10,q->value(15).toTime().toString("hh:mm:ss"));
if(!q->value(15).toDateTime().isNull()) {
l->setText(9,q->value(15).toDateTime().toString("M/d/yyyy hh:mm:ss"));
}
else {
l->setText(9,tr("None"));
l->setText(10,tr("None"));
}
l->setText(11,q->value(9).toString());
if(q->value(23).toString().isEmpty()) {
l->setText(12,"["+tr("not available")+"]");
if(!q->value(17).isNull()) {
l->setText(10,q->value(16).toTime().toString("hh:mm:ss"));
l->setText(11,q->value(17).toTime().toString("hh:mm:ss"));
}
else {
l->setText(12,q->value(23).toString());
l->setText(10,tr("None"));
l->setText(11,tr("None"));
}
l->setText(12,q->value(11).toString());
if(q->value(25).toString().isEmpty()) {
l->setText(13,"["+tr("not available")+"]");
}
else {
l->setText(13,q->value(25).toString());
}
total_length+=q->value(3).toUInt();
pass++;
@ -843,7 +858,7 @@ void AudioCart::RefreshLine(RDListViewItem *item)
unsigned total_length=0;
QDateTime current_datetime=
QDateTime(QDate::currentDate(),QTime::currentTime());
QString cut_name=item->text(11);
QString cut_name=item->text(12);
sql=ValidateCutFields()+
QString().sprintf(" where (CART_NUMBER=%u)&&",rdcart_cart->number())+
"(CUT_NAME=\""+RDEscapeString(cut_name)+"\")";
@ -856,14 +871,14 @@ void AudioCart::RefreshLine(RDListViewItem *item)
item->setBackgroundColor(RD_CART_ERROR_COLOR);
}
else {
switch(ValidateCut(q,10,RDCart::NeverValid,current_datetime)) {
switch(ValidateCut(q,12,RDCart::NeverValid,current_datetime)) {
case RDCart::NeverValid:
item->setBackgroundColor(RD_CART_ERROR_COLOR);
break;
case RDCart::ConditionallyValid:
if((!q->value(12).isNull())&&
(q->value(12).toDateTime()<current_datetime)) {
if((!q->value(14).isNull())&&
(q->value(14).toDateTime()<current_datetime)) {
item->setBackgroundColor(RD_CART_ERROR_COLOR);
}
else {
@ -892,36 +907,46 @@ void AudioCart::RefreshLine(RDListViewItem *item)
}
item->setText(4,q->value(5).toString());
if(!q->value(6).toDateTime().isNull()) {
item->setText(5,q->value(7).toString()+" - "+
item->setText(6,q->value(7).toString()+" - "+
q->value(6).toDateTime().toString("M/d/yy hh:mm:ss"));
}
item->setText(6,q->value(8).toString());
if(!q->value(12).toDateTime().isNull()) {
item->setText(7,q->value(12).toDateTime().toString("M/d/yyyy hh:mm:ss"));
QString user=q->value(8).toString()+"@";
if(q->value(8).toString().isEmpty()) {
user="";
}
if(q->value(9).toString().isEmpty()) {
item->setText(5,"["+tr("unknown")+"]");
}
else {
item->setText(7,tr("None"));
item->setText(5,user+q->value(9).toString());
}
if(!q->value(13).toDateTime().isNull()) {
item->setText(8,q->value(13).toDateTime().toString("M/d/yyyy hh:mm:ss"));
item->setText(7,q->value(10).toString());
if(!q->value(14).toDateTime().isNull()) {
item->setText(8,q->value(14).toDateTime().toString("M/d/yyyy hh:mm:ss"));
}
else {
item->setText(8,tr("None"));
}
if(!q->value(15).isNull()) {
item->setText(9,q->value(14).toTime().toString("hh:mm:ss"));
item->setText(10,q->value(15).toTime().toString("hh:mm:ss"));
if(!q->value(15).toDateTime().isNull()) {
item->setText(9,q->value(15).toDateTime().toString("M/d/yyyy hh:mm:ss"));
}
else {
item->setText(9,tr("None"));
item->setText(10,tr("None"));
}
item->setText(11,q->value(9).toString());
if(q->value(23).toString().isEmpty()) {
item->setText(12,"["+tr("not available")+"]");
if(!q->value(17).isNull()) {
item->setText(10,q->value(16).toTime().toString("hh:mm:ss"));
item->setText(11,q->value(17).toTime().toString("hh:mm:ss"));
}
else {
item->setText(12,q->value(23).toString());
item->setText(10,tr("None"));
item->setText(11,tr("None"));
}
item->setText(12,q->value(11).toString());
if(q->value(25).toString().isEmpty()) {
item->setText(13,"["+tr("not available")+"]");
}
else {
item->setText(13,q->value(25).toString());
}
total_length+=q->value(3).toUInt();
}

View File

@ -1011,60 +1011,46 @@ void MainWidget::RefreshList()
if(type_filter.isEmpty()) {
return;
}
//
// 00 - CART.NUMBER
// 01 - CART.FORCED_LENGTH
// 02 - CART.TITLE
// 03 - CART.ARTIST
// 04 - CART.ALBUM
// 05 - CART.LABEL
// 06 - CART.CLIENT
// 07 - CART.AGENCY
// 08 - CART.USER_DEFINED
// 09 - CART.COMPOSER
// 10 - CART.PUBLISHER
// 11 - CART.CONDUCTOR
// 12 - CART.GROUP_NAME
// 13 - CART.START_DATETIME
// 14 - CART.END_DATETIME
// 15 - CART.TYPE
// 16 - CART.CUT_QUANTITY
// 17 - CART.LAST_CUT_PLAYED
// 18 - CART.ENFORCE_LENGTH
// 19 - CART.PRESERVE_PITCH
// 20 - CART.LENGTH_DEVIATION
// 21 - CART.OWNER
// 22 - CART.VALIDITY
// 23 - GROUPS.COLOR
// 24 - CUTS.LENGTH
// 25 - CUTS.EVERGREEN
// 26 - CUTS.START_DATETIME
// 27 - CUTS.END_DATETIME
// 28 - CUTS.START_DAYPART
// 29 - CUTS.END_DAYPART
// 30 - CUTS.MON
// 31 - CUTS.TUE
// 32 - CUTS.WED
// 33 - CUTS.THU
// 34 - CUTS.FRI
// 35 - CUTS.SAT
// 36 - CUTS.SUN
//
sql="select CART.NUMBER,CART.FORCED_LENGTH,CART.TITLE,CART.ARTIST,\
CART.ALBUM,CART.LABEL,\
CART.CLIENT,CART.AGENCY,CART.USER_DEFINED,\
CART.COMPOSER,CART.PUBLISHER,CART.CONDUCTOR,\
CART.GROUP_NAME,CART.START_DATETIME,CART.END_DATETIME,CART.TYPE,\
CART.CUT_QUANTITY,CART.LAST_CUT_PLAYED,\
CART.ENFORCE_LENGTH,CART.PRESERVE_PITCH,\
CART.LENGTH_DEVIATION,CART.OWNER,CART.VALIDITY,GROUPS.COLOR, \
CUTS.LENGTH,CUTS.EVERGREEN,CUTS.START_DATETIME,CUTS.END_DATETIME,\
CUTS.START_DAYPART,CUTS.END_DAYPART,CUTS.MON,CUTS.TUE,\
CUTS.WED,CUTS.THU,CUTS.FRI,CUTS.SAT,CUTS.SUN from CART \
left join GROUPS on CART.GROUP_NAME=GROUPS.NAME \
left join CUTS on CART.NUMBER=CUTS.CART_NUMBER";
sql=QString("select ")+
"CART.NUMBER,"+ // 00
"CART.FORCED_LENGTH,"+ // 01
"CART.TITLE,"+ // 02
"CART.ARTIST,"+ // 03
"CART.ALBUM,"+ // 04
"CART.LABEL,"+ // 05
"CART.CLIENT,"+ // 06
"CART.AGENCY,"+ // 07
"CART.USER_DEFINED,"+ // 08
"CART.COMPOSER,"+ // 09
"CART.PUBLISHER,"+ // 10
"CART.CONDUCTOR,"+ // 11
"CART.GROUP_NAME,"+ // 12
"CART.START_DATETIME,"+ // 13
"CART.END_DATETIME,"+ // 14
"CART.TYPE,"+ // 15
"CART.CUT_QUANTITY,"+ // 16
"CART.LAST_CUT_PLAYED,"+ // 17
"CART.ENFORCE_LENGTH,"+ // 18
"CART.PRESERVE_PITCH,"+ // 19
"CART.LENGTH_DEVIATION,"+ // 20
"CART.OWNER,"+ // 21
"CART.VALIDITY,"+ // 22
"GROUPS.COLOR,"+ // 23
"CUTS.LENGTH,"+ // 24 offsets begin here
"CUTS.EVERGREEN,"+ // 25
"CUTS.START_DATETIME,"+ // 26
"CUTS.END_DATETIME,"+ // 27
"CUTS.START_DAYPART,"+ // 28
"CUTS.END_DAYPART,"+ // 29
"CUTS.MON,"+ // 30
"CUTS.TUE,"+ // 31
"CUTS.WED,"+ // 32
"CUTS.THU,"+ // 33
"CUTS.FRI,"+ // 34
"CUTS.SAT,"+ // 35
"CUTS.SUN "+ // 36
"from CART left join GROUPS on CART.GROUP_NAME=GROUPS.NAME "+
"left join CUTS on CART.NUMBER=CUTS.CART_NUMBER";
QString schedcode="";
if(lib_codes_box->currentText()!=tr("ALL")) {
schedcode=lib_codes_box->currentText();

View File

@ -43,7 +43,7 @@
</message>
<message>
<source>ORIGIN</source>
<translation>PŮVOD</translation>
<translation type="obsolete">PŮVOD</translation>
</message>
<message>
<source>OUTCUE</source>
@ -232,6 +232,18 @@ Do you still want to delete?</source>
<source>not available</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>INGEST</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SOURCE</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>CdRipper</name>

View File

@ -43,7 +43,7 @@
</message>
<message>
<source>ORIGIN</source>
<translation>HERKUNFT</translation>
<translation type="obsolete">HERKUNFT</translation>
</message>
<message>
<source>OUTCUE</source>
@ -232,6 +232,18 @@ Do you still want to delete?</source>
<source>not available</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>INGEST</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SOURCE</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>CdRipper</name>

View File

@ -43,7 +43,7 @@
</message>
<message>
<source>ORIGIN</source>
<translation>ORIGEN</translation>
<translation type="obsolete">ORIGEN</translation>
</message>
<message>
<source>OUTCUE</source>
@ -232,6 +232,18 @@ Do you still want to delete?</source>
<source>not available</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>INGEST</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SOURCE</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>CdRipper</name>

View File

@ -41,10 +41,6 @@
<source># OF PLAYS</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>ORIGIN</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>OUTCUE</source>
<translation type="unfinished"></translation>
@ -210,6 +206,18 @@ Do you still want to delete?</source>
<source>not available</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>INGEST</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SOURCE</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>CdRipper</name>

View File

@ -43,7 +43,7 @@
</message>
<message>
<source>ORIGIN</source>
<translation>OPPHAV</translation>
<translation type="obsolete">OPPHAV</translation>
</message>
<message>
<source>OUTCUE</source>
@ -227,6 +227,18 @@ Do you still want to delete?</source>
<source>not available</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>INGEST</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SOURCE</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>CdRipper</name>

View File

@ -43,7 +43,7 @@
</message>
<message>
<source>ORIGIN</source>
<translation>OPPHAV</translation>
<translation type="obsolete">OPPHAV</translation>
</message>
<message>
<source>OUTCUE</source>
@ -227,6 +227,18 @@ Do you still want to delete?</source>
<source>not available</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>INGEST</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SOURCE</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>CdRipper</name>

View File

@ -43,7 +43,7 @@
</message>
<message>
<source>ORIGIN</source>
<translation>ORIGEM</translation>
<translation type="obsolete">ORIGEM</translation>
</message>
<message>
<source>OUTCUE</source>
@ -228,6 +228,18 @@ Do you still want to delete?</source>
<source>not available</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>INGEST</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>SOURCE</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>CdRipper</name>

View File

@ -34,22 +34,24 @@ QString ValidateCutFields()
"PLAY_COUNTER,"+ // 05
"ORIGIN_DATETIME,"+ // 06
"ORIGIN_NAME,"+ // 07
"OUTCUE,"+ // 08
"CUT_NAME,"+ // 09
"LENGTH,"+ // 10
"EVERGREEN,"+ // 11
"START_DATETIME,"+ // 12
"END_DATETIME,"+ // 13
"START_DAYPART,"+ // 14
"END_DAYPART,"+ // 15
"MON,"+ // 16
"TUE,"+ // 17
"WED,"+ // 18
"THU,"+ // 19
"FRI,"+ // 20
"SAT,"+ // 21
"SUN,"+ // 22
"SHA1_HASH "+ // 23
"ORIGIN_LOGIN_NAME,"+ // 08
"SOURCE_HOSTNAME,"+ // 09
"OUTCUE,"+ // 10
"CUT_NAME,"+ // 11
"LENGTH,"+ // 12 offsets begin here
"EVERGREEN,"+ // 13
"START_DATETIME,"+ // 14
"END_DATETIME,"+ // 15
"START_DAYPART,"+ // 16
"END_DAYPART,"+ // 17
"MON,"+ // 18
"TUE,"+ // 19
"WED,"+ // 20
"THU,"+ // 21
"FRI,"+ // 22
"SAT,"+ // 23
"SUN,"+ // 24
"SHA1_HASH "+ // 25
"from CUTS";
return sql;
@ -66,7 +68,7 @@ RDCart::Validity ValidateCut(RDSqlQuery *q,unsigned offset,
if(q->value(offset).toInt()==0) { // Length
return prev_validity;
}
if(q->value(offset+1).toString()=="Y") { // Evergreen
if(q->value(offset+1+2).toString()=="Y") { // Evergreen
return RDCart::EvergreenValid;
}
if(q->value(offset+5+datetime.date().dayOfWeek()).toString()!="Y") {