update for version 1.0.2
This commit is contained in:
@@ -0,0 +1,188 @@
|
||||
@extends('themes.default1.agent.layout.kb')
|
||||
|
||||
@section('article')
|
||||
active
|
||||
@stop
|
||||
@section('add-article')
|
||||
class="active"
|
||||
@stop
|
||||
<script type="text/javascript" src="{{asset('lb-faveo/dist/js/nicEdit.js')}}"></script>
|
||||
<script type="text/javascript">
|
||||
bkLib.onDomLoaded(function() { nicEditors.allTextAreas() });
|
||||
</script>
|
||||
@section('content')
|
||||
{!! Form::open(array('action' => 'Admin\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>
|
||||
<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>
|
||||
<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>
|
||||
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">Add Article</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'=>'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="checkbox" 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'=>'Admin\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.admin.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>
|
||||
{{-- {!! Form::close() !!} --}}
|
||||
@stop
|
||||
@section('FooterInclude')
|
||||
|
||||
@stop
|
||||
|
||||
<!-- /content -->
|
||||
@@ -0,0 +1,192 @@
|
||||
@extends('themes.default1.admin.layout.kb')
|
||||
|
||||
@section('article')
|
||||
active
|
||||
@stop
|
||||
|
||||
@section('all-article')
|
||||
class="active"
|
||||
@stop
|
||||
|
||||
<script type="text/javascript" src="{{asset('dist/js/EditnicEdit.js')}}"></script>
|
||||
<script type="text/javascript">
|
||||
bkLib.onDomLoaded(function() {
|
||||
nicEditors.editors.push(
|
||||
new nicEditor().panelInstance(
|
||||
document.getElementById('myNicEditor')
|
||||
));
|
||||
});
|
||||
</script>
|
||||
|
||||
@section('content')
|
||||
{!! Form::model($article,['url' => 'article/'.$article->slug , '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>
|
||||
<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>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('fails')}}
|
||||
</div>
|
||||
@endif
|
||||
<div class="col-md-9">
|
||||
|
||||
<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>
|
||||
|
||||
<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="checkbox" 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">Add Category</span>
|
||||
<div class="modal" id="j">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
{!! Form::open(['method'=>'post','action'=>'Admin\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.admin.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>
|
||||
|
||||
|
||||
|
||||
|
||||
{{-- {!! Form::close() !!} --}}
|
||||
@stop
|
||||
@section('FooterInclude')
|
||||
|
||||
@stop
|
||||
|
||||
<!-- /content -->
|
||||
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
//Check if we are getting the image
|
||||
if (isset($_FILES['image'])) {
|
||||
//Get the image array of details
|
||||
$img = $_FILES['image'];
|
||||
//The new path of the uploaded image, rand is just used for the sake of it
|
||||
$path = "upload/" . rand() . $img["name"];
|
||||
//Move the file to our new path
|
||||
move_uploaded_file($img['tmp_name'], $path);
|
||||
//Get image info, reuiqred to biuld the JSON object
|
||||
$data = getimagesize($path);
|
||||
//The direct link to the uploaded image, this might varyu depending on your script location
|
||||
$link = "http://$_SERVER[HTTP_HOST]" . "/codex/" . $path;
|
||||
//Here we are constructing the JSON Object
|
||||
$res = array("upload" => array(
|
||||
"links" => array("original" => $link),
|
||||
"image" => array("width" => $data[0],
|
||||
"height" => $data[1],
|
||||
),
|
||||
));
|
||||
//echo out the response :)
|
||||
echo json_encode($res);
|
||||
}
|
||||
?>
|
||||
@@ -0,0 +1,62 @@
|
||||
@extends('themes.default1.admin.layout.admin')
|
||||
@section('article')
|
||||
active
|
||||
@stop
|
||||
@section('all-article')
|
||||
class="active"
|
||||
@stop
|
||||
@section('content')
|
||||
<link href="{{asset('lb-faveo/dist/css/dataTables.bootstrap.css')}}" rel="stylesheet">
|
||||
<div class="box box-primary">
|
||||
<div class="box-header">
|
||||
<h2 class="box-title">{{Lang::get('lang.articles')}}</h2></div>
|
||||
|
||||
<div class="box-body table-responsive no-padding">
|
||||
|
||||
<!-- check whether success or not -->
|
||||
|
||||
@if(Session::has('success'))
|
||||
<div class="alert alert-success alert-dismissable">
|
||||
<i class="fa fa-check-circle"></i>
|
||||
<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>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('fails')}}
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<section class="content">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
|
||||
<div id="example1_wrapper" class="dataTables_wrapper form-inline dt-bootstrap">
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
<table id="allBlogs" class="table table-bordered table-striped dataTable" role="grid" aria-describedby="example1_info">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{Lang::get('lang.name')}}</th>
|
||||
<th>{{Lang::get('lang.create')}}</th>
|
||||
<th>{{Lang::get('lang.action')}}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.1/js/bootstrap.min.js"></script>
|
||||
<script src="{{asset('lb-faveo/dist/js/blogs.js')}}"></script>
|
||||
<script src="{{asset('lb-faveo/dist/js/delete.js')}}"></script>
|
||||
|
||||
@stop
|
||||
@@ -0,0 +1,235 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Faveo | KB</title>
|
||||
<meta content='width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no' name='viewport'>
|
||||
<!-- Bootstrap 3.3.4 -->
|
||||
<link href="bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
|
||||
<!-- Font Awesome Icons -->
|
||||
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css" rel="stylesheet" type="text/css" />
|
||||
<!-- Ionicons -->
|
||||
<link href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css" rel="stylesheet" type="text/css" />
|
||||
<!-- jvectormap -->
|
||||
<link href="plugins/jvectormap/jquery-jvectormap-1.2.2.css" rel="stylesheet" type="text/css" />
|
||||
<!-- Theme style -->
|
||||
<link href="dist/css/AdminLTE.min.css" rel="stylesheet" type="text/css" />
|
||||
<!-- AdminLTE Skins. Choose a skin from the css/skins
|
||||
folder instead of downloading all of them to reduce the load. -->
|
||||
<link href="dist/css/skins/_all-skins.min.css" rel="stylesheet" type="text/css" />
|
||||
<link href="{{asset('dist/css/bootstrap.css')}}" rel="stylesheet">
|
||||
<link href="{{asset('dist/css/dataTables.bootstrap.css')}}" rel="stylesheet">
|
||||
<!-- Data tables CDN -->
|
||||
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.3/js/bootstrap.min.js"></script>
|
||||
<script type="text/javascript" src="{{asset('dist/js/jquery-1.11.1.min.js')}}"></script>
|
||||
<script type="text/javascript" src="//cdn.datatables.net/1.10.0/js/jquery.dataTables.js"></script>
|
||||
<script type="text/javascript" language="javascript" src="//cdn.datatables.net/plug-ins/505bef35b56/integration/bootstrap/3/dataTables.bootstrap.js"></script>
|
||||
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
|
||||
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
|
||||
<!--[if lt IE 9]>
|
||||
<script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
|
||||
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
|
||||
<![endif]-->
|
||||
</head>
|
||||
<body class="skin-blue">
|
||||
<div class="wrapper" id="RefreshAssign">
|
||||
|
||||
<header class="main-header">
|
||||
<?php $settings = App\Model\Settings::where('id', '=', '1')->first();?>
|
||||
<img src="{{asset('Img/icon/faveokb.jpg')}}" class="logo" alt="Knowledge Base"/>
|
||||
{{-- <a href="../../index2.html" class="logo"><b>Faveo</b> Knowledge</a> --}}
|
||||
<!-- Header Navbar: style can be found in header.less -->
|
||||
<nav class="navbar navbar-static-top" role="navigation">
|
||||
<!-- Sidebar toggle button-->
|
||||
<a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</a>
|
||||
<!-- Collect the nav links, forms, and other content for toggling -->
|
||||
<div class="collapse navbar-collapse" id="navbar-collapse">
|
||||
<ul class="tabs tabs-horizontal nav navbar-nav">
|
||||
</ul>
|
||||
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
|
||||
<li class="dropdown user user-menu">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
|
||||
@if(Auth::user()->profile_pic==NULL)
|
||||
<img src="{{asset('dist/img/avatar.png')}}" class="user-image" alt="User Image"/>
|
||||
@else
|
||||
<img src="{{asset('dist')}}{{'/'}}{{Auth::user()->profile_pic}}" class="user-image" alt="User Image"/>
|
||||
@endif
|
||||
<span class="hidden-xs">{{Auth::user()->name}}</span>
|
||||
</a>
|
||||
<ul class="dropdown-menu">
|
||||
<!-- User image -->
|
||||
<li class="user-header">
|
||||
@if(Auth::user()->profile_pic==NULL)
|
||||
<img src="{{asset('dist/img/avatar.png')}}" class="img-circle" alt="User Image"/>
|
||||
@else
|
||||
<img src="{{asset('dist')}}{{'/'}}{{Auth::user()->profile_pic}}" class="img-circle" alt="User Image" />
|
||||
@endif
|
||||
<p>
|
||||
{{Auth::user()->name}}
|
||||
|
||||
</p>
|
||||
</li>
|
||||
<!-- Menu Body -->
|
||||
|
||||
<!-- Menu Footer-->
|
||||
<li class="user-footer">
|
||||
<div class="pull-left">
|
||||
<a href="{{url('profile')}}" class="btn btn-default btn-flat">Profile</a>
|
||||
</div>
|
||||
<div class="pull-right">
|
||||
<a href="{{ url('/auth/logout') }}" class="btn btn-default btn-flat">Sign out</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- <form class="navbar-form navbar-left" role="search">
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" id="navbar-search-input" placeholder="Search">
|
||||
</div>
|
||||
</form> -->
|
||||
|
||||
</div><!-- /.navbar-collapse -->
|
||||
</nav>
|
||||
</header>
|
||||
<!-- Left side column. contains the logo and sidebar -->
|
||||
<aside class="main-sidebar">
|
||||
<!-- sidebar: style can be found in sidebar.less -->
|
||||
<section class="sidebar">
|
||||
<!-- Sidebar user panel -->
|
||||
<!-- search form -->
|
||||
|
||||
<!-- /.search form -->
|
||||
<!-- sidebar menu: : style can be found in sidebar.less -->
|
||||
|
||||
<ul class="sidebar-menu">
|
||||
<li class="treeview @yield('category')">
|
||||
<a href="#">
|
||||
<i class="fa fa-list-ul"></i> <span>Category</span>
|
||||
<i class="fa fa-angle-left pull-right"></i>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li @yield('add-category')><a href="{{url('category/create')}}"><i class="fa fa-circle-o"></i>Add Category</a></li>
|
||||
<li @yield('all-category')><a href="{{url('category')}}"><i class="fa fa-circle-o"></i> All Category</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="treeview @yield('article')">
|
||||
<a href="#">
|
||||
<i class="fa fa-edit"></i> <span>Article</span>
|
||||
<i class="fa fa-angle-left pull-right"></i>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li @yield('add-article')><a href="{{url('article/create')}}"><i class="fa fa-circle-o"></i>Add Article</a></li>
|
||||
<li @yield('all-article')><a href="{{url('article')}}"><i class="fa fa-circle-o"></i> All Article</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li class="treeview @yield('pages')">
|
||||
<a href="#">
|
||||
<i class="fa fa-file-text"></i> <span>Pages</span>
|
||||
<i class="fa fa-angle-left pull-right"></i>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li @yield('add-pages')><a href="{{url('page/create')}}"><i class="fa fa-circle-o"></i>Add Pages</a></li>
|
||||
<li @yield('all-pages')><a href="{{url('page')}}"><i class="fa fa-circle-o"></i> All Pages</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="treeview @yield('widget')">
|
||||
<a href="#">
|
||||
<i class="fa fa-th"></i> <span>Widgets</span>
|
||||
<i class="fa fa-angle-left pull-right"></i>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
<li @yield('footer1')><a href="{{url('create-footer')}}"><i class="fa fa-circle-o"></i>Footer 1</a></li>
|
||||
<li @yield('footer2')><a href="{{url('create-footer2')}}"><i class="fa fa-circle-o"></i> Footer 2</a></li>
|
||||
<li @yield('footer3')><a href="{{url('create-footer3')}}"><i class="fa fa-circle-o"></i> Footer 3</a></li>
|
||||
<li @yield('footer4')><a href="{{url('create-footer4')}}"><i class="fa fa-circle-o"></i> Footer 4</a></li>
|
||||
<li @yield('side1')><a href="{{url('side1')}}"><i class="fa fa-circle-o"></i>Side Widget 1</a></li>
|
||||
<li @yield('side2')><a href="{{url('side2')}}"><i class="fa fa-circle-o"></i>Side Widget 2</a></li>
|
||||
<li @yield('social')><a href="{{url('social')}}"><i class="fa fa-circle-o"></i>Social</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li @yield('comment')>
|
||||
<a href="{{url('comment')}}">
|
||||
<i class="fa fa-comments-o"></i>
|
||||
<span>Comments</span>
|
||||
</a>
|
||||
</li>
|
||||
<li @yield('settings')>
|
||||
<a href="{{url('settings')}}">
|
||||
<i class="fa fa-wrench"></i>
|
||||
<span>Settings</span>
|
||||
</a>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
|
||||
</section>
|
||||
<!-- /.sidebar -->
|
||||
</aside>
|
||||
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
<!-- Content Header (Page header) -->
|
||||
<div class="tab-content" style="background-color: white; border-top:1px solid #F0F0F0;">
|
||||
<div class="collapse navbar-collapse" id="navbar-collapse">
|
||||
<div class="tabs-content">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Main content -->
|
||||
<section class="content">
|
||||
<!-- Info boxes -->
|
||||
@yield('content')
|
||||
</section><!-- /.content -->
|
||||
</div><!-- /.content-wrapper -->
|
||||
|
||||
<footer class="main-footer">
|
||||
<div class="pull-right hidden-xs">
|
||||
<b>Version</b> {{$settings->version}}
|
||||
</div>
|
||||
<strong>Copyright © {{date("Y")}} <a href="{{$settings->website}}"> {{$settings->company_name}}</a>. Powered By <a href="http://www.faveohelpdesk.com">Faveo</a>.</strong>
|
||||
</footer>
|
||||
|
||||
<!-- Control Sidebar -->
|
||||
|
||||
</div><!-- ./wrapper -->
|
||||
|
||||
<!-- jQuery 2.1.4 -->
|
||||
<script src="plugins/jQuery/jQuery-2.1.4.min.js"></script>
|
||||
<!-- Bootstrap 3.3.2 JS -->
|
||||
<script src="bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
|
||||
<!-- FastClick -->
|
||||
<script src='plugins/fastclick/fastclick.min.js'></script>
|
||||
<!-- AdminLTE App -->
|
||||
<script src="dist/js/app.min.js" type="text/javascript"></script>
|
||||
<!-- Sparkline -->
|
||||
<script src="plugins/sparkline/jquery.sparkline.min.js" type="text/javascript"></script>
|
||||
<!-- jvectormap -->
|
||||
<script src="plugins/jvectormap/jquery-jvectormap-1.2.2.min.js" type="text/javascript"></script>
|
||||
<script src="plugins/jvectormap/jquery-jvectormap-world-mill-en.js" type="text/javascript"></script>
|
||||
<!-- SlimScroll 1.3.0 -->
|
||||
<script src="plugins/slimScroll/jquery.slimscroll.min.js" type="text/javascript"></script>
|
||||
<!-- ChartJS 1.0.1 -->
|
||||
<script src="plugins/chartjs/Chart.min.js" type="text/javascript"></script>
|
||||
|
||||
<!-- AdminLTE dashboard demo (This is only for demo purposes) -->
|
||||
<script src="dist/js/pages/dashboard2.js" type="text/javascript"></script>
|
||||
|
||||
<!-- AdminLTE for demo purposes -->
|
||||
<script src="dist/js/demo.js" type="text/javascript"></script>
|
||||
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.1/js/bootstrap.min.js"></script>
|
||||
<script src="{{asset('dist/js/blogs.js')}}"></script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,133 @@
|
||||
@extends('themes.default1.layouts.master')
|
||||
@section('head')
|
||||
<!-- DATA TABLES -->
|
||||
<link href="{{asset("lb-faveo/plugins/datatables/dataTables.bootstrap.css")}}" rel="stylesheet" type="text/css" />
|
||||
@stop
|
||||
@section('header')
|
||||
|
||||
<h1>Home</h1>
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>
|
||||
<li class="active">Dashboard</li>
|
||||
</ol>
|
||||
@stop
|
||||
|
||||
@section('content')
|
||||
<section class="content">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
@if(Session::has('success'))
|
||||
<div class="alert alert-success alert-dismissable">
|
||||
<i class="fa fa-ban"></i>
|
||||
<b>Alert!</b> Failed.
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
<p>{{Session::get('success')}}</p>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<!-- -->
|
||||
<div class="box">
|
||||
<div class="box-header">
|
||||
<h3 class="box-title">Song List</h3>
|
||||
</div><!-- /.box-header -->
|
||||
<div class="box-body">
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>ID</th>
|
||||
<th>Title</th>
|
||||
<th>Slug</th>
|
||||
<th>Action</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($songs as $song)
|
||||
<tr>
|
||||
<td>{!! $song->id !!}</td>
|
||||
<td>{!! $song->title !!}</td>
|
||||
<td>{!! $song->slug !!}</td>
|
||||
<td>{!! link_to_route('songs.show','Show',[$song->slug],['id'=>'show','class'=>'btn btn-primary btn-sm']) !!}
|
||||
|
||||
<button class="btn btn-info btn-sm" data-toggle="modal" data-target="#{{$song->slug}}">Modal Edit</button>
|
||||
<div class="modal fade" id="{{$song->slug}}">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
{!! Form::model($song,['route'=>['songs.update', $song->slug],'method'=>'PATCH']) !!}
|
||||
<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">Edit Song</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
@include('themes.default1.admin.songs.form')
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<div class="form-group">
|
||||
{!! Form::submit('Update Song',['class'=>'btn btn-primary'])!!}
|
||||
</div>
|
||||
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">Close</button>
|
||||
</div>
|
||||
{!! Form::close() !!}
|
||||
</div><!-- /.modal-content -->
|
||||
</div><!-- /.modal-dialog -->
|
||||
</div><!-- /.modal -->
|
||||
|
||||
<button class="btn btn-danger btn-sm" data-toggle="modal" data-target="#{{$song->slug}}delete">Modal Delete</button>
|
||||
<div class="modal fade" id="{{$song->slug}}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('songs.delete','Delete',[$song->slug],['id'=>'delete','class'=>'btn btn-danger btn-sm']) !!}
|
||||
</div>
|
||||
</div><!-- /.modal-content -->
|
||||
</div><!-- /.modal-dialog -->
|
||||
</div><!-- /.modal -->
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<th>ID</th>
|
||||
<th>Title</th>
|
||||
<th>Slug</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
</div><!-- /.box-body -->
|
||||
</div>
|
||||
<!-- -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
@stop
|
||||
@section('footer')
|
||||
<script src="{{asset("lb-faveo/plugins/datatables/jquery.dataTables.js")}}" type="text/javascript"></script>
|
||||
<script src="{{asset("lb-faveo/plugins/datatables/dataTables.bootstrap.js")}}" type="text/javascript"></script>
|
||||
<!-- 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
|
||||
@@ -0,0 +1,60 @@
|
||||
@extends('themes.default1.article.layout')
|
||||
@section('content')
|
||||
<link href="{{asset('dist/css/bootstrap.css')}}" rel="stylesheet">
|
||||
<link href="{{asset('dist/css/dataTables.bootstrap.css')}}" rel="stylesheet">
|
||||
<!-- Data tables CDN -->
|
||||
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.3/js/bootstrap.min.js"></script>
|
||||
<script type="text/javascript" src="{{asset('dist/js/jquery-1.11.1.min.js')}}"></script>
|
||||
<script type="text/javascript" src="//cdn.datatables.net/1.10.0/js/jquery.dataTables.js"></script>
|
||||
<script type="text/javascript" language="javascript" src="//cdn.datatables.net/plug-ins/505bef35b56/integration/bootstrap/3/dataTables.bootstrap.js"></script>
|
||||
</head>
|
||||
<body style="font-family: 'Segoe UI'">
|
||||
<div class="box box-primary">
|
||||
<div class="box-header">
|
||||
<h2 class="box-title">Articles</h2></div>
|
||||
|
||||
<div class="box-body table-responsive no-padding">
|
||||
|
||||
<!-- check whether success or not -->
|
||||
|
||||
@if(Session::has('success'))
|
||||
<div class="alert alert-success alert-dismissable">
|
||||
<i class="fa fa-check-circle"></i>
|
||||
<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>
|
||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||
{{Session::get('fails')}}
|
||||
</div>
|
||||
@endif
|
||||
|
||||
|
||||
|
||||
<table id="allBlogs" class="table table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
<th>Description</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.1/js/bootstrap.min.js"></script>
|
||||
<script src="{{asset('dist/js/blogs.js')}}"></script>
|
||||
</body>
|
||||
@stop
|
||||
Reference in New Issue
Block a user