HOME


Mini Shell 1.0
DIR: /home/islapiiu/sites/pramudi/control-panel/
Upload File :
Current File : /home/islapiiu/sites/pramudi/control-panel/manage-product-categories.php
<?php
include_once(dirname(__FILE__) . '/../class/include.php');
include_once(dirname(__FILE__) . '/auth.php');

$PRODUCT_CATEGORY = new ProductCategory(NULL);
?>
<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
        <title>Product Categories - Synotec</title>
       <link rel="icon" type="image/x-icon" href="../images/3d-fav1.png" />
        <link href="https://fonts.googleapis.com/css?family=Roboto:400,700&subset=latin,cyrillic-ext" rel="stylesheet" type="text/css">
        <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet" type="text/css">
        <link href="plugins/bootstrap/css/bootstrap.css" rel="stylesheet">
        <link href="plugins/node-waves/waves.css" rel="stylesheet" />
        <link href="plugins/animate-css/animate.css" rel="stylesheet" />
        <link href="plugins/sweetalert/sweetalert.css" rel="stylesheet" />
        <link href="plugins/jquery-datatable/skin/bootstrap/css/dataTables.bootstrap.css" rel="stylesheet">
        <link href="css/style.css" rel="stylesheet">
        <link href="css/themes/all-themes.css" rel="stylesheet" />
        <link href="css/jm.spinner.css" rel="stylesheet" type="text/css"/>
    </head>

    <body class="theme-red">
        <?php
        include './navigation-and-header.php';
        ?>

        <section class="content">
            <div class="container-fluid">  
                <?php
                $vali = new Validator();

                $vali->show_message();
                ?>
                <!-- Vertical Layout -->
                <div class="row clearfix">
                    <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
                        <div class="card">
                            <div class="header">
                                <h2>Create Product Category</h2>
                                <ul class="header-dropdown">
                                    <li class="">
                                        <a href="manage-product-categories.php"> 
                                        </a>
                                    </li>
                                </ul>
                            </div>
                            <div class="body">
                                <div class="body">
                                    <!--<form class="form-horizontal"  method="post" action="post-and-get/product-category.php" enctype="multipart/form-data">--> 
                                    <form class="form-horizontal"  method="post"  id="form-data" enctype="multipart/form-data">     
                                    <div class="row clearfix">
                                            <div class="col-lg-2 col-md-2 col-sm-4 col-xs-5 form-control-label">
                                                <label for="name">Name</label>
                                            </div>
                                            <div class="col-lg-10 col-md-10 col-sm-8 col-xs-7">
                                                <div class="form-group">
                                                    <div class="form-line">
                                                        <input type="text" id="name" class="form-control"  name="name"  >
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="col-lg-2 col-md-2 col-sm-4 col-xs-5 form-control-label">
                                                <label for="image">Image</label>
                                            </div>
                                            <div class="col-lg-10 col-md-10 col-sm-8 col-xs-7">
                                                <div class="form-group">
                                                    <div class="form-line">
                                                        <input type="file" id="image" class="form-control" name="image" >
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="row clearfix">
                                                <div class="col-lg-offset-2 col-md-offset-2 col-sm-offset-4 col-xs-offset-5"> 
                                                    <input type="hidden" name="create"value="create"/>
                                                    <input type="submit" id="create" class="btn btn-primary m-t-15 waves-effect" value="create"/>
                                                </div>
                                            </div>
                                        </div>
                                    </form>
                                </div>
                                <div class="row">
                                </div>
                                <div class="row clearfix">
                                    <hr/>
                                    <div class="heading m-cat">
                                        <p>Manage Product Categories</p>
                                        <a href="manage-product-categories.php">
                                        </a>
                                    </div> 
                                    <div>
                                        <table class="table table-bordered table-striped table-hover js-basic-example dataTable">
                                            <thead>
                                                <tr>
                                                    <th>ID</th>
                                                    <th>Name</th> 
                                                    <th>Options</th>
                                                </tr>
                                            </thead>
                                            <tfoot>
                                                <tr>
                                                    <th>ID</th>
                                                    <th>Name</th> 
                                                    <th>Options</th>
                                                </tr>
                                            </tfoot>
                                            <tbody>
                                                <?php
                                                foreach ($PRODUCT_CATEGORY->all() as $key => $product_category) {

                                                    $key++;
                                                    ?>
                                                    <tr id="row_<?php echo $product_category['id']; ?>">
                                                        <td><?php echo $key; ?></td> 
                                                        <td><?php echo $product_category['name']; ?></td> 
                                                        <td>  

                                                            <a href="edit-product-category.php?id=<?php echo $product_category['id']; ?>"> 
                                                                <button class="glyphicon glyphicon-pencil edit-btn"  title="Edit Product Category"></button></a>


                                                            |  

                                                            <a href="#" > 
                                                                <button class="glyphicon glyphicon-trash delete-btn delete-product-category"  title="Delete Product Category" data-id="<?php echo $product_category['id']; ?>"></button>
                                                            </a>

                                                            |

                                                            <a href="arrange-product-category.php?id="> 
                                                                <button class="glyphicon glyphicon-random arrange-btn"  title="Arrange Product Categories"></button>
                                                            </a>

                                                            |

                                                            <a href="create-product.php?id=<?php echo $product_category['id']; ?>"> 
                                                                <button class="glyphicon glyphicon-shopping-cart list-btn"  title="Manage Products"></button>
                                                            </a>

                                                        </td>
                                                    </tr>
                                                    <?php
                                                }
                                                ?>   
                                            </tbody>
                                        </table>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <!-- #END# Manage brand -->
            </div>
            <!-- #END# Vertical Layout -->
        </section>

        <!-- Jquery Core Js -->
        <script src="plugins/jquery/jquery.min.js"></script>
        <script src="plugins/bootstrap/js/bootstrap.js"></script>
        <script src="plugins/bootstrap-select/js/bootstrap-select.js"></script>
        <script src="plugins/jquery-slimscroll/jquery.slimscroll.js"></script>
        <script src="plugins/node-waves/waves.js"></script>
        <script src="plugins/jquery-datatable/jquery.dataTables.js"></script>
        <script src="plugins/jquery-datatable/skin/bootstrap/js/dataTables.bootstrap.js"></script>
        <script src="plugins/jquery-datatable/extensions/export/dataTables.buttons.min.js"></script>
        <script src="plugins/jquery-datatable/extensions/export/buttons.flash.min.js"></script>
        <script src="plugins/jquery-datatable/extensions/export/jszip.min.js"></script>
        <script src="plugins/jquery-datatable/extensions/export/pdfmake.min.js"></script>
        <script src="plugins/jquery-datatable/extensions/export/vfs_fonts.js"></script>
        <script src="plugins/jquery-datatable/extensions/export/buttons.html5.min.js"></script>
        <script src="plugins/jquery-datatable/extensions/export/buttons.print.min.js"></script>
        <script src="js/admin.js"></script>
        <script src="js/pages/tables/jquery-datatable.js"></script>
        <script src="js/demo.js"></script>
        <script src="plugins/sweetalert/sweetalert.min.js"></script>
        <script src="plugins/bootstrap-notify/bootstrap-notify.js"></script>
        <script src="js/pages/ui/dialogs.js"></script>
        <script src="js/jm.spinner.js" type="text/javascript"></script>
        <script src="delete/js/product-category.js" type="text/javascript"></script>
        <script src="js/ajax/product-category.js" type="text/javascript"></script>
    </body>

</html>