<div ng:controller="ContentMainController" class="row-fluid" qn:fillheight>
    <div class="col10">
        <div class="toolbar cfix">
            <div class="toolbar-group">
                <h3>
                    <span class="circle circle-small blue"><span class="icon li_tag"></span></span>
                    {{$resource('contents.contents')}}
                </h3>
            </div>
            <div class="toolbar-group">
                <button title="{{$resource('utility.reset')}}" class="button tooltip" ng:show="isSearch()" ng:click="reset()"><i class="icon-angle-left"></i></button>
                <button title="{{$resource('utility.search')}}" class="button tooltip" ng:click="filter()"><i class="icon-search"></i></button>
                <div class="form button-widget" qn:popover>
                    <form>
                        <div class="control-group">
                            <label>{{$resource('contents.title')}}</label>
                            <div class="controls">
                                <input class="input-xlarge" placeholder="i.e. Wordpress" ng:model="query.Title"/>
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label"></label>
                            <div class="controls">
                                <button class="button lightblue" ng:click="search()"><i class="icon-search"></i></button>
                            </div>
                        </div> 
                    </form>
                </div>
            </div>
            <div class="toolbar-group">
                <button title="{{$resource('utility.refresh')}}" class="button tooltip" ng:click="refresh()"><i class="icon-refresh"></i></button>
            </div>
            <div class="toolbar-group right">
                <span class="info">{{pager.from}}-{{pager.to}} of {{pager.total}}</span>
                <button class="button prev" ng:disabled="!pager.canPrev()" ng:click="pager.prev()"><i class="icon-chevron-left"></i></button>
                <button class="button next" ng:disabled="!pager.canNext()" ng:click="pager.next()"><i class="icon-chevron-right"></i></button>
            </div>
            <div class="toolbar-group">
                <button title="{{$resource('utility.new')}}" ng:click="new()" class="button lightblue tooltip"><i class="icon-plus"></i></button>
            </div>
        </div>
        <div class="table table-hover fillh">
            <table>
                <thead>
                    <tr>
                        <th class="icon"></th>
                        <th>{{$resource('contents.title')}}</th>
                        <th></th>
                    </tr>
                </thead>
                <tbody ng:Model="contents">
                    <tr ng:repeat="content in contents">
                        <td class="icon"><div class="circle"></div></td>
                        <td class="title" ng:click="edit(content)">
                            <div class="inner">
                                <h2>{{content.Title}}</h2>
                            </div>
                        </td>
                        <td class="command icon">
                            <a title="{{$resource('utility.options')}}" class="trigger tooltip"><i class="icon-reorder"></i></a>
                            <div qn:popover="{position: {my: 'right top', at: 'left top'}}">
                                <ul>
                                    <li ng:click="remove(content, $index)" value="Are you sure?"><a><i class="icon-trash"></i>{{$resource('contents.delete')}}</a></li>
                                </ul>
                            </div>
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>
    </div>
    <div class="col2 sidebar">
        <div class="toolbar toolbar-strip lightblue cfix">
            <div class="toolbar-group row-fluid">
                <button title="Basic" class="button lightblue col4" ng:class="{active:sidebarView == 'basic'}" ng:click="switchSidebar('contents')"><i class="icon-star"></i></button>
                <button class="button lightblue col4"><i class="icon-tag"></i></button>
                <button class="button lightblue col4"><i class="icon-tasks"></i></button>
            </div>
        </div>
    </div>
</div>

