add publick landing page
|
@ -50,7 +50,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
|
||||||
| my-controller/my-method -> my_controller/my_method
|
| my-controller/my-method -> my_controller/my_method
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$route['default_controller'] = 'Login';
|
$route['default_controller'] = 'Dashboard';
|
||||||
$route['404_override'] = '';
|
$route['404_override'] = '';
|
||||||
$route['translate_uri_dashes'] = FALSE;
|
$route['translate_uri_dashes'] = FALSE;
|
||||||
$route['admin'] = 'admin/Dashboard';
|
$route['admin'] = 'admin/Dashboard';
|
||||||
|
|
|
@ -0,0 +1,26 @@
|
||||||
|
<?php
|
||||||
|
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||||
|
|
||||||
|
class Dashboard extends CI_Controller {
|
||||||
|
|
||||||
|
public function __construct()
|
||||||
|
{
|
||||||
|
parent::__construct();
|
||||||
|
$this->load->model("UserModel");
|
||||||
|
$this->load->model("ProdukModel");
|
||||||
|
$this->load->model("UmkmModel");
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public function index()
|
||||||
|
{
|
||||||
|
|
||||||
|
$data['produk'] = $this->ProdukModel->getThree();
|
||||||
|
$data['umkm'] = $this->UmkmModel->getThree();
|
||||||
|
$data['user_logged'] = $this->session->userdata('user_logged');
|
||||||
|
$this->load->view('dashboard',$data);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -26,6 +26,12 @@ class ProdukModel extends CI_Model
|
||||||
return $produk = $this->db->get($this->_table)->row();
|
return $produk = $this->db->get($this->_table)->row();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getThree(){
|
||||||
|
$this->db->order_by('id_produk', 'DESC');
|
||||||
|
$this->db->limit('3');
|
||||||
|
return $produk = $this->db->get($this->_table)->result();
|
||||||
|
}
|
||||||
|
|
||||||
public function getLastProdukByIdUmkm($id_umkm){
|
public function getLastProdukByIdUmkm($id_umkm){
|
||||||
$this->db->where('id_umkm', $id_umkm);
|
$this->db->where('id_umkm', $id_umkm);
|
||||||
$this->db->order_by('id_produk', 'DESC');
|
$this->db->order_by('id_produk', 'DESC');
|
||||||
|
|
|
@ -77,6 +77,11 @@ class UmkmModel extends CI_Model
|
||||||
return $umkm = $this->db->get($this->_table)->row();
|
return $umkm = $this->db->get($this->_table)->row();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getThree(){
|
||||||
|
$this->db->order_by('id_umkm', 'DESC');
|
||||||
|
$this->db->limit('3');
|
||||||
|
return $umkm = $this->db->get($this->_table)->result();
|
||||||
|
}
|
||||||
|
|
||||||
public function getUmkmCountByUserId($id_pemilik){
|
public function getUmkmCountByUserId($id_pemilik){
|
||||||
$this->db->where('id_pemilik', $id_pemilik);
|
$this->db->where('id_pemilik', $id_pemilik);
|
||||||
|
|
|
@ -0,0 +1,262 @@
|
||||||
|
<!doctype html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<!-- Required meta tags -->
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
||||||
|
<!-- Bootstrap CSS -->
|
||||||
|
<link rel="stylesheet" href="<?php echo base_url()?>assets/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
|
||||||
|
<link rel="stylesheet" href="<?php echo base_url()?>assets/css/dataTables.bootstrap4.min.css">
|
||||||
|
|
||||||
|
<link rel="icon" type="image/png" href="../assets/images/favicon.png" />
|
||||||
|
|
||||||
|
<title>Portal Data UMKM Kota Magelang</title>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<style>
|
||||||
|
.carousel .item {
|
||||||
|
height: 100px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item img {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
min-height: 100px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* GLOBAL STYLES
|
||||||
|
-------------------------------------------------- */
|
||||||
|
/* Padding below the footer and lighter body text */
|
||||||
|
|
||||||
|
|
||||||
|
/* CUSTOMIZE THE CAROUSEL
|
||||||
|
-------------------------------------------------- */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* MARKETING CONTENT
|
||||||
|
-------------------------------------------------- */
|
||||||
|
|
||||||
|
/* Center align the text within the three columns below the carousel */
|
||||||
|
.marketing .col-lg-4 {
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.marketing h2 {
|
||||||
|
font-weight: 400;
|
||||||
|
}
|
||||||
|
.marketing .col-lg-4 p {
|
||||||
|
margin-right: .75rem;
|
||||||
|
margin-left: .75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Featurettes
|
||||||
|
------------------------- */
|
||||||
|
|
||||||
|
.featurette-divider {
|
||||||
|
margin: 5rem 0; /* Space out the Bootstrap <hr> more */
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Thin out the marketing headings */
|
||||||
|
.featurette-heading {
|
||||||
|
font-weight: 300;
|
||||||
|
line-height: 1;
|
||||||
|
letter-spacing: -.05rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* RESPONSIVE CSS
|
||||||
|
-------------------------------------------------- */
|
||||||
|
|
||||||
|
@media (min-width: 40em) {
|
||||||
|
/* Bump up size of carousel content */
|
||||||
|
|
||||||
|
.featurette-heading {
|
||||||
|
font-size: 50px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (min-width: 62em) {
|
||||||
|
.featurette-heading {
|
||||||
|
margin-top: 7rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<header>
|
||||||
|
|
||||||
|
<nav class="navbar navbar-expand-lg navbar-dark bg-dark fixed-top">
|
||||||
|
<a class="navbar-brand" href="#">
|
||||||
|
<img src="../assets/images/favicon.png" width="30" height="30" class="d-inline-block align-top" alt="">
|
||||||
|
PORTAL UMKM
|
||||||
|
</a>
|
||||||
|
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
|
||||||
|
<span class="navbar-toggler-icon"></span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
||||||
|
<ul class="navbar-nav mr-auto">
|
||||||
|
<li class="nav-item active">
|
||||||
|
<a class="nav-link" href="<?php echo base_url()?>index.php/">Beranda <span class="sr-only">(current)</span></a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="<?php echo base_url()?>index.php/umkm">Umkm</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item">
|
||||||
|
<a class="nav-link" href="<?php echo base_url()?>index.php/produk">Produk</a>
|
||||||
|
</li>
|
||||||
|
<li class="nav-item dropdown">
|
||||||
|
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||||
|
Data
|
||||||
|
</a>
|
||||||
|
<div class="dropdown-menu" aria-labelledby="navbarDropdown">
|
||||||
|
<a class="dropdown-item" href="<?php echo base_url()?>index.php/laporan">Laporan Tahunan</a>
|
||||||
|
<a class="dropdown-item" href="<?php echo base_url()?>index.php/laporanbulanan">Laporan Bulanan</a>
|
||||||
|
<a class="dropdown-item" href="<?php echo base_url()?>index.php/laporankecamatan">Laporan Kecamatan</a>
|
||||||
|
<a class="dropdown-item" href="<?php echo base_url()?>index.php/laporankelurahan">Laporan Kelurahan</a>
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<form class="form-inline my-2 my-lg-0">
|
||||||
|
<a class="btn btn-outline-light btn-sm my-2 my-sm-0" href="<?php echo base_url()?>index.php/login">Login</a>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</nav>
|
||||||
|
</header>
|
||||||
|
|
||||||
|
<div class="fluid" >
|
||||||
|
<div id="carouselExampleIndicators" class="carousel slide" data-ride="carousel">
|
||||||
|
<ol class="carousel-indicators">
|
||||||
|
<li data-target="#carouselExampleIndicators" data-slide-to="0" class="active"></li>
|
||||||
|
<li data-target="#carouselExampleIndicators" data-slide-to="1"></li>
|
||||||
|
<li data-target="#carouselExampleIndicators" data-slide-to="2"></li>
|
||||||
|
</ol>
|
||||||
|
<div class="carousel-inner">
|
||||||
|
<div class="carousel-item active">
|
||||||
|
<img class="d-block w-100" src="../assets/images/corousel1.jpg" alt="First slide">
|
||||||
|
<div class="carousel-caption d-none d-md-block mb-5">
|
||||||
|
<h1>UMKM KOTA MAGELANG</h1>
|
||||||
|
<h3>saat ini, kota magelang mempunyai <strong>5</strong> UMKM aktif</h3>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="carousel-item">
|
||||||
|
<img class="d-block w-100" src="../assets/images/corousel2.jpg" alt="Second slide">
|
||||||
|
<div class="carousel-caption d-none d-md-block mb-5">
|
||||||
|
<h1>TENAGA KERJA</h1>
|
||||||
|
<h3><strong>500</strong> Tenaga kerja terserap oleh kegiatan UMKM</h3>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="carousel-item">
|
||||||
|
<img class="d-block w-100" src="../assets/images/corousel3.jpg" alt="Third slide">
|
||||||
|
<div class="carousel-caption d-none d-md-block mb-5">
|
||||||
|
<h1>PRODUK UMKM</h1>
|
||||||
|
<h3>UMKM kota magelang menghasilkan <strong>500</strong> produk</h3>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<a class="carousel-control-prev" href="#carouselExampleIndicators" role="button" data-slide="prev">
|
||||||
|
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
|
||||||
|
<span class="sr-only">Previous</span>
|
||||||
|
</a>
|
||||||
|
<a class="carousel-control-next" href="#carouselExampleIndicators" role="button" data-slide="next">
|
||||||
|
<span class="carousel-control-next-icon" aria-hidden="true"></span>
|
||||||
|
<span class="sr-only">Next</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Three columns of text below the carousel -->
|
||||||
|
<div class="container mt-4">
|
||||||
|
<div class="container marketing">
|
||||||
|
<div class="text-center text-secondary"><h3><u>PRODUK UMKM</u></h3></div>
|
||||||
|
<div class="row mt-4">
|
||||||
|
<?php
|
||||||
|
foreach($produk as $prod){
|
||||||
|
?>
|
||||||
|
<div class="col-lg-4">
|
||||||
|
<img class="rounded-circle" src="../assets/images/produk/<?php echo $prod->foto_produk ?>" alt="Generic placeholder image" width="140" height="140">
|
||||||
|
<h2><?php echo $prod->produk ?></h2>
|
||||||
|
<p><a class="btn btn-secondary" href="#" role="button">View details »</a></p>
|
||||||
|
</div><!-- /.col-lg-4 -->
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="text-center"> <label><a href="#" class="btn btn-outline-primary">Lihat Produk Lengkap</a></label></div>
|
||||||
|
<hr>
|
||||||
|
|
||||||
|
<!-- START THE FEATURETTES -->
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$no='ganjil';
|
||||||
|
foreach($umkm as $um){
|
||||||
|
if($no=='ganjil'){
|
||||||
|
|
||||||
|
?>
|
||||||
|
|
||||||
|
<hr class="featurette-divider">
|
||||||
|
|
||||||
|
<div class="row featurette">
|
||||||
|
<div class="col-md-7">
|
||||||
|
<h2 class="featurette-heading"><?php echo $um->nama ?></h2>
|
||||||
|
<p class="lead"><?php echo $um->deskripsi ?></p>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-5">
|
||||||
|
<img class="featurette-image img-fluid mx-auto" src="../assets/images/umkm/<?php echo $um->foto_umkm ?>" alt="Generic placeholder image">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$no = 'genap';
|
||||||
|
}else{
|
||||||
|
?>
|
||||||
|
|
||||||
|
<hr class="featurette-divider">
|
||||||
|
|
||||||
|
<div class="row featurette">
|
||||||
|
<div class="col-md-7 order-md-2">
|
||||||
|
<h2 class="featurette-heading"><?php echo $um->nama ?></h2>
|
||||||
|
<p class="lead"><?php echo $um->deskripsi ?></p>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-5 order-md-1">
|
||||||
|
<img class="featurette-image img-fluid mx-auto" src="../assets/images/umkm/<?php echo $um->foto_umkm ?>" alt="Generic placeholder image">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
$no='ganjil';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- /END THE FEATURETTES -->
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="bg-dark text-light mt-5" style="padding-top: 50px;padding-bottom:40px;">
|
||||||
|
<footer class="container">
|
||||||
|
<p class="float-right"><a href="#">Back to top</a></p>
|
||||||
|
<p>© 2021 , Ardi Ferdianto</p>
|
||||||
|
</footer>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Optional JavaScript -->
|
||||||
|
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
|
||||||
|
<script src="<?php echo base_url()?>assets/js/jquery-3.2.1.slim.min.js" integrity="sha384-KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN" crossorigin="anonymous"></script>
|
||||||
|
<script src="<?php echo base_url()?>assets/js/popper.min.js" integrity="sha384-ApNbgh9B+Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q" crossorigin="anonymous"></script>
|
||||||
|
<script src="<?php echo base_url()?>assets/js/bootstrap.min.js" integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl" crossorigin="anonymous"></script>
|
||||||
|
<script src="<?php echo base_url()?>assets/js/jquery.dataTables.min.js"></script>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
|
@ -53,7 +53,9 @@
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="text-center"><a href="<?php echo base_url()?>index.php/">Kembali ke Beranda</a></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="card-footer text-muted">
|
<div class="card-footer text-muted">
|
||||||
Copyright 2021 || Ardi Ferdianto
|
Copyright 2021 || Ardi Ferdianto
|
||||||
</div>
|
</div>
|
||||||
|
|
After Width: | Height: | Size: 38 KiB |
After Width: | Height: | Size: 2.1 MiB |
After Width: | Height: | Size: 1.4 MiB |
After Width: | Height: | Size: 1.8 MiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 9.8 KiB |
After Width: | Height: | Size: 17 KiB |
Before Width: | Height: | Size: 4.6 KiB After Width: | Height: | Size: 19 KiB |
After Width: | Height: | Size: 8.5 KiB |
After Width: | Height: | Size: 73 KiB |
After Width: | Height: | Size: 38 KiB |
After Width: | Height: | Size: 76 KiB |