diff --git a/01 LOGIN DETAILS & PROJECT INFO.txt b/01 LOGIN DETAILS & PROJECT INFO.txt new file mode 100644 index 0000000..e07d192 --- /dev/null +++ b/01 LOGIN DETAILS & PROJECT INFO.txt @@ -0,0 +1,21 @@ +**Database Name: inventory_system** + +**Developed by Siamon Hasan** + +**Recommended PHP Version 5.6.3** + + +**Admin Login Details** + +Username: admin +Password: admin + +**Special User Login Details** + +Username: special +Password: special + +**User(Employee) Login Details** + +Username: user +Password: user diff --git a/add_group.php b/add_group.php new file mode 100644 index 0000000..29612cd --- /dev/null +++ b/add_group.php @@ -0,0 +1,73 @@ + +msg('d','Sorry! Entered Group Name already in database!'); + redirect('add_group.php', false); + }elseif(find_by_groupLevel($_POST['group-level']) === false) { + $session->msg('d','Sorry! Entered Group Level already in database!'); + redirect('add_group.php', false); + } + if(empty($errors)){ + $name = remove_junk($db->escape($_POST['group-name'])); + $level = remove_junk($db->escape($_POST['group-level'])); + $status = remove_junk($db->escape($_POST['status'])); + + $query = "INSERT INTO user_groups ("; + $query .="group_name,group_level,group_status"; + $query .=") VALUES ("; + $query .=" '{$name}', '{$level}','{$status}'"; + $query .=")"; + if($db->query($query)){ + //sucess + $session->msg('s',"Group has been creted! "); + redirect('add_group.php', false); + } else { + //failed + $session->msg('d',' Sorry failed to create Group!'); + redirect('add_group.php', false); + } + } else { + $session->msg("d", $errors); + redirect('add_group.php',false); + } + } +?> + +
+
+

Add new user Group

+
+ +
+
+ + +
+
+ + +
+
+ + +
+
+ +
+
+
+ + diff --git a/add_product.php b/add_product.php new file mode 100644 index 0000000..f569af9 --- /dev/null +++ b/add_product.php @@ -0,0 +1,134 @@ + +escape($_POST['product-title'])); + $p_cat = remove_junk($db->escape($_POST['product-categorie'])); + $p_qty = remove_junk($db->escape($_POST['product-quantity'])); + $p_buy = remove_junk($db->escape($_POST['buying-price'])); + $p_sale = remove_junk($db->escape($_POST['saleing-price'])); + if (is_null($_POST['product-photo']) || $_POST['product-photo'] === "") { + $media_id = '0'; + } else { + $media_id = remove_junk($db->escape($_POST['product-photo'])); + } + $date = make_date(); + $query = "INSERT INTO products ("; + $query .=" name,quantity,buy_price,sale_price,categorie_id,media_id,date"; + $query .=") VALUES ("; + $query .=" '{$p_name}', '{$p_qty}', '{$p_buy}', '{$p_sale}', '{$p_cat}', '{$media_id}', '{$date}'"; + $query .=")"; + $query .=" ON DUPLICATE KEY UPDATE name='{$p_name}'"; + if($db->query($query)){ + $session->msg('s',"Product added "); + redirect('add_product.php', false); + } else { + $session->msg('d',' Sorry failed to added!'); + redirect('product.php', false); + } + + } else{ + $session->msg("d", $errors); + redirect('add_product.php',false); + } + + } + +?> + +
+
+ +
+
+
+
+
+
+ + + Add New Product + +
+
+
+
+
+
+ + + + +
+
+
+
+
+ +
+
+ +
+
+
+ +
+
+
+
+ + + + +
+
+
+
+ + + + + .00 +
+
+
+
+ + + + + .00 +
+
+
+
+ +
+
+
+
+
+
+ + diff --git a/add_sale.php b/add_sale.php new file mode 100644 index 0000000..615dd60 --- /dev/null +++ b/add_sale.php @@ -0,0 +1,87 @@ + +escape((int)$_POST['s_id']); + $s_qty = $db->escape((int)$_POST['quantity']); + $s_total = $db->escape($_POST['total']); + $date = $db->escape($_POST['date']); + $s_date = make_date(); + + $sql = "INSERT INTO sales ("; + $sql .= " product_id,qty,price,date"; + $sql .= ") VALUES ("; + $sql .= "'{$p_id}','{$s_qty}','{$s_total}','{$s_date}'"; + $sql .= ")"; + + if($db->query($sql)){ + update_product_qty($s_qty,$p_id); + $session->msg('s',"Sale added. "); + redirect('add_sale.php', false); + } else { + $session->msg('d',' Sorry failed to add!'); + redirect('add_sale.php', false); + } + } else { + $session->msg("d", $errors); + redirect('add_sale.php',false); + } + } + +?> + +
+
+ +
+
+
+ + + + +
+
+
+
+
+
+
+ +
+
+
+ + + Sale Eidt + +
+
+
+ + + + + + + + + + +
Item Price Qty Total Date Action
+
+
+
+
+ +
+ + diff --git a/add_user.php b/add_user.php new file mode 100644 index 0000000..aa1b1e5 --- /dev/null +++ b/add_user.php @@ -0,0 +1,84 @@ + +escape($_POST['full-name'])); + $username = remove_junk($db->escape($_POST['username'])); + $password = remove_junk($db->escape($_POST['password'])); + $user_level = (int)$db->escape($_POST['level']); + $password = sha1($password); + $query = "INSERT INTO users ("; + $query .="name,username,password,user_level,status"; + $query .=") VALUES ("; + $query .=" '{$name}', '{$username}', '{$password}', '{$user_level}','1'"; + $query .=")"; + if($db->query($query)){ + //sucess + $session->msg('s',"User account has been creted! "); + redirect('add_user.php', false); + } else { + //failed + $session->msg('d',' Sorry failed to create account!'); + redirect('add_user.php', false); + } + } else { + $session->msg("d", $errors); + redirect('add_user.php',false); + } + } +?> + + +
+
+
+ + + Add New User + +
+
+
+
+
+ + +
+
+ + +
+
+ + +
+
+ + +
+
+ +
+
+
+ +
+ +
+
+ + diff --git a/admin.php b/admin.php new file mode 100644 index 0000000..f3e1bd5 --- /dev/null +++ b/admin.php @@ -0,0 +1,189 @@ + + + + +
+
+ +
+
+
+ +
+
+
+ +
+
+

+

Users

+
+
+
+
+ + +
+
+
+ +
+
+

+

Categories

+
+
+
+
+ + +
+
+
+ +
+
+

+

Products

+
+
+
+
+ + +
+
+
+ +
+
+

+

Sales

+
+
+
+
+
+ +
+
+
+
+ + + Highest Selling Products + +
+
+ + + + + + + + + + + + + + + + + +
TitleTotal SoldTotal Quantity
+
+
+
+
+
+
+ + + LATEST SALES + +
+
+ + + + + + + + + + + + + + + + + + + + +
#Product NameDateTotal Sale
+ + + + $
+
+
+
+
+
+
+ + + Recently Added Products + +
+ +
+
+
+
+ +
+ + + + diff --git a/ajax.php b/ajax.php new file mode 100644 index 0000000..19a7262 --- /dev/null +++ b/ajax.php @@ -0,0 +1,65 @@ +isUserLoggedIn(true)) { redirect('index.php', false);} +?> + +"; + $html .= $product['name']; + $html .= ""; + endforeach; + } else { + + $html .= '
  • '; + $html .= 'Not found'; + $html .= "
  • "; + + } + + echo json_encode($html); + } + ?> + escape($_POST['p_name'])); + if($results = find_all_product_info_by_title($product_title)){ + foreach ($results as $result) { + + $html .= ""; + + $html .= "".$result['name'].""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + $html .= ""; + + } + } else { + $html ='product name not resgister in database'; + } + + echo json_encode($html); + } + ?> diff --git a/auth.php b/auth.php new file mode 100644 index 0000000..1a2c7b0 --- /dev/null +++ b/auth.php @@ -0,0 +1,28 @@ + +login($user_id); + //Update Sign in time + updateLastLogIn($user_id); + $session->msg("s", "Welcome to Inventory Management System"); + redirect('admin.php',false); + + } else { + $session->msg("d", "Sorry Username/Password incorrect."); + redirect('index.php',false); + } + +} else { + $session->msg("d", $errors); + redirect('index.php',false); +} + +?> diff --git a/auth_v2.php b/auth_v2.php new file mode 100644 index 0000000..ce1b673 --- /dev/null +++ b/auth_v2.php @@ -0,0 +1,40 @@ + +login($user['id']); + //Update Sign in time + updateLastLogIn($user['id']); + // redirect user to group home page by user level + if($user['user_level'] === '1'): + $session->msg("s", "Hello ".$user['username'].", Welcome to OSWA-INV."); + redirect('admin.php',false); + elseif ($user['user_level'] === '2'): + $session->msg("s", "Hello ".$user['username'].", Welcome to OSWA-INV."); + redirect('special.php',false); + else: + $session->msg("s", "Hello ".$user['username'].", Welcome to OSWA-INV."); + redirect('home.php',false); + endif; + + else: + $session->msg("d", "Sorry Username/Password incorrect."); + redirect('index.php',false); + endif; + + } else { + + $session->msg("d", $errors); + redirect('login_v2.php',false); + } + +?> diff --git a/categorie.php b/categorie.php new file mode 100644 index 0000000..8fbd7d3 --- /dev/null +++ b/categorie.php @@ -0,0 +1,98 @@ + +escape($_POST['categorie-name'])); + if(empty($errors)){ + $sql = "INSERT INTO categories (name)"; + $sql .= " VALUES ('{$cat_name}')"; + if($db->query($sql)){ + $session->msg("s", "Successfully Added New Category"); + redirect('categorie.php',false); + } else { + $session->msg("d", "Sorry Failed to insert."); + redirect('categorie.php',false); + } + } else { + $session->msg("d", $errors); + redirect('categorie.php',false); + } + } +?> + + +
    +
    + +
    +
    +
    +
    +
    +
    + + + Add New Category + +
    +
    +
    +
    + +
    + +
    +
    +
    +
    +
    +
    +
    + + + All Categories + +
    +
    + + + + + + + + + + + + + + + + + + +
    #CategoriesActions
    + +
    +
    +
    +
    +
    + + diff --git a/change_password.php b/change_password.php new file mode 100644 index 0000000..14ed272 --- /dev/null +++ b/change_password.php @@ -0,0 +1,60 @@ + + +msg('d', "Your old password not match"); + redirect('change_password.php',false); + } + + $id = (int)$_POST['id']; + $new = remove_junk($db->escape(sha1($_POST['new-password']))); + $sql = "UPDATE users SET password ='{$new}' WHERE id='{$db->escape($id)}'"; + $result = $db->query($sql); + if($result && $db->affected_rows() === 1): + $session->logout(); + $session->msg('s',"Login with your new password."); + redirect('index.php', false); + else: + $session->msg('d',' Sorry failed to updated!'); + redirect('change_password.php', false); + endif; + } else { + $session->msg("d", $errors); + redirect('change_password.php',false); + } + } +?> + +
    +
    +

    Change your password

    +
    + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    +
    + diff --git a/daily_sales.php b/daily_sales.php new file mode 100644 index 0000000..db173c3 --- /dev/null +++ b/daily_sales.php @@ -0,0 +1,56 @@ + + + + +
    +
    + +
    +
    +
    +
    +
    +
    + + + Daily Sales + +
    +
    + + + + + + + + + + + + + + + + + + + + + +
    # Product name Quantity sold Total Date
    +
    +
    +
    +
    + + diff --git a/delete_categorie.php b/delete_categorie.php new file mode 100644 index 0000000..33bee70 --- /dev/null +++ b/delete_categorie.php @@ -0,0 +1,22 @@ + +msg("d","Missing Categorie id."); + redirect('categorie.php'); + } +?> +msg("s","Categorie deleted."); + redirect('categorie.php'); + } else { + $session->msg("d","Categorie deletion failed."); + redirect('categorie.php'); + } +?> diff --git a/delete_group.php b/delete_group.php new file mode 100644 index 0000000..60bbfdb --- /dev/null +++ b/delete_group.php @@ -0,0 +1,15 @@ + +msg("s","Group has been deleted."); + redirect('group.php'); + } else { + $session->msg("d","Group deletion failed Or Missing Prm."); + redirect('group.php'); + } +?> diff --git a/delete_media.php b/delete_media.php new file mode 100644 index 0000000..475fed0 --- /dev/null +++ b/delete_media.php @@ -0,0 +1,16 @@ + +media_destroy($find_media['id'],$find_media['file_name'])){ + $session->msg("s","Photo has been deleted."); + redirect('media.php'); + } else { + $session->msg("d","Photo deletion failed Or Missing Prm."); + redirect('media.php'); + } +?> diff --git a/delete_product.php b/delete_product.php new file mode 100644 index 0000000..55f42da --- /dev/null +++ b/delete_product.php @@ -0,0 +1,22 @@ + +msg("d","Missing Product id."); + redirect('product.php'); + } +?> +msg("s","Products deleted."); + redirect('product.php'); + } else { + $session->msg("d","Products deletion failed."); + redirect('product.php'); + } +?> diff --git a/delete_sale.php b/delete_sale.php new file mode 100644 index 0000000..a48f30f --- /dev/null +++ b/delete_sale.php @@ -0,0 +1,22 @@ + +msg("d","Missing sale id."); + redirect('sales.php'); + } +?> +msg("s","sale deleted."); + redirect('sales.php'); + } else { + $session->msg("d","sale deletion failed."); + redirect('sales.php'); + } +?> diff --git a/delete_user.php b/delete_user.php new file mode 100644 index 0000000..0ba5a49 --- /dev/null +++ b/delete_user.php @@ -0,0 +1,15 @@ + +msg("s","User deleted."); + redirect('users.php'); + } else { + $session->msg("d","User deletion failed Or Missing Prm."); + redirect('users.php'); + } +?> diff --git a/edit_account.php b/edit_account.php new file mode 100644 index 0000000..a6f97cf --- /dev/null +++ b/edit_account.php @@ -0,0 +1,105 @@ + +upload($_FILES['file_upload']); + if($photo->process_user($user_id)){ + $session->msg('s','photo has been uploaded.'); + redirect('edit_account.php'); + } else{ + $session->msg('d',join($photo->errors)); + redirect('edit_account.php'); + } + } +?> +escape($_POST['name'])); + $username = remove_junk($db->escape($_POST['username'])); + $sql = "UPDATE users SET name ='{$name}', username ='{$username}' WHERE id='{$id}'"; + $result = $db->query($sql); + if($result && $db->affected_rows() === 1){ + $session->msg('s',"Acount updated "); + redirect('edit_account.php', false); + } else { + $session->msg('d',' Sorry failed to updated!'); + redirect('edit_account.php', false); + } + } else { + $session->msg("d", $errors); + redirect('edit_account.php',false); + } + } +?> + +
    +
    + +
    +
    +
    +
    +
    + + Change My photo +
    +
    +
    +
    +
    + +
    +
    +
    +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    +
    +
    +
    +
    + + Edit My Account +
    +
    +
    +
    + + +
    +
    + + +
    +
    + Change Password + +
    +
    +
    +
    +
    +
    + + + diff --git a/edit_categorie.php b/edit_categorie.php new file mode 100644 index 0000000..5d54245 --- /dev/null +++ b/edit_categorie.php @@ -0,0 +1,66 @@ + +msg("d","Missing categorie id."); + redirect('categorie.php'); + } +?> + +escape($_POST['categorie-name'])); + if(empty($errors)){ + $sql = "UPDATE categories SET name='{$cat_name}'"; + $sql .= " WHERE id='{$categorie['id']}'"; + $result = $db->query($sql); + if($result && $db->affected_rows() === 1) { + $session->msg("s", "Successfully updated Categorie"); + redirect('categorie.php',false); + } else { + $session->msg("d", "Sorry! Failed to Update"); + redirect('categorie.php',false); + } + } else { + $session->msg("d", $errors); + redirect('categorie.php',false); + } +} +?> + + +
    +
    + +
    +
    +
    +
    + + + Editing + +
    +
    +
    +
    + +
    + +
    +
    +
    +
    +
    + + + + diff --git a/edit_group.php b/edit_group.php new file mode 100644 index 0000000..c5b301a --- /dev/null +++ b/edit_group.php @@ -0,0 +1,71 @@ + +msg("d","Missing Group id."); + redirect('group.php'); + } +?> +escape($_POST['group-name'])); + $level = remove_junk($db->escape($_POST['group-level'])); + $status = remove_junk($db->escape($_POST['status'])); + + $query = "UPDATE user_groups SET "; + $query .= "group_name='{$name}',group_level='{$level}',group_status='{$status}'"; + $query .= "WHERE ID='{$db->escape($e_group['id'])}'"; + $result = $db->query($query); + if($result && $db->affected_rows() === 1){ + //sucess + $session->msg('s',"Group has been updated! "); + redirect('edit_group.php?id='.(int)$e_group['id'], false); + } else { + //failed + $session->msg('d',' Sorry failed to updated Group!'); + redirect('edit_group.php?id='.(int)$e_group['id'], false); + } + } else { + $session->msg("d", $errors); + redirect('edit_group.php?id='.(int)$e_group['id'], false); + } + } +?> + +
    +
    +

    Edit Group

    +
    + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + +
    +
    +
    + + diff --git a/edit_product.php b/edit_product.php new file mode 100644 index 0000000..4ded8d3 --- /dev/null +++ b/edit_product.php @@ -0,0 +1,147 @@ + +msg("d","Missing product id."); + redirect('product.php'); +} +?> +escape($_POST['product-title'])); + $p_cat = (int)$_POST['product-categorie']; + $p_qty = remove_junk($db->escape($_POST['product-quantity'])); + $p_buy = remove_junk($db->escape($_POST['buying-price'])); + $p_sale = remove_junk($db->escape($_POST['saleing-price'])); + if (is_null($_POST['product-photo']) || $_POST['product-photo'] === "") { + $media_id = '0'; + } else { + $media_id = remove_junk($db->escape($_POST['product-photo'])); + } + $query = "UPDATE products SET"; + $query .=" name ='{$p_name}', quantity ='{$p_qty}',"; + $query .=" buy_price ='{$p_buy}', sale_price ='{$p_sale}', categorie_id ='{$p_cat}',media_id='{$media_id}'"; + $query .=" WHERE id ='{$product['id']}'"; + $result = $db->query($query); + if($result && $db->affected_rows() === 1){ + $session->msg('s',"Product updated "); + redirect('product.php', false); + } else { + $session->msg('d',' Sorry failed to updated!'); + redirect('edit_product.php?id='.$product['id'], false); + } + + } else{ + $session->msg("d", $errors); + redirect('edit_product.php?id='.$product['id'], false); + } + + } + +?> + +
    +
    + +
    +
    +
    +
    +
    + + + Add New Product + +
    +
    +
    +
    +
    +
    + + + + +
    +
    +
    +
    +
    + +
    +
    + +
    +
    +
    + +
    +
    +
    +
    + +
    + + + + +
    +
    +
    +
    +
    + +
    + + + + + .00 +
    +
    +
    +
    +
    + +
    + + + + + .00 +
    +
    +
    +
    +
    + +
    +
    +
    +
    +
    + + diff --git a/edit_sale.php b/edit_sale.php new file mode 100644 index 0000000..a119cce --- /dev/null +++ b/edit_sale.php @@ -0,0 +1,108 @@ + +msg("d","Missing product id."); + redirect('sales.php'); +} +?> + +escape((int)$product['id']); + $s_qty = $db->escape((int)$_POST['quantity']); + $s_total = $db->escape($_POST['total']); + $date = $db->escape($_POST['date']); + $s_date = date("Y-m-d", strtotime($date)); + + $sql = "UPDATE sales SET"; + $sql .= " product_id= '{$p_id}',qty={$s_qty},price='{$s_total}',date='{$s_date}'"; + $sql .= " WHERE id ='{$sale['id']}'"; + $result = $db->query($sql); + if( $result && $db->affected_rows() === 1){ + update_product_qty($s_qty,$p_id); + $session->msg('s',"Sale updated."); + redirect('edit_sale.php?id='.$sale['id'], false); + } else { + $session->msg('d',' Sorry failed to updated!'); + redirect('sales.php', false); + } + } else { + $session->msg("d", $errors); + redirect('edit_sale.php?id='.(int)$sale['id'],false); + } + } + +?> + +
    +
    + +
    +
    +
    + +
    +
    +
    + + + All Sales + + +
    +
    + + + + + + + + + + + + + + + + + + + + + +
    Product title Qty Price Total Date Action
    + +
    +
    + + + + + + + + + +
    + +
    +
    +
    + +
    + + diff --git a/edit_user.php b/edit_user.php new file mode 100644 index 0000000..aa44d31 --- /dev/null +++ b/edit_user.php @@ -0,0 +1,134 @@ + +msg("d","Missing user id."); + redirect('users.php'); + } +?> + +escape($_POST['name'])); + $username = remove_junk($db->escape($_POST['username'])); + $level = (int)$db->escape($_POST['level']); + $status = remove_junk($db->escape($_POST['status'])); + $sql = "UPDATE users SET name ='{$name}', username ='{$username}',user_level='{$level}',status='{$status}' WHERE id='{$db->escape($id)}'"; + $result = $db->query($sql); + if($result && $db->affected_rows() === 1){ + $session->msg('s',"Acount Updated "); + redirect('edit_user.php?id='.(int)$e_user['id'], false); + } else { + $session->msg('d',' Sorry failed to updated!'); + redirect('edit_user.php?id='.(int)$e_user['id'], false); + } + } else { + $session->msg("d", $errors); + redirect('edit_user.php?id='.(int)$e_user['id'],false); + } + } +?> +escape($_POST['password'])); + $h_pass = sha1($password); + $sql = "UPDATE users SET password='{$h_pass}' WHERE id='{$db->escape($id)}'"; + $result = $db->query($sql); + if($result && $db->affected_rows() === 1){ + $session->msg('s',"User password has been updated "); + redirect('edit_user.php?id='.(int)$e_user['id'], false); + } else { + $session->msg('d',' Sorry failed to updated user password!'); + redirect('edit_user.php?id='.(int)$e_user['id'], false); + } + } else { + $session->msg("d", $errors); + redirect('edit_user.php?id='.(int)$e_user['id'],false); + } +} + +?> + +
    +
    +
    +
    +
    + + + Update Account + +
    +
    +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + +
    +
    +
    +
    +
    + +
    +
    +
    + + + Change password + +
    +
    +
    +
    + + +
    +
    + +
    +
    +
    +
    +
    + +
    + diff --git a/group.php b/group.php new file mode 100644 index 0000000..d93279a --- /dev/null +++ b/group.php @@ -0,0 +1,68 @@ + + +
    +
    + +
    +
    +
    +
    +
    +
    + + + Groups + + Add New Group +
    +
    + + + + + + + + + + + + + + + + + + + + + +
    #Group NameGroup LevelStatusActions
    + + + + + + + + + +
    +
    +
    +
    +
    + diff --git a/home.php b/home.php index 2b48d14..d8a2232 100644 --- a/home.php +++ b/home.php @@ -1,111 +1,20 @@ prepare("SELECT product_name, stock FROM products"); - $stmt->execute(); - $product_data = $stmt->fetchAll(PDO::FETCH_ASSOC); -} catch (PDOException $e) { - $is_success = false; - $response_message = 'Error: ' . htmlspecialchars($e->getMessage()); -} - + $page_title = 'Home Page'; + require_once('includes/load.php'); + if (!$session->isUserLoggedIn(true)) { redirect('index.php', false);} ?> - - - - - - - Dashboard - Inventory Management System - - - - - - - -
    - -
    - -
    -
    -

    Product Stock Overview

    -
    - -
    - -
    -

    -
    - -
    -
    -
    + +
    +
    + +
    +
    +
    +
    +

    Welcome User
    Inventory Management System

    +

    Browes around to find out the pages that you can access!

    +
    - - - +
    +
    + diff --git a/index.php b/index.php index b2305a8..23d30d6 100644 --- a/index.php +++ b/index.php @@ -1,148 +1,27 @@ - - - - - - HomePage-Inventory management system - - - -
    - Login -
    -
    - Admin Login -
    -
    -
    -
    -

    WMS

    -

    Warehouse management system

    +isUserLoggedIn(true)) { redirect('home.php', false);} +?> + + -
    -
    - easy -

    Simple UI

    -

    - Lorem ipsum dolor sit amet, consectetur adipisicing elit. Odio - expedita ullam, -

    -
    -
    - star -

    Flat Design

    -

    - Lorem ipsum dolor sit amet, consectetur adipisicing elit. Odio - expedita ullam, -

    -
    -
    - audience -

    Reach yuor Aidience

    -

    - Lorem ipsum dolor sit amet, consectetur adipisicing elit. Odio - expedita ullam, -

    -
    -
    -
    -
    -
    -

    Get notified on any update!

    -

    - Lorem, ipsum dolor sit amet consectetur adipisicing elit. Numquam - illo itaque distinctio eos rem consequuntur sunt, ullam eveniet - praesentium, fuga dolores nisi consequatur quod quia voluptate amet - blanditiis saepe sed? -

    - -
    - - -
    - +
    +
    -
    - -
    -
    -
    -
    -

    Say Hi & Get in touch

    -

    - At Inventory Solutions Inc., we redefine inventory management with - innovative solutions tailored to streamline your operations and boost - efficiency. Our cutting-edge technology ensures precise real-time - tracking, automated replenishment, and insightful analytics, all - designed to keep your inventory optimized and your business running - smoothly.We understand that every business has unique needs, which is - why our solutions are customizable and seamlessly integrate with your - existing systems. Our expert team is committed to providing dedicated - support to overcome any challenges and enhance your inventory processes. - Experience a new level of operational excellence with Inventory - Solutions Inc. and transform the way you manage your inventory. Contact - us today to explore how our solutions can drive your business forward. -

    -
    - google-plus - twitter - linkden - pinsterest - instagram - youtube -
    -
    - - - + +
    + diff --git a/login_v2.php b/login_v2.php new file mode 100644 index 0000000..f205dda --- /dev/null +++ b/login_v2.php @@ -0,0 +1,27 @@ +isUserLoggedIn(true)) { redirect('home.php', false);} +?> + + + diff --git a/logout.php b/logout.php new file mode 100644 index 0000000..545c3e0 --- /dev/null +++ b/logout.php @@ -0,0 +1,4 @@ +logout()) {redirect("index.php");} +?> diff --git a/media.php b/media.php new file mode 100644 index 0000000..df3ddb0 --- /dev/null +++ b/media.php @@ -0,0 +1,86 @@ + + +upload($_FILES['file_upload']); + if($photo->process_media()){ + $session->msg('s','photo has been uploaded.'); + redirect('media.php'); + } else{ + $session->msg('d',join($photo->errors)); + redirect('media.php'); + } + + } + +?> + +
    +
    + +
    + +
    +
    +
    + + All Photos +
    +
    +
    +
    + + + + + +
    +
    +
    +
    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/monthly_sales.php b/monthly_sales.php new file mode 100644 index 0000000..8e23b3a --- /dev/null +++ b/monthly_sales.php @@ -0,0 +1,54 @@ + + + +
    +
    + +
    +
    +
    +
    +
    +
    + + + Monthly Sales + +
    +
    +
    #PhotoPhoto NamePhoto TypeActions
    + + + + + + + + + +
    + + + + + + + + + + + + + + + + + + + + +
    # Product name Quantity sold Total Date
    +
    +
    +
    +
    + + diff --git a/product.php b/product.php new file mode 100644 index 0000000..9063038 --- /dev/null +++ b/product.php @@ -0,0 +1,70 @@ + + +
    +
    + +
    +
    +
    +
    +
    + Add New +
    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/profile.php b/profile.php new file mode 100644 index 0000000..90fb10a --- /dev/null +++ b/profile.php @@ -0,0 +1,31 @@ + + + +
    +
    +
    +
    + +

    +
    + + + +
    +
    +
    + diff --git a/sale_report_process.php b/sale_report_process.php new file mode 100644 index 0000000..a8f3732 --- /dev/null +++ b/sale_report_process.php @@ -0,0 +1,134 @@ + +escape($_POST['start-date'])); + $end_date = remove_junk($db->escape($_POST['end-date'])); + $results = find_sale_by_dates($start_date,$end_date); + else: + $session->msg("d", $errors); + redirect('sales_report.php', false); + endif; + + } else { + $session->msg("d", "Select dates"); + redirect('sales_report.php', false); + } +?> + + + + + Default Page Title + + + + + +
    +
    +

    Inventory Management System - Sales Report

    + TILL DATE +
    +
    # Photo Product Title Categories In-Stock Buying Price Selling Price Product Added Actions
    + + + + + + + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    DateProduct TitleBuying PriceSelling PriceTotal QtyTOTAL
    +
    +
    Grand Total $ + +
    Profit $
    +
    + msg("d", "Sorry no sales has been found. "); + redirect('sales_report.php', false); + endif; + ?> + + +db_disconnect(); } ?> diff --git a/sales.php b/sales.php new file mode 100644 index 0000000..7102bf6 --- /dev/null +++ b/sales.php @@ -0,0 +1,66 @@ + + + +
    +
    + +
    +
    +
    +
    +
    +
    + + + All Sales + +
    + Add sale +
    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + +
    # Product name Quantity Total Date Actions
    + +
    +
    +
    +
    +
    + diff --git a/sales_report.php b/sales_report.php new file mode 100644 index 0000000..b7a58db --- /dev/null +++ b/sales_report.php @@ -0,0 +1,39 @@ + + +
    +
    + +
    +
    +
    +
    +
    +
    + +
    +
    +
    +
    + +
    + + + +
    +
    +
    + +
    +
    +
    + +
    +
    + +
    + diff --git a/users.php b/users.php new file mode 100644 index 0000000..17772fc --- /dev/null +++ b/users.php @@ -0,0 +1,73 @@ + + + +
    +
    + +
    +
    +
    +
    +
    +
    + + + Users + + Add New User +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + +
    #Name UsernameUser RoleStatusLast LoginActions
    + + + + + + + +
    +
    +
    +
    +
    +