summaryrefslogblamecommitdiffstats
path: root/modules-available/news/templates/page-news.html
blob: d3cb26b91141a35d605febb6ec7290fd2e2b4efd (plain) (tree)
1
2
3
4
5
6
7
8
9
 
                                 

                                                                                                                                                
                                                                                                                                                          



                                                                                                             
                                                                      
                                                 





                                                                                                                                                                
                                                                                                                                                                                   
                              
                                                                                                                                                   
                                                                            
                                                                    
                       







                                                                                                
                                                                                                                

                                                                    


                                                                                                                    





                                                                                                         



                                                                                                                                                  











                                                                                                                                                                                                                                              
              
                                                                                         
                                                                                               

                                                                                     
                                                                                                                                                                                     
                              
                                                                                                                                                   
                                                                            
                                
                       
                     






                                                                                                              
                                                                                                                

                                                                    

                                                                                                                    





                                                                                                         


                                                                                                                                                  










                                                                                                                                                                                                                                              

                      
      









                                                           

<h1>{{lang_vmChooser_title}}</h1>
<ul class="nav nav-tabs" role="tablist">
	<li role="presentation" class="{{^editHelp}}active{{/editHelp}}"><a href="#news" role="tab" data-toggle="tab">{{lang_editNews}}</a></li>
	<li role="presentation" class="{{#editHelp}}active{{/editHelp}}"	  ><a href="#help" role="tab" data-toggle="tab">{{lang_editHelp}}</a></li>
</ul>

<div class="tab-content">
	<div role="tabpanel" class="tab-pane {{^editHelp}}active{{/editHelp}}" id="news" style="padding:5px">
		<form action="?do=News&amp;action=save" method="post">
			<p>{{lang_newsIntro}}</p>
			<div class="form-group">
				<label for="news-title-id">{{lang_title}}</label>
				<input type="text" name="news-title" id ="news-title-id" class="form-control" placeholder="{{welcome}}" value="{{latestTitle}}">
			</div>
			<div class="form-group">
				<label for="news-content-id">{{lang_content}}</label>
				<textarea name="news-content" id ="news-content-id" class="form-control summernote" rows="5" cols="30"  placeholder="">{{latestContent}}</textarea>
			</div>
			<button class="btn btn-primary btn-sm sn-btn pull-right" name="news-type" value="news" type="submit">{{lang_save}}</button>
			<input type="hidden" name="token" value="{{token}}">
			<p>{{lang_latestUpdate}}: {{latestDate}}</p>
		</form>
		<br/>
		<div class="panel panel-default">
			<div class="panel-heading">
				{{lang_newsOld}}
			</div>
			<div class="panel-body">
				<div class="table-responsive">
					<form method="post" action="?do=News&amp;action=delete">
						<table class="table table-stripped table-condensed stupidtable">
							<thead>
								<tr>
									<th data-sort="date">{{lang_date}}</th>
									<th data-sort="string">{{lang_title}}</th>
									<th data-sort="string">{{lang_content}}</th>
									<th></th>
								</tr>
							</thead>
							<tbody>
								{{#list}}
								<tr {{#active}}class="active"{{/active}}>
									<td class="text-left text-nowrap">{{date}}</td>
									<td><table class="slx-ellipsis"><tr><td>{{title}}</td></tr></table></td>
									<td><table class="slx-ellipsis"><tr><td>{{content}}</td></tr></table></td>
									<td class="text-nowrap">
										<a class="btn btn-primary btn-xs" href="?do=news&amp;newsid={{newsid}}&amp;action=show"><span class="glyphicon glyphicon-share-alt"></span> {{lang_show}}</a>
										<button class="btn btn-danger btn-xs" type="submit" name="newsid" value="{{newsid}}"><span class="glyphicon glyphicon-remove"></span> {{lang_delete}}</button>
									</td>
								</tr>
								{{/list}}
							</tbody>
						</table>
						<input type="hidden" name="token" value="{{token}}">
					</form>
				</div>
			</div>
		</div>
	</div>
	<div role="tabpanel" class="tab-pane {{#editHelp}}active{{/editHelp}}" id="help">
		<form class="bottom-margin-50" action="?do=News&amp;action=save" method="post">
			<div class="form-group">
				<label for="news-content-id">{{lang_content}}</label>
				<textarea name="help-content" id="help-content-id" class="form-control summernote" style="min-height:400px"  placeholder="">{{latestHelp}}</textarea>
			</div>
			<button class="btn btn-primary btn-sm sn-btn pull-right" name="news-type" value="help" type="submit">{{lang_save}}</button>
			<input type="hidden" name="token" value="{{token}}">
			<p> </p>
		</form>
		<br/>
		<div class="panel panel-default">
			<div class="panel-heading">
				{{lang_oldHelp}}
			</div>
			<div class="panel-body">
				<div class="table-responsive">
					<form method="post" action="?do=News&amp;action=delete&editHelp=true">
						<table class="table table-stripped table-condensed stupidtable">
							<thead>
								<tr>
									<th data-sort="date">{{lang_date}}</th>
									<th data-sort="string">{{lang_content}}</th>
									<th></th>
								</tr>
							</thead>
							<tbody>
								{{#listHelp}}
								<tr {{#active}}class="active"{{/active}}>
									<td class="text-left text-nowrap">{{date}}</td>
									<td><table class="slx-ellipsis"><tr><td>{{content}}</td></tr></table></td>
									<td class="text-nowrap">
										<a class="btn btn-primary btn-xs" href="?do=news&amp;newsid={{newsid}}&amp;action=show"><span class="glyphicon glyphicon-share-alt"></span> {{lang_show}}</a>
										<button class="btn btn-danger btn-xs" type="submit" name="newsid" value="{{newsid}}"><span class="glyphicon glyphicon-remove"></span> {{lang_delete}}</button>
									</td>
								</tr>
								{{/listHelp}}
							</tbody>
						</table>
						<input type="hidden" name="token" value="{{token}}">
					</form>
				</div>
			</div>
		</div>
	</div>
</div>
<script type="application/javascript"><!--
document.addEventListener("DOMContentLoaded", function () {
	$('.sn-btn').click(function (event) {
		var $button = $('.note-btn.btn-codeview');
		if ($button.hasClass('active')) {
			$button.click();
		}
	});
}, false);
// --></script>