first commit
This commit is contained in:
@@ -0,0 +1,86 @@
|
||||
<form class="form-horizontal" method="POST" action="<?= 'companyProfile/update' ?>" enctype="multipart/form-data">
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Name</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="text" class="form-control" id="name" name="name"
|
||||
value="<?= $data->name ?>"
|
||||
placeholder="Name">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Alias</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" id="alias" name="alias"
|
||||
value="<?= $data->alias ?>"
|
||||
placeholder="Alias">
|
||||
|
||||
<input type="hidden" class="form-control" id="id" name="id"
|
||||
value="<?= $data->id ?>"
|
||||
placeholder="ID">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Version</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control" id="version" name="version"
|
||||
value="<?= $data->version ?>"
|
||||
placeholder="Version">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Year</label>
|
||||
<div class="col-sm-2">
|
||||
<input type="text" class="form-control" id="year" name="year"
|
||||
value="<?= $data->year ?>"
|
||||
placeholder="Year">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Description</label>
|
||||
<div class="col-sm-6">
|
||||
<textarea type="text" class="form-control" id="description" name="description"
|
||||
placeholder="Description"><?= $data->description ?></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Company</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="text" class="form-control" id="company" name="company"
|
||||
value="<?= $data->company ?>"
|
||||
placeholder="Name">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Address</label>
|
||||
<div class="col-sm-8">
|
||||
<textarea type="text" class="form-control" id="address" name="address" placeholder="Address"><?= $data->address ?></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Website</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="text" class="form-control" id="website" name="website"
|
||||
value="<?= $data->website ?>"
|
||||
placeholder="Website">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_logo" class="col-sm-2 col-form-label">Logo</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="file" class="form-control" id="logo" name="logo" value="" placeholder="Logo">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-footer">
|
||||
<button type="submit"
|
||||
class="btn btn-info float-right">Update Company</button>
|
||||
</div>
|
||||
</form>
|
||||
@@ -0,0 +1,63 @@
|
||||
<section class="content">
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<div class="card card-primary card-outline">
|
||||
<div class="card-body box-profile">
|
||||
<div class="text-center">
|
||||
<img class="profile-user-img img-fluid img-circle"
|
||||
src="<?= (!empty($data->logo)) ? base_url('assets/img/upload/' . $data->logo) : base_url('assets/img/system/no_img.jpg') ?>"
|
||||
alt="User profile picture">
|
||||
</div>
|
||||
<h3 class="profile-username text-center"><?= $data->name ?></h3>
|
||||
<p class="text-muted text-center"><?= $data->alias ?></p>
|
||||
<ul class="list-group list-group-unbordered mb-3">
|
||||
<li class="list-group-item">
|
||||
<b>Year</b> <a class="float-right"><?= $data->year ?></a>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<b>Version</b> <a class="float-right"><?= $data->version ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-9">
|
||||
<div class="card">
|
||||
<div class="card-header p-2">
|
||||
<ul class="nav nav-pills">
|
||||
<li class="nav-item"><a class="nav-link active" href="#detail"
|
||||
data-toggle="tab">Detail</a></li>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['company-profile[U]']))) : ?>
|
||||
<li class="nav-item"><a class="nav-link" href="#setting" data-toggle="tab">Setting</a>
|
||||
</li>
|
||||
<?php endif; ?>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="tab-content">
|
||||
<div class="active tab-pane" id="detail">
|
||||
<strong><i class="fas fa-building"></i> Company</strong>
|
||||
<p class="text-muted"><?= $data->company ?></p>
|
||||
<hr>
|
||||
<strong><i class="fas fa-map-marker-alt mr-1"></i> Address</strong>
|
||||
<p class="text-muted"><?= $data->address ?></p>
|
||||
<hr>
|
||||
<strong><i class="far fa-file-alt mr-1"></i> Description</strong>
|
||||
<p class="text-muted"><?= $data->description ?></p>
|
||||
<hr>
|
||||
<strong><i class="fas fa-globe"></i> Website</strong>
|
||||
<p class="text-muted"><?= $data->website ?></p>
|
||||
</div>
|
||||
<div class="tab-pane" id="setting">
|
||||
<div id="div-setting"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
echo "\nERROR: ",
|
||||
$heading,
|
||||
"\n\n",
|
||||
$message,
|
||||
"\n\n";
|
||||
@@ -0,0 +1,8 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
echo "\nDatabase error: ",
|
||||
$heading,
|
||||
"\n\n",
|
||||
$message,
|
||||
"\n\n";
|
||||
@@ -0,0 +1,21 @@
|
||||
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
|
||||
|
||||
An uncaught Exception was encountered
|
||||
|
||||
Type: <?php echo get_class($exception), "\n"; ?>
|
||||
Message: <?php echo $message, "\n"; ?>
|
||||
Filename: <?php echo $exception->getFile(), "\n"; ?>
|
||||
Line Number: <?php echo $exception->getLine(); ?>
|
||||
|
||||
<?php if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE === TRUE): ?>
|
||||
|
||||
Backtrace:
|
||||
<?php foreach ($exception->getTrace() as $error): ?>
|
||||
<?php if (isset($error['file']) && strpos($error['file'], realpath(BASEPATH)) !== 0): ?>
|
||||
File: <?php echo $error['file'], "\n"; ?>
|
||||
Line: <?php echo $error['line'], "\n"; ?>
|
||||
Function: <?php echo $error['function'], "\n\n"; ?>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
|
||||
<?php endif ?>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
echo "\nERROR: ",
|
||||
$heading,
|
||||
"\n\n",
|
||||
$message,
|
||||
"\n\n";
|
||||
@@ -0,0 +1,21 @@
|
||||
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
|
||||
|
||||
A PHP Error was encountered
|
||||
|
||||
Severity: <?php echo $severity, "\n"; ?>
|
||||
Message: <?php echo $message, "\n"; ?>
|
||||
Filename: <?php echo $filepath, "\n"; ?>
|
||||
Line Number: <?php echo $line; ?>
|
||||
|
||||
<?php if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE === TRUE): ?>
|
||||
|
||||
Backtrace:
|
||||
<?php foreach (debug_backtrace() as $error): ?>
|
||||
<?php if (isset($error['file']) && strpos($error['file'], realpath(BASEPATH)) !== 0): ?>
|
||||
File: <?php echo $error['file'], "\n"; ?>
|
||||
Line: <?php echo $error['line'], "\n"; ?>
|
||||
Function: <?php echo $error['function'], "\n\n"; ?>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
|
||||
<?php endif ?>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
?><!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>404 Page Not Found</title>
|
||||
<style type="text/css">
|
||||
|
||||
::selection { background-color: #E13300; color: white; }
|
||||
::-moz-selection { background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 12px 15px 12px 15px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<h1><?php echo $heading; ?></h1>
|
||||
<?php echo $message; ?>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
?><!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Database Error</title>
|
||||
<style type="text/css">
|
||||
|
||||
::selection { background-color: #E13300; color: white; }
|
||||
::-moz-selection { background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 12px 15px 12px 15px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<h1><?php echo $heading; ?></h1>
|
||||
<?php echo $message; ?>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
?>
|
||||
|
||||
<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>An uncaught Exception was encountered</h4>
|
||||
|
||||
<p>Type: <?php echo get_class($exception); ?></p>
|
||||
<p>Message: <?php echo $message; ?></p>
|
||||
<p>Filename: <?php echo $exception->getFile(); ?></p>
|
||||
<p>Line Number: <?php echo $exception->getLine(); ?></p>
|
||||
|
||||
<?php if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE === TRUE): ?>
|
||||
|
||||
<p>Backtrace:</p>
|
||||
<?php foreach ($exception->getTrace() as $error): ?>
|
||||
|
||||
<?php if (isset($error['file']) && strpos($error['file'], realpath(BASEPATH)) !== 0): ?>
|
||||
|
||||
<p style="margin-left:10px">
|
||||
File: <?php echo $error['file']; ?><br />
|
||||
Line: <?php echo $error['line']; ?><br />
|
||||
Function: <?php echo $error['function']; ?>
|
||||
</p>
|
||||
<?php endif ?>
|
||||
|
||||
<?php endforeach ?>
|
||||
|
||||
<?php endif ?>
|
||||
|
||||
</div>
|
||||
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
?><!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Error</title>
|
||||
<style type="text/css">
|
||||
|
||||
::selection { background-color: #E13300; color: white; }
|
||||
::-moz-selection { background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 12px 15px 12px 15px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<h1><?php echo $heading; ?></h1>
|
||||
<?php echo $message; ?>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
?>
|
||||
|
||||
<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: <?php echo $severity; ?></p>
|
||||
<p>Message: <?php echo $message; ?></p>
|
||||
<p>Filename: <?php echo $filepath; ?></p>
|
||||
<p>Line Number: <?php echo $line; ?></p>
|
||||
|
||||
<?php if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE === TRUE): ?>
|
||||
|
||||
<p>Backtrace:</p>
|
||||
<?php foreach (debug_backtrace() as $error): ?>
|
||||
|
||||
<?php if (isset($error['file']) && strpos($error['file'], realpath(BASEPATH)) !== 0): ?>
|
||||
|
||||
<p style="margin-left:10px">
|
||||
File: <?php echo $error['file'] ?><br />
|
||||
Line: <?php echo $error['line'] ?><br />
|
||||
Function: <?php echo $error['function'] ?>
|
||||
</p>
|
||||
|
||||
<?php endif ?>
|
||||
|
||||
<?php endforeach ?>
|
||||
|
||||
<?php endif ?>
|
||||
|
||||
</div>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,107 @@
|
||||
<?php
|
||||
$link = 'groupMenu/create';
|
||||
if (!$isNewRecord) {
|
||||
$link = 'groupMenu/update';
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="card card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">Create Menu</h3>
|
||||
</div>
|
||||
|
||||
<form class="form-horizontal" method="POST" action="<?php echo base_url($link); ?>">
|
||||
<div class="card-body">
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Nama</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control" id="name" name="name"
|
||||
value="<?= (!$isNewRecord) ? $data->name : '' ?>" placeholder="Group Menu">
|
||||
<input type="hidden" class="form-control" id="isNewRecord" name="isNewRecord"
|
||||
value="<?= (!$isNewRecord) ? 'false' : 'true' ?>" placeholder="Group Menu">
|
||||
<input type="hidden" class="form-control" id="typpositione" name="position"
|
||||
value="3" placeholder="position">
|
||||
<input type="hidden" class="form-control" id="id" name="id"
|
||||
value="<?= (!$isNewRecord) ? $data->id : '' ?>" placeholder="ID">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" style="padding: 12px">
|
||||
<div class="col-md-12">
|
||||
<div class="card card-outline card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">
|
||||
List Menu
|
||||
</h3>
|
||||
</div>
|
||||
<div class="card-body p-0">
|
||||
<div class="row" style="padding: 20px">
|
||||
<div style="overflow:auto;max-height:57vh; width: 100%">
|
||||
<table class="table table-hover">
|
||||
<?php foreach ($data_menu as $menu): ?>
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where parent_id = '" . $menu->id . "' ");
|
||||
$level_2 = $sql->result_array();
|
||||
?>
|
||||
<tr style="background-color:<?= (count($level_2) > 0) ? '#ff9999' : '' ?> ">
|
||||
<td><?= $menu->name ?></td>
|
||||
<?php foreach ($cruda as $ind => $val): ?>
|
||||
<td width="75px">
|
||||
<input class="checkbox-three" type="checkbox"
|
||||
name="MenuRoleForm[menus][]"
|
||||
value="<?= $menu->slug . '[' . $ind . ']' ?>" <?= isset($arr_menu[$menu->slug. '[' . $ind . ']']) ? 'checked' : '' ?>
|
||||
id="menu-<?= $menu->slug ?>[<?= $ind ?>]"> <?= $ind ?>
|
||||
</td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php foreach ($level_2 as $menu2): ?>
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where parent_id = '" . $menu2['id'] . "' ");
|
||||
$level_3 = $sql->result_array();
|
||||
?>
|
||||
<tr style="background-color:<?= (count($level_3) > 0) ? '#91e4e4' : '' ?> ">
|
||||
<td> <?= $menu2['name'] ?></td>
|
||||
<?php foreach ($cruda as $ind => $val): ?>
|
||||
<td width="75px">
|
||||
<input class="checkbox-three" type="checkbox"
|
||||
name="MenuRoleForm[menus][]"
|
||||
value="<?= $menu2['slug'] . '[' . $ind . ']' ?>" <?= isset($arr_menu[$menu2['slug'] . '[' . $ind . ']']) ? 'checked' : '' ?>
|
||||
id="menu-<?= $menu2['slug'] ?>[<?= $ind ?>]"> <?= $ind ?>
|
||||
</td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php foreach ($level_3 as $menu3): ?>
|
||||
<tr>
|
||||
<td>
|
||||
<?= $menu3['name'] ?></td>
|
||||
<?php foreach ($cruda as $ind => $val): ?>
|
||||
<td width="75px">
|
||||
<input class="checkbox-three" type="checkbox"
|
||||
name="MenuRoleForm[menus][]"
|
||||
value="<?= $menu3['slug'] . '[' . $ind . ']' ?>" <?= isset($arr_menu[$menu3['slug'] . '[' . $ind . ']']) ? 'checked' : '' ?>
|
||||
id="menu-<?= $menu3['slug'] ?>[<?= $ind ?>]"> <?= $ind ?>
|
||||
</td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
<?php endforeach; ?>
|
||||
<?php endforeach; ?>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-footer">
|
||||
<button type="submit"
|
||||
class="btn btn-info float-right"><?= ($isNewRecord) ? 'Create Group Menu' : 'Update Group Menu' ?></button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,81 @@
|
||||
<?php
|
||||
$cruda = ['C' => 'CREATE', 'R' => 'READ', 'U' => 'UPDATE', 'D' => 'DELETE', 'A' => 'APPROVAL'];
|
||||
?>
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3 class="card-title">List Group Menu</h3>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-header">
|
||||
<a href="<?= base_url('groupMenu/create') ?>" class="btn btn-success btn-sm float-right">Create Group Menu</a>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<?php if ($this->session->flashdata('success')): ?>
|
||||
<div class="alert alert-success" role="alert">
|
||||
<?php echo $this->session->flashdata('success'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if ($this->session->flashdata('failed')): ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<?php echo $this->session->flashdata('failed'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
<th>Child Menu</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($data as $item): ?>
|
||||
<tr>
|
||||
<td><?= $item['name'] ?></td>
|
||||
<td>
|
||||
<?php foreach ($item['details']['group'] as $group => $val): ?>
|
||||
<span class="badge badge-primary"><?= $group ?></span>
|
||||
<?php endforeach; ?>
|
||||
|
||||
<?php foreach ($item['details']['menu'] as $menu => $val): ?>
|
||||
<?php $lact = ""; ?>
|
||||
<?php foreach ($cruda as $act => $keterangan) : ?>
|
||||
<?php if (in_array($act, $val)) {
|
||||
$label = '';
|
||||
if ($act == 'C') {
|
||||
$label = 'success';
|
||||
} elseif ($act == 'R') {
|
||||
$label = 'info';
|
||||
} elseif ($act == 'U') {
|
||||
$label = 'warning';
|
||||
} elseif ($act == 'D') {
|
||||
$label = 'danger';
|
||||
} elseif ($act == 'A') {
|
||||
$label = 'primary';
|
||||
}
|
||||
|
||||
$lact .= '<span class="badge badge-' . $label . '">' . $act . '</span> ';
|
||||
} ?>
|
||||
|
||||
<?php endforeach; ?>
|
||||
<span class="badge badge-secondary"><?= $menu .' ' . $lact ?></span>
|
||||
<?php endforeach; ?>
|
||||
</td>
|
||||
<td>
|
||||
<a href="<?= base_url('groupMenu/update/' . encrypt_url($item['id'])) ?>"
|
||||
class="btn btn-info btn-xs"><i class="fas fa-edit"></i></a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,110 @@
|
||||
<?php
|
||||
$app = $this->db->query("select * from company_profile")->row();
|
||||
?>
|
||||
<footer class="main-footer">
|
||||
<strong>Copyright © <?= !empty($app->year) ? $app->year : '' ?> <a
|
||||
href="<?= !empty($app->website) ? $app->website : '#' ?>"><?= isset($app) ? $app->company : '' ?></a>.</strong>
|
||||
<div class="float-right d-none d-sm-inline-block">
|
||||
<?= !empty($app->version) ? '<b>Version </b>' . $app->version : '' ?>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
<!-- Control Sidebar -->
|
||||
<aside class="control-sidebar control-sidebar-dark">
|
||||
<!-- Control sidebar content goes here -->
|
||||
</aside>
|
||||
<!-- /.control-sidebar -->
|
||||
</div>
|
||||
<!-- ./wrapper -->
|
||||
|
||||
<!-- jQuery -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/jquery/jquery.min.js"></script>
|
||||
|
||||
<!-- jQuery UI 1.11.4 -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/jquery-ui/jquery-ui.min.js"></script>
|
||||
|
||||
<!-- Resolve conflict in jQuery UI tooltip with Bootstrap tooltip -->
|
||||
<script>
|
||||
$.widget.bridge('uibutton', $.ui.button)
|
||||
</script>
|
||||
<!-- Bootstrap 4 -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
|
||||
|
||||
<!-- ChartJS -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/chart.js/Chart.min.js"></script>
|
||||
|
||||
<!-- Sparkline -->
|
||||
<!--<script src="<?= base_url(); ?>assets/template/plugins/sparklines/sparkline.js"></script>-->
|
||||
<!-- JQVMap -->
|
||||
<!--<script src="<?= base_url(); ?>assets/template/plugins/jqvmap/jquery.vmap.min.js"></script>-->
|
||||
<!--<script src="<?= base_url(); ?>assets/template/plugins/jqvmap/maps/jquery.vmap.usa.js"></script>-->
|
||||
<!-- jQuery Knob Chart -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/jquery-knob/jquery.knob.min.js"></script>
|
||||
<!-- daterangepicker -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/moment/moment.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/daterangepicker/daterangepicker.js"></script>
|
||||
<!-- Tempusdominus Bootstrap 4 -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/tempusdominus-bootstrap-4/js/tempusdominus-bootstrap-4.min.js"></script>
|
||||
<!-- Summernote -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/summernote/summernote-bs4.min.js"></script>
|
||||
<!-- overlayScrollbars -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/overlayScrollbars/js/jquery.overlayScrollbars.min.js"></script>
|
||||
<!-- AdminLTE App -->
|
||||
<script src="<?= base_url(); ?>assets/template/dist/js/adminlte.js"></script>
|
||||
|
||||
<!--Internal Sweet-Alert js-->
|
||||
<script src="<?php echo base_url('assets/template/'); ?>plugins/sweet-alert/dist/js/sweetalert2.min.js"></script>
|
||||
|
||||
<!-- AdminLTE for demo purposes -->
|
||||
<!--<script src="--><? //= base_url(); ?><!--assets/template/dist/js/demo.js"></script>-->
|
||||
<!-- AdminLTE dashboard demo (This is only for demo purposes) -->
|
||||
<!--<script src="<?= base_url(); ?>assets/template/dist/js/pages/dashboard.js"></script>-->
|
||||
<!-- DataTables & Plugins -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables/jquery.dataTables.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-bs4/js/dataTables.bootstrap4.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-responsive/js/dataTables.responsive.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-responsive/js/responsive.bootstrap4.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-buttons/js/dataTables.buttons.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-buttons/js/buttons.bootstrap4.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/jszip/jszip.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/pdfmake/pdfmake.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/pdfmake/vfs_fonts.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-buttons/js/buttons.html5.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-buttons/js/buttons.print.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/datatables-buttons/js/buttons.colVis.min.js"></script>
|
||||
<!-- Select2 -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/select2/js/select2.full.min.js"></script>
|
||||
<!-- Bootstrap4 Duallistbox -->
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/bootstrap4-duallistbox/jquery.bootstrap-duallistbox.min.js"></script>
|
||||
|
||||
<script src="<?= base_url(); ?>assets/js_system/index.js">
|
||||
</script>
|
||||
|
||||
<?php if (isset($js_page)) { ?>
|
||||
<script src="<?= base_url('assets/js_system/') . $js_page ?>.js"></script>
|
||||
<?php } ?>
|
||||
|
||||
<script>
|
||||
var getUrl = window.location;
|
||||
var baseUrl = getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split('/')[1];
|
||||
|
||||
$(function () {
|
||||
$("#example1").DataTable({
|
||||
"responsive": true, "lengthChange": false, "autoWidth": false
|
||||
}).buttons().container().appendTo('#example1_wrapper .col-md-6:eq(0)');
|
||||
$('#example2').DataTable({
|
||||
"paging": true,
|
||||
"lengthChange": false,
|
||||
"searching": false,
|
||||
"ordering": true,
|
||||
"info": true,
|
||||
"autoWidth": false,
|
||||
"responsive": true,
|
||||
});
|
||||
|
||||
$('.select2').select2()
|
||||
});
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,59 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title><?= $title ?></title>
|
||||
|
||||
<!-- Google Font: Source Sans Pro -->
|
||||
<link rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700&display=fallback">
|
||||
<!-- Font Awesome -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/fontawesome-free/css/all.min.css"/>
|
||||
|
||||
<!-- Ionicons -->
|
||||
<link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
|
||||
<!-- Tempusdominus Bootstrap 4 -->
|
||||
<link rel="stylesheet"
|
||||
href="<?= base_url(); ?>assets/template/plugins/tempusdominus-bootstrap-4/css/tempusdominus-bootstrap-4.min.css"/>
|
||||
|
||||
<!-- Select2 -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/select2/css/select2.min.css">
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/select2-bootstrap4-theme/select2-bootstrap4.min.css">
|
||||
|
||||
<!-- iCheck -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/icheck-bootstrap/icheck-bootstrap.min.css"/>
|
||||
|
||||
<!-- JQVMap -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/jqvmap/jqvmap.min.css"/>
|
||||
|
||||
<!-- Theme style -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/dist/css/adminlte.min.css"/>
|
||||
|
||||
<!-- overlayScrollbars -->
|
||||
<link rel="stylesheet"
|
||||
href="<?= base_url(); ?>assets/template/plugins/overlayScrollbars/css/OverlayScrollbars.min.css"/>
|
||||
|
||||
<!-- Daterange picker -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/daterangepicker/daterangepicker.css"/>
|
||||
|
||||
<!-- summernote -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/summernote/summernote-bs4.min.css"/>
|
||||
|
||||
<!-- DataTables -->
|
||||
<link rel="stylesheet"
|
||||
href="<?= base_url(); ?>assets/template/plugins/datatables-bs4/css/dataTables.bootstrap4.min.css"/>
|
||||
<link rel="stylesheet"
|
||||
href="<?= base_url(); ?>assets/template/plugins/datatables-responsive/css/responsive.bootstrap4.min.css"/>
|
||||
<link rel="stylesheet"
|
||||
href="<?= base_url(); ?>assets/template/plugins/datatables-buttons/css/buttons.bootstrap4.min.css"/>
|
||||
|
||||
<!-- Bootstrap4 Duallistbox -->
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/bootstrap4-duallistbox/bootstrap-duallistbox.min.css">
|
||||
|
||||
<!--- Internal Sweet-Alert css-->
|
||||
<link href="<?php echo base_url('assets/template/'); ?>plugins/sweet-alert/dist/css/sweetalert2.css"
|
||||
rel="stylesheet">
|
||||
</head>
|
||||
<body class="layout-footer-fixed layout-navbar-fixed">
|
||||
<div class="wrapper">
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php $this->load->view("layouts/main_header"); ?>
|
||||
<?php $this->load->view("layouts/main_nav"); ?>
|
||||
<?php $this->load->view("layouts/main_left"); ?>
|
||||
<!-- Content Wrapper. Contains page content -->
|
||||
<div class="content-wrapper">
|
||||
<section class="content-header">
|
||||
<div class="container-fluid">
|
||||
<div class="row mb-2">
|
||||
<div class="col-sm-6">
|
||||
<h1><?= $title ?></h1>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<ol class="breadcrumb float-sm-right">
|
||||
<li class="breadcrumb-item"><a href="<?= base_url(); ?>">Home</a></li>
|
||||
<?php foreach ($breadcrumbs as $item) : ?>
|
||||
<li class="breadcrumb-item <?= isset($item['active']) ? $item['active'] : '' ?>">
|
||||
<?= (isset($item['url']) ? '<a href="' . $item['url'] . '">' : '') ?>
|
||||
<?= $item['label'] ?>
|
||||
<?= (isset($item['url']) ? '</a>' : '') ?>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.container-fluid -->
|
||||
</section>
|
||||
|
||||
<section class="content">
|
||||
<div class="container-fluid">
|
||||
<?php $this->load->view($main_content); ?>
|
||||
</div><!-- /.container-fluid -->
|
||||
</section>
|
||||
<!-- /.content -->
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<?php $this->load->view("layouts/main_footer"); ?>
|
||||
@@ -0,0 +1,103 @@
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where type = 1 and level = 1");
|
||||
$menu_left_level_1 = $sql->result_array();
|
||||
|
||||
$app = $this->db->query("select * from company_profile")->row();
|
||||
|
||||
?>
|
||||
|
||||
<!-- Main Sidebar Container -->
|
||||
<aside class="main-sidebar sidebar-dark-primary elevation-4">
|
||||
<!-- Brand Logo -->
|
||||
<a href="<?= base_url() ?>" class="brand-link">
|
||||
<?php if (!empty($app->logo)): ?>
|
||||
<img src="<?= base_url('assets/img/upload/' . $app->logo); ?>" alt="AdminLTE Logo"
|
||||
class="brand-image img-circle elevation-3" style="opacity: .8">
|
||||
<?php endif; ?>
|
||||
<span class="brand-text font-weight-light"><?= isset($app) ? $app->name : '' ?></span>
|
||||
</a>
|
||||
|
||||
<!-- Sidebar -->
|
||||
<div class="sidebar">
|
||||
<!-- Sidebar user panel (optional) -->
|
||||
<div class="user-panel mt-3 pb-3 mb-3 d-flex">
|
||||
<div class="image">
|
||||
<img src="<?= (!empty($this->session->userdata('foto'))) ? base_url('assets/img/upload/'. $this->session->userdata('foto')) : base_url('assets/img/system/no_person.jpg') ?>" class="img-circle elevation-2"
|
||||
alt="User Image">
|
||||
</div>
|
||||
<div class="info">
|
||||
<a href="<?= base_url() ?>" class="d-block"><?= $this->session->userdata('name') ?></a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Sidebar Menu -->
|
||||
<nav class="mt-2">
|
||||
<ul class="nav nav-pills nav-sidebar flex-column" data-widget="treeview" role="menu" data-accordion="false">
|
||||
<li class="nav-header">MENU UTAMA</li>
|
||||
|
||||
<?php if ($menu_left_level_1 > 0): ?>
|
||||
<?php foreach ($menu_left_level_1 as $level_1): ?>
|
||||
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where type = 1 and level = 2 and parent_id = '" . $level_1['id'] . "' ");
|
||||
$menu_left_level_2 = $sql->result_array();
|
||||
?>
|
||||
|
||||
<li class="nav-item">
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')[$level_1['slug'] . '[R]']))) : ?>
|
||||
<a href="<?= base_url($level_1['link']) ?>" class="nav-link">
|
||||
<?php if (!empty($level_1['icon'])) : ?>
|
||||
<i class="nav-icon <?= $level_1['icon'] ?> nav-icon"></i>
|
||||
<?php endif; ?>
|
||||
<p>
|
||||
<?= $level_1['name'] ?>
|
||||
<?php if (!empty($menu_left_level_2)): ?>
|
||||
<i class="fas fa-angle-left right"></i>
|
||||
<?php endif; ?>
|
||||
</p>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if (!empty($menu_left_level_2)): ?>
|
||||
<ul class="nav nav-treeview">
|
||||
<?php foreach ($menu_left_level_2 as $level_2):
|
||||
$sql = $this->db->query("select * from menu where type = 1 and level = 3 and parent_id = '" . $level_2['id'] . "' ");
|
||||
$menu_left_level_3 = $sql->result_array();
|
||||
?>
|
||||
<li class="nav-item">
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')[$level_2['slug'] . '[R]']))) : ?>
|
||||
<a href="<?= $level_2['link'] ?>" class="nav-link">
|
||||
<i class="far fa-circle nav-icon"></i>
|
||||
<p><?= $level_2['name'] ?></p>
|
||||
<?php if (!empty($menu_left_level_3)): ?>
|
||||
<i class="right fas fa-angle-left"></i>
|
||||
<?php endif; ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php if (!empty($menu_left_level_3)): ?>
|
||||
<ul class="nav nav-treeview">
|
||||
<?php foreach ($menu_left_level_3 as $level_3): ?>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')[$level_3['slug'] . '[R]']))) : ?>
|
||||
<li class="nav-item">
|
||||
<a href="<?= $level_3['link'] ?>" class="nav-link">
|
||||
<i class="far fa-dot-circle nav-icon"></i>
|
||||
<p><?= $level_3['name'] ?></p>
|
||||
</a>
|
||||
</li>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
</li>
|
||||
|
||||
<?php endforeach; ?>
|
||||
<?php endif; ?>
|
||||
</ul>
|
||||
</nav>
|
||||
<!-- /.sidebar-menu -->
|
||||
</div>
|
||||
<!-- /.sidebar -->
|
||||
</aside>
|
||||
@@ -0,0 +1,89 @@
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where type = 2 and level = 1");
|
||||
$menu_top_level_1 = $sql->result_array();
|
||||
|
||||
?>
|
||||
<!-- Navbar -->
|
||||
<nav class="main-header navbar navbar-expand navbar-white navbar-light">
|
||||
<!-- Left navbar links -->
|
||||
<ul class="navbar-nav">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" data-widget="pushmenu" href="#" role="button"><i class="fas fa-bars"></i></a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<ul class="navbar-nav ml-auto">
|
||||
<?php if ($this->session->userdata('switch')): ?>
|
||||
<li class="nav-item d-none d-sm-inline-block">
|
||||
<a href="javascript:void(0)" data-id="<?= $this->session->userdata('user_initial')['id'] ?>"
|
||||
class="nav-link btn-block btn-outline-danger btn-switch-admin"><i class="fas fa-random"></i>
|
||||
<?= $this->session->userdata('user_initial')['name'] ?></a>
|
||||
</li>
|
||||
<?php endif; ?>
|
||||
<!-- Menu TOP -->
|
||||
<?php if ($menu_top_level_1 > 0) : ?>
|
||||
<?php foreach ($menu_top_level_1 as $level_1) : ?>
|
||||
<li class="nav-item dropdown">
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')[$level_1['slug'] . '[R]']))) : ?>
|
||||
<a class="nav-link" data-toggle="dropdown" href="#">
|
||||
<?php if (!empty($level_1['icon'])) : ?>
|
||||
<i class="<?= $level_1['icon'] ?>"></i>
|
||||
<?php endif; ?>
|
||||
|
||||
<?= $level_1['name'] ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where type = 2 and level = 2 and parent_id = '" . $level_1['id'] . "' ");
|
||||
$menu_top_level_2 = $sql->result_array();
|
||||
?>
|
||||
<?php if ($menu_top_level_2 > 0) : ?>
|
||||
<div class="dropdown-menu dropdown-menu-lg dropdown-menu-right">
|
||||
<span class="dropdown-item dropdown-header"><?= $level_1['name'] ?></span>
|
||||
<?php foreach ($menu_top_level_2 as $level_2) : ?>
|
||||
<div class="dropdown-divider"></div>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')[$level_2['slug'] . '[R]']))) : ?>
|
||||
<a href="<?= base_url() . $level_2['link'] ?>" class="dropdown-item">
|
||||
<?php if (!empty($level_2['icon'])) : ?>
|
||||
<i class="<?= $level_2['icon'] ?>"></i>
|
||||
<?php endif; ?>
|
||||
<?= $level_2['name'] ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<li class="nav-item dropdown">
|
||||
<a class="nav-link" data-toggle="dropdown" href="#">
|
||||
<i class="fas fa-user"></i> <?= $this->session->userdata('name') ?>
|
||||
</a>
|
||||
<div class="dropdown-menu dropdown-menu-lg dropdown-menu-right">
|
||||
<div class="user-panel-admin mt-3 pb-3 mb-3 d-flex " style="justify-content: center">
|
||||
<div class="image">
|
||||
<img src="<?= (!empty($this->session->userdata('foto'))) ? base_url('assets/img/upload/'. $this->session->userdata('foto')) : base_url('assets/img/system/no_person.jpg') ?>"
|
||||
class="img-circle elevation-2" alt="User Image" style="width: 100px">
|
||||
</div>
|
||||
</div>
|
||||
<p style="text-align: center; padding-bottom: 10px"><?= $this->session->userdata('name') ?></p>
|
||||
<div class="dropdown-divider"></div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<a href="<?php echo base_url('profile/view/' . encrypt_url($this->session->userdata('id'))) ?>"
|
||||
class="dropdown-item dropdown-footer"> Profile</a>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<a href="<?php echo base_url('site/logout') ?>" class="dropdown-item dropdown-footer"> Log
|
||||
Out</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
<!-- /.navbar -->
|
||||
@@ -0,0 +1,117 @@
|
||||
<?php
|
||||
$link = 'menu/create';
|
||||
if (!$isNewRecord) {
|
||||
$link = 'menu/update';
|
||||
}
|
||||
?>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="card card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">Create Menu</h3>
|
||||
</div>
|
||||
<form class="form-horizontal" method="POST" action="<?php echo base_url($link); ?>"
|
||||
enctype="multipart/form-data">
|
||||
<div class="card-body">
|
||||
<input type="hidden" class="form-control" id="id" name="id"
|
||||
value="<?= (!$isNewRecord) ? $data->id : '' ?>" placeholder="ID">
|
||||
<input type="hidden" class="form-control" id="isNewRecord" name="isNewRecord"
|
||||
value="<?= (!$isNewRecord) ? 'false' : 'true' ?>" placeholder="isNewRecord">
|
||||
|
||||
<input type="hidden" class="form-control" id="level" name="level"
|
||||
value="<?= (!$isNewRecord) ? $data->level : '' ?>" placeholder="Level">
|
||||
|
||||
<input type="hidden" class="form-control" id="parent_1" name="parent_1"
|
||||
value="<?= (!$isNewRecord) ? $parent[1] : '' ?>" placeholder="Parent 1">
|
||||
|
||||
<input type="hidden" class="form-control" id="parent_2" name="parent_2"
|
||||
value="<?= (!$isNewRecord) ? $parent[2] : '' ?>" placeholder="Parent 2">
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Nama</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control" id="name" name="name"
|
||||
value="<?= (!$isNewRecord) ? $data->name : '' ?>" placeholder="Nama Menu">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_link" class="col-sm-2 col-form-label">Link</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="text" class="form-control" id="link" name="link"
|
||||
value="<?= (!$isNewRecord) ? $data->link : '' ?>"
|
||||
placeholder="Link / Function Controller">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_icon" class="col-sm-2 col-form-label">Icon</label>
|
||||
<div class="col-sm-3">
|
||||
<input type="text" class="form-control" id="icon" name="icon"
|
||||
value="<?= (!$isNewRecord) ? $data->icon : '' ?>" placeholder="Icon">
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
<a href="https://fontawesome.com/v5/search" class="btn btn-default btn-sm" target="_blank">
|
||||
<i class="fab fa-font-awesome"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_position" class="col-sm-2 col-form-label">Position</label>
|
||||
<div class="col-sm-3">
|
||||
<div class="form-group">
|
||||
<select class="form-control select2" id="position" name="position" style="width: 100%;">
|
||||
<?php if ($isNewRecord) : ?>
|
||||
<option value="">-- Select Positon --</option>
|
||||
<option value="1">Left</option>
|
||||
<option value="2">Top</option>
|
||||
<?php else: ?>
|
||||
<option value="1"
|
||||
selected=<?= ($data->type == 1) ? '"' . 'selected' . '"' : '' ?>>Left
|
||||
</option>
|
||||
<option value="2"
|
||||
selected=<?= ($data->type == 2) ? '"' . 'selected' . '"' : '' ?>>Top
|
||||
</option>
|
||||
<?php endif; ?>
|
||||
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_urutan" class="col-sm-2 col-form-label">Urutan</label>
|
||||
<div class="col-sm-1">
|
||||
<input type="text" class="form-control" id="urutan" name="urutan"
|
||||
value="<?= (!$isNewRecord) ? $data->urutan : '' ?>" placeholder="Urutan">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_parent" class="col-sm-2 col-form-label">Parent</label>
|
||||
<div class="col-sm-3">
|
||||
<div class="form-group">
|
||||
<select class="form-control select2" id="level_1" name="level_1" style="width: 100%;">
|
||||
<option value="">-- Select Level 1 --</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
<div class="form-group">
|
||||
<select class="form-control select2" id="level_2" name="level_2" style="width: 100%;">
|
||||
<option value="">-- Select Level 2 --</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-footer">
|
||||
<button type="submit" class="btn btn-info float-right"><?= ($isNewRecord) ? 'Create Menu' : 'Update Menu' ?></button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,62 @@
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3 class="card-title">List Menu</h3>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-header">
|
||||
<a href="<?= base_url('menu/create') ?>" class="btn btn-success btn-sm float-right">Create Menu</a>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<?php if ($this->session->flashdata('success')): ?>
|
||||
<div class="alert alert-success" role="alert">
|
||||
<?php echo $this->session->flashdata('success'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if ($this->session->flashdata('failed')): ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<?php echo $this->session->flashdata('failed'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
<th>Position</th>
|
||||
<th>Level</th>
|
||||
<th>Urutan</th>
|
||||
<th>Link</th>
|
||||
<th>Icon</th>
|
||||
<th>Parent</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($data as $item): ?>
|
||||
<tr>
|
||||
<td><?= $item->name ?></td>
|
||||
<td><?= ($item->type == 1) ? 'Left' : 'Top' ?></td>
|
||||
<td><?= $item->level ?></td>
|
||||
<td><?= $item->urutan ?></td>
|
||||
<td><?= $item->link ?></td>
|
||||
<td><?= $item->icon ?></td>
|
||||
<td><?= $item->parent ?></td>
|
||||
<td>
|
||||
<a href="<?= base_url('menu/update/' . encrypt_url($item->id)) ?>"
|
||||
class="btn btn-info btn-xs"><i class="fas fa-edit"></i></a>
|
||||
<a href="<?= base_url('menu/delete/' . encrypt_url($item->id)) ?>"
|
||||
class="btn btn-danger btn-xs"><i class="fas fa-trash-alt"></i></a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,143 @@
|
||||
<?php
|
||||
$link = 'profile/create';
|
||||
if (!$isNewRecord) {
|
||||
$link = 'profile/update';
|
||||
}
|
||||
$key = 'secret-key-in-config';
|
||||
|
||||
?>
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="card card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">Create Menu</h3>
|
||||
</div>
|
||||
<form class="form-horizontal" method="POST" action="<?php echo base_url($link); ?>"
|
||||
enctype="multipart/form-data">
|
||||
|
||||
<div class="row" style="padding: 12px">
|
||||
<div class="col-md-12">
|
||||
<div class="card card-outline card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">
|
||||
Akun User
|
||||
</h3>
|
||||
</div>
|
||||
<div class="card-body p-0">
|
||||
<div class="row" style="padding: 20px">
|
||||
<div style="width: 100%">
|
||||
<div class="form-group row">
|
||||
<label for="input_username" class="col-sm-2 col-form-label">Username</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" id="username"
|
||||
name="User[username]"
|
||||
value="<?= (!$isNewRecord) ? $data->username : '' ?>"
|
||||
placeholder="Username" <?= (!$isNewRecord) ? 'readOnly' : '' ?> >
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php if ($isNewRecord): ?>
|
||||
<div class="form-group row">
|
||||
<label for="input_password"
|
||||
class="col-sm-2 col-form-label">Password</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="password" class="form-control" id="password"
|
||||
name="User[password]"
|
||||
value="<?= (!$isNewRecord) ? $data->password : '' ?>"
|
||||
placeholder="Password">
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr/>
|
||||
|
||||
<div class="card-body">
|
||||
<!-- HIDDEN FORM -->
|
||||
<div class="form-group row">
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="hidden" class="form-control" id="isNewRecord" name="isNewRecord"
|
||||
value="<?= (!$isNewRecord) ? 'false' : 'true' ?>"
|
||||
placeholder="isNewRecord">
|
||||
|
||||
<input type="hidden" class="form-control" id="user_id" name="user_id"
|
||||
value="<?= (!$isNewRecord) ? $data->user_id : '' ?>"
|
||||
placeholder="User ID">
|
||||
</div>
|
||||
</div>
|
||||
<!-- HIDDEN FORM -->
|
||||
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Name</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="text" class="form-control" id="name" name="name"
|
||||
value="<?= (!$isNewRecord) ? $data->name : '' ?>"
|
||||
placeholder="Name">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_email" class="col-sm-2 col-form-label">Email</label>
|
||||
<div class="col-sm-7">
|
||||
<input type="email" class="form-control" id="email" name="email"
|
||||
value="<?= (!$isNewRecord) ? $data->email : '' ?>"
|
||||
placeholder="Email">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_phone" class="col-sm-2 col-form-label">Phone</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="number" class="form-control" id="phone" name="phone"
|
||||
value="<?= (!$isNewRecord) ? $data->phone : '' ?>"
|
||||
placeholder="Phone">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_parent" class="col-sm-2 col-form-label">Typeuser</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="form-group">
|
||||
<select class="form-control select2" id="typeuser_id" name="typeuser_id"
|
||||
style="width: 100%;">
|
||||
<?php if ($isNewRecord) : ?>
|
||||
<option value="">-- Select Typeuser --</option>
|
||||
<?php endif; ?>
|
||||
<?php foreach ($typeuser as $item): ?>
|
||||
<option value="<?= $item->id ?>" <?= (!$isNewRecord) ? $item->id == $data->typeuser_id ? "Selected" : "" : '' ?>><?= $item->value ?></option>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_foto" class="col-sm-2 col-form-label">Foto</label>
|
||||
<div class="col-sm-7">
|
||||
<input type="file" class="form-control" id="foto" name="foto" placeholder="Foto">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="card-footer">
|
||||
<button type="submit"
|
||||
class="btn btn-info float-right"><?= ($isNewRecord) ? 'Create Profile' : 'Update Profile' ?></button>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,48 @@
|
||||
<div class="modal fade" id="modal-reset">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h4 class="modal-title">Reset Password</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<form id="form-reset" autocomplete="off">
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="password" class="col-sm-2 col-form-label">Password</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="password" class="form-control" id="password" name="password"
|
||||
placeholder="New Password">
|
||||
<input type="hidden" class="form-control" id="user_id" name="user_id"
|
||||
value="<?= $user_id ?>"
|
||||
placeholder="User ID">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
</div>
|
||||
<div class="modal-footer justify-content-between">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
|
||||
<button type="button" class="btn btn-primary" id="btn-reset-password">Reset</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$("body").off("click", "#btn-reset-password").on("click", "#btn-reset-password", function (e) {
|
||||
var data = $('#form-reset').serializeArray();
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: baseUrl + '/profile/reset_password',
|
||||
data: data,
|
||||
cache: false,
|
||||
dataType: 'json',
|
||||
success: function (data) {
|
||||
location.reload();
|
||||
},
|
||||
error: function (XMLHttpRequest, textStatus, errorThrown) {
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@@ -0,0 +1,84 @@
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3 class="card-title">List Profile</h3>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-header">
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['profile[C]']))) : ?>
|
||||
<a href="<?= base_url('profile/create') ?>" class="btn btn-success btn-sm float-right">Create Profile</a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<?php if ($this->session->flashdata('success')): ?>
|
||||
<div class="alert alert-success" role="alert">
|
||||
<?php echo $this->session->flashdata('success'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if ($this->session->flashdata('failed')): ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<?php echo $this->session->flashdata('failed'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
<th>Username</th>
|
||||
<th>Email</th>
|
||||
<th>Typeuser</th>
|
||||
<th>Status</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php if (!empty($data)): ?>
|
||||
<?php foreach ($data as $item) : ?>
|
||||
<tr>
|
||||
<td><?= $item['name'] ?></td>
|
||||
<td><?= $item['username'] ?></td>
|
||||
<td><?= $item['email'] ?></td>
|
||||
<td><?= $item['typeuser'] ?></td>
|
||||
<td>
|
||||
<?php if ($item['status'] == 1): ?>
|
||||
<span class="right badge badge-success">Active</span>
|
||||
<?php else: ?>
|
||||
<span class="right badge badge-danger">Blocked</span>
|
||||
<?php endif; ?>
|
||||
|
||||
</td>
|
||||
<td>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['profile[R]']))) : ?>
|
||||
<a href="<?= base_url('profile/view/' . encrypt_url($item['user_id'])) ?>"
|
||||
class="btn btn-warning btn-xs"><i class="fas fa-eye"></i></a>
|
||||
<?php endif; ?>
|
||||
<?php if ($item['status'] == 1) : ?>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['profile[U]']))) : ?>
|
||||
<a href="<?= base_url('profile/update/' . encrypt_url($item['user_id'])) ?>"
|
||||
class="btn btn-info btn-xs"><i class="fas fa-edit"></i></a>
|
||||
<?php endif; ?>
|
||||
<?php if ($item['typeuser_id'] != 1) : ?>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['profile[D]']))) : ?>
|
||||
<a href="<?= base_url('profile/blocked/' . encrypt_url($item['user_id'])) ?>"
|
||||
class="btn btn-danger btn-xs"><i class="fas fa-ban"> Block</i></a>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
<?php else: ?>
|
||||
<tr>
|
||||
<td colspan="6" style="text-align: center; font-style: italic">Data is empty!</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,57 @@
|
||||
<section class="content">
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<div class="card card-primary card-outline">
|
||||
<div class="card-body box-profile">
|
||||
<div class="text-center">
|
||||
<img class="profile-user-img img-fluid img-circle"
|
||||
src="<?= (!empty($data->foto)) ? base_url('assets/img/upload/' . $data->foto) : base_url('assets/img/system/no_img.jpg') ?>"
|
||||
alt="User profile picture">
|
||||
</div>
|
||||
<h3 class="profile-username text-center"><?= $data->name ?></h3>
|
||||
<p class="text-muted text-center"><?= $data->typeuser ?></p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-9">
|
||||
<div class="card">
|
||||
<div class="card-header p-2">
|
||||
<ul class="nav nav-pills">
|
||||
<li class="nav-item"><a class="nav-link active" href="#detail"
|
||||
data-toggle="tab">Detail</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="tab-content">
|
||||
<div class="active tab-pane" id="detail">
|
||||
<strong><i class="fas fa-user-check"></i> Username</strong>
|
||||
<p class="text-muted"><?= $data->username ?></p>
|
||||
<hr>
|
||||
<strong><i class="fas fa-envelope"></i> Email</strong>
|
||||
<p class="text-muted"><?= $data->email ?></p>
|
||||
<hr>
|
||||
<strong><i class="fas fa-phone-square"></i> Phone</strong>
|
||||
<p class="text-muted"><?= $data->phone ?></p>
|
||||
<hr>
|
||||
<strong><i class="fas fa-toggle-on"></i> Status</strong>
|
||||
<p class="text-muted">
|
||||
<?php if ($data->status == 1): ?>
|
||||
<span class="right badge badge-success">Active</span>
|
||||
<?php else: ?>
|
||||
<span class="right badge badge-danger">Blocked</span>
|
||||
<?php endif; ?>
|
||||
</p>
|
||||
<hr>
|
||||
</div>
|
||||
<div class="tab-pane" id="setting">
|
||||
<div id="div-setting"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,148 @@
|
||||
<?php
|
||||
$link = 'role/create';
|
||||
if (!$isNewRecord) {
|
||||
$link = 'role/update';
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="card card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">Create Menu</h3>
|
||||
</div>
|
||||
|
||||
<form class="form-horizontal" method="POST" action="<?php echo base_url($link); ?>">
|
||||
<div class="card-body">
|
||||
<div class="col-md-6">
|
||||
<table class="table">
|
||||
<tr>
|
||||
<th width="200px">Nama</th>
|
||||
<th width="2px">:</th>
|
||||
<td><?= $model->name ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th width="200px">Username</th>
|
||||
<th width="2px">:</th>
|
||||
<td><?= $model->username ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th width="200px">Typeuser</th>
|
||||
<th width="2px">:</th>
|
||||
<td><?= $model->typeuser ?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<div class="col-sm-4">
|
||||
<input type="hidden" class="form-control" id="isNewRecord" name="isNewRecord"
|
||||
value="<?= (!$isNewRecord) ? 'false' : 'true' ?>" placeholder="Group Menu">
|
||||
<input type="hidden" class="form-control" id="user_id" name="user_id"
|
||||
value="<?= $user_id ?>" placeholder="User ID">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" style="padding: 12px">
|
||||
<div class="col-md-4">
|
||||
<div class="card card-outline card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">
|
||||
Group Menu
|
||||
</h3>
|
||||
</div>
|
||||
<div class="card-body p-0">
|
||||
<div class="row" style="padding: 20px">
|
||||
<table class="table">
|
||||
<?php foreach ($group_menu as $item): ?>
|
||||
<tr>
|
||||
<td width="100px">
|
||||
<input class="checkbox-three" type="checkbox"
|
||||
name="MenuRoleForm[groupmenus][]"
|
||||
value="<?= $item['slug'] ?>" <?= isset($arr_group[$item['slug']]) ? 'checked' : '' ?>
|
||||
id="gmenu-<?= $item['slug'] ?>">
|
||||
<?= $item['name'] ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<div class="card card-outline card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">
|
||||
List Menu
|
||||
</h3>
|
||||
</div>
|
||||
<div class="card-body p-0">
|
||||
<div class="row" style="padding: 20px">
|
||||
<div style="overflow:auto;max-height:57vh; width: 100%">
|
||||
<table class="table table-hover">
|
||||
<?php foreach ($data_menu as $menu): ?>
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where parent_id = '" . $menu->id . "' ");
|
||||
$level_2 = $sql->result_array();
|
||||
?>
|
||||
<tr style="background-color:<?= (count($level_2) > 0) ? '#ff9999' : '' ?> ">
|
||||
<td><?= $menu->name ?></td>
|
||||
<?php foreach ($cruda as $ind => $val): ?>
|
||||
<td width="75px">
|
||||
<input class="checkbox-three" type="checkbox"
|
||||
name="MenuRoleForm[menus][]"
|
||||
value="<?= $menu->slug . '[' . $ind . ']' ?>" <?= isset($arr_menu[$menu->slug. '[' . $ind . ']']) ? 'checked' : '' ?>
|
||||
id="menu-<?= $menu->slug ?>[<?= $ind ?>]"> <?= $ind ?>
|
||||
</td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php foreach ($level_2 as $menu2): ?>
|
||||
<?php
|
||||
$sql = $this->db->query("select * from menu where parent_id = '" . $menu2['id'] . "' ");
|
||||
$level_3 = $sql->result_array();
|
||||
?>
|
||||
<tr style="background-color:<?= (count($level_3) > 0) ? '#91e4e4' : '' ?> ">
|
||||
<td> <?= $menu2['name'] ?></td>
|
||||
<?php foreach ($cruda as $ind => $val): ?>
|
||||
<td width="75px">
|
||||
<input class="checkbox-three" type="checkbox"
|
||||
name="MenuRoleForm[menus][]"
|
||||
value="<?= $menu2['slug'] . '[' . $ind . ']' ?>" <?= isset($arr_menu[$menu2['slug'] . '[' . $ind . ']']) ? 'checked' : '' ?>
|
||||
id="menu-<?= $menu2['slug'] ?>[<?= $ind ?>]"> <?= $ind ?>
|
||||
</td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php foreach ($level_3 as $menu3): ?>
|
||||
<tr>
|
||||
<td>
|
||||
<?= $menu3['name'] ?></td>
|
||||
<?php foreach ($cruda as $ind => $val): ?>
|
||||
<td width="75px">
|
||||
<input class="checkbox-three" type="checkbox"
|
||||
name="MenuRoleForm[menus][]"
|
||||
value="<?= $menu3['slug'] . '[' . $ind . ']' ?>" <?= isset($arr_menu[$menu3['slug'] . '[' . $ind . ']']) ? 'checked' : '' ?>
|
||||
id="menu-<?= $menu3['slug'] ?>[<?= $ind ?>]"> <?= $ind ?>
|
||||
</td>
|
||||
<?php endforeach; ?>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
<?php endforeach; ?>
|
||||
<?php endforeach; ?>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-footer">
|
||||
<button type="submit"
|
||||
class="btn btn-info float-right"><?= ($isNewRecord) ? 'Create Group Menu' : 'Update Role' ?></button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,89 @@
|
||||
<?php
|
||||
$cruda = ['C' => 'CREATE', 'R' => 'READ', 'U' => 'UPDATE', 'D' => 'DELETE', 'A' => 'APPROVAL'];
|
||||
?>
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3 class="card-title">Role Access User</h3>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-body">
|
||||
<?php if ($this->session->flashdata('success')): ?>
|
||||
<div class="alert alert-success" role="alert">
|
||||
<?php echo $this->session->flashdata('success'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if ($this->session->flashdata('failed')): ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<?php echo $this->session->flashdata('failed'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Username</th>
|
||||
<th>Name</th>
|
||||
<th>Menu Access</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($model as $item): ?>
|
||||
<tr>
|
||||
<td>
|
||||
<a href="<?= base_url('profile/view/' . encrypt_url($item['user_id'])) ?>"><?= $item['username'] ?></a>
|
||||
</td>
|
||||
<td>
|
||||
<?= $item['name'] ?> <br>
|
||||
<i class="text-muted" style="font-size:11px"><?= $item['typeuser'] ?></i>
|
||||
</td>
|
||||
<td>
|
||||
<?php foreach ($item['details']['group'] as $group => $val): ?>
|
||||
<span class="badge badge-primary"><?= $val ?></span>
|
||||
<?php endforeach; ?>
|
||||
|
||||
<?php foreach ($item['details']['menu'] as $menu => $val): ?>
|
||||
<?php $lact = ""; ?>
|
||||
<?php foreach ($cruda as $act => $keterangan) : ?>
|
||||
<?php if (in_array($act, $val)) {
|
||||
$label = '';
|
||||
if ($act == 'C') {
|
||||
$label = 'success';
|
||||
} elseif ($act == 'R') {
|
||||
$label = 'info';
|
||||
} elseif ($act == 'U') {
|
||||
$label = 'warning';
|
||||
} elseif ($act == 'D') {
|
||||
$label = 'danger';
|
||||
} elseif ($act == 'A') {
|
||||
$label = 'primary';
|
||||
}
|
||||
|
||||
$lact .= '<span class="badge badge-' . $label . '">' . $act . '</span> ';
|
||||
} ?>
|
||||
|
||||
<?php endforeach; ?>
|
||||
<span class="badge badge-secondary"><?= $menu . ' ' . $lact ?></span>
|
||||
<?php endforeach; ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php if ($item['typeuser_id'] != 1): ?>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['role[R]']))) : ?>
|
||||
<a href="<?= base_url('role/update/' . encrypt_url($item['user_id'])) ?>"
|
||||
class="btn btn-info btn-xs"><i class="fas fa-edit"></i></a>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1 @@
|
||||
INI DASHBOARD
|
||||
@@ -0,0 +1,78 @@
|
||||
<?php
|
||||
$app = $this->db->query("select * from company_profile")->row();
|
||||
$link = 'site/login';
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title><?= isset($app) ? $app->name : '' ?> | Log in</title>
|
||||
|
||||
<link rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700&display=fallback">
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/fontawesome-free/css/all.min.css"/>
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/plugins/icheck-bootstrap/icheck-bootstrap.min.css"/>
|
||||
<link rel="stylesheet" href="<?= base_url(); ?>assets/template/dist/css/adminlte.min.css"/>
|
||||
|
||||
</head>
|
||||
<body class="hold-transition login-page">
|
||||
<div class="login-box">
|
||||
<div class="login-logo">
|
||||
<p><b><?= isset($app) ? $app->name : '' ?></b></p>
|
||||
</div>
|
||||
<div class="card">
|
||||
<div class="card-body login-card-body">
|
||||
<p class="login-box-msg">Sign in to start your session</p>
|
||||
|
||||
<form class="form-horizontal" method="POST" action="<?php echo base_url($link); ?>"
|
||||
enctype="multipart/form-data">
|
||||
<div class="input-group mb-3">
|
||||
<input type="text" class="form-control" placeholder="Username" id="username" name="username">
|
||||
<div class="input-group-append">
|
||||
<div class="input-group-text">
|
||||
<span class="fas fa-envelope"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="input-group mb-3">
|
||||
<input type="password" class="form-control" placeholder="Password" id="password" name="password">
|
||||
<div class="input-group-append">
|
||||
<div class="input-group-text">
|
||||
<span class="fas fa-lock"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-8">
|
||||
<div class="icheck-primary">
|
||||
<input type="checkbox" id="remember">
|
||||
<label for="remember">
|
||||
Remember Me
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<button type="submit" class="btn btn-primary btn-block">Sign In</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<p class="mb-1">
|
||||
<a href="forgot-password.html">I forgot my password</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="myalert">
|
||||
<?php echo $this->session->flashdata('alert', true)?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/jquery/jquery.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
|
||||
<script src="<?= base_url(); ?>assets/template/dist/js/adminlte.min.js"></script>
|
||||
|
||||
<script>
|
||||
$('#myalert').delay('slow').slideDown('slow').delay(2000).slideUp(600);
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,63 @@
|
||||
<?php
|
||||
$link = 'typeuser/create';
|
||||
if (!$isNewRecord) {
|
||||
$link = 'typeuser/update';
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="card card-info">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">Create Typeuser</h3>
|
||||
</div>
|
||||
<form class="form-horizontal" method="POST" action="<?php echo base_url($link); ?>" enctype="multipart/form-data">
|
||||
<div class="card-body">
|
||||
<!-- HIDDEN FORM -->
|
||||
<div class="form-group row">
|
||||
|
||||
<div class="col-sm-8">
|
||||
<input type="hidden" class="form-control" id="isNewRecord" name="isNewRecord" value="<?= (!$isNewRecord) ? 'false' : 'true' ?>" placeholder="isNewRecord">
|
||||
|
||||
<input type="hidden" class="form-control" id="id" name="id" value="<?= (!$isNewRecord) ? $data->id : '' ?>" placeholder="id">
|
||||
</div>
|
||||
</div>
|
||||
<!-- HIDDEN FORM -->
|
||||
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_name" class="col-sm-2 col-form-label">Code</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="text" class="form-control" id="code" name="code" value="<?= (!$isNewRecord) ? $data->code : '' ?>" placeholder="Code">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_email" class="col-sm-2 col-form-label">Value</label>
|
||||
<div class="col-sm-7">
|
||||
<input type="text" class="form-control" id="value" name="value" value="<?= (!$isNewRecord) ? $data->value : '' ?>" placeholder="Value">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label for="input_phone" class="col-sm-2 col-form-label">Description</label>
|
||||
<div class="col-sm-6">
|
||||
<input type="text" class="form-control" id="description" name="description" value="<?= (!$isNewRecord) ? $data->description : '' ?>" placeholder="Description">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="card-footer">
|
||||
<button type="submit" class="btn btn-info float-right"><?= ($isNewRecord) ? 'Create Profile' : 'Update Type User' ?></button>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,67 @@
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3 class="card-title">List Typeuser</h3>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-header">
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['typeuser[C]']))) : ?>
|
||||
<a href="<?= base_url('typeuser/create') ?>" class="btn btn-success btn-sm float-right">Create Typeuser</a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<?php if ($this->session->flashdata('success')) : ?>
|
||||
<div class="alert alert-success" role="alert">
|
||||
<?php echo $this->session->flashdata('success'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if ($this->session->flashdata('failed')) : ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<?php echo $this->session->flashdata('failed'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Code</th>
|
||||
<th>Value</th>
|
||||
<th>Description</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php if (!empty($data)) :
|
||||
?>
|
||||
|
||||
<?php foreach ($data as $item) : ?>
|
||||
<tr>
|
||||
|
||||
<td><?= $item->code ?></td>
|
||||
<td><?= $item->value ?></td>
|
||||
<td><?= $item->description ?></td>
|
||||
<td>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['typeuser[U]']))) : ?>
|
||||
<a href="<?= base_url('typeuser/update/' . encrypt_url($item->id)) ?>" class="btn btn-info btn-xs"><i class="fas fa-edit"></i></a>
|
||||
<?php endif; ?>
|
||||
<?php if (($this->session->userdata('is_developer')) || (isset($this->session->userdata('you_can')['typeuser[D]']))) : ?>
|
||||
<a href="<?= base_url('typeuser/delete/' . encrypt_url($item->id)) ?>" class="btn btn-danger btn-xs"><i class="fas fa-trash"></i></a>
|
||||
<?php endif; ?>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
<?php else : ?>
|
||||
<tr>
|
||||
<td colspan="6" style="text-align: center; font-style: italic">Data is empty!</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,53 @@
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h3 class="card-title">List User</h3>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-body">
|
||||
<?php if ($this->session->flashdata('success')): ?>
|
||||
<div class="alert alert-success" role="alert">
|
||||
<?php echo $this->session->flashdata('success'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if ($this->session->flashdata('failed')): ?>
|
||||
<div class="alert alert-danger" role="alert">
|
||||
<?php echo $this->session->flashdata('failed'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<table id="example1" class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Username</th>
|
||||
<th>Name</th>
|
||||
<th>Email</th>
|
||||
<th>Typeuser</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($model as $item): ?>
|
||||
<tr>
|
||||
<td>
|
||||
<a href="<?= base_url('profile/view/' . encrypt_url($item['user_id'])) ?>"><?= $item['username'] ?></a>
|
||||
</td>
|
||||
<td><?= $item['name'] ?></td>
|
||||
<td><?= $item['email'] ?></td>
|
||||
<td><?= $item['typeuser'] ?></td>
|
||||
<td>
|
||||
<a href="javascript:void(0)" data-id=<?= $item['user_id'] ?>
|
||||
class="btn btn-primary btn-switch-user"><i class="fas fa-random"></i> Switch</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,100 @@
|
||||
<?php
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
?><!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Welcome to CodeIgniter</title>
|
||||
|
||||
<style type="text/css">
|
||||
|
||||
::selection { background-color: #E13300; color: white; }
|
||||
::-moz-selection { background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
color: #97310e;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#body {
|
||||
margin: 0 15px 0 15px;
|
||||
min-height: 96px;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 0 0 10px;
|
||||
padding:0;
|
||||
}
|
||||
|
||||
p.footer {
|
||||
text-align: right;
|
||||
font-size: 11px;
|
||||
border-top: 1px solid #D0D0D0;
|
||||
line-height: 32px;
|
||||
padding: 0 10px 0 10px;
|
||||
margin: 20px 0 0 0;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
<h1>Welcome to CodeIgniter!</h1>
|
||||
|
||||
<div id="body">
|
||||
<p>The page you are looking at is being generated dynamically by CodeIgniter.</p>
|
||||
|
||||
<p>If you would like to edit this page you'll find it located at:</p>
|
||||
<code>application/views/welcome_message.php</code>
|
||||
|
||||
<p>The corresponding controller for this page is found at:</p>
|
||||
<code>application/controllers/Welcome.php</code>
|
||||
|
||||
<p>If you are exploring CodeIgniter for the very first time, you should start by reading the <a href="userguide3/">User Guide</a>.</p>
|
||||
</div>
|
||||
|
||||
<p class="footer">Page rendered in <strong>{elapsed_time}</strong> seconds. <?php echo (ENVIRONMENT === 'development') ? 'CodeIgniter Version <strong>' . CI_VERSION . '</strong>' : '' ?></p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user