<div ng:controller="ArticleCreateController" class="row-fluid" qn:fillheight>
   <link rel="stylesheet" href="/Areas/Qusion/Scripts/Vendor/widgets/redactor/redactor.css" />
   <script src="/Areas/Qusion/Scripts/Vendor/widgets/redactor/redactor.min.js"></script>  
    <div class="toolbar cfix">
        <div class="toolbar-group">
            
            <h3>
                <span ng:click="back()" class="circle circle-small blue"><span class="icon li_cloud"></span></span>
                {{$resource('articles.new_article')}}
            </h3>
        </div>
        <div class="toolbar-group right">
            <button title="{{$resource('utility.home')}}" class="button tooltip" ng:click="back()"><i class="icon-angle-left"></i></button>
        </div>
    </div>
    <div>
        <div class="col2 sidebar">
            <ul class="nav">
                <li class="active"><a>{{$resource('articles.basic_info')}}</a></li>
                <li><a>{{$resource('articles.content')}}</a></li>
                <li><a>{{$resource('articles.publishing')}}</a></li>
            </ul>
        </div>
        <div class="col10">
            <div class="form">
                <form name="Article" class="form-horizontal fillh" method="post">
                    <div class="control-group required">
                        <label class="control-label">{{$resource('articles.title')}}</label>
                        <div class="controls">
                            <input type="text" class="col6" name="Title"  ng:model="article.Title" required />
                            <div ng:show="errors['article.Title'][0]" class="error">{{$resource(errors['article.Title'][0])}}</div>
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">{{$resource('articles.alias')}}</label>
                        <div class="controls">
                            <input type="text" class="col6" name="Alias" ng:model="article.Alias"  />
                            <div ng:show="errors['article.Alias'][0]" class="error">{{$resource(errors['article.Alias'][0])}}</div>
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">{{$resource('articles.author')}}</label>
                        <div class="controls">
                            <input type="text" class="col6" name="Author" ng:model="article.Author" />
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">{{$resource('articles.published')}}/{{$resource('articles.expires')}}</label>
                        <div class="controls">
                            <div class="input-prepend">
                                <span class="add-on"><i class="icon-calendar"></i></span>
                                <input qn:datepicker="{dateFormat: 'd MM yy'}" class="input-medium" type="text" name="PublishedOn.Date" ng:model="article.PublishedOn" />
                            </div>
                            <div class="input-prepend">
                                <span class="add-on"><i class="icon-calendar"></i></span>
                                <input qn:datepicker="{dateFormat: 'd MM yy'}" class="input-medium" type="text" name="ExpiresOn.Date" ng:model="article.ExpiresOn" />
                            </div>
                        </div>
                    </div>
                    <div class="control-group ">
                        <label class="control-label">{{$resource('articles.thumb')}}</label>
                        <div class="controls">
                            <input type="text" qn:imagesSelector="ImageSelectorOpiton" ng:Model="article.Thumb"  />
                        </div>
                    </div>
                    <div class="control-group">
                         <label class="control-label">{{$resource('articles.library')}}</label>
                        <div class="controls">
                            <input type="text" qn:librarySelector="LibrarySelectorOpiton" ng:Model="article.Library"  />
                        </div>
                    </div>
                      <div class="control-group"> 
                         <label class="control-label">{{$resource('articles.document')}}</label>
                  
                       <div class="controls">
                            <input type="text" qn:documentsselectora="DocumentSelectorOpiton" ng:Model="article.Document"  />
                        </div>
                  </div>
                 <div class="control-group">
                       <label class="control-label">{{$resource('articles.libraryDocument')}}</label>
                        <div class="controls">
                            <input type="text" qn:librarySelectordocument="LibrarySelectorOpiton" ng:Model="article.LibraryDocument" />
                        </div>
                   </div> 
                    <div class="control-group">
                        <label class="control-label">{{$resource('karte.izbor')}}</label>
                        <div class="controls">
                            <input type="text" qn:kartaselector="KartaSelectorOpiton" ng:Model="article.Karta" />
                        </div>
                    </div>
                    <div class="control-group required">
                        <label class="control-label">{{$resource('articles.summary')}}</label>
                        <div class="controls">
                            <textarea class="col6" rows="3" name="Summary" ng:model="article.Summary" required />
                            <div ng:show="errors['article.Summary'][0]" style="display: block; clear: both; color: red; padding: 10px 0 0;">{{$resource(errors['article.Summary'][0])}}</div>
                        </div>
                    </div>
                    <div class="control-group required">
                        <label class="control-label">{{$resource('articles.content')}}</label>
                        <div class="controls" style="width: 600px">
                            <textarea name="Content" class="span5"  redactor ng:model="article.Content" required></textarea>
                            <div ng:show="errors['article.Content'][0]" style="display: block; clear: both; color: red; padding: 10px 0 0;">{{$resource(errors['article.Content'][0])}}</div>
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">{{$resource('articles.source')}}</label>
                        <div class="controls">
                            <input class="col6" type="text" name="Source" ng:model="article.Source" />
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">{{$resource('articles.external_link')}}</label>
                        <div class="controls">
                            <input class="col6" type="text" name="ExternalLink" ng:model="article.ExternalLink" />
                        </div>
                    </div>
                  
                    <div class="control-group">
                        <label class="control-label">{{$resource('articles.tags')}}</label>
                        <div class="controls">
                            <select qn:multiselect="" multiple="multiple" ng:model="classifications['tag']" ng:options="label.ID as label.Name for label in tags.Labels"></select>
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">{{$resource('articles.categories')}}</label>
                        <div class="controls">
                            <input qn:Treeselector="treeOptions" qn:Treedata="categories" ng:model="classifications['vijesti']" />
                        </div>
                    </div>
                    <br/>
                    <div class="control-group">
                        <label class="control-label"></label>
                        <div class="controls">
                            <button class="button green" ng:click="create()">{{$resource('articles.create')}}</button>
                            <button type="button" class="button" ng:click="back()">{{$resource('articles.cancel')}}</button>
                        </div>
                    </div> 
                </form>
            </div>
        </div>
    </div>
</div>