Deleted show was being returned because we don't delete it from database if it's repeating, nor do we check
if it's modified when querying the db.
Fixed by checking modified_instance column; only return it if modified_instance != TRUE
I just realized this:
1. Enable "Enable Soundcloud Upload" in preference and fill in the username+password, click save
2. Go back to preference, change unrelated setting like "Station Name", click save
3. Now since soundcloud password field is empty (expected, as we don't want others to see how many digits
are there), the save failed
This commit is to fix this. Created another custom validator for the password field, which does the same
thing as ConditionalNotEmpty validator but allow password field to be empty when the username/email field
wasn't changed.
For a previous ticket, I changed the code so that both "Today's Program" widget
and "Now Playing" widget both use the liveInfoAction, but forgot that for "Now Playing" widget, it retrieves
the shows within next 48 hours instead of within end of day today...
Fixed by passing GET parameters to liveInfoAction, specify whether we want to retrieve shows within an
interval or end of day. Also added a GET parameter for specifying the number of shows to display.
Fixing bug introduced by last commit...Should test more thoroughly next time...
Fixed by creating and adding a custom validator that checks if the field is empty only when some other
fields have specific values, in this case, when 'UploadToSoundcloudOption' has a value of '1'.
- mktemp is used to generate temp name within /tmp dir
- it generate temp file when the file gets uploade to /tmp and then copy to
organize folder as original file name
It's not showing anything because I thought it's not suppose to display the currently playing show.
Fixed by retrieving the currently playing show along with next shows, and display them.
todayInfoAction is no longer needed since liveInfoAction does the same thing.
- Converting times to UTC timezone in ApiController before sending them to model functions
- Added utility functions in DateHelper.php
- GetShowsByDayOfWeek has been removed due to bugs caused by using local timezone
based variable like $day, which represents day of the week in local time, in db query,
which has times saved in UTC timezone. Converting stuff like day of the week from local
to UTC is messy. GetNextShows(...) can do the job so WeekInfoAction now uses it instead