first commit

This commit is contained in:
ryanwong
2022-06-30 05:46:02 -04:00
commit a96eaec33b
859 changed files with 199842 additions and 0 deletions
+222
View File
@@ -0,0 +1,222 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2021*/
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif;
?>
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4">
<?php echo $view_model->get_heading();?>
<span class="add-part d-flex justify-content-md-end text-white "><a class="btn btn-primary btn-sm" target="__blank" href="/member/cart/add"><i class="fas fa-plus-circle"></i></a></span>
</h5>
<section class="table-placeholder bg-white mb-5 p-3 pl-4 pr-4 pt-4" style="height:auto;">
<div class="table-responsive">
<div class="row">
<div class="col p-2">
<div class="float-right mr-4"></div>
</div>
<div class="clearfix"></div>
</div>
<input type="hidden" id="per_page" value="<?php echo $this->_data['view_model']->get_per_page(); ?>" >
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="dataTables_length" id="config-table_length">
<small class="d-flex align-items-baseline">Show
<select data-sorturl="<?php echo $view_model->get_sort_base_url(); ?>" id="change_per_page" name="config-table_length" aria-controls="config-table" class="form-control form-control-sm mx-2" style="width: auto;margin-bottom: 10px;">
<?php if(isset($_GET['per_page_sort'])) { ?>
<option value="10" <?php echo ($_GET['per_page_sort'] == '5' && $_GET['per_page_sort']) ? 'selected' : '';?>>5</option>
<option value="10" <?php echo ($_GET['per_page_sort'] == '10' && $_GET['per_page_sort']) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($_GET['per_page_sort'] == '25' && $_GET['per_page_sort']) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($_GET['per_page_sort'] == '50' && $_GET['per_page_sort']) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($_GET['per_page_sort'] == '100' && $_GET['per_page_sort']) ? 'selected' : '';?>>100</option>
<?php } else { ?>
<option value="10" <?php echo ($this->_data['view_model']->get_per_page() == '10' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($this->_data['view_model']->get_per_page() == '25' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($this->_data['view_model']->get_per_page() == '50' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($this->_data['view_model']->get_per_page() == '100' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>100</option>
<?php } ?>
</select>
entries</small>
</div>
</div>
</div>
<table class="display nowrap table table-hover table-striped table-bordered w-100 table-compact mb-0 mkd-table-container">
<thead class=''>
<?php
$order_by = $view_model->get_order_by();
$direction = $view_model->get_sort();
$model_base_url = $view_model->get_sort_base_url();
$field_column = $view_model->get_field_column();
$clean_mode = $view_model->get_format_layout();
$query_string = $view_model->get_query_parameter();
$per_page = $this->_data['view_model']->get_per_page();
$format_mode = '';
if ($clean_mode) {
$format_mode = '&layout_clean_mode=1';
}
foreach ($view_model->get_column() as $key => $data) {
$data_field = $field_column[$key];
if (strlen($order_by) < 1 || $data_field == '')
{
echo "<th scope='col' class='paragraphText text-center'>{$data}</th>";
}
else
{
if ($order_by === $data_field)
{
if ($direction == 'ASC')
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-asc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=DESC{$query_string}'>{$data}</a></th>";
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-desc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
} ?>
</thead>
<tbody class="tbody-light">
<?php $i=1; foreach ($view_model->get_list() as $data) { ?>
<?php
echo '<tr>';
echo '<td style=\'max-width: 100px;\'>';
echo '<a class="btn-link link-underline text-underline" target="__blank" href="/member/cart/edit/' . $data->id . '">Edit</a>';
echo ' <a class="btn-link link-underline text-underline" target="__blank" href="/member/cart/view/' . $data->id . '">View</a>';
echo ' <a data-id="'.$data->id.'" class="btn-link link-underline text-underline text-danger remove_link" href="#">Remove</a>';
echo '</td>'; echo "<td>{$data->id}</td>";
echo "<td>{$data->product_id}</td>";
echo "<td>{$data->user_id}</td>";
echo "<td>{$data->session_id}</td>";
echo "<td>{$data->subtotal}</td>";
echo "<td>{$data->quantity}</td>";
echo "<td>{$data->total}</td>";
echo '</tr>';
?>
<?php $i++; } ?>
</tbody>
</table>
<small><?php echo $view_model->get_total_rows();?> results found</small>
<span class="pagination_custom">
<?php echo $view_model->get_links(); ?>
</span>
</div>
</section>
</div>
<?php
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
echo '<style>#tab-content{padding:0px !important;margin:0px !important;}</style>';
}
?>
<!-- delete modal -->
<div class="modal fade" id="deleteModal" tabindex="-1" role="dialog" aria-labelledby="deleteModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">Delete <?php echo $view_model->get_heading();?></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<p>Are you sure you want to delete?</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary text-white close_btn" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger delete_confirm_btn">Confirm</button>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<script>
$(document).ready(function() {
$(".remove_link").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
$('#deleteModal').modal('show');
var id = e.currentTarget.getAttribute('data-id');
if (id != 0 || id != '') {
$(".delete_confirm_btn").click(function(e) {
e.preventDefault();
$('.delete_confirm_btn').prop('disabled',true);
$('.close_btn').prop('disabled',true);
// toastr.info(id);
// return false;
$.ajax({
url: '/v1/api/member/cart/delete',
type: "POST",
data: { id: id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.error(response.msg);
}
},
});
return false;
});
} else {
toastr.error('Data not found.');
return false;
}
});
});
</script>
+84
View File
@@ -0,0 +1,84 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/cart/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
Add
</li>
</ol>
</div>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Add <?php echo $view_model->get_heading();?>
</h5>
<?= form_open() ?>
<div class="form-group col-md-5 col-sm-12 ">
<label for="User ID">User ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_user_id" name="user_id" value="<?php echo set_value('user_id'); ?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Session ID">Session ID </label>
<input type="text" class="form-control data-input" id="form_session_id" name="session_id" value="<?php echo set_value('session_id'); ?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Subtotal">Subtotal <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_subtotal" name="subtotal" value="<?php echo set_value('subtotal'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Total">Total <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_total" name="total" value="<?php echo set_value('total'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary text-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
</div>
+83
View File
@@ -0,0 +1,83 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start">
<!-- <li class="breadcrumb-item active" aria-current="page">
<a href="/member/dashboard" class="breadcrumb-link">Dashboard</a>
</li> -->
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/cart/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
Edit
</li>
</ol>
</div>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Edit <?php echo $view_model->get_heading();?>
</h5>
<?= form_open() ?>
<div class="form-group col-md-5 col-sm-12">
<label for="User ID">User ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_user_id" name="user_id" value="<?php echo set_value('user_id', $this->_data['view_model']->get_user_id());?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Session ID">Session ID </label>
<input type="text" class="form-control data-input" id="form_session_id" name="session_id" value="<?php echo set_value('session_id', $this->_data['view_model']->get_session_id());?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Subtotal">Subtotal <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_subtotal" name="subtotal" value="<?php echo set_value('subtotal', $this->_data['view_model']->get_subtotal());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Total">Total <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_total" name="total" value="<?php echo set_value('total', $this->_data['view_model']->get_total());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary ext-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
+76
View File
@@ -0,0 +1,76 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2021*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start" style="background-color: inherit;">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/cart/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
View
</li>
</ol>
</div>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card pb-5" style='border-bottom:1px solid #ccc;'>
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
<?php echo $view_model->get_heading();?> Details
</h5>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
User ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_user_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Session ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_session_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Subtotal
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_subtotal();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Total
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_total();?>
</div>
</div>
</div>
</div>
</div>
</div>
+92
View File
@@ -0,0 +1,92 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<title>outlineguru</title>
<style>
.form-container {
width: 40%;
min-width: 300px;
max-width: 500px;
border: 1px solid #ccc;
height: auto;
margin: 50px auto;
}
.btn-primary {
background-color: #2C5ED6;
}
@media (max-width: 500px) {
h1 {
font-size: 24px;
}
.form-container {
margin: 10px auto;
}
}
</style>
</head>
<body>
<nav class="navbar navbar-expand-sm navbar-dark bg-primary mb-3">
<div class="container">
<a class="navbar-brand" href="#">
outlineguru
<!-- <img style="height:35px" src="/assets/image/logo.png"/> -->
</a>
<div class="collapse navbar-collapse" id="navbarNav">
</div>
</div>
</nav>
<div class="">
<div class='text-center'>
<h1>Change your password</h1>
</div>
<div class="form-container p-5">
<?php echo form_open();?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="alert">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="form-group text-container">
<label class='required' for="Password">Password </label>
<input type="password" class="form-control site-input" id="password" name="password" required="true" >
</div>
<div class="form-group">
<input type="submit" name='btn-login' class="btn btn-primary btn-block" value="Submit">
</div>
</form>
</div>
</div>
<div class='text-center'>&copy; <?php echo date("yy"); ?> outlineguru. All Right Reserved.</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" crossorigin="anonymous"></script>
<!-- Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020 -->
</body>
</html>
+54
View File
@@ -0,0 +1,54 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed');
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="row">
</div>
<div class="row">
<?php if (validation_errors()) : ?>
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
<?php endif; ?>
</div>
<div class="row">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<h5 class="card-header">Edit Credentials</h5>
<div class="card-body">
<?= form_open() ?>
<div class="form-group">
<label for="First Name">Email</label>
<input type="email" class="form-control" id="form_first_name" name="email" value="<?php echo set_value('email', $this->_data['view_model']->get_email());?>"/>
</div>
<div class="form-group">
<label for="Password">Password</label>
<input type="password" class="form-control" id="form_password" name="password" />
</div>
<div class="form-group">
<input type="submit" class="btn btn-primary" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
+24
View File
@@ -0,0 +1,24 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
<div class="tab-content mx-4" id="nav-tabContent">
<h2>Dashboard</h2>
<br>
<div class="clear"></div>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
</div>
+57
View File
@@ -0,0 +1,57 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
<div class="row">
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4 ml-3">
Dispute
<span class=""></span>
</h5>
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body pb-3 pl-3 pr-3">
<?php if(($this->_data['status_'] ?? '')=='success') { ?>
<div class="alert alert-success" role="alert">
<?php echo $this->_data['status_msg'];?>
</div>
<?php } ?>
<?php if(($this->_data['status_'] ?? '')=='error') { ?>
<div class="alert alert-danger" role="alert">
<?php echo $this->_data['status_msg'];?>
</div>
<?php } ?>
<form method="get" action="<?php echo base_url();?>member/post_dispute">
<!-- <input type="hidden" name="order_id" value="<?php echo $this->uri->segment(3) ?? ($_GET['order_id']??'') ;?>" /> -->
<div class="form-group col-md-5 col-sm-12">
<h5 class="primaryHeading2 text-md-left mt-1">
Reason For Dispute
</h5>
<textarea name="comment" class="form-control"></textarea>
</div>
<div class="form-group col-md-5 col-sm-12">
<h5 class="primaryHeading2 text-md-left mt-1">
Order #
</h5>
<select name="order_id" required class="form-control ">
<?php foreach ($this->_data['orders'] as $key => $value) {
echo '<option value="'.$value['id'].'" '.(($this->uri->segment(3) ?? ($_GET['order_id']??'')) == $value['id'] ? "selected" : "").' > Order #'.$value['id'].'</option>';
}?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<input class="btn btn-primary" type="submit" name="submit" value="Save" />
</div>
</form>
</div>
</div>
</div>
</div>
+103
View File
@@ -0,0 +1,103 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2021*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start" style="background-color: inherit;">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/dispute/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
View
</li>
</ol>
</div>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card pb-5" style='border-bottom:1px solid #ccc;'>
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
<?php echo $view_model->get_heading();?> Details
</h5>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Order ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_order_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
User ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_user_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Reason
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_reason();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Explanation
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_explanation();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Stripe Charge ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_stripe_charge_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Stripe Dispute ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_stripe_dispute_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Status
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_status();?>
</div>
</div>
</div>
</div>
</div>
</div>
+119
View File
@@ -0,0 +1,119 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<title>OutlineGurus | Forgot Password</title>
<style>
.form-container {
width: 40%;
min-width: 300px;
max-width: 500px;
border: 1px solid #ccc;
height: auto;
margin: 50px auto;
}
@media (max-width: 500px) {
h1 {
font-size: 24px;
}
.form-container {
margin: 10px auto;
}
}
#logo{
width: 180px;
}
.navbar{
padding:3px 10px !important;
}
#Navbar2{
text-align: center;
}
.nav-link{
color:blue;
}
.nav-link.active{
text-decoration: underline;
}
</style>
</head>
<body>
<nav class="navbar navbar-expand-sm bg-light navbar-danger" style="margin-bottom: 1px">
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#Navbar">
<span class="navbar-toggler-icon"><img
src="https://img.icons8.com/material-outlined/24/000000/menu--v1.png" /></span>
</button>
<!-- Brand/logo -->
<a href="<?php echo base_url();?>"><img class="navbar-brand" id="logo" src="<?php echo base_url();?>/assets/frontend/img/Logo Files/Logo Files/SVG/Artboard 1 copy.svg" /></a>
<!-- Links -->
<div class="collapse navbar-collapse" id="Navbar">
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link text-dark" href="<?php echo base_url();?>/member/login">Login</a>
</li>
</ul>
</div>
</nav>
<div class="">
<div class='text-center'>
<h1>Forgot Password</h1>
</div>
<div class="form-container p-5">
<?php echo form_open();?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="alert">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="form-group">
<label class='required' for="Email">Email</label>
<input type="email" class="form-control site-input" id="email" name="email" required="true" />
</div>
<div class="form-group">
<input type="submit" name='btn-login' class="btn btn-primary btn-block" value="Reset Password">
</div>
<div class="form-group mt-3 d-flex justify-content-center">
<a href="/member/login" id="mkd-forgot-password-link">Back</a>
</div>
</form>
</div>
</div>
<div class="row justify-content-center mt-0" style=" width: 100%;">
<div class="col-auto mt-3">
<p>© Copyright 2021 Outline Gurus</p>
</div>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" crossorigin="anonymous"></script>
</body>
</html>
+374
View File
@@ -0,0 +1,374 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
?>
<div class="tab-content mx-4" id="nav-tabContent">
<br>
<div class="clear"></div>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<style>
.select2-container .select2-selection--single {
height: 36px !important;
}
.select2-container--default .select2-selection--single .select2-selection__rendered{
line-height: 32px !important;
}
</style>
<section>
<?php /*
<div class="row filter-section">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card" id="inventory_filter_listing">
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
Uploaded Notes
</h5>
<?= form_open('/member/inventory/0', ['method' => 'get']) ?>
<div class="row">
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="ID">ID </label>
<input type="text" class="form-control" id="id" name="id" value="<?php echo $this->_data['view_model']->get_id();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Title">Title </label>
<input type="text" class="form-control" id="title" name="title" value="<?php echo $this->_data['view_model']->get_title();?>"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="School ID">School </label>
<select id="form_school_id" name="school_id" class="form-control select2 data-input" required>
<option>--Select--</option>
<?php
if (!empty($schools)):
foreach ($schools as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_school_id()==$res1->id ? 'selected' :'';?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Professor ID">Professor </label>
<select id="form_professor_id" name="professor_id" class="form-control select2 data-input" required>
<option>--Select--</option>
<?php
if (!empty($professors)):
foreach ($professors as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_professor_id()==$res1->id ? 'selected' : '' ; ?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Class ID">Course </label>
<select id="form_class_id" name="class_id" class="form-control select2 data-input" required>
<option>--Select--</option>
<?php
if (!empty($classes)):
foreach ($classes as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_class_id()==$res1->id ? 'selected' :'';?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Textbook ID">Textbook </label>
<select id="form_textbook_id" name="textbook_id" class="form-control select2 data-input" required>
<option>--Select--</option>
<?php
if (!empty($textbooks)):
foreach ($textbooks as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_textbook_id()==$res1->id ? 'selected' :'';?> ><?=$res1->isbn;?></option>
<?php
endforeach;
endif;
?>
</select>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Word Count">Word Count </label>
<input type="text" class="form-control" id="word_count" name="word_count" value="<?php echo $this->_data['view_model']->get_word_count();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Year">Year </label>
<input type="text" class="form-control " id="year" name="year" value="<?php echo $this->_data['view_model']->get_year();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Status">Status </label>
<select name="status" class="form-control select2">
<option value="">All</option>
<?php foreach ($view_model->status_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_status() == $key && $view_model->get_status() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
</div>
<input type="hidden" name="order_by" value="<?php echo $view_model->get_order_by();?>"/>
<input type="hidden" name="direction" value="<?php echo $view_model->get_sort();?>"/>
<div style="width:100%;height:10px;display:block;float:none;"></div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<input type="hidden" id="form_per_page" value="<?php echo $this->_data['view_model']->get_per_page() ?>" name="per_page_sort">
<input type="submit" name="submit" class="btn btn-primary" value="Search">
<a class="btn btn-danger" name="submit" type="button" href="<?php echo $view_model->get_sort_base_url().'?order_by=id&direction=DESC&per_page_sort='.$this->_data['view_model']->get_per_page(); ?>">Clear Search</a>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
*/?></section>
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4">
Uploaded Notes
<span class="add-part d-flex justify-content-md-end text-white "><a class="btn btn-primary btn-sm" target="__blank" href="/sell"><i class="fas fa-plus-circle"></i></a></span>
</h5>
<section class="table-placeholder bg-white mb-5 p-3 pl-4 pr-4 pt-4" style="height:auto;">
<div class="table-responsive">
<div class="row">
<div class="col p-2">
<div class="float-right mr-1"></div>
</div>
<div class="clearfix"></div>
</div>
<input type="hidden" id="per_page" value="<?php echo $this->_data['view_model']->get_per_page(); ?>" >
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="dataTables_length" id="config-table_length">
<small class="d-flex align-items-baseline">Show
<select data-sorturl="<?php echo $view_model->get_sort_base_url(); ?>" id="change_per_page" name="config-table_length" aria-controls="config-table" class="form-control form-control-sm mx-2" style="width: auto;margin-bottom: 10px;">
<?php if(isset($_GET['per_page_sort'])) { ?>
<option value="10" <?php echo ($_GET['per_page_sort'] == '5' && $_GET['per_page_sort']) ? 'selected' : '';?>>5</option>
<option value="10" <?php echo ($_GET['per_page_sort'] == '10' && $_GET['per_page_sort']) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($_GET['per_page_sort'] == '25' && $_GET['per_page_sort']) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($_GET['per_page_sort'] == '50' && $_GET['per_page_sort']) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($_GET['per_page_sort'] == '100' && $_GET['per_page_sort']) ? 'selected' : '';?>>100</option>
<?php } else { ?>
<option value="10" <?php echo ($this->_data['view_model']->get_per_page() == '10' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($this->_data['view_model']->get_per_page() == '25' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($this->_data['view_model']->get_per_page() == '50' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($this->_data['view_model']->get_per_page() == '100' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>100</option>
<?php } ?>
</select>
entries</small>
</div>
</div>
</div>
<table class="display nowrap table table-hover table-striped table-bordered w-100 table-compact mb-0 mkd-table-container">
<thead class=''>
<?php
$order_by = $view_model->get_order_by();
$direction = $view_model->get_sort();
$model_base_url = $view_model->get_sort_base_url();
$field_column = $view_model->get_field_column();
$clean_mode = $view_model->get_format_layout();
$query_string = $view_model->get_query_parameter();
$per_page = $this->_data['view_model']->get_per_page();
$format_mode = '';
if ($clean_mode) {
$format_mode = '&layout_clean_mode=1';
}
foreach ($view_model->get_column() as $key => $data) {
$data_field = $field_column[$key];
if (strlen($order_by) < 1 || $data_field == '')
{
echo "<th scope='col' class='paragraphText text-center'>{$data}</th>";
}
else
{
if ($order_by === $data_field)
{
if ($direction == 'ASC')
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-asc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=DESC{$query_string}'>{$data}</a></th>";
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-desc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
} ?>
</thead>
<tbody class="tbody-light">
<?php $i=1; foreach ($view_model->get_list() as $data) { ?>
<?php
echo '<tr>';
echo '<td style=\'max-width: 100px;\'>';
echo ' <a class="btn-link link-underline text-underline" target="__blank" href="/member/inventory/view/' . $data->id . '">View</a>';
echo ' <a data-id="'.$data->id.'" class="btn-link link-underline text-underline text-danger remove_link" href="#">Remove</a>';
echo '</td>'; echo "<td>{$data->id}</td>";
// echo "<td>{$data->title}</td>";
echo "<td>{$data->school_id}</td>";
echo "<td>{$data->professor_id}</td>";
echo "<td>{$data->class_id}</td>";
echo "<td>{$data->isbn}</td>";
// echo "<td><div class='mkd-image-container'><img class='img-fluid modal-image' src='$data->feature_image' onerror=\"if (this.src != '/uploads/placeholder.jpg') this.src = '/uploads/placeholder.jpg';\"/></div></td>";
echo "<td>{$data->word_count}</td>";
echo "<td>{$data->year}</td>";
echo "<td>".($data->purchased_count ?? 0)."</td>";
echo "<td>".($data->refunded_count ?? 0)."</td>";
echo "<td>" . ucfirst($view_model->status_mapping()[$data->status]) ."</td>";
echo '</tr>';
?>
<?php $i++; } ?>
</tbody>
</table>
<small><?php echo $view_model->get_total_rows();?> results found</small>
<span class="pagination_custom">
<?php echo $view_model->get_links(); ?>
</span>
</div>
</section>
</div>
<?php
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
echo '<style>.filter-section {display: none !important;}</style>';
echo '<style>#tab-content{padding:0px !important; margin:0px !important;}</style>';
}
?>
<!-- delete modal -->
<div class="modal fade" id="deleteModal" tabindex="-1" role="dialog" aria-labelledby="deleteModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">Delete <?php echo $view_model->get_heading();?></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<p>Are you sure you want to delete?</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary text-white close_btn" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger delete_confirm_btn">Confirm</button>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<script>
$(document).ready(function() {
$('.select2').select2();
$(".remove_link").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
$('#deleteModal').modal('show');
var id = e.currentTarget.getAttribute('data-id');
if (id != 0 || id != '') {
$(".delete_confirm_btn").click(function(e) {
e.preventDefault();
$('.delete_confirm_btn').prop('disabled',true);
$('.close_btn').prop('disabled',true);
// toastr.info(id);
// return false;
$.ajax({
url: '/v1/api/member/inventory/delete',
type: "POST",
data: { id: id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.error(response.msg);
}
},
});
return false;
});
} else {
toastr.error('Data not found.');
return false;
}
});
});
</script>
+396
View File
@@ -0,0 +1,396 @@
<?php
defined('BASEPATH') || exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode)
{
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/inventory/0" class="breadcrumb-link">Notes</a>
</li>
<li class="breadcrumb-item active" aria-current="page">
Add
</li>
</ol>
</div>
<?php if (validation_errors()): ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?=validation_errors()?>
</div>
</div>
</div>
<?php endif;?>
<?php if (strlen($error) > 0): ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif;?>
<?php if (strlen($success) > 0): ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif;?>
<style>
.select2-container .select2-selection--single {
height: 36px !important;
}
.select2-container--default .select2-selection--single .select2-selection__rendered{
line-height: 32px !important;
}
</style>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Add Notes
</h5>
<?=form_open()?>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Title">Title <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_title" name="title" value="<?php echo set_value('title'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="form_school_id">School <b class="required_field"> * </b></label>
<select id="form_school_id" name="school_id" class=" select2 form-control data-input" required>
<option>--Select--</option>
<?php
if (!empty($schools)):
foreach ($schools as $res1): ?>
<option value='<?=$res1->id;?>' <?=set_select('school_id', $res1->id);?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
<span style="font-size: 14px;">(If your school is not listed above, <a class="text-primary add_suggestion_link" href="">click here</a> to submit)</span>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="form_class_id">Course <b class="required_field"> * </b></label>
<select id="form_class_id" name="class_id" class=" select2 form-control data-input" required>
<option>--Select--</option>
<?php
if (!empty($classes)):
foreach ($classes as $res1): ?>
<option value='<?=$res1->id;?>' <?=set_select('class_id', $res1->id);?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
<span style="font-size: 14px;">(If your Course is not listed above, <a class="text-primary add_suggestion_link" href="">click here</a> to submit)</span>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="form_professor_id">Professor <b class="required_field"> * </b></label>
<select id="form_professor_id" name="professor_id" class=" select2 form-control data-input" required>
<option>--Select--</option>
<?php
if (!empty($professors)):
foreach ($professors as $res1): ?>
<option value='<?=$res1->id;?>' <?=set_select('professor_id', $res1->id);?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
<span style="font-size: 14px;">(If your professor is not listed above, <a class="text-primary add_suggestion_link" href="">click here</a> to submit)</span>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="form_textbook_id">Textbook <b class="required_field"> </b></label>
<select id="form_textbook_id" name="textbook_id" class="select2 form-control data-input" required>
<option>--Select--</option>
<?php
if (!empty($textbooks)):
foreach ($textbooks as $res1): ?>
<option value='<?=$res1->id;?>' <?=set_select('textbook_id', $res1->id);?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
<span style="font-size: 14px;">(If your textbook is not listed above, <a class="text-primary add_suggestion_link" href="">click here</a> to submit)</span>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Word Count">Word Count <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_word_count" name="word_count" value="<?php echo set_value('word_count'); ?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Note Type">Type <b class="required_field"> * </b></label>
<select id="form_note_type" name="note_type" class="form-control data-input">
<?php foreach ($view_model->note_type_mapping() as $key => $value)
{
echo "<option value='{$key}'> {$value} </option>";
}?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Year">Year <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_year" name="year" value="<?php echo set_value('year'); ?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="ISBN">Textbook ISBN (Optional)</label>
<input type="text" class="form-control data-input" id="form_isbn" name="isbn" value="<?php echo set_value('isbn'); ?>"/>
</div>
<!-- <div class="form-group col-md-5 col-sm-12 ">
<label for="Paypal Email">PayPal Email to pay out to you <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_paypal_email" name="paypal_email" value="<?php echo set_value('paypal_email'); ?>"/>
</div> -->
<div class="form-group col-md-5 col-sm-12 ">
<div class="mkd-upload-form-btn-wrapper">
<label for="File">Notes <b class="required_field"> * </b></label>
<button class="mkd-upload-btn btn btn-primary d-block">Upload a file</button>
<input type="file" name="file_upload" id="file_upload" onchange="onFileUploaded(event, 'file')" accept=".doc,.docx,.pdf,.txt,.xls,.xlsx,.xml"/>
<input type="hidden" id="file" name="file"/>
<input type="hidden" id="file_id" name="file_id"/>
<span id="file_text" class="mkd-upload-filename"></span>
</div>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<div class="mkd-upload-form-btn-wrapper">
<label for="File">Preview <b class="required_field"> * </b></label>
<button class="mkd-upload-btn btn btn-primary d-block">Upload a file</button>
<input type="file" name="file_upload2" id="file_upload2" onchange="onFileUploadedCustom(event, 'feature_image')" accept=".doc,.docx,.pdf,.txt,.rtf,.xls,.xlsx,.xml"/>
<input type="hidden" id="feature_image" name="feature_image"/>
<input type="hidden" id="feature_image_id" name="feature_image_id"/>
<span id="file_text2" class="mkd-upload-filename"></span>
</div>
</div>
<!-- <div class="form-group col-md-5 col-sm-12">
<label for="Feature Image">Feature Image <b class="required_field"> * </b></label>
<img id="output_feature_image" style="max-height:100px" onerror=\"if (this.src != '/uploads/placeholder.jpg') this.src = '/uploads/placeholder.jpg';\"/>
<div class="btn uppload-button image_id_uppload_library btn-primary btn-sm " data-image-url="feature_image" data-image-id="feature_image_id" data-image-preview="output_feature_image" data-view-width="250" data-view-height="250" data-boundary-width="500" data-boundary-height="500">Choose Image</div>
<div class='btn btn-success' onclick='show_image_gallery("feature_image", "feature_image_id")'>Gallery</div>
<div class="btn btn-primary btn-sm mkd-media-gallery" data-target="#mkd-media-gallery" data-toggle="modal" data-view-width="250" data-view-height="250" data-boundary-width="500" data-boundary-height="500">Media Gallery</div>
<input type="hidden" id="feature_image" name="feature_image" value=""/>
<input type="hidden" id="feature_image_id" name="feature_image_id" value=""/>
<span id="feature_image_complete" class="image_complete_uppload" ></span>
</div> -->
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary text-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<!-- Add suggestion modal start -->
<div class="modal fade" id="add-suggestion-modal" tabindex="-1" role="dialog" aria-labelledby="cardAddLabel" aria-hidden="true">
<div class="modal-dialog modal-md modal-dialog-centered" role="document">
<div class="modal-content">
<div class="modal-header bg-dark text-white">
<h5 class="modal-title" id="cardAddLabel">Submit Suggestion</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true" class="text-white">&times;</span>
</button>
</div>
<form class="p-3 add_suggestion_form" autocomplete="off">
<div class="form-row justify-content-between">
<div class="col-12 my-3">
<label for="name" class="required">Name</label>
<input type="text" name="name" placeholder="Enter Name" class="form-control name" />
</div>
<div class="col-12 my-3">
<label for="email" class="required">Email</label>
<input type="email" name="email" placeholder="Enter Email" class="form-control email" />
</div>
<div class="col-12 my-3">
<label for="phone" class="required">Suggestion Type</label>
<select class="form-control suggestion_type" name="suggestion_type" id="suggestion_type">
<option value="0">--Select--</option>
<option value="1">School</option>
<option value="2">Professor</option>
<option value="3">Textbook</option>
<option value="4">Class</option>
</select>
</div>
<div class="col-12 my-3">
<label for="suggestion_name" class="required">Suggestion Name</label>
<input type="text" name="suggestion_name" placeholder="Enter Suggestion Name" class="form-control suggestion_name" />
</div>
<div class="col-12 my-3">
<label for="additional_notes" class="required">Additional Notes</label>
<input type="text" name="additional_notes" placeholder="Enter Additional Notes" class="form-control additional_notes" />
</div>
<div class="col-12 my-3">
<button type="submit" class="btn btn-primary submit_suggestion_btn">Submit</button>
<a class="btn btn-danger reset_suggestion_form" href="">Reset Form</a>
</div>
</div>
</form>
</div>
</div>
</div>
<!-- Add suggestion modal end -->
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<script>
$('.select2').select2();
//hammad
function onFileUploadedCustom(event, id,name="file_upload") {
var selectedFile = event.target.files[0];
var formData = new FormData();
formData.append("file", selectedFile, "file");
jQuery.ajax({
url: "/v1/api/file/upload",
type: "post",
data: formData,
processData: false,
contentType: false,
cache: false,
async: false,
success: function (data) {
$("#feature_image").val(data.file);
$("#feature_image_id").val(data.id);
$("#file_text2").html(data.file);
}
});
}
$(document).ready(function() {
// on click add suggestion link
$('.add_suggestion_link').click(function(e){
e.preventDefault();
$('#add-suggestion-modal').modal('toggle');
return false;
});
// submit suggestion form
$('.add_suggestion_form').submit(function (e) {
e.preventDefault();
$('.submit_suggestion_btn').prop('disabled', true);
var name = $('.name').val();
var email = $('.email').val();
var suggestion_type = $('.suggestion_type').val();
var suggestion_name = $('.suggestion_name').val();
var additional_notes = $('.additional_notes').val();
if (name == '' || name == 0) {
toastr.error('Insert name');
$('.submit_suggestion_btn').prop('disabled', false);
return false;
}
if (email == '' || email == 0) {
toastr.error('Insert email');
$('.submit_suggestion_btn').prop('disabled', false);
return false;
}
function validateEmail(email) {
const re = /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
return re.test(email);
}
if (!validateEmail(email)) {
toastr.error('Enter a valid email.');
$('.submit_suggestion_btn').prop('disabled', false);
return false;
}
if (suggestion_type == '' || suggestion_type == 0) {
toastr.error('Select suggestion type');
$('.submit_suggestion_btn').prop('disabled', false);
return false;
}
if (suggestion_name == '' || suggestion_name == 0) {
toastr.error('Insert suggestion name');
$('.submit_suggestion_btn').prop('disabled', false);
return false;
}
$.ajax({
type: 'POST',
url: '/v1/api/member/suggestion/add',
dataType: 'JSON',
timeout: 5000,
data: {
name: name,
email: email,
suggestion_type: suggestion_type,
suggestion_name: suggestion_name,
additional_notes: additional_notes
},
success: function (response) {
if (response.success) {
$('#add-suggestion-modal').modal('toggle');
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function () {
location.reload();
};
toastr.success(response.msg);
}
if (response.error) {
$('#add-suggestion-modal').modal('toggle');
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function () {
location.reload();
};
toastr.error(response.msg);
}
},
});
return false;
});
// reset suggestion form
$('.reset_suggestion_form').click(function(e){
e.preventDefault();
$('.name').val('');
$('.email').val('');
$('.suggestion_type').val('0');
$('.suggestion_name').val('');
$('.additional_notes').val('');
return false;
});
});
</script>
+221
View File
@@ -0,0 +1,221 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start">
<!-- <li class="breadcrumb-item active" aria-current="page">
<a href="/member/dashboard" class="breadcrumb-link">Dashboard</a>
</li> -->
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/inventory/0" class="breadcrumb-link">Notes</a>
</li>
<li class="breadcrumb-item active" aria-current="page">
Edit
</li>
</ol>
</div>
<style>
.select2-container .select2-selection--single {
height: 36px !important;
}
.select2-container--default .select2-selection--single .select2-selection__rendered{
line-height: 32px !important;
}
</style>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Edit Notes
</h5>
<?= form_open() ?>
<!-- <div class="form-group col-md-5 col-sm-12">
<label for="Title">Title <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_title" name="title" value="<?php echo set_value('title', $this->_data['view_model']->get_title());?>"/>
</div> -->
<div class="form-group col-md-5 col-sm-12">
<label for="School ID">School <b class="required_field"> * </b></label>
<select id="form_school_id" name="school_id" class="select2 form-control data-input" required>
<option>--Select--</option>
<?php
if (!empty($schools)):
foreach ($schools as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_school_id()==$res1->id ? 'selected' :'';?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Professor ID">Professor <b class="required_field"> * </b></label>
<select id="form_professor_id" name="professor_id" class="select2 form-control data-input" required>
<option>--Select--</option>
<?php
if (!empty($professors)):
foreach ($professors as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_professor_id()==$res1->id ? 'selected' : '' ; ?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Class ID">Course <b class="required_field"> * </b></label>
<select id="form_class_id" name="class_id" class="select2 form-control data-input" required>
<option>--Select--</option>
<?php
if (!empty($classes)):
foreach ($classes as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_class_id()==$res1->id ? 'selected' :'';?> ><?=$res1->name;?></option>
<?php
endforeach;
endif;
?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Textbook ID">Textbook <b class="required_field"> </b></label>
<input type="text" name="isbn" class="form-control" value="<?php echo $this->_data['view_model']->get_isbn() ?? ''?>" />
<?php /* <select id="form_textbook_id" name="textbook_id" class="select2 form-control data-input" >
<option>--Select--</option>
<?php
if (!empty($textbooks)):
foreach ($textbooks as $res1): ?>
<option value='<?=$res1->id;?>' <?= $this->_data['view_model']->get_textbook_id()==$res1->id ? 'selected' :'';?> ><?=$res1->isbn;?></option>
<?php
endforeach;
endif;
?>
</select>
*/?>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Word Count">Word Count <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_word_count" name="word_count" value="<?php echo set_value('word_count', $this->_data['view_model']->get_word_count());?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Year">Year <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_year" name="year" value="<?php echo set_value('year', $this->_data['view_model']->get_year());?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<!-- <div class="form-group col-md-5 col-sm-12">
<label for="ISBN">ISBN </label>
<input type="text" class="form-control data-input" id="form_isbn" name="isbn" value="<?php echo set_value('isbn', $this->_data['view_model']->get_isbn());?>"/>
</div> -->
<!-- <div class="form-group col-md-5 col-sm-12">
<label for="Paypal Email">Paypal Email <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_paypal_email" name="paypal_email" value="<?php echo set_value('paypal_email', $this->_data['view_model']->get_paypal_email());?>"/>
</div> -->
<div class="form-group col-md-5 col-sm-12">
<!-- <div class="mkd-upload-form-btn-wrapper"> -->
<label for="File">File <b class="required_field"> * </b></label>
<!-- <button class="mkd-upload-btn btn btn-primary d-block">Upload a file</button>
<input type="file" name="file_upload" id="file_upload" onchange="onFileUploaded(event, 'file')" accept=".doc,.docx,.pdf,.txt,.rtf,.xls,.xlsx,.xml"/>
<input type="hidden" id="file" name="file" value="<?php echo set_value('file', $this->_data['view_model']->get_file());?>"/>
<input type="hidden" id="file_id" name="file_id" value="<?php echo set_value('file_id', $this->_data['view_model']->get_file_id());?>"/> -->
<span id="file_text" class="mkd-upload-filename"><?php echo set_value('file', $this->_data['view_model']->get_file());?></span>
<!-- </div> -->
</div>
<!-- <div class="form-group col-md-5 col-sm-12 ">
<div class="mkd-upload-form-btn-wrapper">
<label for="File">Preview <b class="required_field"> * </b></label>
<button class="mkd-upload-btn btn btn-primary d-block">Upload a file</button>
<input type="file" name="file_upload2" id="file_upload2" onchange="onFileUploadedCustom(event, 'feature_image')" accept=".doc,.docx,.pdf,.txt,.rtf,.xls,.xlsx,.xml"/>
<input type="hidden" id="feature_image" name="feature_image" value="<?php echo set_value('file', $this->_data['view_model']->get_feature_image());?>"/>
<input type="hidden" id="feature_image_id" name="feature_image_id" value="<?php echo set_value('feature_image_id', $this->_data['view_model']->get_feature_image_id());?>"/>
<span id="file_text2" class="mkd-upload-filename"><?php echo set_value('file', $this->_data['view_model']->get_feature_image());?></span>
</div>
</div>
-->
<div class="form-group col-md-5 col-sm-12">
<label for="Note Type">Note Type <b class="required_field"> * </b></label>
<select id="form_note_type" name="note_type" class="form-control data-input">
<?php foreach ($view_model->note_type_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_note_type() == $key && $view_model->get_note_type() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
<!-- <div class="form-group col-md-5 col-sm-12">
<label for="Description">Description </label>
<textarea id='form_description' name='description' class='data-input form-control' rows='5'><?php echo set_value('description', $this->_data['view_model']->get_description());?></textarea>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Inventory Note">Additional Note </label>
<textarea id='form_inventory_note' name='inventory_note' class='data-input form-control' rows='5'><?php echo set_value('inventory_note', $this->_data['view_model']->get_inventory_note());?></textarea>
</div> -->
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary ext-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<script>
$('.select2').select2();
//hammad
function onFileUploadedCustom(event, id,name="file_upload") {
var selectedFile = event.target.files[0];
var formData = new FormData();
formData.append("file", selectedFile, "file");
jQuery.ajax({
url: "/v1/api/file/upload",
type: "post",
data: formData,
processData: false,
contentType: false,
cache: false,
async: false,
success: function (data) {
$("#feature_image").val(data.file);
$("#feature_image_id").val(data.id);
$("#file_text2").html(data.file);
}
});
}
</script>
+193
View File
@@ -0,0 +1,193 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2021*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start" style="background-color: inherit;">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/inventory/0" class="breadcrumb-link">Notes</a>
</li>
<li class="breadcrumb-item active" aria-current="page">
View
</li>
</ol>
</div>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card pb-5" style='border-bottom:1px solid #ccc;'>
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
Notes Details
</h5>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_id();?>
</div>
</div>
<!-- <div class='row mb-4'>
<div class='col-lg-3 col-12'>
Title
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_title();?>
</div>
</div> -->
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
School
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_school_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Professor
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_professor_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Course
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_class_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Textbook
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_isbn();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Word Count
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_word_count();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Year
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_year();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
ISBN
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_isbn();?>
</div>
</div>
<!-- <div class='row mb-4'>
<div class='col-lg-3 col-12'>
Paypal Email
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_paypal_email();?>
</div>
</div> -->
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
File
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_file();?>
</div>
</div>
<!-- <div class='row mb-4'>
<div class='col-lg-3 col-12'>
Preview
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_feature_image();?>
</div>
</div> -->
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Note Type
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->note_type_mapping()[$view_model->get_note_type()];?>
</div>
</div>
<!-- <div class='row mb-4'>
<div class='col-lg-3 col-12'>
Description
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_description();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Additional Note
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_inventory_note();?>
</div>
</div> -->
<!--
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Pin to top
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->pin_to_top_mapping()[$view_model->get_pin_to_top()];?>
</div>
</div> -->
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Approve
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->approve_mapping()[$view_model->get_approve()];?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Status
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->status_mapping()[$view_model->get_status()];?>
</div>
</div>
</div>
</div>
</div>
</div>
+138
View File
@@ -0,0 +1,138 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<title>OutlineGurus</title>
<style>
.form-container {
width: 40%;
min-width: 300px;
max-width: 500px;
border: 1px solid #ccc;
height: auto;
margin: 50px auto;
}
.btn-primary {
background-color: #2C5ED6;
}
@media (max-width: 500px) {
h1 {
font-size: 24px;
}
.form-container {
margin: 10px auto;
}
}
</style>
<style>
#logo{
width: 180px;
}
.navbar{
padding:3px 10px !important;
}
#Navbar2{
text-align: center;
}
.nav-link{
color:blue;
}
.nav-link.active{
text-decoration: underline;
}
</style>
</head>
<body>
<nav class="navbar navbar-expand-sm bg-light navbar-danger" style="margin-bottom: 1px">
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#Navbar">
<span class="navbar-toggler-icon"><img
src="https://img.icons8.com/material-outlined/24/000000/menu--v1.png" /></span>
</button>
<!-- Brand/logo -->
<a href="<?php echo base_url();?>"><img class="navbar-brand" id="logo" src="<?php echo base_url();?>assets/frontend/img/Logo Files/Logo Files/SVG/Artboard 1 copy.svg" /></a>
<!-- Links -->
<div class="collapse navbar-collapse" id="Navbar">
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link text-dark" href="<?php echo base_url();?>member/register">Register</a>
</li>
</ul>
</div>
</nav>
<div>
<div class='text-center'>
<h1>Login</h1>
</div>
<div class="form-container p-5">
<?php echo form_open();?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="alert">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="form-group">
<label class='required' for="Email">Email</label>
<input type="email" class="form-control site-input" id="email" name="email" required="true" />
</div>
<div class="form-group text-container">
<label class='required' for="Password">Password </label>
<input type="password" class="form-control site-input" id="password" name="password" required="true" >
</div>
<div class="form-group text-container">
<input type="checkbox" value="1" name="remember_me"> &nbsp;&nbsp;Remember Me
</div>
<?php if($_GET['return_url'] ??''){
echo '<input type="hidden" name="return_url" value="'.$_GET['return_url'].'" /> ';
}
?>
<div class="form-group">
<input type="submit" name='btn-login' class="btn btn-primary btn-block" value="Login">
</div>
<div class="form-group mt-3 d-flex justify-content-center">
<a href="/<?php echo $portal;?>/forgot" id="mkd-forgot-password-link">Forgot password?</a>
</div>
</form>
</div>
</div>
<div class="row justify-content-center mt-0" style=" width: 100%;">
<div class="col-auto mt-3">
<p>© Copyright 2021 Outline Gurus</p>
</div>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" crossorigin="anonymous"></script>
</body>
</html>
+63
View File
@@ -0,0 +1,63 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<br/>
<div class="tab-content m-4" id="nav-tabContent">
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<br/>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Change Password
</h5>
<?= form_open() ?>
<div class="form-group col-md-5 col-sm-12">
<label for="Email">Email </label>
<input type="text" class="form-control data-input" id="form_email" name="email" value="<?php echo set_value('email', $this->_data['email']);?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Password">Password </label>
<input type="password" class="form-control data-input" id="form_password" name="password" value=""/>
</div>
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary ext-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
</div>
+94
View File
@@ -0,0 +1,94 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
<br/>
<div class="tab-content m-4" id="nav-tabContent">
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="row">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body pb-3 pl-3 pr-3">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3 mt-1">
Edit Profile
</h5>
<?= form_open() ?>
<!-- <div class="form-group col-md-5 col-sm-12">
<label for="Username">Username </label>
<input type="text" class="form-control" id="form_username" name="username" value="<?php echo set_value('username', $this->_data['username'] );?>"/>
</div> -->
<div class="form-group col-md-5 col-sm-12">
<label for="Email">Email </label>
<input type="email" class="form-control" id="form_email" name="email" value="<?php echo set_value('email', $this->_data['view_model']->get_email());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Password">Password </label>
<input type="password" class="form-control" id="form_password" name="password" value=""/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="First Name">First Name </label>
<input type="text" class="form-control" id="form_first_name" name="first_name" value="<?php echo set_value('first_name', $this->_data['view_model']->get_first_name());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Last Name">Last Name </label>
<input type="text" class="form-control" id="form_last_name" name="last_name" value="<?php echo set_value('last_name', $this->_data['view_model']->get_last_name());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Phone">Phone (Optional) </label>
<input type="text" class="form-control" id="form_phone" name="phone" value="<?php echo set_value('phone', (($this->_data['phone']) ? $this->_data['phone'] : ''));?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="form_category_id">School (Optional) </label>
<select id="form_category_id" name="school_id" class="form-control data-input select2">
<option value="">--Select--</option>
<?php foreach ( $this->_data['schools'] as $key)
{
echo "<option value='{$key->id}' " . (($this->_data['school_id'] == $key->id && $this->_data['school_id'] != '') ? 'selected' : '') . "> {$key->name} </option>";
} ?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<script>
$('.select2').select2();
</script>
+316
View File
@@ -0,0 +1,316 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
?>
<div class="tab-content mx-4" id="nav-tabContent">
<br>
<div class="clear"></div>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<style>
th:first-child{
width: 113px !important;
}
</style>
<section>
<!-- <div class="row filter-section">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card" id="purchases_filter_listing">
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
Purchased Notes
</h5>
<?= form_open('/member/purchases/0', ['method' => 'get']) ?>
<div class="row">
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="ID">ID </label>
<input type="text" class="form-control" id="id" name="id" value="<?php echo $this->_data['view_model']->get_id();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="school_id">School</label>
<select name="school_id" id="school" class="form-control select2">
<option value="">All</option>
<?php foreach ($this->_data['schools'] as $key => $value)
{
echo "<option value='{$value->id}' " . (( ( $_GET['school_id'] ??0) == $value->id ) ? 'selected' : '') . "> {$value->name} </option>";
} ?>
</select>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="professor_id">Professor</label>
<select name="professor_id" id="professor" class="form-control select2">
<option value="">All</option>
<?php foreach ($this->_data['professors'] as $key => $value)
{
echo "<option value='{$value->id}' " . ((( $_GET['professor_id'] ??0) == $value->id ) ? 'selected' : '') . "> {$value->name} </option>";
} ?>
</select>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Inventory ID">Year </label>
<input type="text" class="form-control" id="inventory_id" name="year" value="<?php echo $_GET['year'] ?? ''?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Order Date">Order Date </label>
<input type="date" class="form-control" id="order_date" name="order_date" value="<?php echo $this->_data['view_model']->get_order_date();?>"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Status">Status </label>
<select name="status" class="form-control select2">
<option value="">All</option>
<?php foreach ($view_model->status_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_status() == $key && $view_model->get_status() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
</div>
<input type="hidden" name="order_by" value="<?php echo $view_model->get_order_by();?>"/>
<input type="hidden" name="direction" value="<?php echo $view_model->get_sort();?>"/>
<div style="width:100%;height:10px;display:block;float:none;"></div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<input type="hidden" id="form_per_page" value="<?php echo $this->_data['view_model']->get_per_page() ?>" name="per_page_sort">
<input type="submit" name="submit" class="btn btn-primary" value="Search">
<a class="btn btn-danger" name="submit" type="button" href="<?php echo $view_model->get_sort_base_url().'?order_by=id&direction=DESC&per_page_sort='.$this->_data['view_model']->get_per_page(); ?>">Clear Search</a>
</div>
</div>
</div>
</form>
</div>
</div>
</div> -->
</section>
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4">
Purchased Notes
<span class=""></span>
</h5>
<section class="table-placeholder bg-white mb-5 p-3 pl-4 pr-4 pt-4" style="height:auto;">
<div class="table-responsive">
<div class="row">
<div class="col p-2">
<div class="float-right mr-1"></div>
</div>
<div class="clearfix"></div>
</div>
<input type="hidden" id="per_page" value="<?php echo $this->_data['view_model']->get_per_page(); ?>" >
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="dataTables_length" id="config-table_length">
<small class="d-flex align-items-baseline">Show
<select data-sorturl="<?php echo $view_model->get_sort_base_url(); ?>" id="change_per_page" name="config-table_length" aria-controls="config-table" class="form-control form-control-sm mx-2" style="width: auto;margin-bottom: 10px;">
<?php if(isset($_GET['per_page_sort'])) { ?>
<option value="10" <?php echo ($_GET['per_page_sort'] == '5' && $_GET['per_page_sort']) ? 'selected' : '';?>>5</option>
<option value="10" <?php echo ($_GET['per_page_sort'] == '10' && $_GET['per_page_sort']) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($_GET['per_page_sort'] == '25' && $_GET['per_page_sort']) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($_GET['per_page_sort'] == '50' && $_GET['per_page_sort']) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($_GET['per_page_sort'] == '100' && $_GET['per_page_sort']) ? 'selected' : '';?>>100</option>
<?php } else { ?>
<option value="10" <?php echo ($this->_data['view_model']->get_per_page() == '10' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($this->_data['view_model']->get_per_page() == '25' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($this->_data['view_model']->get_per_page() == '50' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($this->_data['view_model']->get_per_page() == '100' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>100</option>
<?php } ?>
</select>
entries</small>
</div>
</div>
</div>
<table class="display nowrap table table-hover table-striped table-bordered w-100 table-compact mb-0 mkd-table-container">
<thead class=''>
<?php
$order_by = $view_model->get_order_by();
$direction = $view_model->get_sort();
$model_base_url = $view_model->get_sort_base_url();
$field_column = $view_model->get_field_column();
$clean_mode = $view_model->get_format_layout();
$query_string = $view_model->get_query_parameter();
$per_page = $this->_data['view_model']->get_per_page();
$format_mode = '';
if ($clean_mode) {
$format_mode = '&layout_clean_mode=1';
}
foreach ($view_model->get_column() as $key => $data) {
$data_field = $field_column[$key];
if (strlen($order_by) < 1 || $data_field == '')
{
echo "<th scope='col' class='paragraphText text-center'>{$data}</th>";
}
else
{
if ($order_by === $data_field)
{
if ($direction == 'ASC')
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-asc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=DESC{$query_string}'>{$data}</a></th>";
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-desc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
} ?>
</thead>
<tbody class="tbody-light">
<?php $i=1; foreach ($view_model->get_list() as $data) { ?>
<?php
echo '<tr>';
echo '<td style=\'max-width: 200px;\'>';
// echo ' <a class="btn-link link-underline text-underline" target="__blank" href="'.$data->file_src.'">Download</a>';
echo $data->review_given==0 ? '<p><a class="btn-link link-underline text-underline" target="__blank" href="/member/review/' . $data->inventory_id . '/'.$data->id.'">Leave Review</a></p>' : '' ;
echo $data->dispute_given ==1 ? '' :'<p><a class="btn-link link-underline text-underline" target="__blank" href="/member/dispute_order/' . $data->id . '">Dispute</a></p>';
echo '</td>';
echo "<td>{$data->id}</td>";
echo "<td>".($data->school ?? '')."</td>";
echo "<td>".($data->professor ?? '')."</td>";
echo "<td>{$data->word_count}</td>";
echo "<td>{$data->year}</td>";
echo "<td>" . date('F d Y', strtotime($data->order_date)) . "</td>";
echo "<td>" . ucfirst($view_model->status_mapping()[$data->status]) ."</td>";
echo '</tr>';
?>
<?php $i++; } ?>
</tbody>
</table>
<small><?php echo $view_model->get_total_rows();?> results found</small>
<span class="pagination_custom">
<?php echo $view_model->get_links(); ?>
</span>
</div>
</section>
</div>
<?php
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
echo '<style>.filter-section {display: none !important;}</style>';
echo '<style>#tab-content{padding:0px !important; margin:0px !important;}</style>';
}
?>
<!-- delete modal -->
<div class="modal fade" id="deleteModal" tabindex="-1" role="dialog" aria-labelledby="deleteModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">Delete <?php echo $view_model->get_heading();?></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<p>Are you sure you want to delete?</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary text-white close_btn" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger delete_confirm_btn">Confirm</button>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<script>
$(document).ready(function() {
$('.select2').select2();
$(".remove_link").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
$('#deleteModal').modal('show');
var id = e.currentTarget.getAttribute('data-id');
if (id != 0 || id != '') {
$(".delete_confirm_btn").click(function(e) {
e.preventDefault();
$('.delete_confirm_btn').prop('disabled',true);
$('.close_btn').prop('disabled',true);
// toastr.info(id);
// return false;
$.ajax({
url: '/v1/api/member/purchases/delete',
type: "POST",
data: { id: id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.error(response.msg);
}
},
});
return false;
});
} else {
toastr.error('Data not found.');
return false;
}
});
});
</script>
+148
View File
@@ -0,0 +1,148 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2021*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start" style="background-color: inherit;">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/purchases/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
View
</li>
</ol>
</div>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card pb-5" style='border-bottom:1px solid #ccc;'>
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
<?php echo $view_model->get_heading();?> Details
</h5>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Purchase User ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_purchase_user_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Sale User ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_sale_user_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Inventory ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_inventory_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Order Date
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_order_date();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Order Time
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_order_time();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Subtotal
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_subtotal();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Tax
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_tax();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Discount
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_discount();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Total
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_total();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Stripe Charge ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_stripe_charge_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
xyzstripe_intent
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_stripe_intent();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Status
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->status_mapping()[$view_model->get_status()];?>
</div>
</div>
</div>
</div>
</div>
</div>
+143
View File
@@ -0,0 +1,143 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<title>outlineguru</title>
<style>
.form-container {
width: 40%;
min-width: 300px;
max-width: 500px;
border: 1px solid #ccc;
height: auto;
margin: 50px auto;
}
@media (max-width: 500px) {
h1 {
font-size: 24px;
}
.form-container {
margin: 10px auto;
}
}
#logo{
width: 180px;
}
.navbar{
padding:3px 10px !important;
}
#Navbar2{
text-align: center;
}
.nav-link{
color:blue;
}
.nav-link.active{
text-decoration: underline;
}
</style>
</head>
<body>
<nav class="navbar navbar-expand-sm bg-light navbar-danger" style="margin-bottom: 1px">
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#Navbar">
<span class="navbar-toggler-icon"><img
src="https://img.icons8.com/material-outlined/24/000000/menu--v1.png" /></span>
</button>
<!-- Brand/logo -->
<a href="<?php echo base_url();?>"><img class="navbar-brand" id="logo" src="<?php echo base_url();?>/assets/frontend/img/Logo Files/Logo Files/SVG/Artboard 1 copy.svg" /></a>
<!-- Links -->
<div class="collapse navbar-collapse" id="Navbar">
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link text-dark" href="<?php echo base_url();?>member/login">Login</a>
</li>
</ul>
</div>
</nav>
<div class="">
<div class='text-center'>
<h1>Register</h1>
</div>
<div class="form-container p-5">
<?php echo form_open();?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="alert">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<!-- <div class="form-group">
<label class='required' for="Username">Username</label>
<input type="text" class="form-control site-input" id="username" name="username" required="true" value="<?php echo set_value('username'); ?>" />
</div> -->
<?php if($_GET['return_url'] ??''){
echo '<input type="hidden" name="return_url" value="'.$_GET['return_url'].'" /> ';
}
?>
<div class="form-group">
<label class='required' for="Email">Email</label>
<input type="email" class="form-control site-input" id="email" name="email" required="true" value="<?php echo set_value('email'); ?>" />
</div>
<div class="form-group">
<label class='required' for="First Name">First Name</label>
<input type="text" class="form-control site-input" id="first_name" name="first_name" required="true" value="<?php echo set_value('first_name'); ?>" />
</div>
<div class="form-group">
<label class='required' for="xyzlast Name">Last Name</label>
<input type="text" class="form-control site-input" id="last_name" name="last_name" required="true" value="<?php echo set_value('last_name'); ?>" />
</div>
<div class="form-group text-container">
<label class='required' for="Password">Password </label>
<input type="password" class="form-control site-input" id="password" name="password" required="true" >
</div>
<div class="form-group text-container">
<label class='required' for="Repeat Password">Repeat Password </label>
<input type="password" class="form-control site-input" id="confirm_password" name="confirm_password" required="true" >
</div>
<div class="form-group">
<input type="submit" name='btn-login' class="btn btn-primary btn-block" value="Sign Up">
</div>
</form>
</div>
</div>
<div class="row justify-content-center mt-0" style=" width: 100%;">
<div class="col-auto mt-3">
<p>© Copyright 2021 Outline Gurus</p>
</div>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" crossorigin="anonymous"></script>
</body>
</html>
+129
View File
@@ -0,0 +1,129 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<title>OutlineGurus</title>
<style>
.form-container {
width: 40%;
min-width: 300px;
max-width: 500px;
border: 1px solid #ccc;
height: auto;
margin: 50px auto;
}
.btn-primary {
background-color: #2C5ED6;
}
@media (max-width: 500px) {
h1 {
font-size: 24px;
}
.form-container {
margin: 10px auto;
}
}
</style>
<style>
#logo{
width: 180px;
}
.navbar{
padding:3px 10px !important;
}
#Navbar2{
text-align: center;
}
.nav-link{
color:blue;
}
.nav-link.active{
text-decoration: underline;
}
</style>
</head>
<body>
<nav class="navbar navbar-expand-sm bg-light navbar-danger" style="margin-bottom: 1px">
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#Navbar">
<span class="navbar-toggler-icon"><img src="https://img.icons8.com/material-outlined/24/000000/menu--v1.png" /></span>
</button>
<!-- Brand/logo -->
<a href="<?php echo base_url();?>"><img class="navbar-brand" id="logo" src="<?php echo base_url();?>/assets/frontend/img/Logo Files/Logo Files/SVG/Artboard 1 copy.svg" /></a>
<!-- Links -->
<div class="collapse navbar-collapse" id="Navbar">
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link text-dark" href="<?php echo base_url();?>member/login">Login</a>
</li>
</ul>
</div>
</nav>
<div class="">
<div class='text-center'>
<h1>Reset Password</h1>
</div>
<div class="form-container p-5">
<?php echo form_open();?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="alert">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="form-group">
<label class='required' for="Email">Password</label>
<input name="password" type="password" class="form-control site-input" required="true">
</div>
<div class="form-group text-container">
<label class='required' for="Email">Confirm Password </label>
<input name="confirm_password" type="password" class="form-control site-input" required="true">
</div>
<div class="form-group">
<input type="submit" name='btn-login' class="btn btn-primary btn-block" value="Reset Password">
</div>
<div class="form-group mt-3 d-flex justify-content-center">
<a href="/member/login" id="mkd-forgot-password-link">Back</a>
</div>
</form>
</div>
</div>
<div class="row justify-content-center mt-0" style=" width: 100%;">
<div class="col-auto mt-3">
<p>© Copyright 2021 Outline Gurus</p>
</div>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" crossorigin="anonymous"></script>
</body>
+58
View File
@@ -0,0 +1,58 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
<div class="row">
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4 ml-3">
Review
<span class=""></span>
</h5>
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body pb-3 pl-3 pr-3">
<?php if(($this->_data['status_'] ?? '')=='success') { ?>
<div class="alert alert-success" role="alert">
<?php echo $this->_data['status_msg'];?>
</div>
<?php } ?>
<?php if(($this->_data['status_'] ?? '')=='error') { ?>
<div class="alert alert-danger" role="alert">
<?php echo $this->_data['status_msg'];?>
</div>
<?php } ?>
<form method="get" action="<?php echo base_url();?>member/post_review/<?php echo $this->uri->segment(3).'/'.$this->uri->segment(4);?>">
<input type="hidden" name="inventory_id" value="<?php echo $this->uri->segment(3) ?? ($_GET['inventory_id']??'') ;?>" />
<div class="form-group col-md-5 col-sm-12">
<h5 class="primaryHeading2 ">
Comment
</h5>
<textarea name="comment" class="form-control"></textarea>
</div>
<div class="form-group col-md-5 col-sm-12">
<h5 class="primaryHeading2 ">
Review
</h5>
<select name="review" required class="form-control ">
<option value="1">1/10</option>
<option value="2">2/10</option>
<option value="3">3/10</option>
<option value="4">4/10</option>
<option value="5">5/10</option>
<option value="6">6/10</option>
<option value="7">7/10</option>
<option value="8">8/10</option>
<option value="9">9/10</option>
<option value="10">10/10</option>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<input class="btn btn-primary" type="submit" name="submit" value="Save" />
</div>
</form>
</div>
</div>
</div>
</div>
+296
View File
@@ -0,0 +1,296 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
?>
<div class="tab-content mx-4" id="nav-tabContent">
<br>
<div class="clear"></div>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<section>
<!-- <div class="row filter-section">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card" id="sales_filter_listing">
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
<?php echo $view_model->get_heading();?> Search
</h5>
<?= form_open('/member/sales/0', ['method' => 'get']) ?>
<div class="row">
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="ID">ID </label>
<input type="text" class="form-control" id="id" name="id" value="<?php echo $this->_data['view_model']->get_id();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="User ID">User ID </label>
<input type="text" class="form-control" id="user_id" name="user_id" value="<?php echo $this->_data['view_model']->get_user_id();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Order ID">Order ID </label>
<input type="text" class="form-control" id="order_id" name="order_id" value="<?php echo $this->_data['view_model']->get_order_id();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Amount">Amount </label>
<input type="text" class="form-control" id="amount" name="amount" value="<?php echo $this->_data['view_model']->get_amount();?>"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Created At">Created At </label>
<input type="date" class="form-control" id="created_at" name="created_at" value="<?php echo $this->_data['view_model']->get_created_at();?>"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Status">Status </label>
<select name="status" class="form-control">
<option value="">All</option>
<?php foreach ($view_model->status_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_status() == $key && $view_model->get_status() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
</div>
<input type="hidden" name="order_by" value="<?php echo $view_model->get_order_by();?>"/>
<input type="hidden" name="direction" value="<?php echo $view_model->get_sort();?>"/>
<div style="width:100%;height:10px;display:block;float:none;"></div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<input type="hidden" id="form_per_page" value="<?php echo $this->_data['view_model']->get_per_page() ?>" name="per_page_sort">
<input type="submit" name="submit" class="btn btn-primary" value="Search">
<a class="btn btn-danger" name="submit" type="button" href="<?php echo $view_model->get_sort_base_url().'?order_by=id&direction=DESC&per_page_sort='.$this->_data['view_model']->get_per_page(); ?>">Clear Search</a>
</div>
</div>
</div>
</form>
</div>
</div>
</div> -->
</section>
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4">
<?php echo $view_model->get_heading();?>
<span class=""></span>
</h5>
<section class="table-placeholder bg-white mb-5 p-3 pl-4 pr-4 pt-4" style="height:auto;">
<div class="table-responsive">
<div class="row">
<div class="col p-2">
<div class="float-right mr-1"></div>
</div>
<div class="clearfix"></div>
</div>
<input type="hidden" id="per_page" value="<?php echo $this->_data['view_model']->get_per_page(); ?>" >
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="dataTables_length" id="config-table_length">
<small class="d-flex align-items-baseline">Show
<select data-sorturl="<?php echo $view_model->get_sort_base_url(); ?>" id="change_per_page" name="config-table_length" aria-controls="config-table" class="form-control form-control-sm mx-2" style="width: auto;margin-bottom: 10px;">
<?php if(isset($_GET['per_page_sort'])) { ?>
<option value="10" <?php echo ($_GET['per_page_sort'] == '5' && $_GET['per_page_sort']) ? 'selected' : '';?>>5</option>
<option value="10" <?php echo ($_GET['per_page_sort'] == '10' && $_GET['per_page_sort']) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($_GET['per_page_sort'] == '25' && $_GET['per_page_sort']) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($_GET['per_page_sort'] == '50' && $_GET['per_page_sort']) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($_GET['per_page_sort'] == '100' && $_GET['per_page_sort']) ? 'selected' : '';?>>100</option>
<?php } else { ?>
<option value="10" <?php echo ($this->_data['view_model']->get_per_page() == '10' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($this->_data['view_model']->get_per_page() == '25' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($this->_data['view_model']->get_per_page() == '50' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($this->_data['view_model']->get_per_page() == '100' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>100</option>
<?php } ?>
</select>
entries</small>
</div>
</div>
</div>
<table class="display nowrap table table-hover table-striped table-bordered w-100 table-compact mb-0 mkd-table-container">
<thead class=''>
<?php
$order_by = $view_model->get_order_by();
$direction = $view_model->get_sort();
$model_base_url = $view_model->get_sort_base_url();
$field_column = $view_model->get_field_column();
$clean_mode = $view_model->get_format_layout();
$query_string = $view_model->get_query_parameter();
$per_page = $this->_data['view_model']->get_per_page();
$format_mode = '';
if ($clean_mode) {
$format_mode = '&layout_clean_mode=1';
}
foreach ($view_model->get_column() as $key => $data) {
$data_field = $field_column[$key];
if (strlen($order_by) < 1 || $data_field == '')
{
echo "<th scope='col' class='paragraphText text-center'>{$data}</th>";
}
else
{
if ($order_by === $data_field)
{
if ($direction == 'ASC')
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-asc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=DESC{$query_string}'>{$data}</a></th>";
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-desc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
} ?>
</thead>
<tbody class="tbody-light">
<?php $i=1; foreach ($view_model->get_list() as $data) { ?>
<?php
echo '</td>'; echo "<td>{$data->id}</td>";
// echo "<td>{$data->user_id}</td>";
echo "<td>{$data->order_id}</td>";
echo "<td>{$data->inventory_id}</td>";
echo "<td>{$data->school}</td>";
echo "<td>{$data->professor}</td>";
echo "<td>{$data->class}</td>";
echo "<td>{$data->isbn}</td>";
echo "<td>$".$data->amount."</td>";
echo "<td>{$data->created_at}</td>";
echo "<td>" . ucfirst($view_model->status_mapping()[$data->status]) ."</td>";
echo '</tr>';
?>
<?php $i++; } ?>
</tbody>
</table>
<small><?php echo $view_model->get_total_rows();?> results found</small>
<span class="pagination_custom">
<?php echo $view_model->get_links(); ?>
</span>
</div>
</section>
</div>
<?php
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
echo '<style>.filter-section {display: none !important;}</style>';
echo '<style>#tab-content{padding:0px !important; margin:0px !important;}</style>';
}
?>
<!-- delete modal -->
<div class="modal fade" id="deleteModal" tabindex="-1" role="dialog" aria-labelledby="deleteModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">Delete <?php echo $view_model->get_heading();?></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<p>Are you sure you want to delete?</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary text-white close_btn" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger delete_confirm_btn">Confirm</button>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<script>
$(document).ready(function() {
$(".remove_link").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
$('#deleteModal').modal('show');
var id = e.currentTarget.getAttribute('data-id');
if (id != 0 || id != '') {
$(".delete_confirm_btn").click(function(e) {
e.preventDefault();
$('.delete_confirm_btn').prop('disabled',true);
$('.close_btn').prop('disabled',true);
// toastr.info(id);
// return false;
$.ajax({
url: '/v1/api/member/sales/delete',
type: "POST",
data: { id: id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.error(response.msg);
}
},
});
return false;
});
} else {
toastr.error('Data not found.');
return false;
}
});
});
</script>
+37
View File
@@ -0,0 +1,37 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
<br/>
<br/>
<div class="row">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body pb-3 pl-3 pr-3">
<?php if(($this->_data['status_'] ?? '')=='success') { ?>
<div class="alert alert-success" role="alert">
<?php echo $this->_data['status_msg'];?>
</div>
<?php } ?>
<?php if(($this->_data['status_'] ?? '')=='error') { ?>
<div class="alert alert-danger" role="alert">
<?php echo $this->_data['status_msg'];?>
</div>
<?php } ?>
<form method="get" action="<?php echo base_url();?>member/post_setting">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3 mt-1">
PayPal Email
</h5>
<div class="form-group col-md-5 col-sm-12">
<input type="email" class="form-control" name="email" autocomplete="off" value="<?php echo $this->_data['paypal_email']['paypal_email'] ??'';?>" />
</div>
<div class="form-group col-md-5 col-sm-12">
<input class="btn btn-primary" type="submit" name="submit" value="Save" />
</div>
</form>
</div>
</div>
</div>
</div>
+133
View File
@@ -0,0 +1,133 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootoast@1.0.1/dist/bootoast.min.css" crossorigin="anonymous">
<title>outlineguru</title>
<style>
.form-container {
width: 40%;
min-width: 300px;
max-width: 500px;
border: 1px solid #ccc;
height: auto;
margin: 50px auto;
}
.btn-primary {
background-color: #2C5ED6;
}
@media (max-width: 500px) {
h1 {
font-size: 24px;
}
.form-container {
margin: 10px auto;
}
}
</style>
</head>
<body>
<nav class="navbar navbar-expand-sm navbar-dark bg-primary mb-3">
<div class="container">
<a class="navbar-brand" href="#">
outlineguru
<!-- <img style="height:35px" src="/assets/image/logo.png"/> -->
</a>
<div class="collapse navbar-collapse" id="navbarNav">
</div>
</div>
</nav>
<div class="">
<div class='text-center'>
<h1>Verify your Number</h1>
</div>
<div class="form-container p-5">
<?php echo form_open();?>
<?php if (strlen($error ?? '') > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success ?? '') > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="alert">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="form-group text-container">
<label class='required' for="Email">Verification Code</label>
<input type="text" class="form-control site-input" id="verification_code" name="code" value="<?php echo set_value('code'); ?>" required="true" >
</div>
<div class="form-group">
<input type="hidden" class="form-control site-input" id="phone_number" disabled name="phone" value="<?php echo $phone; ?>" />
<a id='btn-verify' class='btn btn-accent-light btn-block' href="#" style='text-decoration:underline;'>Resend Verification Code</a>
</div>
<div class="form-group">
<input type="submit" name='btn-login' class="btn btn-primary btn-block" value="Login">
</div>
</form>
</div>
</div>
<div class='text-center'>&copy; <?php echo date("yy"); ?> outlineguru. All Right Reserved.</div>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/bootoast@1.0.1/dist/bootoast.min.js" crossorigin="anonymous"></script>
<script>
$(document).ready(function () {
$("#btn-verify").click(function (e) {
e.preventDefault();
var phone = $("#phone_number").val();
var url = "/member/sent_verification";
var posting = $.post(url, { phone: phone });
posting.done(function (data) {
var data = JSON.parse(data);
if (data.error == false) {
bootoast.toast({
message: "xyzVerification sent",
type: "info",
});
return;
}
if (data.error == true) {
bootoast.toast({
message: data.message || "Error",
type: "danger",
});
return;
}
});
posting.fail(function () {
bootoast.toast({
message: "Error Sending Code",
type: "danger",
});
});
});
});
</script>
<!-- Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020 -->
</body>
</html>
+285
View File
@@ -0,0 +1,285 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
?>
<div class="tab-content mx-4" id="nav-tabContent">
<br>
<div class="clear"></div>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<section>
<div class="row filter-section">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card" id="ticket_filter_listing">
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
Tickets Searchzzz
</h5>
<?= form_open('/member/ticket/0', ['method' => 'get']) ?>
<div class="row">
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Order ID">Order ID </label>
<input type="text" class="form-control" id="order_id" name="order_id" value="<?php echo $this->_data['view_model']->get_order_id();?>" onkeypress="return event.charCode >= 48 && event.charCode <= 57"/>
</div>
</div>
<!-- <div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Reason">Reason </label>
<input type="text" id='message' name='message' class='form-control' value="<?php echo $this->_data['view_model']->get_message();?>">
</div>
</div> -->
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Admin Received">Admin Received </label>
<select name="receive_status" class="form-control">
<option value="">All</option>
<?php foreach ($view_model->receive_status_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_receive_status() == $key && $view_model->get_receive_status() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Status">Status </label>
<select name="status" class="form-control">
<option value="">All</option>
<?php foreach ($view_model->status_mapping() as $key => $value) {
echo "<option value='{$key}'> {$value} </option>";
}?>
</select>
</div>
</div>
<input type="hidden" name="order_by" value="<?php echo $view_model->get_order_by();?>"/>
<input type="hidden" name="direction" value="<?php echo $view_model->get_sort();?>"/>
<div style="width:100%;height:10px;display:block;float:none;"></div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<input type="hidden" id="form_per_page" value="<?php echo $this->_data['view_model']->get_per_page() ?>" name="per_page_sort">
<input type="submit" name="submit" class="btn btn-primary" value="Search">
<a class="btn btn-danger" name="submit" type="button" href="<?php echo $view_model->get_sort_base_url().'?order_by=id&direction=DESC&per_page_sort='.$this->_data['view_model']->get_per_page(); ?>">Clear Search</a>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
</section>
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4">
Tickets
<span class=""></span>
</h5>
<section class="table-placeholder bg-white mb-5 p-3 pl-4 pr-4 pt-4" style="height:auto;">
<div class="table-responsive">
<div class="row">
<div class="col p-2">
<div class="float-right mr-1"></div>
</div>
<div class="clearfix"></div>
</div>
<input type="hidden" id="per_page" value="<?php echo $this->_data['view_model']->get_per_page(); ?>" >
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="dataTables_length" id="config-table_length">
<small class="d-flex align-items-baseline">Show
<select data-sorturl="<?php echo $view_model->get_sort_base_url(); ?>" id="change_per_page" name="config-table_length" aria-controls="config-table" class="form-control form-control-sm mx-2" style="width: auto;margin-bottom: 10px;">
<?php if(isset($_GET['per_page_sort'])) { ?>
<option value="10" <?php echo ($_GET['per_page_sort'] == '5' && $_GET['per_page_sort']) ? 'selected' : '';?>>5</option>
<option value="10" <?php echo ($_GET['per_page_sort'] == '10' && $_GET['per_page_sort']) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($_GET['per_page_sort'] == '25' && $_GET['per_page_sort']) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($_GET['per_page_sort'] == '50' && $_GET['per_page_sort']) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($_GET['per_page_sort'] == '100' && $_GET['per_page_sort']) ? 'selected' : '';?>>100</option>
<?php } else { ?>
<option value="10" <?php echo ($this->_data['view_model']->get_per_page() == '10' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($this->_data['view_model']->get_per_page() == '25' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($this->_data['view_model']->get_per_page() == '50' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($this->_data['view_model']->get_per_page() == '100' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>100</option>
<?php } ?>
</select>
entries</small>
</div>
</div>
</div>
<table class="display nowrap table table-hover table-striped table-bordered w-100 table-compact mb-0 mkd-table-container">
<thead class=''>
<?php
$order_by = $view_model->get_order_by();
$direction = $view_model->get_sort();
$model_base_url = $view_model->get_sort_base_url();
$field_column = $view_model->get_field_column();
$clean_mode = $view_model->get_format_layout();
$query_string = $view_model->get_query_parameter();
$per_page = $this->_data['view_model']->get_per_page();
$format_mode = '';
if ($clean_mode) {
$format_mode = '&layout_clean_mode=1';
}
foreach ($view_model->get_column() as $key => $data) {
$data_field = $field_column[$key];
if (strlen($order_by) < 1 || $data_field == '')
{
echo "<th scope='col' class='paragraphText text-center'>{$data}</th>";
}
else
{
if ($order_by === $data_field)
{
if ($direction == 'ASC')
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-asc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=DESC{$query_string}'>{$data}</a></th>";
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-desc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
} ?>
</thead>
<tbody class="tbody-light">
<?php $i=1; foreach ($view_model->get_list() as $data) { ?>
<?php
echo '<tr>';
// echo '<td style=\'max-width: 100px;\'>';
// echo '</td>';
echo "<td>{$data->order_ids}</td>";
echo "<td>{$data1->messages}</td>";
echo "<td>" . ucfirst($view_model->receive_status_mapping()[$data->receive_statuss]) ."</td>";
echo "<td>" . ucfirst($view_model->status_mapping()[$data->statuss]) ."</td>";
echo '</tr>';
?>
<?php $i++; } ?>
</tbody>
</table>
<small><?php echo $view_model->get_total_rows1();?> results found</small>
<span class="pagination_custom">
<?php echo $view_model->get_links2(); ?>
</span>
</div>
</section>
</div>
<?php
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
echo '<style>.filter-section {display: none !important;}</style>';
echo '<style>#tab-content{padding:0px !important; margin:0px !important;}</style>';
}
?>
<!-- delete modal -->
<div class="modal fade" id="deleteModal" tabindex="-1" role="dialog" aria-labelledby="deleteModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">Delete <?php echo $view_model->get_heading();?></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<p>Are you sure you want to delete?</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary text-white close_btn" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger delete_confirm_btn">Confirm</button>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<script>
$(document).ready(function() {
$(".remove_link").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
$('#deleteModal').modal('show');
var id = e.currentTarget.getAttribute('data-id');
if (id != 0 || id != '') {
$(".delete_confirm_btn").click(function(e) {
e.preventDefault();
$('.delete_confirm_btn').prop('disabled',true);
$('.close_btn').prop('disabled',true);
// toastr.info(id);
// return false;
$.ajax({
url: '/v1/api/member/ticket/delete',
type: "POST",
data: { id: id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.error(response.msg);
}
},
});
return false;
});
} else {
toastr.error('Data not found.');
return false;
}
});
});
</script>
+227
View File
@@ -0,0 +1,227 @@
<?php defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2021*/
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif;
?>
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4">
<?php echo $view_model->get_heading();?>
<span class="add-part d-flex justify-content-md-end text-white "><a class="btn btn-primary btn-sm" target="__blank" href="/member/transaction/add"><i class="fas fa-plus-circle"></i></a></span>
</h5>
<section class="table-placeholder bg-white mb-5 p-3 pl-4 pr-4 pt-4" style="height:auto;">
<div class="table-responsive">
<div class="row">
<div class="col p-2">
<div class="float-right mr-4"></div>
</div>
<div class="clearfix"></div>
</div>
<input type="hidden" id="per_page" value="<?php echo $this->_data['view_model']->get_per_page(); ?>" >
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="dataTables_length" id="config-table_length">
<small class="d-flex align-items-baseline">Show
<select data-sorturl="<?php echo $view_model->get_sort_base_url(); ?>" id="change_per_page" name="config-table_length" aria-controls="config-table" class="form-control form-control-sm mx-2" style="width: auto;margin-bottom: 10px;">
<?php if(isset($_GET['per_page_sort'])) { ?>
<option value="10" <?php echo ($_GET['per_page_sort'] == '5' && $_GET['per_page_sort']) ? 'selected' : '';?>>5</option>
<option value="10" <?php echo ($_GET['per_page_sort'] == '10' && $_GET['per_page_sort']) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($_GET['per_page_sort'] == '25' && $_GET['per_page_sort']) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($_GET['per_page_sort'] == '50' && $_GET['per_page_sort']) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($_GET['per_page_sort'] == '100' && $_GET['per_page_sort']) ? 'selected' : '';?>>100</option>
<?php } else { ?>
<option value="10" <?php echo ($this->_data['view_model']->get_per_page() == '10' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($this->_data['view_model']->get_per_page() == '25' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($this->_data['view_model']->get_per_page() == '50' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($this->_data['view_model']->get_per_page() == '100' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>100</option>
<?php } ?>
</select>
entries</small>
</div>
</div>
</div>
<table class="display nowrap table table-hover table-striped table-bordered w-100 table-compact mb-0 mkd-table-container">
<thead class=''>
<?php
$order_by = $view_model->get_order_by();
$direction = $view_model->get_sort();
$model_base_url = $view_model->get_sort_base_url();
$field_column = $view_model->get_field_column();
$clean_mode = $view_model->get_format_layout();
$query_string = $view_model->get_query_parameter();
$per_page = $this->_data['view_model']->get_per_page();
$format_mode = '';
if ($clean_mode) {
$format_mode = '&layout_clean_mode=1';
}
foreach ($view_model->get_column() as $key => $data) {
$data_field = $field_column[$key];
if (strlen($order_by) < 1 || $data_field == '')
{
echo "<th scope='col' class='paragraphText text-center'>{$data}</th>";
}
else
{
if ($order_by === $data_field)
{
if ($direction == 'ASC')
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-asc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=DESC{$query_string}'>{$data}</a></th>";
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-desc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
} ?>
</thead>
<tbody class="tbody-light">
<?php $i=1; foreach ($view_model->get_list() as $data) { ?>
<?php
echo '<tr>';
echo '<td style=\'max-width: 100px;\'>';
echo '<a class="btn-link link-underline text-underline" target="__blank" href="/member/transaction/edit/' . $data->id . '">Edit</a>';
echo ' <a class="btn-link link-underline text-underline" target="__blank" href="/member/transaction/view/' . $data->id . '">View</a>';
echo ' <a data-id="'.$data->id.'" class="btn-link link-underline text-underline text-danger remove_link" href="#">Remove</a>';
echo '</td>'; echo "<td>{$data->id}</td>";
echo "<td>{$data->order_id}</td>";
echo "<td>{$data->user_id}</td>";
echo "<td>" . date('F d Y', strtotime($data->transaction_date)) . "</td>";
echo "<td>{$data->transaction_time}</td>";
echo "<td>{$data->subtotal}</td>";
echo "<td>{$data->tax}</td>";
echo "<td>{$data->discount}</td>";
echo "<td>{$data->total}</td>";
echo "<td>{$data->stripe_charge_id}</td>";
echo "<td>" . ucfirst($view_model->payment_method_mapping()[$data->payment_method]) ."</td>";
echo "<td>" . ucfirst($view_model->status_mapping()[$data->status]) ."</td>";
echo '</tr>';
?>
<?php $i++; } ?>
</tbody>
</table>
<small><?php echo $view_model->get_total_rows();?> results found</small>
<span class="pagination_custom">
<?php echo $view_model->get_links(); ?>
</span>
</div>
</section>
</div>
<?php
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
echo '<style>#tab-content{padding:0px !important;margin:0px !important;}</style>';
}
?>
<!-- delete modal -->
<div class="modal fade" id="deleteModal" tabindex="-1" role="dialog" aria-labelledby="deleteModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">Delete <?php echo $view_model->get_heading();?></h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<p>Are you sure you want to delete?</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary text-white close_btn" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-danger delete_confirm_btn">Confirm</button>
</div>
</div>
</div>
</div>
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
<script>
$(document).ready(function() {
$(".remove_link").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
$('#deleteModal').modal('show');
var id = e.currentTarget.getAttribute('data-id');
if (id != 0 || id != '') {
$(".delete_confirm_btn").click(function(e) {
e.preventDefault();
$('.delete_confirm_btn').prop('disabled',true);
$('.close_btn').prop('disabled',true);
// toastr.info(id);
// return false;
$.ajax({
url: '/v1/api/member/transaction/delete',
type: "POST",
data: { id: id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 1500;
toastr.options.fadeOut = 1500;
toastr.options.onHidden = function() {
location.reload();
}
toastr.error(response.msg);
}
},
});
return false;
});
} else {
toastr.error('Data not found.');
return false;
}
});
});
</script>
+120
View File
@@ -0,0 +1,120 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/transaction/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
Add
</li>
</ol>
</div>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Add <?php echo $view_model->get_heading();?>
</h5>
<?= form_open() ?>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Order ID">Order ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_order_id" name="order_id" value="<?php echo set_value('order_id'); ?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="User ID">User ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_user_id" name="user_id" value="<?php echo set_value('user_id'); ?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Transaction Date">Transaction Date </label>
<input type="date" class="form-control data-input" id="form_transaction_date" name="transaction_date" value="<?php echo set_value('transaction_date'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Transaction Time">Transaction Time <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_transaction_time" name="transaction_time" value="<?php echo set_value('transaction_time'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Subtotal">Subtotal <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_subtotal" name="subtotal" value="<?php echo set_value('subtotal'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Tax">Tax <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_tax" name="tax" value="<?php echo set_value('tax'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Discount">Discount <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_discount" name="discount" value="<?php echo set_value('discount'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Total">Total <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_total" name="total" value="<?php echo set_value('total'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Stripe Charge ID">Stripe Charge ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_stripe_charge_id" name="stripe_charge_id" value="<?php echo set_value('stripe_charge_id'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Payment Method">Payment Method <b class="required_field"> * </b></label>
<select id="form_payment_method" name="payment_method" class="form-control data-input">
<?php foreach ($view_model->payment_method_mapping() as $key => $value) {
echo "<option value='{$key}'> {$value} </option>";
}?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Status">Status <b class="required_field"> * </b></label>
<select id="form_status" name="status" class="form-control data-input">
<?php foreach ($view_model->status_mapping() as $key => $value) {
echo "<option value='{$key}'> {$value} </option>";
}?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary text-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
</div>
+119
View File
@@ -0,0 +1,119 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start">
<!-- <li class="breadcrumb-item active" aria-current="page">
<a href="/member/dashboard" class="breadcrumb-link">Dashboard</a>
</li> -->
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/transaction/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
Edit
</li>
</ol>
</div>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Edit <?php echo $view_model->get_heading();?>
</h5>
<?= form_open() ?>
<div class="form-group col-md-5 col-sm-12">
<label for="Order ID">Order ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_order_id" name="order_id" value="<?php echo set_value('order_id', $this->_data['view_model']->get_order_id());?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="User ID">User ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_user_id" name="user_id" value="<?php echo set_value('user_id', $this->_data['view_model']->get_user_id());?>" onkeypress="return (event.charCode >= 48 && event.charCode <= 57) || (event.charCode == 45)"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Transaction Date">Transaction Date </label>
<input type="date" class="form-control data-input" id="form_transaction_date" name="transaction_date" value="<?php echo set_value('transaction_date', $this->_data['view_model']->get_transaction_date());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Transaction Time">Transaction Time <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_transaction_time" name="transaction_time" value="<?php echo set_value('transaction_time', $this->_data['view_model']->get_transaction_time());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Subtotal">Subtotal <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_subtotal" name="subtotal" value="<?php echo set_value('subtotal', $this->_data['view_model']->get_subtotal());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Tax">Tax <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_tax" name="tax" value="<?php echo set_value('tax', $this->_data['view_model']->get_tax());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Discount">Discount <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_discount" name="discount" value="<?php echo set_value('discount', $this->_data['view_model']->get_discount());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Total">Total <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_total" name="total" value="<?php echo set_value('total', $this->_data['view_model']->get_total());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Stripe Charge ID">Stripe Charge ID <b class="required_field"> * </b></label>
<input type="text" class="form-control data-input" id="form_stripe_charge_id" name="stripe_charge_id" value="<?php echo set_value('stripe_charge_id', $this->_data['view_model']->get_stripe_charge_id());?>"/>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Payment Method">Payment Method <b class="required_field"> * </b></label>
<select id="form_payment_method" name="payment_method" class="form-control data-input">
<?php foreach ($view_model->payment_method_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_payment_method() == $key && $view_model->get_payment_method() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<label for="Status">Status <b class="required_field"> * </b></label>
<select id="form_status" name="status" class="form-control data-input">
<?php foreach ($view_model->status_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_status() == $key && $view_model->get_status() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12">
<input type="submit" class="btn btn-primary ext-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
+139
View File
@@ -0,0 +1,139 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2021*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start" style="background-color: inherit;">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/transaction/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
View
</li>
</ol>
</div>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card pb-5" style='border-bottom:1px solid #ccc;'>
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
<?php echo $view_model->get_heading();?> Details
</h5>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Order ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_order_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
User ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_user_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Transaction Date
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_transaction_date();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Transaction Time
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_transaction_time();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Subtotal
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_subtotal();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Tax
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_tax();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Discount
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_discount();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Total
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_total();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Stripe Charge ID
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->get_stripe_charge_id();?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Payment Method
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->payment_method_mapping()[$view_model->get_payment_method()];?>
</div>
</div>
<div class='row mb-4'>
<div class='col-lg-3 col-12'>
Status
</div>
<div class='col-lg-9 col-12'>
<?php echo $view_model->status_mapping()[$view_model->get_status()];?>
</div>
</div>
</div>
</div>
</div>
</div>
+301
View File
@@ -0,0 +1,301 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
?>
<div class="tab-content mx-4" id="nav-tabContent">
<br>
<div class="clear"></div>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<section>
<div class="row filter-section">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card" id="user_card_filter_listing">
<div class="card-body">
<h5 class="primaryHeading2 text-md-left">
<?php echo $view_model->get_heading();?> Search
</h5>
<?= form_open('/member/user_card/0', ['method' => 'get']) ?>
<div class="row">
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Last4">Last4 </label>
<input type="text" class="form-control" id="last4" name="last4" value="<?php echo $this->_data['view_model']->get_last4();?>"/>
</div>
</div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<label for="Is Default">Is Default </label>
<select name="is_default" class="form-control">
<option value="">All</option>
<?php foreach ($view_model->is_default_mapping() as $key => $value) {
echo "<option value='{$key}' " . (($view_model->get_is_default() == $key && $view_model->get_is_default() != '') ? 'selected' : '') . "> {$value} </option>";
}?>
</select>
</div>
</div>
<input type="hidden" name="order_by" value="<?php echo $view_model->get_order_by();?>"/>
<input type="hidden" name="direction" value="<?php echo $view_model->get_sort();?>"/>
<div style="width:100%;height:10px;display:block;float:none;"></div>
<div class="col-xl-4 col-lg-4 col-md-4 col-sm-12 col-12">
<div class="form-group">
<input type="hidden" id="form_per_page" value="<?php echo $this->_data['view_model']->get_per_page() ?>" name="per_page_sort">
<input type="submit" name="submit" class="btn btn-primary" value="Search">
<a class="btn btn-danger" name="submit" type="button" href="<?php echo $view_model->get_sort_base_url().'?order_by=id&direction=DESC&per_page_sort='.$this->_data['view_model']->get_per_page(); ?>">Clear Search</a>
</div>
</div>
</div>
</form>
</div>
</div>
</div>
</section>
<h5 class="primaryHeading2 d-flex justify-content-between mt-2 my-4">
<?php echo $view_model->get_heading();?>
<span class="add-part d-flex justify-content-md-end text-white "><a class="btn btn-primary btn-sm" target="_blank" href="/member/user_card/add"><i class="fas fa-plus-circle"></i></a></span>
</h5>
<section class="table-placeholder bg-white mb-5 p-3 pl-4 pr-4 pt-4" style="height:auto;">
<div class="table-responsive">
<div class="row">
<div class="col p-2">
<div class="float-right mr-1"></div>
</div>
<div class="clearfix"></div>
</div>
<input type="hidden" id="per_page" value="<?php echo $this->_data['view_model']->get_per_page(); ?>" >
<div class="row">
<div class="col-sm-12 col-md-6">
<div class="dataTables_length" id="config-table_length">
<small class="d-flex align-items-baseline">Show
<select data-sorturl="<?php echo $view_model->get_sort_base_url(); ?>" id="change_per_page" name="config-table_length" aria-controls="config-table" class="form-control form-control-sm mx-2" style="width: auto;margin-bottom: 10px;">
<?php if(isset($_GET['per_page_sort'])) { ?>
<option value="10" <?php echo ($_GET['per_page_sort'] == '5' && $_GET['per_page_sort']) ? 'selected' : '';?>>5</option>
<option value="10" <?php echo ($_GET['per_page_sort'] == '10' && $_GET['per_page_sort']) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($_GET['per_page_sort'] == '25' && $_GET['per_page_sort']) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($_GET['per_page_sort'] == '50' && $_GET['per_page_sort']) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($_GET['per_page_sort'] == '100' && $_GET['per_page_sort']) ? 'selected' : '';?>>100</option>
<?php } else { ?>
<option value="10" <?php echo ($this->_data['view_model']->get_per_page() == '10' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>10</option>
<option value="25" <?php echo ($this->_data['view_model']->get_per_page() == '25' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>25</option>
<option value="50" <?php echo ($this->_data['view_model']->get_per_page() == '50' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>50</option>
<option value="100" <?php echo ($this->_data['view_model']->get_per_page() == '100' && $this->_data['view_model']->get_per_page()) ? 'selected' : '';?>>100</option>
<?php } ?>
</select>
entries</small>
</div>
</div>
</div>
<table class="display nowrap table table-hover table-striped table-bordered w-100 table-compact mb-0 mkd-table-container">
<thead class=''>
<?php
$order_by = $view_model->get_order_by();
$direction = $view_model->get_sort();
$model_base_url = $view_model->get_sort_base_url();
$field_column = $view_model->get_field_column();
$clean_mode = $view_model->get_format_layout();
$query_string = $view_model->get_query_parameter();
$per_page = $this->_data['view_model']->get_per_page();
$format_mode = '';
if ($clean_mode) {
$format_mode = '&layout_clean_mode=1';
}
foreach ($view_model->get_column() as $key => $data) {
$data_field = $field_column[$key];
if (strlen($order_by) < 1 || $data_field == '')
{
echo "<th scope='col' class='paragraphText text-center'>{$data}</th>";
}
else
{
if ($order_by === $data_field)
{
if ($direction == 'ASC')
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-asc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=DESC{$query_string}'>{$data}</a></th>";
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort sort-desc'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
else
{
echo "<th scope='col' class='paragraphText text-center theme-sort'><a href='{$model_base_url}?order_by={$data_field}{$format_mode}&direction=ASC{$query_string}'>{$data}</a></th>";
}
}
} ?>
</thead>
<tbody class="tbody-light">
<?php $i=1; foreach ($view_model->get_list() as $data) {
$set_default = '';
if ($data->is_default == 0)
{
$set_default = '<a data-id="' . $data->id . '" class="btn-link link-underline text-underline set_default_btn" target="_blank" href="/member/user_card/edit/' . $data->id . '">Set Default</a>';
}
?>
<?php
echo '<tr>';
echo '<td>';
echo $set_default;
echo '<a data-id="' . $data->id . '" class="btn-link link-underline text-underline text-danger remove_btn" target="_blank" href="/member/user_card/delete/' . $data->id . '">Remove</a>';
echo '</td>';
echo "<td>{$data->id}</td>";
echo "<td>" . ucfirst($view_model->is_default_mapping()[$data->is_default]) ."</td>";
echo "<td>{$data->user_id}</td>";
echo "<td>{$data->stripe_card_id}</td>";
echo "<td>{$data->last4}</td>";
echo "<td>{$data->brand}</td>";
echo "<td>{$data->exp_month}</td>";
echo "<td>{$data->exp_year}</td>";
echo '</tr>';
?>
<?php $i++; } ?>
</tbody>
</table>
<small><?php echo $view_model->get_total_rows();?> results found</small>
<span class="pagination_custom">
<?php echo $view_model->get_links(); ?>
</span>
</div>
</section>
</div>
<?php
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
echo '<style>.filter-section {display: none !important;}</style>';
echo '<style>#tab-content{padding:0px !important; margin:0px !important;}</style>';
}
?>
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<script>
$(document).ready(function () {
// set default card
$(".set_default_btn").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
var user_card_id = e.currentTarget.getAttribute('data-id');
if (user_card_id) {
var x = confirm("Are you sure you want to set this default?");
if (x) {
// console.log(user_card_id);
// return false;
$('.remove_btn').removeAttr("href");
$('.set_default_btn').removeAttr("href");
$('.view_btn').removeAttr("href");
$.ajax({
url: '/v1/api/member/user_card/set_default',
type: "POST",
data: { user_card_id: user_card_id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 2000;
toastr.options.fadeOut = 2000;
toastr.options.onHidden = function() {
window.location.href = '/member/user_card/0?order_by=id&direction=DESC';
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 2000;
toastr.options.fadeOut = 2000;
toastr.options.onHidden = function() {
window.location.href = '/member/user_card/0?order_by=id&direction=DESC';
}
toastr.error(response.msg);
}
},
});
} else {
return false;
}
}
});
// delete card
$(".remove_btn").click(function(e) {
// console.log('remove btn clicked');
e.preventDefault();
var user_card_id = e.currentTarget.getAttribute('data-id');
if (user_card_id) {
var x = confirm("Are you sure you want to delete?");
if (x) {
// console.log(user_card_id);
// return false;
$('.remove_btn').removeAttr("href");
$('.set_default_btn').removeAttr("href");
$('.view_btn').removeAttr("href");
$.ajax({
url: '/v1/api/member/user_card/delete',
type: "POST",
data: { user_card_id: user_card_id },
dataType: 'JSON',
success: function (response) {
if (response.success) {
toastr.options.timeOut = 2000;
toastr.options.fadeOut = 2000;
toastr.options.onHidden = function() {
window.location.href = '/member/user_card/0?order_by=id&direction=DESC';
}
toastr.success(response.msg);
}
if (response.error) {
toastr.options.timeOut = 2000;
toastr.options.fadeOut = 2000;
toastr.options.onHidden = function() {
window.location.href = '/member/user_card/0?order_by=id&direction=DESC';
}
toastr.error(response.msg);
}
},
});
} else {
return false;
}
}
});
});
</script>
+120
View File
@@ -0,0 +1,120 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
/*Powered By: Manaknightdigital Inc. https://manaknightdigital.com/ Year: 2020*/
if ($layout_clean_mode) {
echo '<style>#content{padding:0px !important;}</style>';
}
?>
<div class="tab-content mx-4 mt-3" id="nav-tabContent">
<!-- Bread Crumb -->
<div aria-label="breadcrumb">
<ol class="breadcrumb pl-0 mb-1 bg-background d-flex justify-content-center justify-content-md-start">
<li class="breadcrumb-item active" aria-current="page">
<a href="/member/user_card/0" class="breadcrumb-link"><?php echo $view_model->get_heading();?></a>
</li>
<li class="breadcrumb-item active" aria-current="page">
Add
</li>
</ol>
</div>
<?php if (validation_errors()) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?= validation_errors() ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($error) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-danger" role="alert">
<?php echo $error; ?>
</div>
</div>
</div>
<?php endif; ?>
<?php if (strlen($success) > 0) : ?>
<div class="row">
<div class="col-md-12">
<div class="alert alert-success" role="success">
<?php echo $success; ?>
</div>
</div>
</div>
<?php endif; ?>
<div class="row mb-5">
<div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
<div class="card">
<div class="card-body">
<h5 class="primaryHeading2 mb-4 text-md-left pl-3">
Add <?php echo $view_model->get_heading();?>
</h5>
<?= form_open() ?>
<div class="form-group col-md-5 col-sm-12 ">
<label for="card_name">Card Name </label>
<input type="text" class="form-control data-input" id="card_name" name="card_name" value="<?php echo set_value('card_name'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="card_number">Card Number </label>
<input type="text" class="form-control data-input" id="card_number" name="card_number" value="<?php echo set_value('card_number'); ?>"/>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Expire month">Expire month </label>
<select name="exp_month" id="exp_month" class="form-control data-input" required>
<option value="">Select Month</option>
<option value="01">January</option>
<option value="02">February</option>
<option value="03">March</option>
<option value="04">April</option>
<option value="05">May</option>
<option value="06">June</option>
<option value="07">July</option>
<option value="08">August</option>
<option value="09">September</option>
<option value="10">October</option>
<option value="11">November</option>
<option value="12">December</option>
</select>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="Expire year">Expire year </label>
<?php
$year = Date('Y');
$limit = $year + 25;
?>
<select name="exp_year" id="exp_year" class="form-control data-input" required="true">
<option value="">Select Year</option>
<?php
for ($i = $year; $i <= $limit; $i++)
{
echo "<option value='" . $i . "' > " . $i . " </option>";
} ?>
</select>
</div>
<div class="form-group col-md-5 col-sm-12 ">
<label for="cvc" class="required">CVC</label>
<input type="number" pattern="/^-?\d+\.?\d*$/" onKeyPress="if(this.value.length==4) return false;"
name="cvc" id="cvc" placeholder="Enter CVC" class="form-control" max-length="4" min-length="3"
required="true" />
</div>
<div class="form-group col-md-5 col-sm-12">
<input type="hidden" name="is_default" value="1">
<input type="submit" class="btn btn-primary text-white mr-4 my-4" value="Submit">
</div>
</form>
</div>
</div>
</div>
</div>
</div>