399 Commits

Author SHA1 Message Date
Fred Gleason
f04fa15090 2016-06-17 Fred Gleason <fredg@paravelsystems.com>
* Modified rdexport(1) to list correct audio format parameters
	in the XML output.
2016-06-17 12:02:43 -04:00
Fred Gleason
605dfbb964 2016-06-17 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in 'lib/rdcut.cpp' that caused a SQL error when
	generating an XML 'cutList' object.
2016-06-17 10:39:30 -04:00
Fred Gleason
d48935a00a 2016-06-15 Fred Gleason <fredg@paravelsystems.com>
* Added an '--xml' switch to rdexport(1) in
	'utils/rdexport/rdexport.cpp' and 'utils/rdexport/rdexport.h'.
2016-06-15 13:01:03 -04:00
Fred Gleason
aa610a739c 2016-06-15 Fred Gleason <fredg@paravelsystems.com>
* Added '--bitrate=', '--channels=', '--format=', '--quality='
	and '--samplerate=' to rdexport(1) in 'utils/rdexport/rdexport.cpp'
	and 'utils/rdexport/rdexport.h'.
2016-06-15 11:47:26 -04:00
Fred Gleason
faaa5b4cdb 2016-06-14 Fred Gleason <fredg@paravelsystems.com>
* Merged fixes for NULL SQL date-time values from Wayne Merricks
	[GitHub pull request #000133].
2016-06-14 12:33:46 -04:00
Fred Gleason
b4b9b20448 Merge branch 'waynemerricks-stable' into stable 2016-06-14 12:31:34 -04:00
Fred Gleason
d90a226e70 Minor formatting tweaks 2016-06-14 12:31:02 -04:00
Fred Gleason
c21c1a0d5d Merge branch 'stable' of https://github.com/waynemerricks/rivendell into waynemerricks-stable 2016-06-14 11:25:43 -04:00
Fred Gleason
13f9111883 2016-06-11 Fred Gleason <fredg@paravelsystems.com>
* Updated 'NEWS'.
	* Incremented the package version to 2.14.1
v2.14.1
2016-06-11 10:15:24 -04:00
Fred Gleason
5b19b7a9a3 2016-06-10 Fred Gleason <fredg@paravelsystems.com>
* Incremented the package version to 2.14.0int00.
2016-06-10 18:45:02 -04:00
Fred Gleason
6fd3788af7 2016-06-10 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in 'utils/rdmaint/rdmaint.cpp' that failed to process
	SQL NULL date values correctly.
2016-06-10 17:52:59 -04:00
Fred Gleason
815dea346c 2016-06-10 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in 'lib/rdlist_logs.cpp' that failed to process
	SQL NULL date values correctly.
2016-06-10 17:38:15 -04:00
Fred Gleason
c19b241907 2016-06-10 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in 'rdairplay/list_logs.cpp' that failed to process
	SQL NULL date values correctly.
2016-06-10 17:14:22 -04:00
Fred Gleason
ff89b31f61 2016-06-10 Fred Gleason <fredg@paravelsystems.com>
* Updated 'NEWS'.
	* Incremented the package version to 2.14.0.
v2.14.0
2016-06-10 12:58:47 -04:00
Wayne Merricks
8baed5b104 Random Idiocy fixes
Compilation fixes due to idiocy as usual (apologies)
2016-06-09 22:46:07 +01:00
Wayne Merricks
f1175cd2f2 Fixes for invalid NULL sql on date/times
Most files are simple swaps to get rid of extra " as a NULL return will give
invalid SQL if used as follows UPDATE x SET y="NULL";

See github issue 121 for more info.

Extra changes have been made to the following files:
* lib/rdcartslot.cpp
- Added a QDateTime variable to prevent EVENT_DATETIME becoming
  "2016-06-09" "NULL" as it was checked separately for date and time
* lib/rdcut.cpp
- Reworked START_DATETIME and END_DATETIME to save the SQL ifs.  I believe this
  makes it easier to read and understand.
- The >QDate(1900,1,1) and < 8000 is probably not needed but I left it there
  just in case.
* lib/rdescape_string.cpp
- Reworked to add extra " if the date is not NULL see issue 121
* lib/rdfeed.cpp && lib/rdpodcast.cpp
- Had to add a SetRow for QDateTime as with the string conversion the existing
  SetRow would add an extra set of "
* lib/rdsound_panel.cpp && rdairplay/log_traffic.cpp
        && utils/rddgimport/rddgimport.cpp
- Added a QString to contain EVENT_DATETIME to prevent double checks of date
  and time separately (similar to lib/rdcartslot.cpp)
* rdcatchd/rdcatchd.cpp
- Reverted the changes.  The RML here is not touching the DB so is fine, plus
  with the RDCheckDateTime changes you'd have extra " unless it was NULL
* tests/sas_switch_torture.cpp && sas_torture.cpp
- Included missing rdescape_string.h
2016-06-09 00:01:38 +01:00
Fred Gleason
dd0eb7f636 2016-06-08 Fred Gleason <fredg@paravelsystems.com>
* Incremented the package version to 2.13.0int02.
2016-06-08 12:48:19 -04:00
Fred Gleason
ec1f6784cb 2016-06-08 Fred Gleason <fredg@paravelsystems.com>
* Translated the rdimport(1) manpage to DocBook-XML 5.
	* Translated the rdmarkerset(8) manpage to DocBook-XML 5.
2016-06-08 11:51:43 -04:00
Fred Gleason
b33f1ea3df 2016-06-07 Fred Gleason <fredg@paravelsystems.com>
* Incremented the package version to 2.13.0int01.
2016-06-07 14:38:11 -04:00
Fred Gleason
5342d41f8d 2016-06-07 Fred Gleason <fredg@paravelsystems.com>
* Made the 'Test Import' dialog resizeable in
	'rdadmin/test_import.cpp' and 'rdadmin/test_import.h'.
2016-06-07 13:49:25 -04:00
Fred Gleason
adba9b1718 2016-06-07 Fred Gleason <fredg@paravelsystems.com>
* Refactored 'rdlogmanager/generate_log.cpp' and
	'rdlogmanager/generate_log.h' to use 'QWidget::resizeEvent()'.
2016-06-07 13:22:36 -04:00
Fred Gleason
31cd72a7a4 2016-06-07 Fred Gleason <fredg@paravelsystems.com>
* Refactored the 'RDSvc::import()' method in 'lib/rdsvc.cpp' to
	improve robustness and readability.
2016-06-07 12:56:52 -04:00
Fred Gleason
6a05fd90a5 2016-06-07 Fred Gleason <fredg@paravelsystems.com>
* Added code in 'lib/rdevent_line.cpp' and 'lib/rdsvc.cpp' to allow
	embedded traffic breaks to be specified with start time and length
	in the music schedule.
2016-06-07 08:36:59 -04:00
Wayne Merricks
9f52968a02 utils/rdimport/rdimport.cpp MySQL v5.7+ date/time changes 2016-06-04 23:50:26 +01:00
Wayne Merricks
575856c47f utsil/rddgimport/rddgimport.cpp MySQL v5.7+ date/time changes 2016-06-04 23:49:56 +01:00
Wayne Merricks
9dbcfd54b7 tests/sas_torture.cpp MySQL v5.7+ date/time changes 2016-06-04 23:49:26 +01:00
Wayne Merricks
45c33dc578 tests/sas_switch_torture.cpp MySQL v5.7+ date/time changes 2016-06-04 23:49:01 +01:00
Wayne Merricks
370fb3c0b2 rdcatchd/rdcatchd.cpp MySQL v5.7+ date/time changes
Not sure if the wild card resolver is strictly unsafe but added a check anyway.
2016-06-04 23:48:06 +01:00
Wayne Merricks
65be7b3f5f importers/rivendell_filter.cpp MySQL v5.7+ date/time changes
Unsure if the times can be invalid but old MySQL values can have 0000-00-00 as
dates but the 5.7+ can't.  There is a null check for this but I'm not 100% sure
whether 0000-00-00 passes the isNull.  Put in a date check for both just in
case.
2016-06-04 23:45:17 +01:00
Wayne Merricks
9eb97c5b27 rdairplay/log_traffic.cpp MySQL v5.7+ date/time changes 2016-06-04 23:22:05 +01:00
Wayne Merricks
1bfd555d00 web/rdcastmanager/rdcastmanager.cpp MySQL v5.7+ date/time changes 2016-06-04 23:21:32 +01:00
Wayne Merricks
b9452b8e8d lib/rdcart.cpp MySQL v5.7+ date/time changes 2016-06-04 20:27:14 +01:00
Wayne Merricks
58d75f0b5c lib/rdcut.cpp MySQL v5.7+ date/time changes 2016-06-04 20:20:55 +01:00
Wayne Merricks
5a07b62d0c lib/rdrecording.cpp MySQL v5.7+ date/time changes
Amended SetRow(QString,QTime) to contain time checks for MySQL v5.7+
2016-06-04 20:04:52 +01:00
Wayne Merricks
7506d1567c lib/rdlog_event.cpp MySQL v5.7+ date/time checks
Usual date changes and some TODOs for potentially invalid SELECT statements
2016-06-04 20:04:16 +01:00
Wayne Merricks
69ea83d570 lib/rdsound_panel.cpp MySQL v5.7+ Date Changes
Usual checks.  Line 1493 and 1537 is not required as they are derived from
current system datetime as per lines 1466 and 1526 respectively.
2016-06-04 20:04:09 +01:00
Wayne Merricks
1e37f6bbdc lib/rdcartslot.cpp Added MySQL v5.7+ changes
Added usual checks.  Line 690 EVENT_DATETIME is not required as this is derived
from current system datetime as per line 665.
2016-06-04 20:03:57 +01:00
Wayne Merricks
4523e8e90f lib/rdsvc.cpp Added null checks to purge_date as per MySQL v5.7+ changes
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).
2016-06-04 20:03:39 +01:00
Wayne Merricks
e1c9caa987 lib/rdreport.cpp Reverted date checks on SELECT statements
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.
2016-06-04 20:03:24 +01:00
Wayne Merricks
1cf11af447 lib/rdfeed.cpp MySQL v5.7+ date/time null changes
Fixed in setX rather than Row as these are converted to QString before the DB
2016-06-04 20:03:10 +01:00
Wayne Merricks
e98a915f90 lib/rdlog.cpp MySQL v5.7+ date/time null changes
Fixed in SetRow for QDate/QTime and QDateTime
2016-06-04 20:03:03 +01:00
Wayne Merricks
c2560a671b lib/rdevent_line.cpp MySQL v5.7+ date/time null changes
Time is based on event_start_time however can't guarantee validity hence
RDCheckDateTime again.
2016-06-04 20:02:47 +01:00
Wayne Merricks
ace1a01225 lib/rdpodcast.cpp MySQL v5.7+ changes for date nulls
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
2016-06-04 20:02:25 +01:00
Wayne Merricks
e2eb07c615 Added date/time checks for MySQL v5.7+ date/time nulls
Shouldn't be necessary in the daypart SQL but can't verify validity so added
checks there too.
2016-06-03 23:50:29 +01:00
Wayne Merricks
d222ed9ca0 Added QDate/Time variant is valid checks for SQL use
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+.
2016-06-03 23:45:31 +01:00
Fred Gleason
04b4db9157 2016-06-01 Fred Gleason <fredg@paravelsystems.com>
* Changed the default value of the 'CART_NUMBER' field in '_LOG'
	tables from NULL to 0.
	* Incremented the database version to 258.
2016-06-01 12:06:36 -04:00
Fred Gleason
ebb2d90045 2016-06-01 Fred Gleason <fredg@paravelsystems.com>
* 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'.
2016-06-01 11:27:26 -04:00
Fred Gleason
da0ad47ffb 2016-05-26 Fred Gleason <fredg@paravelsystems.com>
* 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'.
2016-05-26 08:25:49 -04:00
Fred Gleason
f2d831f86c 2016-05-26 Fred Gleason <fredg@paravelsystems.com>
* Documented the '--escape-string' switch in
	'docs/docbook/rdexport.xml'.
2016-05-26 08:08:00 -04:00
Fred Gleason
81a60f85d6 2016-05-26 Fred Gleason <fredg@paravelsystems.com>
* Documented the '--allow-clobber' switch in
	'docs/docbook/rdexport.xml'.
	* Documented the '--continue-after-error' switch in
	'docs/docbook/rdexport.xml'.
2016-05-26 07:18:12 -04:00