Update v1.0.6
This commit is contained in:
@@ -0,0 +1,164 @@
|
||||
@extends('themes.default1.admin.layout.admin')
|
||||
|
||||
@section('Emails')
|
||||
class="active"
|
||||
@stop
|
||||
|
||||
@section('emails-bar')
|
||||
active
|
||||
@stop
|
||||
|
||||
@section('template')
|
||||
class="active"
|
||||
@stop
|
||||
|
||||
@section('HeadInclude')
|
||||
@stop
|
||||
<!-- header -->
|
||||
@section('PageHeader')
|
||||
|
||||
@stop
|
||||
<!-- /header -->
|
||||
<!-- breadcrumbs -->
|
||||
@section('breadcrumbs')
|
||||
<ol class="breadcrumb">
|
||||
|
||||
</ol>
|
||||
@stop
|
||||
<!-- /breadcrumbs -->
|
||||
<!-- content -->
|
||||
@section('content')
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="box box-primary">
|
||||
<div class="box-header">
|
||||
<h2 class="box-title">{{Lang::get('lang.template_set')}}</h2>
|
||||
<button class="btn btn-primary pull-right" data-toggle="modal" data-target="#createtemp">{{Lang::get('lang.create_template')}}</button>
|
||||
|
||||
<div class="modal fade" id="createtemp">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
{!! Form::open(['route'=>'template.createnew']) !!}
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">{{Lang::get('lang.create_template')}}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="form-group {{ $errors->has('title') ? 'has-error' : '' }}">
|
||||
|
||||
{!! Form::label('folder_name', 'Template Set Name:',['style'=>'display: block']) !!}
|
||||
|
||||
{!! Form::text('folder_name',null,['class'=>'form-control'])!!}
|
||||
|
||||
{!! $errors->first('folder', '<spam class="help-block">:message</spam>') !!}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<div class="form-group">
|
||||
{!! Form::submit('Create Template Set',['class'=>'btn btn-primary'])!!}
|
||||
|
||||
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">Close</button>
|
||||
</div></div>
|
||||
{!! Form::close() !!}
|
||||
</div>
|
||||
</div>
|
||||
</div></div>
|
||||
|
||||
<div class="box-body ">
|
||||
|
||||
<!-- check whether success or not -->
|
||||
|
||||
@if(Session::has('success'))
|
||||
<div class="alert alert-success alert-dismissable">
|
||||
<i class="fa fa-check-circle"></i>
|
||||
<b>Success!</b>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('success')}}
|
||||
</div>
|
||||
@endif
|
||||
<!-- failure message -->
|
||||
@if(Session::has('fails'))
|
||||
<div class="alert alert-danger alert-dismissable">
|
||||
<i class="fa fa-ban"></i>
|
||||
<b>Fail!</b>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('fails')}}
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<tr>
|
||||
<th width="100px">{{Lang::get('lang.name')}}</th>
|
||||
<th width="100px">{{Lang::get('lang.status')}}</th>
|
||||
<th width="100px">{{Lang::get('lang.action')}}</th>
|
||||
</tr>
|
||||
<!-- Foreach @var templates as @var template -->
|
||||
|
||||
@foreach($directories as $dir)
|
||||
<?php if ($dir === '.' or $dir === '..' or $dir === 'notifications') continue; ?>
|
||||
<tr>
|
||||
<!-- Template Name with Link to Edit page along Id -->
|
||||
<td><a href="{{route('template.list',[$dir,$directory])}}"><?php $parts = explode('.',$dir); $names = $parts[0]; $name = str_replace('_', ' ', $names);$name1 = ucfirst($name); echo $name1?></a></td>
|
||||
<!-- template Status : if status==1 active -->
|
||||
<!-- Deleting Fields -->
|
||||
<?php $status = DB::table('settings_email')->first(); ?>
|
||||
<td><input type="radio" disabled="disabled" value="Active"<?php echo ($status->template == $dir)?'checked':'' ?> /></td>
|
||||
<td>
|
||||
{!! link_to_route('active.set','Activate This Set',[$dir],['class'=>'btn btn-success btn-xs']) !!}
|
||||
|
||||
<?php
|
||||
if($dir == 'default') {
|
||||
$dis = "disabled";
|
||||
} else {
|
||||
$dis = "";
|
||||
} ?>
|
||||
<button class="btn btn-danger btn-xs {!! $dis !!}" data-toggle="modal" data-target="#{{$dir}}delete">Delete</button>
|
||||
<div class="modal fade" id="{{$dir}}delete">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">Delete</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>Are you sure you want to Delete ?</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">Close</button>
|
||||
{!! link_to_route('templates.delete','Delete',[$dir,$directory],['id'=>'delete','class'=>'btn btn-danger btn-sm']) !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> </td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
<!-- Set a link to Create Page -->
|
||||
|
||||
|
||||
|
||||
|
||||
</table>
|
||||
@stop
|
||||
</div><!-- /.box -->
|
||||
@section('FooterInclude')
|
||||
<!-- page script -->
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
$("#example1").dataTable();
|
||||
$('#example2').dataTable({
|
||||
"bPaginate": true,
|
||||
"bLengthChange": false,
|
||||
"bFilter": false,
|
||||
"bSort": true,
|
||||
"bInfo": true,
|
||||
"bAutoWidth": false
|
||||
});
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
@stop
|
||||
@stop
|
||||
<!-- /content -->
|
@@ -0,0 +1,187 @@
|
||||
@extends('themes.default1.agent.layout.agent')
|
||||
@extends('themes.default1.agent.layout.sidebar')
|
||||
|
||||
@section('article')
|
||||
active
|
||||
@stop
|
||||
@section('add-article')
|
||||
class="active"
|
||||
@stop
|
||||
@section('content')
|
||||
{!! Form::open(array('action' => 'Agent\kb\ArticleController@store' , 'method' => 'post') )!!}
|
||||
|
||||
<div class="row">
|
||||
@if(Session::has('success'))
|
||||
<div class="alert alert-success alert-dismissable">
|
||||
<i class="fa fa-check-circle"></i>
|
||||
<b>Success</b>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('success')}}
|
||||
</div>
|
||||
@endif
|
||||
<!-- failure message -->
|
||||
@if(Session::has('fails'))
|
||||
<div class="alert alert-danger alert-dismissable">
|
||||
<i class="fa fa-ban"></i>
|
||||
<b>Fail!</b>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('fails')}}
|
||||
</div>
|
||||
@endif
|
||||
@if(!$category)
|
||||
<div class="alert alert-warning alert-dismissable">
|
||||
<i class="fa fa-info"></i>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{!! Lang::get('lang.create_a_category') !!}
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<div class="box-body">
|
||||
<div class="col-md-9">
|
||||
<div class="box box-primary">
|
||||
<div class="box-header">
|
||||
<h4 class="box-title">{!! Lang::get('lang.addarticle') !!}</h4>
|
||||
</div>
|
||||
<div class="box-body">
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-6 form-group {{ $errors->has('name') ? 'has-error' : '' }}" >
|
||||
|
||||
{!! Form::label('name',Lang::get('lang.name')) !!}
|
||||
{!! $errors->first('name', '<spam class="help-block">:message</spam>') !!}
|
||||
{!! Form::text('name',null,['class' => 'form-control']) !!}
|
||||
</div>
|
||||
|
||||
<div class="col-md-6 form-group {{ $errors->has('slug') ? 'has-error' : '' }}" >
|
||||
|
||||
{!! Form::label('slug',Lang::get('lang.slug')) !!}
|
||||
{!! $errors->first('slug', '<spam class="help-block">:message</spam>') !!}
|
||||
{!! Form::text('slug',null,['class' => 'form-control']) !!}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group {{ $errors->has('description') ? 'has-error' : '' }}">
|
||||
{!! Form::label('description',Lang::get('lang.description')) !!}
|
||||
{!! $errors->first('description', '<spam class="help-block">:message</spam>') !!}
|
||||
<div class="form-group" style="background-color:white">
|
||||
{!! Form::textarea('description',null,['class' => 'form-control color','size' => '128x20','id'=>'myNicEditor','placeholder'=>Lang::get('lang.enter_the_description')]) !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<ul style="list-style-type:none;">
|
||||
<li>
|
||||
<div class="col-md-3">
|
||||
<div class="box box-default">
|
||||
<div class="box-header with-border">
|
||||
<h3 class="box-title">{{Lang::get('lang.publish')}}</h3>
|
||||
</div>
|
||||
<div class="box-body">
|
||||
<div class="form-group {{ $errors->has('type') ? 'has-error' : '' }}">
|
||||
|
||||
{!! Form::label('type',Lang::get('lang.status')) !!}
|
||||
{!! $errors->first('type', '<spam class="help-block">:message</spam>') !!}
|
||||
<div class="row">
|
||||
<div class="col-xs-4">
|
||||
{!! Form::radio('type','1',true) !!}{{Lang::get('lang.published')}}
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
{!! Form::radio('type','0',null) !!}{{Lang::get('lang.draft')}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="form-group {{ $errors->has('status') ? 'has-error' : '' }}">
|
||||
|
||||
{!! Form::label('status',Lang::get('lang.visibility')) !!}
|
||||
{!! $errors->first('status', '<spam class="help-block">:message</spam>') !!}
|
||||
<div class="row">
|
||||
<div class="col-xs-3">
|
||||
{!! Form::radio('status','1',true) !!}{{Lang::get('lang.public')}}
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-3">
|
||||
{!! Form::radio('status','0',null) !!}{{Lang::get('lang.private')}}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="box-footer" style="background-color:#f5f5f5;">
|
||||
<div style="margin-left:140px;">
|
||||
|
||||
{!! Form::submit(Lang::get('lang.publish'),['class'=>'btn btn-primary'])!!}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
<div class="col-md-3">
|
||||
<div class="box box-default">
|
||||
<div class="box-header with-border">
|
||||
<h3 class="box-title">{{Lang::get('lang.category')}}</h3>
|
||||
</div>
|
||||
<div class="box-body" style="height:190px; overflow-y:auto;">
|
||||
|
||||
<div class="form-group {{ $errors->has('category_id') ? 'has-error' : '' }}">
|
||||
{{-- {!! Form::label('category_id','Category') !!} --}}
|
||||
{!! $errors->first('category_id', '<spam class="help-block">:message</spam>') !!}
|
||||
@while (list($key, $val) = each($category))
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<div class="col-md-1">
|
||||
<input type="radio" name="category_id[]" value="<?php echo $val;?>">
|
||||
</div>
|
||||
<div class="col-md-10">
|
||||
<?php echo $key;?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endwhile
|
||||
|
||||
</div>
|
||||
</div>
|
||||
{!! Form::close() !!}
|
||||
<div class="box-footer" style="background-color:#f5f5f5;">
|
||||
|
||||
<span class="btn btn-info btn-sm" data-toggle="modal" data-target="#j">{{Lang::get('lang.addcategory')}}</span>
|
||||
<div class="modal" id="j">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
{!! Form::open(['method'=>'post','action'=>'Agent\kb\CategoryController@store']) !!}
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">{{Lang::get('lang.addcategory')}}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
@include('themes.default1.agent.kb.category.form')
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<div class="form-group">
|
||||
{!! Form::submit('Add')!!}
|
||||
</div>
|
||||
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">Close</button>
|
||||
</div>
|
||||
{!! Form::close() !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
$("textarea").wysihtml5();
|
||||
});
|
||||
</script>
|
||||
{{-- {!! Form::close() !!} --}}
|
||||
@stop
|
177
resources/views/themes/default1/agent/kb/article/edit1.blade.php
Normal file
177
resources/views/themes/default1/agent/kb/article/edit1.blade.php
Normal file
@@ -0,0 +1,177 @@
|
||||
@extends('themes.default1.agent.layout.agent')
|
||||
@extends('themes.default1.agent.layout.sidebar')
|
||||
@section('article')
|
||||
active
|
||||
@stop
|
||||
@section('all-article')
|
||||
class="active"
|
||||
@stop
|
||||
@section('content')
|
||||
{!! Form::model($article,['url' => 'article/'.$article->id , 'method' => 'PATCH'] )!!}
|
||||
<div class="row">
|
||||
<div class="box-body" >
|
||||
@if(Session::has('success'))
|
||||
<div class="alert alert-success alert-dismissable">
|
||||
<i class="fa fa-check-circle"></i>
|
||||
<b>Success</b>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('success')}}
|
||||
</div>
|
||||
@endif
|
||||
<!-- failure message -->
|
||||
@if(Session::has('fails'))
|
||||
<div class="alert alert-danger alert-dismissable">
|
||||
<i class="fa fa-ban"></i>
|
||||
<b>Fail!</b>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('fails')}}
|
||||
</div>
|
||||
@endif
|
||||
<div class="col-md-9">
|
||||
<div class="box box-primary box-body">
|
||||
<div class="row">
|
||||
<div class="col-md-6 form-group {{ $errors->has('name') ? 'has-error' : '' }}" >
|
||||
{!! Form::label('name',Lang::get('lang.name')) !!}
|
||||
{!! $errors->first('name', '<spam class="help-block">:message</spam>') !!}
|
||||
{!! Form::text('name',null,['class' => 'form-control']) !!}
|
||||
</div>
|
||||
<div class="col-md-6 form-group {{ $errors->has('slug') ? 'has-error' : '' }}" >
|
||||
{!! Form::label('slug',Lang::get('lang.slug')) !!}
|
||||
{!! $errors->first('slug', '<spam class="help-block">:message</spam>') !!}
|
||||
{!! Form::text('slug',null,['class' => 'form-control']) !!}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group {{ $errors->has('description') ? 'has-error' : '' }}">
|
||||
{!! Form::label('description',Lang::get('lang.description')) !!}
|
||||
{!! $errors->first('description', '<spam class="help-block">:message</spam>') !!}
|
||||
<div class="form-group" style="background-color:white">
|
||||
{!! Form::textarea('description',null,['class' => 'form-control','size' => '128x20','id'=>'myNicEditor','placeholder'=>'Enter the description']) !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ul style="list-style-type:none;">
|
||||
<li>
|
||||
<div class="col-md-3">
|
||||
<div class="box box-default">
|
||||
<div class="box-header with-border">
|
||||
<h3 class="box-title">{{Lang::get('lang.publish')}}</h3>
|
||||
</div>
|
||||
<div class="box-body">
|
||||
<div class="form-group {{ $errors->has('type') ? 'has-error' : '' }}">
|
||||
|
||||
{!! Form::label('type',Lang::get('lang.status')) !!}
|
||||
{!! $errors->first('type', '<spam class="help-block">:message</spam>') !!}
|
||||
<div class="row">
|
||||
<div class="col-xs-4">
|
||||
{!! Form::radio('type','1',true) !!}{{Lang::get('lang.published')}}
|
||||
</div>
|
||||
<div class="col-xs-3">
|
||||
{!! Form::radio('type','0',null) !!}{{Lang::get('lang.draft')}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="form-group {{ $errors->has('status') ? 'has-error' : '' }}">
|
||||
|
||||
{!! Form::label('status',Lang::get('lang.visibility')) !!}
|
||||
{!! $errors->first('status', '<spam class="help-block">:message</spam>') !!}
|
||||
<div class="row">
|
||||
<div class="col-xs-3">
|
||||
{!! Form::radio('status','1',true) !!}{{Lang::get('lang.public')}}
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-3">
|
||||
{!! Form::radio('status','0',null) !!}{{Lang::get('lang.private')}}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
{!! Form::close() !!}
|
||||
<div class="box-footer" style="background-color:#f5f5f5;">
|
||||
<div style="margin-left:140px;">
|
||||
|
||||
{!! Form::submit(Lang::get('lang.publish'),['class'=>'btn btn-block btn-primary btn-sm'])!!}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</li>
|
||||
<li>
|
||||
<div class="col-md-3">
|
||||
<div class="box box-default">
|
||||
<div class="box-header with-border">
|
||||
<h3 class="box-title">{{Lang::get('lang.category')}}</h3>
|
||||
</div>
|
||||
<div class="box-body" style="height:190px; overflow-y:auto;">
|
||||
|
||||
<div class="form-group {{ $errors->has('category_id') ? 'has-error' : '' }}">
|
||||
{{-- {!! Form::label('category_id','Category') !!} --}}
|
||||
{!! $errors->first('category_id', '<spam class="help-block">:message</spam>') !!}
|
||||
@while (list($key, $val) = each($category))
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<div class="col-md-1">
|
||||
<input type="radio" name="category_id[]" value="<?php echo $val;?>" <?php if (in_array($val, $assign)) {
|
||||
echo ('checked');
|
||||
}
|
||||
?> ></div>
|
||||
<div class="col-md-10">
|
||||
<?php echo $key;?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endwhile
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="box-footer" style="background-color:#f5f5f5;">
|
||||
|
||||
<span class="btn btn-info btn-sm" data-toggle="modal" data-target="#j">{!! Lang::get('lang.addcategory') !!}</span>
|
||||
<div class="modal" id="j">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
{!! Form::open(['method'=>'post','action'=>'Agent\kb\CategoryController@store']) !!}
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">{{Lang::get('lang.addcategory')}}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
@include('themes.default1.agent.kb.category.form')
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<div class="form-group">
|
||||
{!! Form::submit(Lang::get('lang.add'))!!}
|
||||
</div>
|
||||
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">{!! Lang::get('lang.close') !!}</button>
|
||||
</div>
|
||||
{!! Form::close() !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
$("textarea").wysihtml5();
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
{{-- {!! Form::close() !!} --}}
|
||||
@stop
|
||||
<!-- /content -->
|
Reference in New Issue
Block a user