Changed purge_date to a QString so that it can be checked with the normal
RDCheckDateTime function. Also means the QString.isEmpty check is a straight
forward QDate.isValid and in that case we can use QDate.toString rather than
formatting via RDCheckDateTime (and incurring another QDate.isValid check).
Checking is probably not needed and even if it did find an invalid date it would
likely not return valid SQL e.g this is just one paraphrased example from the
code:
SELECT x FROM y WHERE EVENT_DATETIME<="NULL 00:00:00"
I've reverted back the two select changes for the daypart code and put a TODO
note there as a marker.
This doesn't use a dedicated setRow, instead it converts to QString and then
tries to insert the dates instead.
Amended setOrigin and setEffectiveDateTime to use RDCheckDateTime
With MySQL v5.7+ you have to specifically set either a valid date or NULL
otherwise you get SQL errors. In previous versions setting a date to "" implied
NULL, this is no longer the case which causes nice SQL errors all over the
place.
This new RDCheckDateTime is an overloaded function that calls the respective
isValid method of QDate/Time/DateTime and either returns the requested formatted
string or returns NULL as a string.
This can then be used as part of an INSERT/UPDATE without breaking the stricter
NULL interpretation of MySQL v5.7+.
* Modified the Edit Log screen in 'rdlogedit/edit_log.cpp' to
display the link Start Time and Length for Traffic and Music links
in the 'EXT DATA' column.
* Removed display of the link Length for Traffic and Music links
from the LENGTH column in 'rdlogedit/edit_log.cpp'.
* Added 'RDAudioExport::cartNumber()', 'RDAudioExport::cutNumber()'
and 'RDAudioExport::settings()' meethods in 'lib/rdaudioexport.cpp'
and 'lib/rdaudioexport.h'.
* Added expanded error logging in 'utils/rdexport/rdexport.cpp'.
* Documented the '--allow-clobber' switch in
'docs/docbook/rdexport.xml'.
* Documented the '--continue-after-error' switch in
'docs/docbook/rdexport.xml'.
The original insert into user's method of creating rduser is not compatible with MySQL v5.7+.
This moves to a standard create user statement. Also moved to grant statements rather than
inserting directly into the db table to prevent possible changes to that causing issues in the
future.
Removes the INSTANCE column from RDAIRPLAY and RDPANEL tables. This was removed in schema 219 but persists if you create a db from scratch.
This makes rdairplay prompt for a password when exiting and seg faults rdpanel if not removed due to an attempt to insert a record into RDAIRPLAY/RDPANEL without setting a value for INSTANCE which is NOT NULL with no default.
* Removed the 'not null' attribute from the 'LOGS.LINK_DATETIME',
'LOGS.START_DATE' and 'LOGS.END_DATE' fields in the database
[GitHub issue #000121].
* Incremented the database version to 257.
* Added support for the RDCatchd 'DE' command in
'rdcatchd/rdcatchd.cpp', 'rdcatchd/rdcatchd.h',
'rdcatchd/event_player.cpp', 'rdcatchd/event_player.h' and
'rdcatchd/local_macros.cpp'.
* Added a deck event indicator to RDCatch's deck monitor in
'rdcatch/deckmon.cpp' and 'rdcatch/deckmon.h'.
* Added an entry for the Broadcast Tools SRC-16 in
'docs/SWITCHERS.txt'.
* Added a 'CUT_EVENTS' table to the database.
* Added a 'DECK_EVENTS' table to the database.
* Incremented the database version to 256.
* Implemented a 'Cut Event' ['CE'] RML.
* Added a 'Event Carts' section to the Edit Deck dialog in
'rdadmin/edit_deck.cpp' and 'rdadmin/edit_deck.h'.
* Added an entry for the Broadcast Tools SRC-16 in
'docs/SWITCHERS.txt'.
* Added a 'CUT_EVENTS' table to the database.
* Added a 'DECK_EVENTS' table to the database.
* Incremented the database version to 256.
* Implemented a 'Cut Event' ['CE'] RML.
* Added a 'Event Carts' section to the Edit Deck dialog in
'rdadmin/edit_deck.cpp' and 'rdadmin/edit_deck.h'.