The Monitor model is now smart enough to change the stream's scale.
It also has the option of not scaling at all (in the case of the
single monitor view).
No longer need LiveStreamHelper, and the logic of which image to
display (live or placeholder) has been moved to the Moniors model.
This way should be much easier to understand and support. This also
fixes my 'ugly hack' in commit eed6c81287
If there is an upgrade available, the label-info (blue) class is
applied.
If there is not an upgrade avaiable, the label-success (green)
class is applied.
In the interest of releasing something, I am not going to use ajax here
for now. Goal is to have this view behave similar to the original Events
view in the original skin. Currently you can:
* Paginate events
* Filter events using the sidebar
Bug: Filter elements are unset when paginating.
The log functionality is similar to that of the classic skin, though
with fewer options. Initial filtering support is for only component type.
Also displays a fixed last 100 log events, sorted by TimeKey ascending.
Still a lot of work to do such as displaying the proper input
type based on option, however basic tabbing and saving works,
as does the on-hover tooltip (I think I put that in this commit).
The EventsController calls createListThumbnail() to build a list
of thumbnail data which is then passed to the view to be looped though.
Also had to change how I loop through $events so that I can match up the
indexes in $events with the indexes in $thumbData
First I tell extractNamedParams() which params I care about (ignore the rest),
then I loop through the returned results and build my query via named params.
Finally I pass the named params into the $conditions array for paginate to use.
Added a method that processes named parameters and ensures all mandatory ones
exist and substitutes missing optional ones with default values. This makes
named parameters strongly defined and easier to read.
Thanks to http://developinginthedark.com/posts/cakephp-tip-1-named-parameters
for the idea.
* Moved getStreamSrc from Monitors Controller to Monitors Model
* Minor indenting of code
* Removed some old code
* Changed how I lookup ZM_MPEG_LIVE_FORMAT from within getStreamSrc
* Changed Monitors View view to use divs instead of tables