Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 203

BASIC T-SHIRT DEPOT’S AUTOMATED SYSTEM

A Capstone Project
Presented to the Faculty of the Collage of the Teacher Education Department of West
Prime Horizon Institute, Inc.
Pagadian City

In Partial Fulfillment
of the Requirements for the Degree of
Bachelor of Technical – Vocational Teacher Education
Major in Computer Hardware Servicing
Academic Year 2023-2024

By.
Panawan ,Sharlyn B.
Delacerna, Christian M.
Mamangcao, Ranya M.
Bantac, Regine S.
Hermoso, Rico N.
Vente, Jenefe B.

June 2024
APPROVAL SHEET

In partial fulfilment of the requirements for the degree of Bachelor of Technical Vocational
Teacher Education major in Computer Hardware Servicing, this capstone project entitled
"BASIC T-SHIRT DEPOT’S AUTOMATED SYSTEM" is prepared by Panawan, Sharlyn,
Vente, Jenefe B., Bantac, Regine S, Mamangcao, Ranya M., Hermoso, Rico N., and Dela
Cerna, Christian M. is hereby recommended for an oral examination.

Waien G. Watamama

Capstone Project Adviser

___________________________________________________________________________

Approved by the panel of Examiners with the grade of ______.

Panelist Panelist

Panelist Panelist

Chairman

___________________________________________________________________________

Approved in Partial Fulfillment of the requirements for the degree of Bachelor of Technical
Vocational Teacher Education major in Computer Hardware Servicing Capstone Project 1.

CHRISTIAN L. SEBIAL

Acting School President


ACKNOWLEDGEMENT

First and foremost, praises and thanks to God, the almighty, for his showers of blessings
throughout the research work to complete the research successfully.

The researcher would like to extend heartfelt gratitude to the people listed below, who are one
way or another have contributed efforts and support to make this way endeavor a reality.

To Mr. Waien G. Watamama, the adviser of this research for his unlimited effort and support
for the researchers.

To Mr. Christian Sebial, the Acting School President, for his unwavering support and
encouragement to press on to finish this study.

To Mr. Eric Generale, the 3rd year college adviser for showing unending support t to the
researchers.

To Ms. Vaneza Marry J. Simbajon, the grammarian, for showing the knowledge and guiding
their thoughts for the study.

To Mr. Jennoel J. Linao, the statistician, for guiding the researcher to be properly equipped,
enhanced, and prepared in organizing their study.

The faculty and staff of West Prime Horizon Institute, Inc. for continuously believing in what
they could achieve.

To the beloved family of the researchers, for their undying support, motivation understanding,
and inspiration to move forward whatever it takes.

The researchers have acknowledged that without the above mentioned, their quest academic
greatness and progress of knowledge in the realm of academics would be futile.
DEDICATION

This work is dedicated to the following parents who showed their unending love and moral
support:

Mr/Mrs. Panawan

Mr/Mrs. Bantac

Mr/Mrs. Hermoso

Mr/Mrs. Vente

Mr/Mrs. Dela cerna

Mr/Mrs. Mamangcao

Likewise, to their brothers and sisters, relatives, friends, faculty and staff of West Prime
Horizon Institute Inc. for their unconditional support, help, and advice.

Above all, to the Almighty who always guides and provides their needs even in difficult
times.
ABSTRACT

This Capstone Project aimed to develop a comprehensive automated system for Basic
T-shirt Depot, addressing both functional and non-functional requirements to enhance
operational efficiency. The system provided real-time inventory tracking, generated
low stock alerts, and integrated with POS systems for immediate updates. It recorded
sales transactions, managed discounts, and produced customer receipts, alongside
handling purchase orders and supplier performance tracking. Customer credit
accounts were meticulously managed, recording transactions, updating balances, and
tracking payments. Detailed reports on sales and inventory were generated, ensuring
insightful business analytics. The system enforced user roles and permissions to
maintain security and accountability, processing transactions swiftly within 5 seconds
and ensuring 99.9% uptime. The POS module captured sale details, applied discounts,
and updated inventory in real-time, while the Inventory Management module
monitored stock, generated alerts, and tracked purchase orders. The Credit
Management module handled credit accounts and payments. The project's scope
included automating tasks such as payment recording, inventory management, and
report generation, offering full access to owners and managers, with specific
permissions for cashiers and other staff. However, it excluded debit/credit card
transactions and mobile stock management. The system was designed to streamline
operations and provide a robust framework for managing sales, inventory, and credit
effectively.
CHAPTER 1

Introduction

Background of the study


Nowadays, many people use computers in their daily lives. Some use it for
transactions, some use it for educational purposes, and others use it for data storage.
Though it might sound unnecessary, in some cases, when storing a file for such a big
company, can you manage it properly by organizing finding a file, etc. With computers, it
can help you simplify the process of storing and managing the files you need for future
use and make finding files easier than the manual process.
A software program that assists companies in digitally managing their sales
transactions and inventory levels is known as an automated billing and inventory system.
Generally speaking, it enables users to manage suppliers, track sales, keep an eye on
inventory levels, create invoices, and occasionally even interface with accounting
software for more efficient financial administration. These solutions are designed to
increase efficiency and decrease errors by automating and streamlining inventory
management and billing procedures.
Basic T-shirt Depot is facing difficulty in some factors of computing their sales
and inventory. They are seeking to have a computerized system to have easier
transactions for their customer and check their stocks. Currently, the client maintains
records by hand. It involves issuing receipts and checking stocks through labor-intensive
methods. When a transaction occurs, the receipt is handwritten, which requires significant
time and attention to detail to ensure accuracy. Similarly, stock checks are conducted by
physically counting inventory items, recording the counts on paper, and then manually
entering the data into a log or spreadsheet. This approach is prone to human error and is
time-consuming, making it challenging to maintain accurate and up-to-date records in
real-time.
Technology helps people's work become easier. The help of computers has
changed the way people work, especially in the clothing industry. With the help of the
system, the staff can work with less consumed time, which will help their transaction
become effective and faster. Most businesses have used to carry out different transactions
to confront the client or customer. This system will help the staff execute the task more
easily and more accurately. This task includes solving numerical calculations, storing
necessary information, and organizing files that can be used for managing the business.
The goal of this system is to make the staff work effectively and efficiently by
using computer technology. This proposed system aims to simplify work and solve
problems involving strict and complex recording and calculations.

Project Context of the Capstone Project


The capstone project aims to revolutionize the current manual business processes
of Basic T-shirt Depot by developing a comprehensive software solution that integrates
Point of Sale (POS), Inventory Management, and Credit Management modules.
Currently, the client's business operations involve manual issuing of receipts and manual
stock checks, leading to inefficiencies and potential inaccuracies. The proposed system
will automate these tasks, streamlining transaction processing, inventory tracking, and
customer credit management. By transitioning from manual to digital processes, the client
will benefit from increased accuracy, real-time data access, and improved operational
efficiency.

Used Software
The proposed automated system provides many facilities such as product
management, customer management, stock management, supplier management, purchase
management, reorder management, and report generation. The system was developed
using PHP (PHP hypertext Processor) which is a popular open-source scripting language
primarily used for web development. It is a server-side scripting language, which means
that it is executed on the server and generates dynamic web pages that are then sent to the
client's web browser. MySQL was used as the database tool for designing the database.
The software is built on a standard WAMP (Windows, Apache, MySQL, and PHP).

Purpose and Description


The goal of this project is to help store owners save time by automating processes
like sales tracking and inventory adjustments. A manager also gives vital tools and
insights to properly oversee the store's operations and maximize performance. This allows
the manager to track sales in real-time.
A sytem with POS and Inventory module aids employees by increasing their efficiency in
serving customers and managing inventory, resulting in greater customer service and
contributing to the overall success of the store.

General Objectives
The general objective of the project is to design and develop an automated system
for Basic T-shirt Depot with POS, Inventory and Credit Management modules.

Specific Objectives
The project aims to develop a system that can help the Basic T-Shirt Depot manage
sales and inventory. Specifically, the system.
1. Allows Basic T-shirt Depot to transact easily with their customers using the payment
module and e-wallet feature.
2. Monitors the sales and inventory of the items with the use of an inventory module
owner/manager prints reports through the system’s printing module.
3. Helps the owner/ manager print reports through the system’s printing module.
4. Can update the new product information or update stocks.
5. Can ensure a continuous supply of materials and stock so that production does not
suffer at the time of customer.

Scope and limitations


The scope of the project mainly focuses on the development of an automated
system, to be used by Basic T-shirt Depot with automated tasks such as recording
payments, inventory management and printing reports. The proposed system's database
management component will focus on sales and inventory records.
The Basic T-Shirt Depot’ automated system gives full access to the owner and
manager. The cashier is responsible only for the payment transaction. At the same time,
the other staff has full access to the stocks Moreover, the system includes Credit
Management and can accept e-wallet payments.

This capstone project, however, does not cover debit/credit card transactions
and online stock management through the use of smartphones and other devices.
Definition of terms

Customers: refers to a person or a client who buys items in the Basic T-Shirt Depot.

Manager: A person responsible for controlling and administering all parts of the
establishment.
Stock: the goods or merchandise kept on the premises of a business or warehouse and
available for sale or distribution.

Billing: is a designed to handle time and billing tracking as well as invoicing the
customers for services and products. It can also track the hours worked by employees as
well as expenses associated with projects and clients.

Transaction: A transaction is a completed agreement between a buyer and a seller to


exchange goods, services, or financial assets in return for money. The term is also
commonly used in corporate accounting.

PHP: (Hypertext Pre processor) is a popular open-source scripting language primarily


used for web development. It is a server-side scripting language, which means that it is
executed on the server and generates dynamic web pages that are then sent to the client's
web browser.

Payment Processing: A billing system should be able to process payments made by


customers. This might involve integrating with various payment gateways to accept
payments through different methods such as credit cards, debit cards, bank transfers, or
digital wallets.
Sales: monetary transactions where products are exchanged for money,s a set of activities
a business does to help customers buy their product.
CHAPTER II
REVIEW OF RELATED STUDIES AND SYSTEM

Related Studies and System

This chapter presents the proponents’ collected data and information that formed
part of the research literature which are very useful in the development of this study.
According to Collins (2024), a automated system is a system that utilizes
computers and software to perform various tasks and processes. It involves the use of
computer technology to automate and streamline operations, making them more efficient
and accurate. Computerized systems can be found in various domains, such as business,
healthcare, education, transportation, and many others. They can range from simple
applications like word processors and spreadsheets to complex systems like enterprise
resource planning (ERP) software or computer-aided design (CAD) tools. These systems
typically involve hardware components, software programs, databases, and networks to
enable data processing, storage, retrieval, and communication. They play a crucial role in
modern society, enhancing productivity, decision-making, and overall functionality in
numerous fields.
In today’s business environment, even small and medium scale businesses have come
to rely on computerized inventory management system. Certainly, there are many of
smaller retail outlets, manufacturers and other businesses that continue to rely on manual
means of sales and inventory tracking. The recent development of powerful computer
programs capable of addressing a wide variety of record-keeping needs, including sales
and inventory management in one integrated system have also contributed to the growing
popularity (Chukwu, 2018).

Related Foreign Literature


According to Jenkins (2014) companies often lose products in their inventory
because employees sometimes can’t check all the products in their storage. An inventory
management system is a solution for a business that is facing a problem in the area of
regulating the supply chain. An inventory management system is software that helps the
operators of the business manage the inventory more efficiently.
In a study of Hidayati, Sudarmiatin and Hermawan (2023), it shows that the
performance of a POS system can considerably improve a company's efficiency and
financial management. The POS system can assist with inventory management,
forecasting client demand, and avoiding excess or shortages of goods supply. It can also
expedite the client payment process, enhance the customer experience, and create precise
sales figures. The article finds that deploying a POS system can help coffee shop
businesses optimize their operations and boost profitability, despite constraints such as
high implementation costs and staff training.

Related Local Literature

According to Henderson (2004), using an inventory system has three major


advantages: time savings, accuracy, and consistency. These advantages are beneficial for
business owners to increase their sales. Time savings is perhaps the most significant
benefit of using a computerized inventory system. Manual data maintenance is a time-
consuming task, especially in the retail industry. However, with a computerized point of
sale (POS) system, the master inventory list would be updated automatically as each sale
occurs, saving time.
In an article written by Sanders (2010) it is stated that, a computer-based system is
a complex system wherein information technology plays a major role. It makes work
easier, faster, and more accurate. Due to that fact, the automated scheme has become
essential to small and big companies. Companies, especially the big ones, are
recommended to switch from manual to automated systems because this will improve the
efficiency and productivity of the business, which will uplift the industry's reputation.
One of the most sought-after automated systems of different companies is a purchasing
and inventory system which comes hand in hand. A purchasing and inventory system is
very important in every organization because good inventory management can create
excellent productivity. Primarily, inventory work consists of input, output, and
restocking. Input is the process of buying new products into the inventory and replacing
the old products with new ones. Meanwhile, output is the procedure of taking out the
products from the inventory for sales or usage and refilling the insufficient products or
escalating demands. Most of the retailing market uses the traditional way in the
traditional inventory management system where a person is assigned to check and record
the stock by hand using pen and paper. It is where operations about all the stock will be
archived.
Based on the study of Kaizer (2008), inventory control systems maintain
information about activities within firms that ensure the delivery of products to
customers. The subsystems that perform these functions, including sales, manufacturing,
warehousing, ordering, and receiving, may not be strictly contained within separate
subsystems, but these functions must be performed in sequence to have a well-run
inventory control system. In today's business environment, even small and mid-sized
businesses have come to rely on computerized inventory management systems. Certainly,
there are plenty of small retail outlets, manufacturers, and other businesses that continue
to rely on manual means of inventory tracking. Indeed, for some small businesses, like
convenience stores, shoe stores, or nurseries, the purchase of an electronic inventory
tracking system can be seen as unnecessary given the manageable size of their
inventories.
CHAPTER III
DESIGN AND METHODOLOGY

Requirement Analysis

This chapter contains the methodologies being used and the general research
design process of the study. It also shows how the research outcome at the end will be
obtained in line with meeting the objective of the study. In addition, this chapter seeks to
meet the researcher's research strategy and objectives, as well as to show how the
research was carried out during the study time. The proponents require a thorough
investigation of the primary aspects.

Regarding their current system, the proponents interviewed the manager. Through
this, the proponents obtained the necessary information and was able to identify the
problem needed to be addressed. The proponents learned that the establishment required a
system to help them keep track of sales and inventory.

The PHP Hypertext Processor, which provides users with easy access to relational
functionality, was used by the developers to develop the automated system. It is the
simplest and fastest desktop management system available, and the combination of easy-
to-use and powerful tools is described in sufficient detail to enable system design.

Functional Requirement

1. System must track inventory levels in real-time.


2. System should generate alerts for low stock levels.
3. Real-time integration with POS systems for immediate inventory updates.
4. Record sales transactions including date, time, item details, and payment method.
5. Generate and print receipts for customers.
6. Manage and apply discounts
7. Create, manage, and track purchase orders to suppliers.
8. Maintain supplier information and track supplier performance.
9. Track the status of orders from placement to delivery.
10. Maintain customer credit accounts with transaction history.
11. Process and record sales on credit, updating customer balances.
12. Track payments made against credit accounts and outstanding balances.
13. Notify customers and administrators of overdue accounts and approaching credit
limits.
14. Generate detailed sales reports by item, category, time period, and location.
15. Provide reports on stock levels, turnover rates, and valuation.
16. Generate reports on credit sales, outstanding balances, and payment history.
17. Define user roles and permissions to control access to system features.
18. Maintain a log of user activities for accountability and security.

Non- Functional Requirements

1. System should process transactions within 5 seconds.


2. Should handle an increasing number of transactions and users without performance
degradation.
3. Real-time synchronization between POS and inventory databases.
4. System should have at least 99.9% uptime.
5. Regular automated backups and a reliable recovery process in case of data loss.
6. Intuitive and easy-to-use interface for all user roles.

Technical Background

The proponents wish to create an effective, efficient, dependable, and user-


friendly system that will aid in the improvement of the establishment's status.
The project's proponents gathered all relevant research and brainstormed about
which technologies would be used. The developer will utilize HTML to create the design
and screen forms and PHP to make it dynamic for the computerized sales and inventory
system.
Hypertext Pre processor (PHP) is an extremely popular scripting language.PHP is
open-source which means that it is well-documented and can easily be downloaded for
free from the Web. MYSQL is one of the most popular relational database systems.
Originally an open-source solution, MySQL is now owned by Oracle Corporation.
Today, MySQL is a pillar of LAMP application software. That means it’s a part of
Linux, Apache, MySQL, and Perl/PHP/Python stack. Having C and C++ under the
hood, MySQL works well with such system platforms as Windows, Linux, MacOS,
IRIX, and others.

Programming Environment

The programming environment for the capstone project involves using PHP as
the server-side scripting language, MySQL as the database management system,
XAMPP as the local development server, and Notepad as the text editor for coding.
PHP will be used to handle the backend logic, processing user inputs, and interacting
with the MySQL database to store and retrieve data efficiently. MySQL will serve as
the robust and scalable database solution, ensuring data integrity and quick access to
records. XAMPP, an all-in-one development environment, will simplify the setup
process by providing Apache server, PHP, and MySQL in a single package,
facilitating local testing and development. Notepad, though basic, will be the primary
tool for writing and editing the PHP code, making it easy to create, modify, and
maintain the project's scripts and configurations. This environment provides a
cohesive and efficient setup for developing a comprehensive POS, Inventory, and
Credit Management system.

Hardware Specification

Embedded projects frequently need the creation of electronic and mechanical


hardware in tandem with software development. This presents unique hurdles for
software developers who must create software purely based on the Pre - design
specifications for how the hardware is supposed to work.
The following hardware requirements on which it will be deployed. The following
minimum conditions must be considered for the system to operate at its best.

Item Specification
Processor 11th Gen Intel® Core™ i3-111504@
3.00GHz 3.00 GHz
Memory 4.00 GB DDR4
Hard Disk Drive PCIe-8 SSD 500GB
Keyboard and Mouse Standard PS/2 Keyboard
HID-compliant mouse

Table 1. Hardware Specification

Software Specification

The software specifications document outlines the numerous software features,


capabilities, code tests, and functionalities that will be included in the final product.
For the developers, these parameters also include characteristics, design details,
and implementation challenges, depending on the project, the structure of software
specification can be changed, and various features or functions can be introduced in the
process.
The system will be one-portal based on the run-time environment, although some
of the system's components may not be well presented in earlier releases and versions of
the portal. This is the portal via which users will gain access to the system. Users will be
reminded to always use the most recent version of the portal to ensure that the system
runs smoothly. The following minimal software specifications must be considered for the
system to operate at its best.

Operating system Windows 10 Pro Single Language 64 Bit

Programming Application Php Hypertext processor


Virtual Server Xampp 7.2.29
Database
Table 2. Software Specification
Module Described

1. POS Module
*Handles sales transactions, including cash and digital payments.
*Captures details of each sale, such as date, time, items sold, quantities, and total amount.
*Generates and prints receipts to customers.
*Records customer information and purchase history and applies discounts.
*Updates inventory levels in real-time as sales are made.
*Provides an intuitive interface for cashiers and sales associates, including product
lookup

2. Inventory Management Module


*Monitors stock levels in real-time.
*Generates alerts for low
stock levels, reorder points, and stock out situations.
*Creates, manages, and tracks purchase orders to suppliers, and records received
inventory.
*Generates reports on stock levels, inventory turnover, and valuation.

3. Credit Management Module


*Manages customer credit accounts, including transaction history and outstanding
balances.
*Sets and enforces credit limits for individual customers or customer categories.
*Facilitates sales on credit, updating customer balances and credit limits accordingly.
*Tracks payments made against credit sales, and records partial or full payments.
*Sends alerts for overdue accounts, approaching credit limits, and payment reminders.
*Generates detailed reports on credit sales, outstanding balances, and payment history.

4. User Management and Security Module


*Defines and manages user roles and access permissions to ensure security and
appropriate access levels.
*Maintains a log of user activities for accountability and security purposes.
Benefits of the Project/System

The success of the proposed system is deemed beneficial to the following:

1. Depot Owner - The system will help improve their business efficiency and allow them
to cope with technological trends in managing stores. The system will allow them to
easily and efficiently track and monitor the sales and inventory transactions, and the
status of items (running out of stocks).

2. Manager - The manager will benefit from real-time access to sales data, inventory
levels, and credit information, enabling more informed decision-making. The system will
reduce administrative burden, improve accuracy in financial reporting, and enhance
overall operational efficiency. With automated alerts and detailed analytics, the manager
can focus on strategic planning and business growth.

3. Cashier - For the cashier, the system streamlines the transaction process, making it
faster and more accurate. Automated receipt generation reduces errors and speeds up
customer service. The user-friendly interface simplifies training and daily operations,
allowing cashiers to manage transactions efficiently and with minimal manual input.

4. Supplier - Suppliers will experience improved communication and order accuracy. The
inventory management module ensures timely reordering of stock, reducing the risk of
stock outs or overstocking. Suppliers can also benefit from detailed reports on inventory
movement, helping them plan production and deliveries more effectively.

5. Customers - Customers will enjoy quicker checkouts and more accurate billing, leading
to a better shopping experience. The credit management module ensures that customers
who utilize store credit have their accounts managed efficiently, providing transparency
and ease in tracking their credit usage and repayments.

6. Proponents - The project developers, or proponents, gain valuable experience in


designing and implementing a comprehensive business solution. They will enhance their
skills in PHP, MySQL, and system integration, preparing them for future professional
opportunities. Successful implementation also adds a significant achievement to their
portfolio.

7. Future Researchers - Future researchers will benefit from the documentation and
insights provided by this project. They can build on the project's foundation to explore
further improvements, innovations, and applications in business automation. The project
serves as a case study for integrating various modules to enhance business operations,
offering a practical reference for academic and professional research.

CHAPTER IV
DEVELOPMENT, TESTING AND IMPLEMENTATION

This chapter covers the implementation strategy, system development life cycle,
and the proponent’s development and testing methodologies. To validate and support the
study, the proponents used a variety of analytical methodologies and data collection
strategies in this capstone project. The advocates were able to pinpoint the issues that
employees and company owners were having with the methods used for data collecting
under the current system. The analytical methods included brainstorming, observations,
and interviews. The collected data was analyzed and served as the basis for the design and
development of the system.

The System Development Life Cycle (SDLC) with a Waterfall model was
employed by the proponents in system development. This methodology uses the
following steps to carry out the entire software development process in a sequential
fashion: requirement analysis, system design, implementation, and maintenance.
Figure 1. System Development Life Cycle
Development
I. Planning
The proponents performed an interview to gain information on how the manager
owner kept the records. The advocates intended to create an automated system for Basic
T- shirt Depot to safeguard the data and make it easier for the cashier and salesman going
forward. Proponents’ findings about the client reveal significant inefficiencies in their
current business operations due to manual processes. The issuance of receipts is done
manually, which is time-consuming and prone to errors, leading to potential inaccuracies
in sales records. Stock checking is also conducted manually, requiring substantial time
and effort, and increasing the likelihood of inventory discrepancies. Additionally, the
client's business operates on a cash-only basis, limiting payment options for customers
and potentially reducing sales opportunities. These manual methods hinder operational
efficiency, data accuracy, and customer convenience, highlighting the need for an
automated system to streamline these processes.

II. Analysis and Design

After conducting interviews and gathering data, the proponents evaluated the
information, studies relevant literature, carried out experiments, and looked at the manual
record keeping practices of the existing premises. Consequently, an explicitly addressed
stance on software designed engaged, with its proponents using PHP and Visual Studio to
produce an approachable design. The proponents analyzed the data gathered by simply
first identifying the main problem inside the Basic- T-shirt Depot Pagadian based on the
information that the manager stated to the proponents and also based on what the
proponents observed inside. The result of analysis became the basis of the proponents in
designing the graphical user interface (GUI) and identifying the functions and modules to
be included.

III. Coding and Debugging

During development, the system’s source code was coded by the proponents using
PHP programming language. For software development, the source coding system was
identified and the relationship between the data was examined. The advocates test, debug,
and inspect the program after it has been developed.

IV. Testing

Initially, unit testing will be conducted on individual components to verify that


each function works correctly in isolation. This will be followed by integration testing to
ensure that the modules interact seamlessly and data flows correctly between them. User
acceptance testing (UAT) will then be carried out, involving real-world scenarios and
feedback from actual users, including the manager, cashier, and possibly customers, to
validate that the system meets their needs and expectations. Finally, stress testing will be
performed to assess the system's performance under peak load conditions, ensuring it can
handle high volumes of transactions and data processing without failure. Throughout the
testing phases, any identified bugs or issues will be documented and addressed promptly
to ensure a robust and reliable final product.

V. Implementation

The advocates planned to test the implementation. The test was created with a
mechanism in place for responses to be approved or accepted under real world operating
circumstances, where a program that is currently in use will be utilized for in the moment
activities within the workplace.

VI. Maintenance

Lastly, the advocates sent out a user manual covering different types of computer
upkeep required to maintain a system or other features. To be checked for malfunctioning
or outdated external hardware, such as pin pads or customer facing displays, as well as
internal parts, such as memory cards. These gadgets might malfunction and introduce
errors into the system, which could make the whole thing unusable until the
malfunctioning part is fixed or replac
CHAPTER V

RESULT AND DISCUSSION

Results and Discussion

The comprehensive data analysis and program design interface for the developed system's
efficient operation are covered in this chapter. The study's proponents attempted to
analyze the information received through questionnaires, observations, interviews, and
reviews of previous publications. Along with its functions, this part also covers the flow
of requirements and processes.

Figure 2. Context Diagram


Flow Chart Symbols Legend

Terminator: The start of end point

Data: Represents the input and output

Decision: Indicates a question branch of the


process

Process: The process of the action step

Documents: Shows the reports

Database: Serve as internal storage

Flow line Connections: Serve as the connector of products


Figure 3. Entity Relationship Diagram
Use Case Diagram

Use case diagrams actually describe the usage of the system from the viewpoint of
users(actors). Use case can be also viewed an functionality that is accomplished through the
interaction between system actors.

Figure 4. Use Case Diagram


Figure 5. Manager’s Flowchart

Database
Figure 6. Admin’s Flowchart
Conclusion

The implementation of an automated system integrating point-of-sale (POS),


inventory management, and credit management modules has undeniably propelled Basic
T-shirt Depot towards unprecedented levels of business efficiency and effectiveness. By
seamlessly intertwining these critical functionalities, the company has unlocked a
plethora of benefits that transcend mere process optimization. The POS module has not
only expedited transaction processing but also provided invaluable insights into consumer
behavior, enabling more informed decision-making and targeted marketing strategies.
Concurrently, the inventory management module has revolutionized stock control,
minimizing instances of overstocking or stock outs while maximizing inventory turnover
rates, thus optimizing resource allocation and minimizing operational costs.
Furthermore, the integration of the credit management module has fortified Basic
T-shirt Depot's financial framework, fostering smoother credit transactions and enhancing
customer satisfaction through flexible payment options. This robust system not only
ensures timely payments but also mitigates risks associated with bad debts, bolstering the
company's financial resilience. Collectively, these advancements signify more than just a
technological upgrade; they represent a strategic shift towards a more agile, customer-
concentric approach to business operations. As Basic T-shirt Depot continues to harness
the power of automation, it is well-positioned to navigate the complexities of the modern
retail landscape with confidence, efficiency, and sustained growth.

Recommendation
Based on the scope and limitations outlined, the recommendation for the
automated system developed for Basic T-shirt Depot is to continue expanding its
functionalities while addressing the identified gaps. Firstly, to enhance customer
convenience and payment options, integrating debit/credit card transactions into the
system should be prioritized. This expansion will cater to a wider range of payment
preferences and further streamline the checkout process, ultimately improving customer
satisfaction and facilitating smoother transactions.
Furthermore, to maximize the system's utility and user-friendliness, ongoing
training and support for staff members should be emphasized. Investing in comprehensive
training programs will ensure that employees are proficient in utilizing all features of the
automated system, thereby minimizing errors and maximizing productivity. Additionally,
regular updates and maintenance should be prioritized to address any potential issues or
software bugs, ensuring the system's reliability and longevity. By continuously refining
and expanding the capabilities of the automated system in line with evolving business
needs and technological advancements, Basic T-shirt Depot can remain at the forefront of
innovation in the retail industry, delivering exceptional service and driving sustainable
growth.
APPENDIX A

WEST PRIME HORIZON INSTITUTE, Inc.


V. Sagun cor. M. Roxas St., San Francisco

Pagadian City

Dear Ma'am,

Greetings of Peace and Solidarity

We, the students of Bachelor of Technical -Vocational Teacher Education major in Computer
Hardware Servicing of West Prime Horizon Institute Inc. Would like to ask permission to conduct
an interview in Basic T- shirt Depot for the fulfillment of our capstone Project 1 Entitled Basic T-
shirt Depot’s Automated System.

Conducting our study at your premises is crucial for gathering accurate and detailed data directly
from the operational environment. This will enable us to understand the specific challenges and
needs of your business, ensuring that our proposed automated system is tailored to improve
efficiency, accuracy, and customer satisfaction. By observing and analyzing your current
processes in real-time, we can design a solution that effectively addresses the manual tasks of
receipt issuance, stock checking, and cash transactions, ultimately enhancing overall productivity.

Rest assured that the data gathered will be kept confidential.

Thank you.

The proponents:

SHARLYN B. PANAWAN REGINE S. BANTAC RANYA M. MAMANGCAO

JENEFE B. VENTE CHRISTIAN L. DELA CERNA RICO N. HERMOSO

Recommending Approval: Approved by:

Waien G. Watamama Wilson Payales

Adviser Owner
WEST PRIME HORIZON INSTITUTE, INC.
San Francisco Dist,Pagadian City
SURVEY QUESTIONS FOR BASIC T-SHIRT DEPOT PAGADIAN

Name: Wilson Payales


Position: Owner of Basic T - shirt Depot Pagadian
Interview Conducted by: GROUP 1 Panawan

Section 1: Store Information


1. Store Name: Basic T - shirt Depot Pagadian
2. Location (City/Town): Rizal Avenue, San Pedro District, Pagadian City
3. Type of Store (e.g., grocery, retail, convenience, etc.): Clothing wholesale and retail
Section 2: Billing Practices
4. How are customer purchases typically recorded in your store? (Check all that apply)
 Handwritten receipts
 Printed receipts from a standalone machine
 Other (please specify): _______________________
5. On average, how long does it take to process a single customer transaction (from item
selection to payment completion)?
In our store, processing a single customer transaction, from item selection to payment
completion, typically takes around 3 to 5 minutes using handwritten billing.
6.What challenges, if any, have you encountered with your current billing process?
(Open-ended)
The challenges with our current handwritten billing process primarily revolve around
legibility issues, time consumption, error-proneness, and the difficulty in tracking sales
and inventory accurately.
Section 3: Inventory Management Practices
7.How is inventory typically managed in your store? (Check all that apply)
 Manual count
 Spreadsheets
 Other (please specify): _______________________
8. How often do you conduct inventory checks?
Once in every 3 months
Section 4: Future Considerations
9. Are you considering implementing a digital system for billing and/or inventory
management in the future?
 Yes
 No
 Unsure
10. What factors would influence your decision to adopt a digital system? (Select all that
apply)
 Cost
 Ease of use
 Training requirements
 Integration capabilities
 Other (please specify): _______________________

CRISTY DICDICAN
Stock In - Charge
APPENDIX C
PHOTO DOCUMENTATION

This photo of the proponent taken during the conduction of the proponent’s interview at
Basic T shirt Depot Pagadian.

This photo took at Basic t -shirt Depot Pagadian city, this is the manager of this store.
Our proponents conduct follow up interview for addition in our system.
The proponents conduct interview at Basic T-shirt Depot Pagadian located at Rizal
Avenue Pagadian City.

The proponents gathered to have brainstorming and to analyze the information they got
after the interview.
Checking documents and system to our Adviser, for more revise and grammar editing of
our document.
APPENDIX D
GRAPHICAL USER INTERFACE

http://localhost/ahira/

Picture 1. Log In Page

A login page serves as the entry point for users to access a system, application, or website
that requires authentication typically username and password.
Picture 2. Home Page
A homepage serves as the main entry point for a website, providing users with an overview
and access to its key features and manage system performance and operations.

Picture3. Add customer


This picture involves collecting and storing essential customer information, such as name,
contact details, address, and other relevant data.

Picture 4. Sales Transaction


This sales transaction designed to record and manage the exchange of goods or services for
payment between a seller and a buyer. This process involves documenting key details such as
the items sold, quantities, prices, discounts, cash tendered , and the total amount change.

Picture 5. Sales Invoice


Serves as an official request for payment and includes essential information such as the
invoice number, date of issuance, customer details, payment terms.

Picture 6. Stock in
Recording the quantities of items received, stored, and distributed, as well as monitoring
stock levels to ensure optimal inventory control.
Picture 7.Customer List
List details such as customer names, contact information, addresses, credit status, account
status, picture, balance and any relevant notes or preferences.

Picture 8. Update Customer List


Customer records to reflect changes such as new contact information, updated addresses,
changes in account status, or revised preferences and notes.

Picture 9.Apply as New Creditor

Assess applicants' creditworthiness through comprehensive evaluations of their Information,


contact number, financial status, income, and repayment capabilities.
Picture 9. Creditor List
Record of all entities or individuals to whom a debtor owes money. This list includes detailed
information about each creditor.

Picture 10. Update CI Details


Users can edit CI attributes such as name, remarks , date , status, and requirements with other
CI.Ensures that the system maintains an accurate and comprehensive record of all
configuration items, facilitating effective.
Picture 11. Add new product
Adding a new product items ensuring that they are properly documented, organized, and
ready for sale to customers.

Picture 12.Products list

Details about each product, such as its name, description, price, availability, and any
relevant attributes or variations.
Picture 13. Add new category /Category list
Users to create distinct categories that help organize information effectively and improve
navigation for users.
Display a hierarchical list of categories under which items, products, or content are
organized.

Picture 14. Product Inventory


Oversee the storage, ordering, and control of products within a business daily.

Picture 15. Select date sales


Process within a sales or point-of-sale (POS) system that allows users to view, analyze,
and manage sales data for a specific date or range of dates.
Picture 16. Cash Sales Report
Financial document that provides detailed information about all sales transactions
conducted in cash over a specific period.

Picture 17. Account Receivables


Owed to a company by its customers for goods or services that have been delivered.

Picture 18. Income Report


Summarize a company's revenues, costs, and expenses over a specific period, typically
quarterly or annually.
Picture 19. Purchase request
Employees within an organization request the acquisition of goods or services.

Picture 20.Administrator log in


Secure by typically requires authentication typically username and password of
administrative functions and controls that are not available to regular users.

This section welcomes the admin.


Picture 21. Application
Users manage tasks, create documents, and collaborate with others.Designed to perform
specific tasks efficiently and effectively.

Picture 21 .Reports per branch


Detailed insights and analysis of the performance, operations, and activities of individual
branches within a multi-location organization.

Picture 22. Branch


For adding branch operates in a specific location or serves a particular market by entry
complete information.
Picture 23. User
Allows administrators or authorized users to register new users by providing necessary
information such as username, branch, password, and user profile details.

Picture 14. History log


Activity log, is to record and track a chronological sequence of events, actions, or changes
that occur within a system, application, or database.

Picture 15.log out

logout, is to terminate a user's current session and end their access to a system, application, or
website
APPENDIX E
USER MANUAL GUIDE

The rest of his manual will guide you through all the forms which may be available to you
and how to use them.

Admin
http://localhost/ahira/admin/application.php

Logging In
Employee/ Owner
 Enter your username in the ‘Username’ field.
 Enter your password in the ‘Password ‘ field.
 Click the ‘Log in’ button
Logging In for the First Time
When logging in, you need to fill up the ‘ Applications’ to create a branch account.

Branch Dash board Screen

The branch page dashboard screen of a system typically displays essential information about
a specific branch, including performance metrics like sales and revenue, inventory status,
staffing details, customer insights, sales and marketing data, operational efficiency metrics,
alerts, trends, and analysis. It provides an at-a-glance overview to help branch managers and
stakeholders monitor and manage branch operations effectively.

To add branch, follow the following:


Enter your name in ‘Name’ field
Enter your address in ‘Address’ field
Enter your contact in ‘Contact #’ field
Enter your skin in ‘Skin color’ field
Click the ‘save’ button for adding branch.

Branch list

To log out, click ‘Giu Matthew’ at the right side corner immediately Log -out.

http://localhost/ahira/
Log- in page

Enter ‘Username’ in the field.

Enter ‘Password’ in the field.

Click the ‘Sign In button’.


Click any of this ‘Transaction’

1.Purchase: This is the initial step where a customer selects the products they want to buy
and communicates their intent to purchase them. This could happen through various channels
such as in-store, online shopping platforms, or via a sales representative.

2.Stock in: After the purchase is made, the next step involves ensuring that the purchased
products are available in the inventory. If the products are not already in stock, this step
involves acquiring or restocking them to fulfill the customer's order.

3.Payment: Once the products are ready to be delivered or picked up, the customer proceeds
to make the payment for their purchase. This could involve various payment methods such as
cash, credit/debit card, electronic fund transfer, or mobile payment services.

4.Credit: In some cases, customers may opt for credit-based payment methods, where they
are allowed to purchase products on credit and pay for them later within a specified period.
This step involves managing and processing credit transactions, including verifying credit
limits, terms, and agreements.

6. Products: Finally, once the payment is successfully processed, the purchased products are
handed over to the customer or dispatched for delivery, completing the transaction process.
This step ensures that the customer receives the products they paid for in a timely manner and
in good condition.
How to ‘purchase’

 Click the ‘Purchase’

 Click the ‘Go’ under Purchase

 Enter your customer last name in the ‘last name’ field.

 Enter your contact number in the ‘contact #’ field.

 Enter your customer first name in the ‘first name’ field.

 Enter your customer address in the ‘Address’ field.

 Click the ‘Next’ button

For old customer just search customer name

 Select a

Click ‘search’ button


Sales Transaction GUI will then show up.

 Select a product name in ‘product name ‘ field.

 Select a quantity by clicking the ‘ + ’ sign.

 Fill out the ‘total’ field.

 Fill out the ‘discount’ field.

 Fill out the ‘cash ou tendered’ field.

Click the ‘Complete Sales’ Button.

If you’re done, you will see the sales invoice.

 Click the ‘print’ button


Part 2. Sales transaction/ Customer Credit

 Select a product name in ‘product name ‘ field.

 Select a quantity by clicking the ‘ + ’ sign.

 Click the Action for ‘update sales details’.


 Click the button ‘save changes’.

If you want to pay in credit

 Click ‘Complete Credit ‘ button.

You can proceed in credit Information

 Enter the interest in ‘Interest’ field.


 Enter the down payment in ‘down payment’ field.

 Select the ‘ terms’.

 Select the ‘Payable for’

 Click the ‘ Finish ‘ Button

If you’re done, you will see the sales invoice.

 Click the ‘print’ button


How to add ‘Stocks’

Click the ‘Go’


 Select in ‘Product Name’ field.

 Enter the number of ‘Quantity’ field.

 Select the ‘ show entries’.

Click the button ‘Save’

How to use the ‘ Credit Management Section’

Click the ‘Go’ button

 First click the ‘ Apply as New Creditor’

 Fill out the form of ‘apply as new creditor’ form.

 Click the button ‘back’.

 Click the ‘credit management section’


 It save in ‘ creditor list’ .

 Click ‘Back’.

How to ‘Add Supplier’

 Click the ‘Maintenance’

 Click the ‘Supplier’.

 Click the ‘Action’ to Update Details Supplier.


 Enter the Supplier name in ‘Supplier name’ field.

 Enter the Supplier Address in ‘Supplier Address’ field.

 Enter the Supplier Contact Number in ‘Contact # of supplier’ field.

 Select the ‘save changes’ button.

 Add New supplier

 Enter a ‘Supplier Name’ in the field.

 Enter a ‘Supplier complete address’ in the field.

 Enter a ‘Supplier contact # in the field.


Click the button ‘Save’.

And it save in Supplier list.

 Click the button ‘back’.

How to Add ‘Product’.

 Click the ‘+’ button.


 Enter your ‘Product code’ in the field.

 Enter your ‘Product name’ in the field.

 Enter your ‘Product description’ in the field.

 Select a ‘ Supplier’ in the field.

 Enter your ‘product price’ in the field.

 Select a ‘category’ in the field.

 Enter your ‘Reorder’ field.

 Choose a ‘Picture’ and insert.

Click the button ‘Save changes’ and ‘Close’.

“How to use payment”


 Click the ‘Go’ button.

For updating customer list go to ‘Action’.

 Click the ‘Action ‘.


You can proceed in ‘Updating customer details’.

 Click the ‘save changes’ button.

If you’re done in your transaction click the log -out button in the right side.
 Recovering Forgotten Passwords

1. Open ‘XAMMP’ click ‘Start: Apache’, click ‘Start: MySQL’, and click ‘Start:FileZilla’.

2. Minimize the running programs and proceed to the next step.

3. Open ‘Chrome’ or any browser software and type

‘localhost/phpMyAdmin/’.
4. Click system’s database or click ‘New’ to import a new database.

5. Click ‘Inventory Schema’ and locate the encrypted password and the decrypt

6.Ask an IT on how to decrypt it or use any decryption site online.


APPENDIX F
REFERENCES

Hidayati, Irma & Sudarmiatin, Sudarmiatin & Hermawan, Agus. (2023). Analysis of Point of
Sale System Implementation in Coffee Shop. Jurnal Pendidikan dan Kewirausahaan.
11. 932-947. 10.47668/pkwu.v11i3.881.
https://dealhub.io/glossary/billing/#:~:text=Billing%20is%20the%20process%20of,payment
%20within%20a%20specific%20timeframe.
ttps://www.iqsdirectory.com/articles/automation-equipment/automation-system.html#:~:text=An
%20automation%20system%20is%20an,%2C%20electrical%2C%20and%20electronic%20systems.
https://1drv.ms/b/c/e5dc46a1d8ee9e02/EYt_ujhRscRDsp-IP78kKrQBfbBG5thDBp6J1ZDV8o3CUQ
APPENDIX G
SOURCE CODE

LOGIN.PHP
<?php session_start();
?>
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
#cssload-pgloading {}

#cssload-pgloading:after {
content: "";
z-index: -1;
position: absolute;
top: 0; right: 0; bottom: 0; left: 0;
}
#cssload-pgloading .cssload-loadingwrap
{position:absolute;top:45%;bottom:45%;left:25%;right:25%;}
#cssload-pgloading .cssload-bokeh {
font-size: 163px;
width: 2em;
height: 2em;
position: relative;
margin: 0 auto;
list-style: none;
padding:0;
border-radius: 50%;
-o-border-radius: 50%;
-ms-border-radius: 50%;
-webkit-border-radius: 50%;
-moz-border-radius: 50%;
}

#cssload-pgloading .cssload-bokeh li {
position: absolute;
width: .3em;
height: .3em;
border-radius: 50%;
-o-border-radius: 50%;
-ms-border-radius: 50%;
-webkit-border-radius: 50%;
-moz-border-radius: 50%;
}

#cssload-pgloading .cssload-bokeh li:nth-child(1) {


left: 50%;
top: 0;
margin: 0 0 0 -.2em;
background: rgb(0,193,118);
transform-origin: 50% 250%;
-o-transform-origin: 50% 250%;
-ms-transform-origin: 50% 250%;
-webkit-transform-origin: 50% 250%;
-moz-transform-origin: 50% 250%;
animation:
cssload-rota 1.3s linear infinite,
cssload-opa 4.22s ease-in-out infinite alternate;
-o-animation:
cssload-rota 1.3s linear infinite,
cssload-opa 4.22s ease-in-out infinite alternate;
-ms-animation:
cssload-rota 1.3s linear infinite,
cssload-opa 4.22s ease-in-out infinite alternate;
-webkit-animation:
cssload-rota 1.3s linear infinite,
cssload-opa 4.22s ease-in-out infinite alternate;
-moz-animation:
cssload-rota 1.3s linear infinite,
cssload-opa 4.22s ease-in-out infinite alternate;
}

#cssload-pgloading .cssload-bokeh li:nth-child(2) {


top: 50%;
right: 0;
margin: -.2em 0 0 0;
background: rgb(255,0,60);
transform-origin: -150% 50%;
-o-transform-origin: -150% 50%;
-ms-transform-origin: -150% 50%;
-webkit-transform-origin: -150% 50%;
-moz-transform-origin: -150% 50%;
animation:
cssload-rota 2.14s linear infinite,
cssload-opa 4.93s ease-in-out infinite alternate;
-o-animation:
cssload-rota 2.14s linear infinite,
cssload-opa 4.93s ease-in-out infinite alternate;
-ms-animation:
cssload-rota 2.14s linear infinite,
cssload-opa 4.93s ease-in-out infinite alternate;
-webkit-animation:
cssload-rota 2.14s linear infinite,
cssload-opa 4.93s ease-in-out infinite alternate;
-moz-animation:
cssload-rota 2.14s linear infinite,
cssload-opa 4.93s ease-in-out infinite alternate;
}

#cssload-pgloading .cssload-bokeh li:nth-child(3) {


left: 50%;
bottom: 0;
margin: 0 0 0 -.2em;
background: rgb(250,190,40);
transform-origin: 50% -150%;
-o-transform-origin: 50% -150%;
-ms-transform-origin: 50% -150%;
-webkit-transform-origin: 50% -150%;
-moz-transform-origin: 50% -150%;
animation:
cssload-rota 1.67s linear infinite,
cssload-opa 5.89s ease-in-out infinite alternate;
-o-animation:
cssload-rota 1.67s linear infinite,
cssload-opa 5.89s ease-in-out infinite alternate;
-ms-animation:
cssload-rota 1.67s linear infinite,
cssload-opa 5.89s ease-in-out infinite alternate;
-webkit-animation:
cssload-rota 1.67s linear infinite,
cssload-opa 5.89s ease-in-out infinite alternate;
-moz-animation:
cssload-rota 1.67s linear infinite,
cssload-opa 5.89s ease-in-out infinite alternate;
}
#cssload-pgloading .cssload-bokeh li:nth-child(4) {
top: 50%;
left: 0;
margin: -.2em 0 0 0;
background: rgb(136,193,0);
transform-origin: 250% 50%;
-o-transform-origin: 250% 50%;
-ms-transform-origin: 250% 50%;
-webkit-transform-origin: 250% 50%;
-moz-transform-origin: 250% 50%;
animation:
cssload-rota 1.98s linear infinite,
cssload-opa 6.04s ease-in-out infinite alternate;
-o-animation:
cssload-rota 1.98s linear infinite,
cssload-opa 6.04s ease-in-out infinite alternate;
-ms-animation:
cssload-rota 1.98s linear infinite,
cssload-opa 6.04s ease-in-out infinite alternate;
-webkit-animation:
cssload-rota 1.98s linear infinite,
cssload-opa 6.04s ease-in-out infinite alternate;
-moz-animation:
cssload-rota 1.98s linear infinite,
cssload-opa 6.04s ease-in-out infinite alternate;
}

@keyframes cssload-rota {
from { }
to { transform: rotate(360deg); }
}
@-o-keyframes cssload-rota {
from { }
to { -o-transform: rotate(360deg); }
}

@-ms-keyframes cssload-rota {
from { }
to { -ms-transform: rotate(360deg); }
}

@-webkit-keyframes cssload-rota {
from { }
to { -webkit-transform: rotate(360deg); }
}

@-moz-keyframes cssload-rota {
from { }
to { -moz-transform: rotate(360deg); }
}

@keyframes cssload-opa {
0% { }
12.0% { opacity: 0.80; }
19.5% { opacity: 0.88; }
37.2% { opacity: 0.64; }
40.5% { opacity: 0.52; }
52.7% { opacity: 0.69; }
60.2% { opacity: 0.60; }
66.6% { opacity: 0.52; }
70.0% { opacity: 0.63; }
79.9% { opacity: 0.60; }
84.2% { opacity: 0.75; }
91.0% { opacity: 0.87; }
}

@-o-keyframes cssload-opa {
0% { }
12.0% { opacity: 0.80; }
19.5% { opacity: 0.88; }
37.2% { opacity: 0.64; }
40.5% { opacity: 0.52; }
52.7% { opacity: 0.69; }
60.2% { opacity: 0.60; }
66.6% { opacity: 0.52; }
70.0% { opacity: 0.63; }
79.9% { opacity: 0.60; }
84.2% { opacity: 0.75; }
91.0% { opacity: 0.87; }
}

@-ms-keyframes cssload-opa {
0% { }
12.0% { opacity: 0.80; }
19.5% { opacity: 0.88; }
37.2% { opacity: 0.64; }
40.5% { opacity: 0.52; }
52.7% { opacity: 0.69; }
60.2% { opacity: 0.60; }
66.6% { opacity: 0.52; }
70.0% { opacity: 0.63; }
79.9% { opacity: 0.60; }
84.2% { opacity: 0.75; }
91.0% { opacity: 0.87; }
}

@-webkit-keyframes cssload-opa {
0% { }
12.0% { opacity: 0.80; }
19.5% { opacity: 0.88; }
37.2% { opacity: 0.64; }
40.5% { opacity: 0.52; }
52.7% { opacity: 0.69; }
60.2% { opacity: 0.60; }
66.6% { opacity: 0.52; }
70.0% { opacity: 0.63; }
79.9% { opacity: 0.60; }
84.2% { opacity: 0.75; }
91.0% { opacity: 0.87; }
}

@-moz-keyframes cssload-opa {
0% { }
12.0% { opacity: 0.80; }
19.5% { opacity: 0.88; }
37.2% { opacity: 0.64; }
40.5% { opacity: 0.52; }
52.7% { opacity: 0.69; }
60.2% { opacity: 0.60; }
66.6% { opacity: 0.52; }
70.0% { opacity: 0.63; }
79.9% { opacity: 0.60; }
84.2% { opacity: 0.75; }
91.0% { opacity: 0.87; }
}
</style>
</head>
<body>
<div id="cssload-pgloading">
<div class="cssload-loadingwrap">
<ul class="cssload-bokeh">
<li></li>
<li></li>
<li></li>
<li></li>
</ul>
</div>
</div>

</body>

</html>
<?php
include('dist/includes/dbcon.php');

if(isset($_POST['login']))
{

$user_unsafe=$_POST['username'];
$pass_unsafe=$_POST['password'];
$branch=$_POST['branch'];

$user = mysqli_real_escape_string($con,$user_unsafe);
$pass1 = mysqli_real_escape_string($con,$pass_unsafe);

$pass=md5($pass1);
$salt="a1Bz20ydqelm8m1wql";
$pass=$salt.$pass;

date_default_timezone_set('Asia/Manila');

$date = date("Y-m-d H:i:s");


$query=mysqli_query($con,"select * from user natural join branch where username='$user'
and password='$pass' and branch_id='$branch' and status='active'")or
die(mysqli_error($con));
$row=mysqli_fetch_array($query);
$id=$row['user_id'];
$name=$row['name'];
$counter=mysqli_num_rows($query);

$id=$row['user_id'];
$_SESSION['branch']=$row['branch_id'];
$_SESSION['skin']=$row['skin'];

if ($counter == 0)
{
echo "<script type='text/javascript'>alert('Invalid Username or Password!');
document.location='index.php'</script>";
}
elseif ($counter > 0)
{
$_SESSION['id']=$id;
$_SESSION['name']=$name;
$remarks="has logged in the system at ";
mysqli_query($con,"INSERT INTO history_log(user_id,action,date)
VALUES('$id','$remarks','$date')")or die(mysqli_error($con));
$query1=mysqli_query($con,"select * from payment natural join customer where
branch_id='$branch' and status<>'paid'")or die(mysqli_error($con));
while($row1=mysqli_fetch_array($query1)){

$pid=$row1['payment_id'];
$balance=$row1['balance'];
$payment_for = date("Y-m-d",strtotime($row1['payment_for']));
$date = date("Y-m-d");
$due1 = date("Y-m-d",strtotime($payment_for. " +1 months"));
$due2 = date("Y-m-d",strtotime($due1. " +5 days"));
if ($date>$due2)
{
$interest=$balance*(0.03);
mysqli_query($con,"UPDATE payment SET
interest='$interest',remaining=remaining+'$interest' where payment_id='$pid'") or
die(mysqli_error($con));

}
else
{
$interest='0';

echo "<script
type='text/javascript'>document.location='pages/home.php'</script>";
}
}
?>

INDEX.PHP
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Login - <?php include('dist/includes/title.php');?></title>
<!-- Tell the browser to be responsive to screen width -->
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
name="viewport">
<!-- Bootstrap 3.3.5 -->
<link rel="stylesheet" href="bootstrap/css/bootstrap.min.css">

<!-- Font Awesome -->


<!-- Theme style -->
<link rel="stylesheet" href="dist/css/AdminLTE.min.css">
<!-- AdminLTE Skins. Choose a skin from the css/skins
folder instead of downloading all of them to reduce the load. -->
<link rel="stylesheet" href="dist/css/skins/_all-skins.min.css">

<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<!-- ADD THE CLASS layout-top-nav TO REMOVE THE SIDEBAR. -->
<body class="hold-transition login-page">

<div class="login-box">
<div class="login-logo">
<b>Sales and Inventory with Credit Management System</b>

</div><!-- /.login-logo -->


<div class="login-box-body">
<p class="login-box-msg">Sign in to start your session</p>
<form action="login.php" method="post">
<div class="form-group has-feedback">
<input type="text" class="form-control" placeholder="Username" name="username"
required>
<span class="glyphicon glyphicon-envelope form-control-feedback"></span>
</div>
<div class="form-group has-feedback">
<input type="password" class="form-control" placeholder="Password"
name="password" required>
<span class="glyphicon glyphicon-lock form-control-feedback"></span>
</div>
<div class="form-group has-feedback">
<select class="form-control select2" style="width:100%" name="branch" required>
<?php
include('dist/includes/dbcon.php');

$query3=mysqli_query($con,"select * from branch order by branch_name")or


die(mysqli_error($con));
while($row3=mysqli_fetch_array($query3)){
?>
<option value="<?php echo $row3['branch_id'];?>"><?php echo
$row3['branch_name'];?></option>
<?php }?>
</select>
</div>
<div class="row">
<div class="col-xs-6 pull-right">
<button type="reset" class="btn btn-block btn-flat">Clear</button>
</div><!-- /.col -->
<div class="col-xs-6 pull-right">
<button type="submit" class="btn btn-primary btn-block btn-flat" name="login"
default>Sign In</button>
</div><!-- /.col -->
</div>
</form>
</div><!-- /.login-box-body -->
</div><!-- /.login-box -->

<!-- jQuery 2.1.4 -->


<script src="plugins/jQuery/jQuery-2.1.4.min.js"></script>
<!-- Bootstrap 3.3.5 -->
<script src="bootstrap/js/bootstrap.min.js"></script>
<!-- SlimScroll -->
<script src="plugins/slimScroll/jquery.slimscroll.min.js"></script>
<!-- FastClick -->
<script src="plugins/fastclick/fastclick.min.js"></script>
<!-- AdminLTE App -->
<script src="dist/js/app.min.js"></script>
<!-- AdminLTE for demo purposes -->
<script src="dist/js/demo.js"></script>
</body>
</html>

View Application. PHP


<?php session_start();
if(empty($_SESSION['id'])):
header('Location:../index.php');
endif;
if(empty($_SESSION['branch'])):
header('Location:../index.php');
endif;
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Creditor Application | <?php include('../dist/includes/title.php');?></title>
<!-- Tell the browser to be responsive to screen width -->
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
name="viewport">
<!-- Bootstrap 3.3.5 -->
<link rel="stylesheet" href="../bootstrap/css/bootstrap.min.css">
<!-- Font Awesome -->
<link rel="stylesheet" href="../plugins/datatables/dataTables.bootstrap.css">

<link rel="stylesheet" href="../plugins/select2/select2.min.css">


<!-- AdminLTE Skins. Choose a skin from the css/skins
folder instead of downloading all of them to reduce the load. -->

<style>

</style>
</head>
<!-- ADD THE CLASS layout-top-nav TO REMOVE THE SIDEBAR. -->
<body>
<div class="wrapper">
<?php
include('../dist/includes/dbcon.php');
?>
<!-- Full Width Column -->
<div class="content-wrapper">
<div class="container">
<!-- Content Header (Page header) -->

<!-- Main content -->


<section class="content">
<div class="row">
<div class="col-md-12">
<div class="box box-primary">
<div class="box-header with-border">
<h3 class="box-title">Creditor Application</h3>
</div>
<?php
$cid=$_GET['cid'];
$query=mysqli_query($con,"select * from customer where cust_id='$cid'")or
die(mysqli_error());
$row=mysqli_fetch_array($query);

?>

<div class="box-body">
<!-- Date range -->
<form method="post" action="creditor_add.php" enctype="multipart/form-data"
class="form-horizontal">
<div class="row">
<div class="col-md-4">
<label for="date">Last Name</label>
<div class="input-group col-md-12">
<div class="input-group col-sm-12">
<?php echo $row['cust_last'];?>
</div><!-- /.input group -->
</div><!-- /.form group -->
</div>

<div class="col-md-4">
<label for="date">First Name</label>
<div class="input-group col-md-12">
<?php echo $row['cust_first'];?>
</div><!-- /.input group -->

</div>
<div class="col-md-4">
<label for="date">Middle Initial</label>
<div class="input-group col-md-12">
<?php echo $row['cust_mi'];?>
</div><!-- /.input group -->
</div><!-- /.form group -->
</div><!--row-->
<div class="row">
<div class="col-md-4">
<label for="date">Birthday</label>
<div class="input-group col-md-12">
<?php echo date("M d, Y",strtotime($row['bday']));?>
</div><!-- /.input group -->
</div>

<div class="col-md-4">
<label for="date">Nick Name</label>
<div class="input-group col-md-12">
<?php echo $row['nickname'];?>
</div>
</div>

</div>
<div class="row">
<div class="col-md-8">
<label for="date">Present Home Address</label>
<div class="input-group col-md-12">
<?php echo $row['cust_address'];?>
</div><!-- /.input group -->
</div>
<div class="col-md-4">
<label for="date">Tel # and Cellphone #</label>
<div class="input-group col-md-12">
<?php echo $row['cust_contact'];?>
</div><!-- /.input group -->
</div>

</div><!--row-->
<div class="row">
<div class="col-md-6">
<label for="date">House Status</label>
<div class="input-group col-md-6">
<?php echo $row['house_status'];?>
<?php echo $row['years'];?>
</div>

</div>

<div class="col-md-12">
<label for="date">If renting</label>
<div class="input-group col-md-12">
<?php echo $row['rent'];?>
</div>
</div>

<div class="col-md-6">
<label for="date">Name of Employer or Business</label>
<div class="input-group col-md-12">
<?php echo $row['emp_name'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Employer/Business Contact #</label>
<div class="input-group col-md-12">
<?php echo $row['emp_no'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Employer or Business Address</label>
<div class="input-group col-md-12">
<?php echo $row['emp_address'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Years Employed or in Business</label>
<div class="input-group col-md-12">
<?php echo $row['emp_year'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Occupation</label>
<div class="input-group col-md-12">
<?php echo $row['occupation'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Monthly Salary/ Net Business Income</label>
<div class="input-group col-md-12">
<?php echo $row['salary'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Spouse Name</label>
<div class="input-group col-md-12">
<?php echo $row['spouse'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Cellphone Number</label>
<div class="input-group col-md-12">
<?php echo $row['spouse_no'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Spouse Employer or Business</label>
<div class="input-group col-md-12">
<?php echo $row['spouse_emp'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Spouse Employer or Business Address & Telephone
Number</label>
<div class="input-group col-md-12">
<?php echo $row['spouse_details'];?>
</div>
</div>
<div class="col-md-12">
<label for="date">Spouse Monthly Income</label>
<div class="input-group col-md-12">
<?php echo $row['spouse_income'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Name of Co-Maker (If required)</label>
<div class="input-group col-md-12">
<?php echo $row['comaker'];?>
</div>
</div>
<div class="col-md-6">
<label for="date">Present Home Address & Telephone # of Co-Maker</label>
<div class="input-group col-md-12">
<?php echo $row['comaker_details'];?>
</div>
</div>

</div><!--row-->

</form>

</div><!-- /.box-body -->


</div><!-- /.box -->
</div>

</section><!-- /.content -->


</div><!-- /.container -->
</div><!-- /.content-wrapper -->
<?php include('../dist/includes/footer.php');?>
</div><!-- ./wrapper -->

<!-- jQuery 2.1.4 -->


<script src="../plugins/jQuery/jQuery-2.1.4.min.js"></script>
<!-- Bootstrap 3.3.5 -->
<script src="../bootstrap/js/bootstrap.min.js"></script>
<script src="../plugins/select2/select2.full.min.js"></script>
<!-- SlimScroll -->
<script src="../plugins/slimScroll/jquery.slimscroll.min.js"></script>
<!-- FastClick -->
<script src="../plugins/fastclick/fastclick.min.js"></script>
<!-- AdminLTE App -->
<script src="../dist/js/app.min.js"></script>
<!-- AdminLTE for demo purposes -->
<script src="../dist/js/demo.js"></script>
<script src="../plugins/datatables/jquery.dataTables.min.js"></script>
<script src="../plugins/datatables/dataTables.bootstrap.min.js"></script>

<script>
$(function () {
$("#example1").DataTable();
$('#example2').DataTable({
"paging": true,
"lengthChange": false,
"searching": false,
"ordering": true,
"info": true,
"autoWidth": false
});
});
</script>
<script>
$(function () {
//Initialize Select2 Elements
$(".select2").select2();

//Datemask dd/mm/yyyy
$("#datemask").inputmask("dd/mm/yyyy", {"placeholder": "dd/mm/yyyy"});
//Datemask2 mm/dd/yyyy
$("#datemask2").inputmask("mm/dd/yyyy", {"placeholder": "mm/dd/yyyy"});
//Money Euro
$("[data-mask]").inputmask();

//Date range picker


$('#reservation').daterangepicker();
//Date range picker with time picker
$('#reservationtime').daterangepicker({timePicker: true, timePickerIncrement: 30, format:
'MM/DD/YYYY h:mm A'});
//Date range as a button
$('#daterange-btn').daterangepicker(
{
ranges: {
'Today': [moment(), moment()],
'Yesterday': [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
'Last 7 Days': [moment().subtract(6, 'days'), moment()],
'Last 30 Days': [moment().subtract(29, 'days'), moment()],
'This Month': [moment().startOf('month'), moment().endOf('month')],
'Last Month': [moment().subtract(1, 'month').startOf('month'), moment().subtract(1,
'month').endOf('month')]
},
startDate: moment().subtract(29, 'days'),
endDate: moment()
},
function (start, end) {
$('#reportrange span').html(start.format('MMMM D, YYYY') + ' - ' +
end.format('MMMM D, YYYY'));
}
);

//iCheck for checkbox and radio inputs


$('input[type="checkbox"].minimal, input[type="radio"].minimal').iCheck({
checkboxClass: 'icheckbox_minimal-blue',
radioClass: 'iradio_minimal-blue'
});
//Red color scheme for iCheck
$('input[type="checkbox"].minimal-red, input[type="radio"].minimal-red').iCheck({
checkboxClass: 'icheckbox_minimal-red',
radioClass: 'iradio_minimal-red'
});
//Flat red color scheme for iCheck
$('input[type="checkbox"].flat-red, input[type="radio"].flat-red').iCheck({
checkboxClass: 'icheckbox_flat-green',
radioClass: 'iradio_flat-green'
});

//Colorpicker
$(".my-colorpicker1").colorpicker();
//color picker with addon
$(".my-colorpicker2").colorpicker();

//Timepicker
$(".timepicker").timepicker({
showInputs: false
});
});
</script>
</body>
</html>

__________________________________________________________________________________
___
User Update. PHP
<?php session_start();
if(empty($_SESSION['id'])):
header('Location:../index.php');
endif;

include('../dist/includes/dbcon.php');
$id = $_POST['id'];
$name =$_POST['name'];
$username =$_POST['username'];
$status = $_POST['status'];

mysqli_query($con,"update user set


name='$name',username='$username',status='$status' where user_id='$id'")or
die(mysqli_error($con));

echo "<script type='text/javascript'>alert('Successfully updated user


details!');</script>";
echo "<script>document.location='user.php'</script>";

?>

User Add.PHP
<?php

include('../dist/includes/dbcon.php');

$name = $_POST['name'];
$username = $_POST['username'];
$password = $_POST['password'];

$pass=md5($password);
$salt="a1Bz20ydqelm8m1wql";
$pass=$salt.$pass;
mysqli_query($con,"INSERT INTO
user(name,username,password,status)
VALUES('$name','$username','$pass','active')")or
die(mysqli_error($con));

echo "<script type='text/javascript'>alert('Successfully added new


user!');</script>";
echo "<script>document.location='user.php'</script>";

?>

User.PHP

<?php include 'header.php';?>


<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?>
<!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">
<div class = "col-md-4 col-lg-4 col-xs-4">
<?php include 'add_user_form.php';?>
</div>
<div class = "col-md-8 col-lg-8 col-xs-8">
<div class = "x-panel">
<table id="datatable" class="table table-striped
table-bordered table-responsive">
<thead>
<tr>
<th>Fullname</th>
<th>Branch Name</th>
<th>Username</th>
<th>Password</th>
<th>Status</th>
<th>Action</th>

</tr>
</thead>
<tbody>
<?php
include 'dbcon.php';

$query1=mysqli_query($con,"select * from user NATURAL JOIN branch ORDER BY


user_id ASC")or die(mysqli_error($con));
while
($row=mysqli_fetch_array($query1)){

$id=$row['user_id'];

?>
<tr>
<td><?php echo
$row['name'];?></td>
<td><?php echo
$row['branch_name'];?></td>
<td><?php echo
$row['username'];?></td>
<td>****</td>
<td><?php echo
$row['status'];?></td>
<td>
<a
href="#update<?php echo $id;?>" class="btn btn-success btn-xs" data-toggle = "modal" data-
target="#update<?php echo $id;?>"><i class = "fa fa-pencil"></i> Edit</a>

</td>

</tr>
<?php include
'update_user_modal.php';?>
<?php }?>
</tbody>

</table>
</div>
</div>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>
__________________________________________________________________________________
__
update user modal.PHP
<div id = "update<?php echo $id;?>" class="modal fade bs-example-modal-sm" tabindex="-1"
role="dialog" aria-hidden="true">
<div class="modal-dialog modal-sm">
<div class="modal-content">

<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-
label="Close"><span aria-hidden="true">×</span>
</button>
<h4 class="modal-title" id="myModalLabel2">Edit User Details</h4>
</div>
<div class="modal-body">
<form method = "POST" action = "update_user.php">
<input type="hidden" name="user_id"
value="<?php echo $id;?>">
<label>Full name</label>
<input type="text" name
= "name" class="form-control" value = "<?php echo $row['name'];?>">
<br/>

<label>Username</label>
<input type="text" name
= "username" class="form-control" value = "<?php echo $row['username'];?>">
<br/>
<label>Password</label>
<input type="password"
name = "password" class="form-control" placeholder="Enter to Change Password">
<br/>
<label>Status</label>
<select name = "status" class =
"form-control">
<option value =
"active">Active</option>
<option value =
"inactive">Inactive</option>
</select>
<br/>
<label>Branch Name</label>
<select name =
"branch_id" class = "form-control">
<option value =
"<?php echo $row['branch_id'];?>"><?php echo $row['branch_name'];?></option>
<option></option>
<?php
include
'dbcon.php';

$query4=mysqli_query($con,"select * from branch")or die(mysqli_error($con));


while
($row1=mysqli_fetch_array($query4)){

$id3=$row1['branch_id'];
?>
<option value =
"<?php echo $row1['branch_id'];?>"><?php echo $row1['branch_name'];?></option>
<?php } ?>

</select>
<br/>
<button type="button" class="btn btn-
default" data-dismiss="modal">Close</button>
<button name = "update" class="btn
btn-primary">Save changes</button>
</form>
</div>
<div class="modal-footer">
</div>
</div>
</div>
</div>

update user. PHP


<?php
include('dbcon.php');

if (isset($_POST['update']))
{
$id = $_POST['user_id'];
$name = $_POST['name'];
$username = $_POST['username'];
$password = $_POST['password'];
$status = $_POST['status'];
$branch_id = $_POST['branch_id'];

if($password=="")
{

mysqli_query($con,"UPDATE user SET username='$username', name = '$name',


status = '$status', branch_id = '$branch_id' where user_id='$id'")
or die(mysqli_error($con));
}
else
{
$pass=md5($password);
$salt="a1Bz20ydqelm8m1wql";
$pass=$salt.$pass;

mysqli_query($con,"UPDATE user SET username='$username', password =


'$pass', name = '$name', status = '$status', branch_id = '$branch_id' where user_id='$id'")
or die(mysqli_error($con));
}
echo "<script type='text/javascript'>alert('Successfully updated user
details!');</script>";
echo "<script>document.location='user.php'</script>";

update branch modal.PHP


<div id = "update<?php echo $id;?>" class="modal fade bs-example-modal-sm" tabindex="-1"
role="dialog" aria-hidden="true">
<div class="modal-dialog modal-sm">
<div class="modal-content">

<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-
label="Close"><span aria-hidden="true">×</span>
</button>
<h4 class="modal-title" id="myModalLabel2">Edit Branch Details</h4>
</div>
<div class="modal-body">
<form method = "POST" action = "update_branch.php">
<input type="hidden" name="branch_id"
value="<?php echo $id;?>">
<label>Name</label>
<input type="text" name
= "branch_name" class="form-control" value = "<?php echo $row1['branch_name'];?>">
<br/>

<label>Address</label>
<input type="text" name
= "branch_address" class="form-control" value = "<?php echo $row1['branch_address'];?>">
<br/>
<label>Contact #</label>
<input type="text" name
= "branch_contact" class="form-control" value = "<?php echo $row1['branch_contact'];?>">
<br/>
<label>Skin</label>
<select name = "skin"
class = "form-control">
<option value =
"<?php echo $row1['skin'];?>"><?php echo $row1['skin'];?></option>

<option>red</option>

<option>purple</option>

<option>black</option>

<option>blue</option>

<option>green</option>

<option>yellow</option>
</select>
<br/>
<button type="button" class="btn btn-
default" data-dismiss="modal">Close</button>
<button name = "update" class="btn
btn-primary">Save changes</button>
</form>
</div>
<div class="modal-footer">

</div>
</div>
</div>
</div>

update branch.PHP
<?php
include('dbcon.php');

if (isset($_POST['update']))
{
$id = $_POST['branch_id'];
$branch_name = $_POST['branch_name'];
$branch_address = $_POST['branch_address'];
$branch_contact = $_POST['branch_contact'];
$skin = $_POST['skin'];

mysqli_query($con,"UPDATE branch SET branch_name='$branch_name',


branch_address = '$branch_address', branch_contact = '$branch_contact', skin = '$skin' where
branch_id='$id'")
or die(mysqli_error($con));

echo "<script type='text/javascript'>alert('Successfully updated Branch


details!');</script>";
echo "<script>document.location='branch.php'</script>";

top nav.PHP
<div class="top_nav">
<div class="nav_menu">
<nav>
<div class="nav toggle">
<a id="menu_toggle"><i class="fa fa-bars"></i></a>
</div>

<ul class="nav navbar-nav navbar-right">


<li class="">
<a href="javascript:;" class="user-profile dropdown-toggle" data-
toggle="dropdown" aria-expanded="false">
<img src="images/admin.png" alt=""><?php echo $user_username; ?>
<span class=" fa fa-angle-down"></span>
</a>
<ul class="dropdown-menu dropdown-usermenu pull-right">

<li><a href="logout.php"><i class="fa fa-sign-out pull-right"></i> Log


Out</a></li>
</ul>
</li>
</ul>
</nav>
</div>
</div>

Side bar2.PHP
<div class="sidebar-footer hidden-small">
<a data-toggle="tooltip" data-placement="top" title="Settings">
<span class="glyphicon glyphicon-cog" aria-hidden="true"></span>
</a>
<a data-toggle="tooltip" data-placement="top" title="FullScreen">
<span class="glyphicon glyphicon-fullscreen" aria-hidden="true"></span>
</a>
<a data-toggle="tooltip" data-placement="top" title="Lock">
<span class="glyphicon glyphicon-eye-close" aria-hidden="true"></span>
</a>
<a data-toggle="tooltip" data-placement="top" href = "logout.php" title="Logout">
<span class="glyphicon glyphicon-off" aria-hidden="true"></span>
</a>
</div>

Sidebar.PHP
<div id="sidebar-menu" class="main_menu_side hidden-print main_menu">
<div class="menu_section">
<h3>Menu</h3>
<ul class="nav side-menu">
<li><a href = "application.php"><i class="fa fa-file"></i> Applications<span class="fa
fa-chevron-right"></span></a>
<li><a href = "reports.php"><i class="fa fa-file"></i> Reports
per branch<span class="fa fa-chevron-right"></span></a>
<li><a><i class="fa fa-building"></i>Inventory per branch
<span class="fa fa-chevron-down"></span></a>
<ul class="nav child_menu">
<?php
include 'dbcon.php';
$query1=mysqli_query($con,"select * from
branch ORDER BY branch_name")or die(mysqli_error($con));
while ($row=mysqli_fetch_array($query1)){
$id=$row['branch_id'];?>
<li><a href="inventory.php?id=<?php echo $row['branch_id'];?>"><?php echo
$row ['branch_name'];?></a></li>
<?php }?>
</ul>
</li>
<li><a href = "overall.php"><i class="fa fa-file"></i> Overall
Reports<span class="fa fa-chevron-right"></span></a></li>
<li><a href = "branch.php"><i class="fa fa-building"></i> Branch <span class="fa
fa-chevron-right"></span></a>
<!--- <ul class="nav child_menu">
<li><a href="branch.php">Branch</a></li>
<li><a href="index2.html">User</a></li>
<li><a href="index3.html">Dashboard3</a></li>
</ul>--->
</li>
<li><a href = "user.php"><i class="fa fa-users"></i> User <span class="fa fa-
chevron-right"></span></a></li>
<li><a href = "history.php"><i class="fa fa-history"></i> History Log <span
class="fa fa-chevron-right"></span></a></li>
<!-- <li><a href = "product.php"><i class="fa fa-shopping-cart"></i> Products<span
class="fa fa-chevron-right"></span></a></li> -->
<!-- <li><a><i class="fa fa-desktop"></i> UI Elements <span class="fa fa-chevron-
down"></span></a>
<ul class="nav child_menu">
<li><a href="general_elements.html">General Elements</a></li>
<li><a href="media_gallery.html">Media Gallery</a></li>
<li><a href="typography.html">Typography</a></li>
<li><a href="icons.html">Icons</a></li>
<li><a href="glyphicons.html">Glyphicons</a></li>
<li><a href="widgets.html">Widgets</a></li>
<li><a href="invoice.html">Invoice</a></li>
<li><a href="inbox.html">Inbox</a></li>
<li><a href="calendar.html">Calendar</a></li>
</ul>
</li>--->
<!---<li><a><i class="fa fa-table"></i> Tables <span class="fa
fa-chevron-down"></span></a>
<ul class="nav child_menu">
<li><a href="tables.html">Tables</a></li>
<li><a href="tables_dynamic.html">Table Dynamic</a></li>
</ul>
</li>--->
<!---<li><a><i class="fa fa-bar-chart-o"></i> Data Presentation <span class="fa fa-
chevron-down"></span></a>
<ul class="nav child_menu">
<li><a href="chartjs.html">Chart JS</a></li>
<li><a href="chartjs2.html">Chart JS2</a></li>
<li><a href="morisjs.html">Moris JS</a></li>
<li><a href="echarts.html">ECharts</a></li>
<li><a href="other_charts.html">Other Charts</a></li>
</ul>
</li>---->
<!--- <li><a><i class="fa fa-clone"></i>Layouts <span class="fa fa-chevron-
down"></span></a>
<ul class="nav child_menu">
<li><a href="fixed_sidebar.html">Fixed Sidebar</a></li>
<li><a href="fixed_footer.html">Fixed Footer</a></li>
</ul>
</li>--->
</ul>
</div>
<!--- <div class="menu_section">
<h3>Live On</h3>
<ul class="nav side-menu">
<li><a><i class="fa fa-bug"></i> Additional Pages <span class="fa fa-chevron-
down"></span></a>
<ul class="nav child_menu">
<li><a href="e_commerce.html">E-commerce</a></li>
<li><a href="projects.html">Projects</a></li>
<li><a href="project_detail.html">Project Detail</a></li>
<li><a href="contacts.html">Contacts</a></li>
<li><a href="profile.html">Profile</a></li>
</ul>
</li>
<li><a><i class="fa fa-windows"></i> Extras <span class="fa
fa-chevron-down"></span></a>
<ul class="nav child_menu">
<li><a href="page_403.html">403 Error</a></li>
<li><a href="page_404.html">404 Error</a></li>
<li><a href="page_500.html">500 Error</a></li>
<li><a href="plain_page.html">Plain Page</a></li>
<li><a href="login.html">Login Page</a></li>
<li><a href="pricing_tables.html">Pricing Tables</a></li>
</ul>
</li>
<li><a><i class="fa fa-sitemap"></i> Multilevel Menu <span class="fa fa-chevron-
down"></span></a>
<ul class="nav child_menu">
<li><a href="#level1_1">Level One</a>
<li><a>Level One<span class="fa fa-chevron-down"></span></a>
<ul class="nav child_menu">
<li class="sub_menu"><a href="level2.html">Level Two</a>
</li>
<li><a href="#level2_1">Level Two</a>
</li>
<li><a href="#level2_2">Level Two</a>
</li>
</ul>
</li>
<li><a href="#level1_2">Level One</a>
</li>
</ul>
</li>
<li><a href="javascript:void(0)"><i class="fa fa-laptop"></i> Landing Page <span
class="label label-success pull-right">Coming Soon</span></a></li>
</ul>
</div>--->

</div>

Session.PHP
<?php include ('dbcon.php');
session_start();
//Check whether the session variable SESS_MEMBER_ID is present or not
if (!isset($_SESSION['id']) || (trim($_SESSION['id']) == '')) { ?>
<script>
window.location = "index.php";
</script>
<?php
}
$session_id=$_SESSION['id'];

$user_query = mysqli_query($con,"select * from user where user_id = '$session_id'")or


die(mysql_error());
$user_row = mysqli_fetch_array($user_query);
$user_username = $user_row['name'];

?>

Script.PHP
<!-- jQuery -->
<script src="vendors/jquery/dist/jquery.min.js"></script>
<!-- Bootstrap -->
<script src="vendors/bootstrap/dist/js/bootstrap.min.js"></script>
<!-- FastClick -->
<script src="vendors/fastclick/lib/fastclick.js"></script>
<!-- NProgress -->
<script src="vendors/nprogress/nprogress.js"></script>
<!-- Chart.js -->
<script src="vendors/Chart.js/dist/Chart.min.js"></script>
<!-- gauge.js -->
<script src="vendors/gauge.js/dist/gauge.min.js"></script>
<!-- bootstrap-progressbar -->
<script src="vendors/bootstrap-progressbar/bootstrap-progressbar.min.js"></script>
<!-- iCheck -->
<script src="vendors/iCheck/icheck.min.js"></script>
<!-- Skycons -->
<script src="vendors/skycons/skycons.js"></script>
<!-- Flot -->
<script src="vendors/Flot/jquery.flot.js"></script>
<script src="vendors/Flot/jquery.flot.pie.js"></script>
<script src="vendors/Flot/jquery.flot.time.js"></script>
<script src="vendors/Flot/jquery.flot.stack.js"></script>
<script src="vendors/Flot/jquery.flot.resize.js"></script>
<!-- Flot plugins -->
<script src="vendors/flot.orderbars/js/jquery.flot.orderBars.js"></script>
<script src="vendors/flot-spline/js/jquery.flot.spline.min.js"></script>
<script src="vendors/flot.curvedlines/curvedLines.js"></script>
<!-- DateJS -->
<script src="vendors/DateJS/build/date.js"></script>
<!-- JQVMap -->
<script src="vendors/jqvmap/dist/jquery.vmap.js"></script>
<script src="vendors/jqvmap/dist/maps/jquery.vmap.world.js"></script>
<script src="vendors/jqvmap/examples/js/jquery.vmap.sampledata.js"></script>
<!-- bootstrap-daterangepicker -->
<script src="vendors/moment/min/moment.min.js"></script>
<script src="vendors/bootstrap-daterangepicker/daterangepicker.js"></script>

<!-- Custom Theme Scripts -->


<script src="build/js/custom.min.js"></script>

<!-- Flot -->


<script>
$(document).ready(function() {
var data1 = [
[gd(2012, 1, 1), 17],
[gd(2012, 1, 2), 74],
[gd(2012, 1, 3), 6],
[gd(2012, 1, 4), 39],
[gd(2012, 1, 5), 20],
[gd(2012, 1, 6), 85],
[gd(2012, 1, 7), 7]
];

var data2 = [
[gd(2012, 1, 1), 82],
[gd(2012, 1, 2), 23],
[gd(2012, 1, 3), 66],
[gd(2012, 1, 4), 9],
[gd(2012, 1, 5), 119],
[gd(2012, 1, 6), 6],
[gd(2012, 1, 7), 9]
];
$("#canvas_dahs").length && $.plot($("#canvas_dahs"), [
data1, data2
], {
series: {
lines: {
show: false,
fill: true
},
splines: {
show: true,
tension: 0.4,
lineWidth: 1,
fill: 0.4
},
points: {
radius: 0,
show: true
},
shadowSize: 2
},
grid: {
verticalLines: true,
hoverable: true,
clickable: true,
tickColor: "#d5d5d5",
borderWidth: 1,
color: '#fff'
},
colors: ["rgba(38, 185, 154, 0.38)", "rgba(3, 88, 106, 0.38)"],
xaxis: {
tickColor: "rgba(51, 51, 51, 0.06)",
mode: "time",
tickSize: [1, "day"],
//tickLength: 10,
axisLabel: "Date",
axisLabelUseCanvas: true,
axisLabelFontSizePixels: 12,
axisLabelFontFamily: 'Verdana, Arial',
axisLabelPadding: 10
},
yaxis: {
ticks: 8,
tickColor: "rgba(51, 51, 51, 0.06)",
},
tooltip: false
});

function gd(year, month, day) {


return new Date(year, month - 1, day).getTime();
}
});
</script>
<!-- /Flot -->

<!-- JQVMap -->


<script>
$(document).ready(function(){
$('#world-map-gdp').vectorMap({
map: 'world_en',
backgroundColor: null,
color: '#ffffff',
hoverOpacity: 0.7,
selectedColor: '#666666',
enableZoom: true,
showTooltip: true,
values: sample_data,
scaleColors: ['#E6F2F0', '#149B7E'],
normalizeFunction: 'polynomial'
});
});
</script>
<!-- /JQVMap -->

<!-- Skycons -->


<script>
$(document).ready(function() {
var icons = new Skycons({
"color": "#73879C"
}),
list = [
"clear-day", "clear-night", "partly-cloudy-day",
"partly-cloudy-night", "cloudy", "rain", "sleet", "snow", "wind",
"fog"
],
i;

for (i = list.length; i--;)


icons.set(list[i], list[i]);
icons.play();
});
</script>
<!-- /Skycons -->

<!-- Doughnut Chart -->


<script>
$(document).ready(function(){
var options = {
legend: false,
responsive: false
};

new Chart(document.getElementById("canvas1"), {
type: 'doughnut',
tooltipFillColor: "rgba(51, 51, 51, 0.55)",
data: {
labels: [
"Symbian",
"Blackberry",
"Other",
"Android",
"IOS"
],
datasets: [{
data: [15, 20, 30, 10, 30],
backgroundColor: [
"#BDC3C7",
"#9B59B6",
"#E74C3C",
"#26B99A",
"#3498DB"
],
hoverBackgroundColor: [
"#CFD4D8",
"#B370CF",
"#E95E4F",
"#36CAAB",
"#49A9EA"
]
}]
},
options: options
});
});
</script>
<!-- /Doughnut Chart -->

<!-- bootstrap-daterangepicker -->


<script>
$(document).ready(function() {

var cb = function(start, end, label) {


console.log(start.toISOString(), end.toISOString(), label);
$('#reportrange span').html(start.format('MMMM D, YYYY') + ' - ' +
end.format('MMMM D, YYYY'));
};

var optionSet1 = {
startDate: moment().subtract(29, 'days'),
endDate: moment(),
minDate: '01/01/2012',
maxDate: '12/31/2015',
dateLimit: {
days: 60
},
showDropdowns: true,
showWeekNumbers: true,
timePicker: false,
timePickerIncrement: 1,
timePicker12Hour: true,
ranges: {
'Today': [moment(), moment()],
'Yesterday': [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
'Last 7 Days': [moment().subtract(6, 'days'), moment()],
'Last 30 Days': [moment().subtract(29, 'days'), moment()],
'This Month': [moment().startOf('month'), moment().endOf('month')],
'Last Month': [moment().subtract(1, 'month').startOf('month'), moment().subtract(1,
'month').endOf('month')]
},
opens: 'left',
buttonClasses: ['btn btn-default'],
applyClass: 'btn-small btn-primary',
cancelClass: 'btn-small',
format: 'MM/DD/YYYY',
separator: ' to ',
locale: {
applyLabel: 'Submit',
cancelLabel: 'Clear',
fromLabel: 'From',
toLabel: 'To',
customRangeLabel: 'Custom',
daysOfWeek: ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'],
monthNames: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August',
'September', 'October', 'November', 'December'],
firstDay: 1
}
};
$('#reportrange span').html(moment().subtract(29, 'days').format('MMMM D, YYYY') + '
- ' + moment().format('MMMM D, YYYY'));
$('#reportrange').daterangepicker(optionSet1, cb);
$('#reportrange').on('show.daterangepicker', function() {
console.log("show event fired");
});
$('#reportrange').on('hide.daterangepicker', function() {
console.log("hide event fired");
});
$('#reportrange').on('apply.daterangepicker', function(ev, picker) {
console.log("apply event fired, start/end dates are " + picker.startDate.format('MMMM
D, YYYY') + " to " + picker.endDate.format('MMMM D, YYYY'));
});
$('#reportrange').on('cancel.daterangepicker', function(ev, picker) {
console.log("cancel event fired");
});
$('#options1').click(function() {
$('#reportrange').data('daterangepicker').setOptions(optionSet1, cb);
});
$('#options2').click(function() {
$('#reportrange').data('daterangepicker').setOptions(optionSet2, cb);
});
$('#destroy').click(function() {
$('#reportrange').data('daterangepicker').remove();
});
});
</script>
<!-- /bootstrap-daterangepicker -->

<!-- gauge.js -->


<script>
var opts = {
lines: 12,
angle: 0,
lineWidth: 0.4,
pointer: {
length: 0.75,
strokeWidth: 0.042,
color: '#1D212A'
},
limitMax: 'false',
colorStart: '#1ABC9C',
colorStop: '#1ABC9C',
strokeColor: '#F0F3F3',
generateGradient: true
};
var target = document.getElementById('foo'),
gauge = new Gauge(target).setOptions(opts);

gauge.maxValue = 6000;
gauge.animationSpeed = 32;
gauge.set(3200);
gauge.setTextField(document.getElementById("gauge-text"));
</script>

Reports.PHP

<?php include 'header.php';?>


<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?>
<!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">

<?php
include 'dbcon.php';
$query1=mysqli_query($con,"select * from
branch ORDER BY branch_name")or die(mysqli_error($con));
while ($row=mysqli_fetch_array($query1)){
$id=$row['branch_id'];?>
<a href = "page_reports.php?id=<?php echo
$row['branch_id'];?>">
<div class = "col-md-6 col-6-12 col-6">

<div class = "panel panel-success">


<div class = "panel-heading">
<i class = "center fa fa-
building"></i>
</div>
<div class = "panel-body">
<h1 class = ""><?
php echo $row['branch_name'];?></h1>
</div>
</div>

</div>
</a>
<?php } ?>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>

Product.PHP

<?php include 'header.php';

$branch_id = $_GET['id'];
?>
<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?> <!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">

<div class = "x-panel">


<?php
$branch=$_SESSION['branch'];
$query=mysqli_query($con,"select * from branch where
branch_id='$branch'")or die(mysqli_error());
$row=mysqli_fetch_array($query);

?>
<h5><b><?php echo $row['branch_name'];?></b> </h5>
<h6>Address: <?php echo $row['branch_address'];?></h6>
<h6>Contact #: <?php echo $row['branch_contact'];?></h6>
<h5><b>Product Inventory as of today, <?php echo date("M d,
Y h:i a");?></b></h5>

<a class = "btn btn-success btn-print" href = "" onclick =


"window.print()"><i class ="glyphicon glyphicon-print"></i> Print</a>
<a class = "btn btn-primary btn-print"
href = "home.php"><i class ="glyphicon glyphicon-arrow-left"></i> Back to Homepage</a>

<table class="table table-bordered table-striped">


<thead>

<tr>

<th>Product Name</th>
<th>Qty Left</th>

<th>Price</th>
<th>Total</th>
<th>Reorder</th>
</tr>
</thead>
<tbody>
<?php
$branch=$_GET['id'];

$query=mysqli_query($con,"select * from product where branch_id='$branch' order by


prod_name")or die(mysqli_error());
$grand=0;

while($row=mysqli_fetch_array($query)){

$total=$row['prod_price']*$row['prod_qty'];
$grand+=$total;
?>
<tr>
<td><?php echo $row['prod_name'];?></td>
<td><?php echo $row['prod_qty'];?></td>

<td><?php echo $row['prod_price'];?></td>


<td><?php echo
number_format($total,2);?></td>
<td class="text-center"><?php if
($row['prod_qty']<=$row['reorder'])echo "<span class='badge bg-red'><i class='glyphicon
glyphicon-refresh'></i>Reorder</span>";?></td>

</tr>

<?php }?>
</tbody>
<tfoot>
<tr>
<th colspan="3">Total</th>
<th colspan="2">P<?php echo
number_format($grand,2);?></th>

</tr>
</tfoot>
</table>
</div>
</div>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>

Page reports.PHP
<?php include 'header.php';

$branch_id = $_GET['id'];

?>
<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?>
<!-- /top navigation -->

<!-- page content -->


<div role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">
<div class = "x-panel">
<div class="right_col" role="main">
<?php

$branch=$_GET['id'];
$query=mysqli_query($con,"select * from branch where
branch_id='$branch'")or die(mysqli_error());
$row=mysqli_fetch_array($query);

?>
<h5><b><?php echo $row['branch_name'];?></b> </h5>
<h6>Address: <?php echo $row['branch_address'];?></h6>
<h6>Contact #: <?php echo $row['branch_contact'];?></h6>
<h5><b>Product Inventory as of today, <?php echo date("M d,
Y h:i a");?></b></h5>
<a class = "btn btn-success btn-print" href = "" onclick =
"window.print()"><i class ="glyphicon glyphicon-print"></i> Print</a>
<a class = "btn btn-primary btn-print" href = "reports.php"><i
class ="glyphicon glyphicon-arrow-left"></i> Back to Homepage</a>

<div class="row tile_count">


<div class="col-lg-3 col-md-3 col-
sm-3 col-xs-3 tile_stats_count">
<span class="count_top"><i
class="fa fa-money"></i> Total Sales</span>
<?php
$year1 = date("Y");
$month = date("m");
$branch_id = $_GET['id'];
$query =
mysqli_query($con,"select SUM(payment) as total_payment from payment where
MONTH(payment_date)='$month' and YEAR(payment_date)='$year1' and branch_id
='$branch_id' ") or die(mysqli_error($con));

$row=mysqli_fetch_array($query);

?>
<div class="count">
<?php echo
$row['total_payment'];?>

</div>

<span class="count_bottom"><i
class="green"></i>For the month of <?php echo date("F",strtotime($month));?>, <?php echo
$year1;?></span>
</div>
<div class="col-md-3 col-sm-3 col-
xs-3 tile_stats_count">
<span class="count_top"><i
class="fa fa-money"></i> Total Receivables</span>
<?php
$date = date("M. d, Y");
$branch_id = $_GET['id'];
$query =
mysqli_query($con,"select SUM(balance) as total_balance from customer where branch_id
='$branch_id' ") or die(mysqli_error($con));

$row1=mysqli_fetch_array($query);

?>
<div class="count green"><?php
echo $row1['total_balance'];?></div>
<span class="count_bottom"><i
class="green">Total Receivables as of</i> <?php echo $date;?></span>
</div>
<div class="col-md-3 col-sm-3 col-
xs-3 tile_stats_count">
<span class="count_top"><i
class="fa fa-user"></i> Active Customers</span>
<?php
$query =
mysqli_query($con,"select COUNT(*) as total_no_customer from customer where branch_id
='$branch_id' AND balance !='0' ") or die(mysqli_error($con));

$row2=mysqli_fetch_array($query);
?>
<div class="count"><?php echo
$row2['total_no_customer'];?></div>
<span class="count_bottom"><i
class="red">as of today</i></span>
</div>
<div class="col-lg-3 col-md-3 col-
sm-3 col-xs-3 tile_stats_count">
<span class="count_top"><i
class="fa fa-user"></i> Number products re-order</span>
<?php
$query =
mysqli_query($con,"select COUNT(*) as total_no_reorder from product where branch_id
='$branch_id' AND prod_qty <=reorder ") or die(mysqli_error($con));

$row3=mysqli_fetch_array($query);
?>
<div class="count"><?php echo
$row3['total_no_reorder'];?></div>
<span class="count_bottom"><i
class="green">as of today</i></span>
</div>
<div class="col-md-12 col-sm-12 col-xs-
12">
<div
class="x_panel">
<div
class="x_title">
<h2>Total
Monthly Sales <small></small></h2>
<ul
class="nav navbar-right panel_toolbox">
<li><a
class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li
class="dropdown">
<a
href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-
expanded="false"><i class="fa fa-wrench"></i></a>
<ul
class="dropdown-menu" role="menu">

<li><a href="#">Settings 1</a>

</li>
<li><a href="#">Settings 2</a>

</li>

</ul>
</li>
<li><a
class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div
class="clearfix"></div>
</div>
<div
class="x_content">
<div
id="graph"></div>

<table id="example1" class="table table-bordered table-striped">

<tr>

<th>MONTH</th>
<th
class="text-right">SALES</th>
</tr>

<tbody>
<?php
$_SESSION['branch']=$_GET['id'];
$year=date("Y");
$query=mysqli_query($con,"select *,SUM(payment) as
payment,DATE_FORMAT(payment_date,'%b') as month from payment where
YEAR(payment_date)='$year' and branch_id='$branch' group by MONTH(payment_date)")or
die(mysqli_error($con));
$total=0;
while($row=mysqli_fetch_array($query)){
$total=$total+$row['payment'];
?>

<tr>
<th><?php echo$row['month'];?></th>
<td class="text-right"><b><?php echo
number_format($row['payment'],2);?></b></td>
</tr>
<?php }?>
<tr>
<th><h2>TOTAL</h2></th>
<th class="text-right"><h2><b><?php echo
number_format($total,2);?></b></h2></td>
</tr>
</tbody>
<tfoot>

</tfoot>
</table>

</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->

<!-- /footer content -->


</div>
</div>
<script src="vendors/jquery/dist/jquery.min.js"></script>
<script src="js/highcharts.js"></script>
<!-- Bootstrap -->
<script src="js/exporting.js"></script>

<!-- FastClick -->

<script type="text/javascript">
$(document).ready(function() {
var options = {
chart: {
renderTo: 'graph',
type: 'column',
marginRight: 20,
marginBottom: 25
},
title: {
text: '',
x: -20 //center
},
subtitle: {
text: '',
x: -10
},
xAxis: {
categories: []
},
yAxis: {

title: {
text: 'Total Monthly Sales'
},
plotLines: [{
value: 0,
width: 1,
color: '#808080'
}]
},
tooltip: {
formatter: function() {
return '<b>'+ this.series.name +'</b><br/>'+ Highcharts.numberFormat(this.y,
0)
this.x +': '+ this.y

;
}
},
legend: {
layout: 'vertical',
align: 'right',
verticalAlign: 'top',
x: 0,
y: 100,
borderWidth: 0
},
series: []
}

$.getJSON("data.php", function(json) {
options.xAxis.categories = json[0]['name'];
options.series[0] = json[1];
//options.series[1] = json[2];

chart = new Highcharts.Chart(options);


});
});
</script>
<?php include 'datatable_script.php';?>
<!-- /gauge.js -->
</body>
</html>

Overall.PHP

<?php include 'header.php';?>


<style type="text/css">
h5,h6{
text-align:center;
}
@media print {
.btn-print {
display:none !important;
}
.main-footer {
display:none !important;
}
.box.box-primary {
border-top:none !important;
}
.angel{
display:none !important;
}
.hide-section{
display:none;
}

}
</style>

<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?>
<!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class = "row">
<div class = "col-md-12 col-lg-12 hide-section">
<div class = "panel">
<div class="panel-heading">
<h3 class="box-title">Select Date</h3>
<a class = "btn btn-success btn-print" href = "" onclick =
"window.print()"><i class ="glyphicon glyphicon-print"></i> Print</a>
<a class = "btn btn-primary btn-print" href = "home.php"><i
class ="glyphicon glyphicon-arrow-left"></i> Back to Homepage</a>
</div>
<div class="box-body">

<!-- /.form group -->


<form method="post" >
<div class="form-group col-md-6">
<label></label>

<div class="input-group">
<div class="input-group-addon">
<i class="fa fa-calendar"></i>
</div>
<select class="form-control select2"
name="month" tabindex="1" autofocus required>
<option value="1">January</option>
<option value="2">February</option>
<option value="3">March</option>
<option value="4">April</option>
<option value="5">May</option>
<option value="6">June</option>
<option value="7">July</option>
<option value="8">August</option>
<option value="9">September</option>
<option value="10">October</option>
<option value="11">November</option>
<option value="12">December</option>

</select>
</div>
<!-- /.input group -->
</div>
<div class="form-group col-md-5">
<label></label>

<div class="input-group">
<div class="input-group-addon">
<i class="fa fa-calendar"></i>
</div>
<select class="form-control select2"
name="year" tabindex="1" required>
<option>2017</option>
<option>2018</option>
<option>2019</option>

</select>
</div>
<!-- /.input group -->
</div>
<!-- /.form group --><br>
<button type="submit" class="btn btn-primary"
name="display">Display</button>
</form>

</div>
<!-- /.box-body -->
</div>
<!-- /.box -->

</div>
</div>

<div class="row">

<div class="col-md-12 col-sm-12 col-xs-12">

<div id="graph"></div>

<table id="example1" class="table table-bordered table-striped">

<tr>

<th>MONTH</th>

<th>BRANCH</th>
<th
class="text-right">SALES</th>
</tr>

<tbody>
<?php

if (isset($_POST['display'])){
$year=$_POST['year'];
$month=$_POST['month'];
$_SESSION['year']=$year;
$_SESSION['month']=$month;

$query=mysqli_query($con,"select *,SUM(payment) as
payment,DATE_FORMAT(payment_date,'%b') as month from payment natural join branch
where YEAR(payment_date)='$year' and
MONTH(payment_date)='$month' group by branch_id,MONTH(payment_date) order by
MONTH(payment_date)")or die(mysqli_error($con));
$total=0;

echo "<h2 style='text-align:center'><b>Monthly Sales</b></h2>";


while($row=mysqli_fetch_array($query)){
$total=$total+$row['payment'];

?>

<tr>
<th><?php echo $row['month']." ".$year;?></th>
<th><?php echo $row['branch_name'];?></th>
<td class="text-right"><b><?php echo
number_format($row['payment'],2);?></b></td>
</tr>
<?php }
echo "<tr>
<th><h2>TOTAL</h2></th>
<th colspan='2' class='text-right'><h2><b>$total</b></h2></td>
</tr>";
}?>

</tbody>
<tfoot>

</tfoot>
</table>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<script
type="text/javascript"src="vendors/jquery/dist/jquery.min.js"></script>
<script type="text/javascript"src="js/highcharts.js"></script>
<script type="text/javascript"src="js/exporting.js"></script>
<script type="text/javascript">
$(document).ready(function() {
var options = {
chart: {
renderTo: 'graph',
plotBackgroundColor: null,
plotBorderWidth: null,
plotShadow: false,
spacingBottom: 50,
},
title: {
text: '',
style: { fontFamily:
'\'Lato\', sans-serif', lineHeight: '18px', fontSize: '26px' }
},
tooltip: {
formatter: function() {
return '<b>'+ this.point.name +'</b>: '+
Highcharts.numberFormat(this.percentage, 2) +' %';
}
},
plotOptions: {
pie: {
allowPointSelect: true,
cursor: 'pointer',
dataLabels: {
enabled: true,
color: '#000000',

style: { fontFamily: '\'Lato\', sans-serif', lineHeight: '18px', fontSize: '14px' },


connectorColor: '#000000',
formatter: function() {
return '<b>'+ this.point.name +'</b>: '+
Highcharts.numberFormat(this.percentage, 2) +' %';
}
}
}
},
series: [{
type: 'pie',
name: 'Employability Rate',
data: []
}]
}

$.getJSON("datapie.php", function(json) {
options.series[0].data = json;
chart = new Highcharts.Chart(options);
});

});
</script>

<!-- /gauge.js -->


</body>
</html>

Main sidebar.PHP
<div class="col-md-3 left_col">
<div class="left_col scroll-view">
<div class="navbar nav_title" style="border: 0;">
<a href="#" class="site_title"><i class="fa fa-cog"></i>
<span>Administrator</span></a>
</div>

<div class="clearfix"></div>

<!-- menu profile quick info -->


<div class="profile clearfix">
<div class="profile_pic">
<img src="images/admin.jpg" alt="..." class="img-circle profile_img">
</div>
<div class="profile_info">
<span>Basic Shirt Depo Corp</span>

</div>
</div>
<!-- /menu profile quick info -->

<br />

<!-- sidebar menu -->


<?php include 'sidebar.php';?>
<!-- /sidebar menu -->

<!-- /menu footer buttons -->


<?php include 'sidebar2.php';?>
<!-- /menu footer buttons -->
</div>
</div>

Logout.PHP
<?php
include 'dbcon.php';
session_start();
session_destroy();
?>
<script>
window.location = 'index.php';
</script>

Login.PHP
<?php session_start();

include('dbcon.php');

if(isset($_POST['login']))
{

$user_unsafe=$_POST['username'];
$pass_unsafe=$_POST['password'];

$user = mysqli_real_escape_string($con,$user_unsafe);
$pass1 = mysqli_real_escape_string($con,$pass_unsafe);
$pass=md5($pass1);
$salt="a1Bz20ydqelm8m1wql";
$pass=$salt.$pass;

$query=mysqli_query($con,"select * from user where username='$user' and password='$pass'


and status = 'Active' and branch_id='0'")or die(mysqli_error($con));
$row=mysqli_fetch_array($query);
$id=$row['user_id'];
/* $first=$row['admin_first'];
$last=$row['admin_last']; */
$counter=mysqli_num_rows($query);

if ($counter == 0)
{
echo "<script type='text/javascript'>alert('Invalid Username or
Password!');
document.location='index.php'</script>";
}
else
{
$_SESSION['id']=$id;
$_SESSION['branch']=0;
/* $_SESSION['name']=$first." ".$last; */

echo "<script
type='text/javascript'>document.location='reports.php'</script>";
}
}
?>

Inventory.PHP

<?php include 'header.php';

$branch_id = $_GET['id'];
?>
<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?> <!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">

<div class = "x-panel">


<?php
$branch=$_GET['id'];
$query=mysqli_query($con,"select * from branch where
branch_id='$branch'")or die(mysqli_error());
$row=mysqli_fetch_array($query);

?>
<h5><b><?php echo $row['branch_name'];?></b> </h5>
<h6>Address: <?php echo $row['branch_address'];?></h6>
<h6>Contact #: <?php echo $row['branch_contact'];?></h6>
<h5><b>Product Inventory as of today, <?php echo date("M d,
Y h:i a");?></b></h5>

<a class = "btn btn-success btn-print" href = "" onclick =


"window.print()"><i class ="glyphicon glyphicon-print"></i> Print</a>
<a class = "btn btn-primary btn-print"
href = "home.php"><i class ="glyphicon glyphicon-arrow-left"></i> Back to Homepage</a>

<table class="table table-bordered table-striped">


<thead>

<tr>

<th>Product Name</th>
<th>Qty Left</th>

<th>Price</th>
<th>Total</th>
<th>Reorder</th>

</tr>
</thead>
<tbody>
<?php
$branch=$_GET['id'];

$query=mysqli_query($con,"select * from product where branch_id='$branch' order by


prod_name")or die(mysqli_error());
$grand=0;

while($row=mysqli_fetch_array($query)){

$total=$row['prod_price']*$row['prod_qty'];
$grand+=$total;
?>
<tr>
<td><?php echo $row['prod_name'];?></td>
<td><?php echo $row['prod_qty'];?></td>

<td><?php echo $row['prod_price'];?></td>


<td><?php echo
number_format($total,2);?></td>
<td class="text-center"><?php if
($row['prod_qty']<=$row['reorder'])echo "<span class='badge bg-red'><i class='glyphicon
glyphicon-refresh'></i>Reorder</span>";?></td>

</tr>

<?php }?>
</tbody>
<tfoot>
<tr>
<th colspan="3">Total</th>

<th colspan="2">P<?php echo


number_format($grand,2);?></th>

</tr>
</tfoot>
</table>
</div>
</div>
</div>
</div>
</div>
<!-- /page content -->
<!-- footer content -->
<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>

Index.PHP
<?php include 'header_login.php';?>

<body class="login">
<div>

<div class="login_wrapper">
<div class="animate form login_form">
<section class="login_content">
<form method = "POST" action = "login.php">
<h1>Administrator Login</h1>
<div>
<input type="text" name = "username" class="form-control"
placeholder="Username" required="true" />
</div>
<div>
<input type="password" name = "password" class="form-control"
placeholder="Password" required="true" />
</div>
<div>
<button class="btn btn-block btn-warning" name = "login"> Log in</button>

</div>

<div class="clearfix"></div>

<div class="separator">

<div class="clearfix"></div>
<br />

<div>
<h1><i class="fa fa-paw"></i> Sales and Inventory System </h1>
<p>Basic Clothing Line Company</p>
</div>
</div>
</form>
</section>
</div>
</div>
</div>
</body>
</html>

History.PHP

<?php include 'header.php';?>


<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?> <!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">

<div class = "x-panel">


<table id="datatable" class="table table-striped
table-bordered table-responsive">
<thead>
<tr>
<th>Fullname</th>
<th>Activity</th>

</tr>
</thead>
<tbody>
<?php
include 'dbcon.php';

$query1=mysqli_query($con,"select * from history_log NATURAL JOIN user ORDER


BY log_id DESC")or die(mysqli_error($con));
while
($row=mysqli_fetch_array($query1)){

$id=$row['log_id'];
?>
<tr>
<td><?php echo
$row['name'];?></td>
<td><?php echo
$row['action']. " ".date("F d, Y - - h:i A", strtotime($row['date'])); ?></td>

</tr>
<?php include
'update_user_modal.php';?>
<?php }?>
</tbody>

</table>
</div>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>

Header login.PHP
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<!-- Meta, title, CSS, favicons, etc. -->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">

<title>Sales and Inventory System</title>

<!-- Bootstrap -->


<link href="vendors/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
<!-- Font Awesome -->
<link href="vendors/font-awesome/css/font-awesome.min.css" rel="stylesheet">
<!-- NProgress -->
<link href="vendors/nprogress/nprogress.css" rel="stylesheet">
<!-- Animate.css -->
<link href="vendors/animate.css/animate.min.css" rel="stylesheet">

<!-- Custom Theme Style -->


<link href="build/css/custom.min.css" rel="stylesheet">
</head>

Header.PHP
<?php include 'session.php';?>

<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<!-- Meta, title, CSS, favicons, etc. -->
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">

<title>Sales and Inventory System </title>

<!-- Bootstrap -->


<link href="vendors/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
<!-- Font Awesome -->
<link href="vendors/font-awesome/css/font-awesome.min.css" rel="stylesheet">
<!-- NProgress -->
<link href="vendors/nprogress/nprogress.css" rel="stylesheet">
<!-- iCheck -->
<link href="vendors/iCheck/skins/flat/green.css" rel="stylesheet">
<!-- bootstrap-progressbar -->
<link href="vendors/bootstrap-progressbar/css/bootstrap-progressbar-3.3.4.min.css"
rel="stylesheet">
<!-- JQVMap -->
<link href="vendors/jqvmap/dist/jqvmap.min.css" rel="stylesheet"/>
<!-- bootstrap-daterangepicker -->
<link href="vendors/bootstrap-daterangepicker/daterangepicker.css" rel="stylesheet">

<!-- Custom Theme Style -->


<link href="build/css/custom.min.css" rel="stylesheet">

<style>
h5,h6{
text-align:center;
}
@media print {
.btn-print {
display:none !important;
}
.main-footer {
display:none !important;
}
.box.box-primary {
border-top:none !important;
}
.nav_menu {
display:none;
}
footer{
display:none;
}

</style>

<!---dataTable--->

<?php include 'dbcon.php';?>


</head>

Dbcon.PHP
<?php
$con = mysqli_connect("localhost","root","","inventory");

// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
?>

Datatable Script.PHP
<script src="vendors/jquery/dist/jquery.min.js"></script>
<!-- Bootstrap -->
<script src="vendors/bootstrap/dist/js/bootstrap.min.js"></script>
<!-- FastClick -->
<script src="vendors/fastclick/lib/fastclick.js"></script>
<!-- NProgress -->
<script src="vendors/nprogress/nprogress.js"></script>
<!-- iCheck -->
<script src="vendors/iCheck/icheck.min.js"></script>
<!-- Datatables -->
<script src="vendors/datatables.net/js/jquery.dataTables.min.js"></script>
<script src="vendors/datatables.net-bs/js/dataTables.bootstrap.min.js"></script>
<script src="vendors/datatables.net-buttons/js/dataTables.buttons.min.js"></script>
<script src="vendors/datatables.net-buttons-bs/js/buttons.bootstrap.min.js"></script>
<script src="vendors/datatables.net-buttons/js/buttons.flash.min.js"></script>
<script src="vendors/datatables.net-buttons/js/buttons.html5.min.js"></script>
<script src="vendors/datatables.net-buttons/js/buttons.print.min.js"></script>
<script src="vendors/datatables.net-fixedheader/js/dataTables.fixedHeader.min.js"></script>
<script src="vendors/datatables.net-keytable/js/dataTables.keyTable.min.js"></script>
<script src="vendors/datatables.net-responsive/js/dataTables.responsive.min.js"></script>
<script src="vendors/datatables.net-responsive-bs/js/responsive.bootstrap.js"></script>
<script src="vendors/datatables.net-scroller/js/datatables.scroller.min.js"></script>
<script src="vendors/jszip/dist/jszip.min.js"></script>
<script src="vendors/pdfmake/build/pdfmake.min.js"></script>
<script src="vendors/pdfmake/build/vfs_fonts.js"></script>

<!-- Custom Theme Scripts -->


<script src="build/js/custom.min.js"></script>

<!-- Datatables -->


<script>
$(document).ready(function() {
var handleDataTableButtons = function() {
if ($("#datatable-buttons").length) {
$("#datatable-buttons").DataTable({
dom: "Bfrtip",
buttons: [
{
extend: "copy",
className: "btn-sm"
},
{
extend: "csv",
className: "btn-sm"
},
{
extend: "excel",
className: "btn-sm"
},
{
extend: "pdfHtml5",
className: "btn-sm"
},
{
extend: "print",
className: "btn-sm"
},
],
responsive: true
});
}
};

TableManageButtons = function() {
"use strict";
return {
init: function() {
handleDataTableButtons();
}
};
}();

$('#datatable').dataTable();

$('#datatable-keytable').DataTable({
keys: true
});

$('#datatable-responsive').DataTable();

$('#datatable-scroller').DataTable({
ajax: "js/datatables/json/scroller-demo.json",
deferRender: true,
scrollY: 380,
scrollCollapse: true,
scroller: true
});

$('#datatable-fixed-header').DataTable({
fixedHeader: true
});
var $datatable = $('#datatable-checkbox');

$datatable.dataTable({
'order': [[ 1, 'asc' ]],
'columnDefs': [
{ orderable: false, targets: [0] }
]
});
$datatable.on('draw.dt', function() {
$('input').iCheck({
checkboxClass: 'icheckbox_flat-green'
});
});

TableManageButtons.init();
});
</script>

Datapie.PHP
<?php
session_start();
include('dbcon.php');
$year=$_SESSION['year'];
$month=$_SESSION['month'];
$result = mysqli_query($con,"select branch_name,SUM(payment) as payment from payment
natural join branch
where YEAR(payment_date)='$year' and
MONTH(payment_date)='$month' group by branch_id,MONTH(payment_date) order by
MONTH(payment_date)");

$rows = array();
while($r = mysqli_fetch_array($result)) {
$row[0] = $r[0];
$row[1] = $r[1];
array_push($rows,$row);
}

print json_encode($rows, JSON_NUMERIC_CHECK);


mysqli_close($con);
?>

Data.PHP
<?php
session_start();
include('dbcon.php');
$year=date("Y");
$branch=$_SESSION['branch'];
$query = mysqli_query($con,"select *,SUM(payment) as
amount,DATE_FORMAT(payment_date,'%b') as month from payment where
YEAR(payment_date)='$year' and branch_id='$branch' group by MONTH(payment_date)")
or die(mysqli_error($con));

$category = array();
//$category['name'];

$series1 = array();
$series1['name'] = 'Monthly Sales';

while($r = mysqli_fetch_array($query)) {

//$count=$r['total'];
$category['name'][] =$r['month'];
$category['data'][] =$r['month'];
$series1['data'][] = $r['amount'];

}
$result = array();
array_push($result,$category);
array_push($result,$series1);
//array_push($result,$series2);

print json_encode($result, JSON_NUMERIC_CHECK);

mysqli_close($con);

?>

Dashboard.PHP

<?php include 'header.php';?>


<body class="nav-md">
<div class="container body">
<div class="main_container">
<div class="col-md-3 left_col">
<div class="left_col scroll-view">
<div class="navbar nav_title" style="border: 0;">
<a href="index.html" class="site_title"><i class="fa fa-paw"></i>
<span>Administrator</span></a>
</div>

<div class="clearfix"></div>

<!-- menu profile quick info -->


<div class="profile clearfix">
<div class="profile_pic">
<img src="images/img.jpg" alt="..." class="img-circle profile_img">
</div>
<div class="profile_info">
<span>Welcome</span>
<h2><?php echo $user_username;?></h2>
</div>
</div>
<!-- /menu profile quick info -->

<br />

<!-- sidebar menu -->


<?php include 'sidebar.php';?>
<!-- /sidebar menu -->

<!-- /menu footer buttons -->


<?php include 'sidebar2.php';?>
<!-- /menu footer buttons -->
</div>
</div>

<!-- top navigation -->


<?php include 'top_nav.php';?>
<!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<!-- top tiles -->
<div class="row tile_count">
<div class="col-md-2 col-sm-4 col-xs-6 tile_stats_count">
<span class="count_top"><i class="fa fa-user"></i> Total Users</span>
<div class="count">2500</div>
<span class="count_bottom"><i class="green">4% </i> From last Week</span>
</div>
<div class="col-md-2 col-sm-4 col-xs-6 tile_stats_count">
<span class="count_top"><i class="fa fa-clock-o"></i> Average Time</span>
<div class="count">123.50</div>
<span class="count_bottom"><i class="green"><i class="fa fa-sort-asc"></i>3%
</i> From last Week</span>
</div>
<div class="col-md-2 col-sm-4 col-xs-6 tile_stats_count">
<span class="count_top"><i class="fa fa-user"></i> Total Males</span>
<div class="count green">2,500</div>
<span class="count_bottom"><i class="green"><i class="fa fa-sort-asc"></i>34%
</i> From last Week</span>
</div>
<div class="col-md-2 col-sm-4 col-xs-6 tile_stats_count">
<span class="count_top"><i class="fa fa-user"></i> Total Females</span>
<div class="count">4,567</div>
<span class="count_bottom"><i class="red"><i class="fa fa-sort-desc"></i>12%
</i> From last Week</span>
</div>
<div class="col-md-2 col-sm-4 col-xs-6 tile_stats_count">
<span class="count_top"><i class="fa fa-user"></i> Total Collections</span>
<div class="count">2,315</div>
<span class="count_bottom"><i class="green"><i class="fa fa-sort-asc"></i>34%
</i> From last Week</span>
</div>
<div class="col-md-2 col-sm-4 col-xs-6 tile_stats_count">
<span class="count_top"><i class="fa fa-user"></i> Total Connections</span>
<div class="count">7,325</div>
<span class="count_bottom"><i class="green"><i class="fa fa-sort-asc"></i>34%
</i> From last Week</span>
</div>
</div>
<!-- /top tiles -->

<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">
<div class="dashboard_graph">
<div class="row x_title">
<div class="col-md-6">
<h3>Network Activities <small>Graph title sub-title</small></h3>
</div>
<div class="col-md-6">
<div id="reportrange" class="pull-right" style="background: #fff; cursor:
pointer; padding: 5px 10px; border: 1px solid #ccc">
<i class="glyphicon glyphicon-calendar fa fa-calendar"></i>
<span>December 30, 2014 - January 28, 2015</span> <b class="caret"></b>
</div>
</div>
</div>

<div class="col-md-9 col-sm-9 col-xs-12">


<div id="placeholder33" style="height: 260px; display: none" class="demo-
placeholder"></div>
<div style="width: 100%;">
<div id="canvas_dahs" class="demo-placeholder" style="width: 100%;
height:270px;"></div>
</div>
</div>
<div class="col-md-3 col-sm-3 col-xs-12 bg-white">
<div class="x_title">
<h2>Top Campaign Performance</h2>
<div class="clearfix"></div>
</div>

<div class="col-md-12 col-sm-12 col-xs-6">


<div>
<p>Facebook Campaign</p>
<div class="">
<div class="progress progress_sm" style="width: 76%;">
<div class="progress-bar bg-green" role="progressbar" data-
transitiongoal="80"></div>
</div>
</div>
</div>
<div>
<p>Twitter Campaign</p>
<div class="">
<div class="progress progress_sm" style="width: 76%;">
<div class="progress-bar bg-green" role="progressbar" data-
transitiongoal="60"></div>
</div>
</div>
</div>
</div>
<div class="col-md-12 col-sm-12 col-xs-6">
<div>
<p>Conventional Media</p>
<div class="">
<div class="progress progress_sm" style="width: 76%;">
<div class="progress-bar bg-green" role="progressbar" data-
transitiongoal="40"></div>
</div>
</div>
</div>
<div>
<p>Bill boards</p>
<div class="">
<div class="progress progress_sm" style="width: 76%;">
<div class="progress-bar bg-green" role="progressbar" data-
transitiongoal="50"></div>
</div>
</div>
</div>
</div>

</div>

<div class="clearfix"></div>
</div>
</div>

</div>
<br />

<div class="row">

<div class="col-md-4 col-sm-4 col-xs-12">


<div class="x_panel tile fixed_height_320">
<div class="x_title">
<h2>App Versions</h2>
<ul class="nav navbar-right panel_toolbox">
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button"
aria-expanded="false"><i class="fa fa-wrench"></i></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Settings 1</a>
</li>
<li><a href="#">Settings 2</a>
</li>
</ul>
</li>
<li><a class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<h4>App Usage across versions</h4>
<div class="widget_summary">
<div class="w_left w_25">
<span>0.1.5.2</span>
</div>
<div class="w_center w_55">
<div class="progress">
<div class="progress-bar bg-green" role="progressbar" aria-valuenow="60"
aria-valuemin="0" aria-valuemax="100" style="width: 66%;">
<span class="sr-only">60% Complete</span>
</div>
</div>
</div>
<div class="w_right w_20">
<span>123k</span>
</div>
<div class="clearfix"></div>
</div>

<div class="widget_summary">
<div class="w_left w_25">
<span>0.1.5.3</span>
</div>
<div class="w_center w_55">
<div class="progress">
<div class="progress-bar bg-green" role="progressbar" aria-valuenow="60"
aria-valuemin="0" aria-valuemax="100" style="width: 45%;">
<span class="sr-only">60% Complete</span>
</div>
</div>
</div>
<div class="w_right w_20">
<span>53k</span>
</div>
<div class="clearfix"></div>
</div>
<div class="widget_summary">
<div class="w_left w_25">
<span>0.1.5.4</span>
</div>
<div class="w_center w_55">
<div class="progress">
<div class="progress-bar bg-green" role="progressbar" aria-valuenow="60"
aria-valuemin="0" aria-valuemax="100" style="width: 25%;">
<span class="sr-only">60% Complete</span>
</div>
</div>
</div>
<div class="w_right w_20">
<span>23k</span>
</div>
<div class="clearfix"></div>
</div>
<div class="widget_summary">
<div class="w_left w_25">
<span>0.1.5.5</span>
</div>
<div class="w_center w_55">
<div class="progress">
<div class="progress-bar bg-green" role="progressbar" aria-valuenow="60"
aria-valuemin="0" aria-valuemax="100" style="width: 5%;">
<span class="sr-only">60% Complete</span>
</div>
</div>
</div>
<div class="w_right w_20">
<span>3k</span>
</div>
<div class="clearfix"></div>
</div>
<div class="widget_summary">
<div class="w_left w_25">
<span>0.1.5.6</span>
</div>
<div class="w_center w_55">
<div class="progress">
<div class="progress-bar bg-green" role="progressbar" aria-valuenow="60"
aria-valuemin="0" aria-valuemax="100" style="width: 2%;">
<span class="sr-only">60% Complete</span>
</div>
</div>
</div>
<div class="w_right w_20">
<span>1k</span>
</div>
<div class="clearfix"></div>
</div>

</div>
</div>
</div>

<div class="col-md-4 col-sm-4 col-xs-12">


<div class="x_panel tile fixed_height_320 overflow_hidden">
<div class="x_title">
<h2>Device Usage</h2>
<ul class="nav navbar-right panel_toolbox">
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button"
aria-expanded="false"><i class="fa fa-wrench"></i></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Settings 1</a>
</li>
<li><a href="#">Settings 2</a>
</li>
</ul>
</li>
<li><a class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<table class="" style="width:100%">
<tr>
<th style="width:37%;">
<p>Top 5</p>
</th>
<th>
<div class="col-lg-7 col-md-7 col-sm-7 col-xs-7">
<p class="">Device</p>
</div>
<div class="col-lg-5 col-md-5 col-sm-5 col-xs-5">
<p class="">Progress</p>
</div>
</th>
</tr>
<tr>
<td>
<canvas id="canvas1" height="140" width="140" style="margin: 15px 10px
10px 0"></canvas>
</td>
<td>
<table class="tile_info">
<tr>
<td>
<p><i class="fa fa-square blue"></i>IOS </p>
</td>
<td>30%</td>
</tr>
<tr>
<td>
<p><i class="fa fa-square green"></i>Android </p>
</td>
<td>10%</td>
</tr>
<tr>
<td>
<p><i class="fa fa-square purple"></i>Blackberry </p>
</td>
<td>20%</td>
</tr>
<tr>
<td>
<p><i class="fa fa-square aero"></i>Symbian </p>
</td>
<td>15%</td>
</tr>
<tr>
<td>
<p><i class="fa fa-square red"></i>Others </p>
</td>
<td>30%</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</div>
</div>

<div class="col-md-4 col-sm-4 col-xs-12">


<div class="x_panel tile fixed_height_320">
<div class="x_title">
<h2>Quick Settings</h2>
<ul class="nav navbar-right panel_toolbox">
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button"
aria-expanded="false"><i class="fa fa-wrench"></i></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Settings 1</a>
</li>
<li><a href="#">Settings 2</a>
</li>
</ul>
</li>
<li><a class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<div class="dashboard-widget-content">
<ul class="quick-list">
<li><i class="fa fa-calendar-o"></i><a href="#">Settings</a>
</li>
<li><i class="fa fa-bars"></i><a href="#">Subscription</a>
</li>
<li><i class="fa fa-bar-chart"></i><a href="#">Auto Renewal</a> </li>
<li><i class="fa fa-line-chart"></i><a href="#">Achievements</a>
</li>
<li><i class="fa fa-bar-chart"></i><a href="#">Auto Renewal</a> </li>
<li><i class="fa fa-line-chart"></i><a href="#">Achievements</a>
</li>
<li><i class="fa fa-area-chart"></i><a href="#">Logout</a>
</li>
</ul>

<div class="sidebar-widget">
<h4>Profile Completion</h4>
<canvas width="150" height="80" id="foo" class="" style="width: 160px;
height: 100px;"></canvas>
<div class="goal-wrapper">
<span class="gauge-value pull-left">$</span>
<span id="gauge-text" class="gauge-value pull-left">3,200</span>
<span id="goal-text" class="goal-value pull-right">$5,000</span>
</div>
</div>
</div>
</div>
</div>
</div>

</div>

<div class="row">
<div class="col-md-4 col-sm-4 col-xs-12">
<div class="x_panel">
<div class="x_title">
<h2>Recent Activities <small>Sessions</small></h2>
<ul class="nav navbar-right panel_toolbox">
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button"
aria-expanded="false"><i class="fa fa-wrench"></i></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Settings 1</a>
</li>
<li><a href="#">Settings 2</a>
</li>
</ul>
</li>
<li><a class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<div class="dashboard-widget-content">

<ul class="list-unstyled timeline widget">


<li>
<div class="block">
<div class="block_content">
<h2 class="title">
<a>Who Needs Sundance When You’ve
Got&nbsp;Crowdfunding?</a>
</h2>
<div class="byline">
<span>13 hours ago</span> by <a>Jane Smith</a>
</div>
<p class="excerpt">Film festivals used to be do-or-die moments for movie
makers. They were where you met the producers that could fund your project, and if the buyers
liked your flick, they’d pay to Fast-forward and… <a>Read&nbsp;More</a>
</p>
</div>
</div>
</li>
<li>
<div class="block">
<div class="block_content">
<h2 class="title">
<a>Who Needs Sundance When You’ve
Got&nbsp;Crowdfunding?</a>
</h2>
<div class="byline">
<span>13 hours ago</span> by <a>Jane Smith</a>
</div>
<p class="excerpt">Film festivals used to be do-or-die moments for movie
makers. They were where you met the producers that could fund your project, and if the buyers
liked your flick, they’d pay to Fast-forward and… <a>Read&nbsp;More</a>
</p>
</div>
</div>
</li>
<li>
<div class="block">
<div class="block_content">
<h2 class="title">
<a>Who Needs Sundance When You’ve
Got&nbsp;Crowdfunding?</a>
</h2>
<div class="byline">
<span>13 hours ago</span> by <a>Jane Smith</a>
</div>
<p class="excerpt">Film festivals used to be do-or-die moments for movie
makers. They were where you met the producers that could fund your project, and if the buyers
liked your flick, they’d pay to Fast-forward and… <a>Read&nbsp;More</a>
</p>
</div>
</div>
</li>
<li>
<div class="block">
<div class="block_content">
<h2 class="title">
<a>Who Needs Sundance When You’ve
Got&nbsp;Crowdfunding?</a>
</h2>
<div class="byline">
<span>13 hours ago</span> by <a>Jane Smith</a>
</div>
<p class="excerpt">Film festivals used to be do-or-die moments for movie
makers. They were where you met the producers that could fund your project, and if the buyers
liked your flick, they’d pay to Fast-forward and… <a>Read&nbsp;More</a>
</p>
</div>
</div>
</li>
</ul>
</div>
</div>
</div>
</div>

<div class="col-md-8 col-sm-8 col-xs-12">

<div class="row">

<div class="col-md-12 col-sm-12 col-xs-12">


<div class="x_panel">
<div class="x_title">
<h2>Visitors location <small>geo-presentation</small></h2>
<ul class="nav navbar-right panel_toolbox">
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown"
role="button" aria-expanded="false"><i class="fa fa-wrench"></i></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Settings 1</a>
</li>
<li><a href="#">Settings 2</a>
</li>
</ul>
</li>
<li><a class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<div class="dashboard-widget-content">
<div class="col-md-4 hidden-small">
<h2 class="line_30">125.7k Views from 60 countries</h2>

<table class="countries_list">
<tbody>
<tr>
<td>United States</td>
<td class="fs15 fw700 text-right">33%</td>
</tr>
<tr>
<td>France</td>
<td class="fs15 fw700 text-right">27%</td>
</tr>
<tr>
<td>Germany</td>
<td class="fs15 fw700 text-right">16%</td>
</tr>
<tr>
<td>Spain</td>
<td class="fs15 fw700 text-right">11%</td>
</tr>
<tr>
<td>Britain</td>
<td class="fs15 fw700 text-right">10%</td>
</tr>
</tbody>
</table>
</div>
<div id="world-map-gdp" class="col-md-8 col-sm-12 col-xs-12"
style="height:230px;"></div>
</div>
</div>
</div>
</div>

</div>
<div class="row">

<!-- Start to do list -->


<div class="col-md-6 col-sm-6 col-xs-12">
<div class="x_panel">
<div class="x_title">
<h2>To Do List <small>Sample tasks</small></h2>
<ul class="nav navbar-right panel_toolbox">
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown"
role="button" aria-expanded="false"><i class="fa fa-wrench"></i></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Settings 1</a>
</li>
<li><a href="#">Settings 2</a>
</li>
</ul>
</li>
<li><a class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<div class="">
<ul class="to_do">
<li>
<p>
<input type="checkbox" class="flat"> Schedule meeting with new client
</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Create email address for new
intern</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Have IT fix the network printer</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Copy backups to offsite location</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Food truck fixie locavors
mcsweeney</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Food truck fixie locavors
mcsweeney</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Create email address for new
intern</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Have IT fix the network printer</p>
</li>
<li>
<p>
<input type="checkbox" class="flat"> Copy backups to offsite location</p>
</li>
</ul>
</div>
</div>
</div>
</div>
<!-- End to do list -->

<!-- start of weather widget -->


<div class="col-md-6 col-sm-6 col-xs-12">
<div class="x_panel">
<div class="x_title">
<h2>Daily active users <small>Sessions</small></h2>
<ul class="nav navbar-right panel_toolbox">
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
</li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown"
role="button" aria-expanded="false"><i class="fa fa-wrench"></i></a>
<ul class="dropdown-menu" role="menu">
<li><a href="#">Settings 1</a>
</li>
<li><a href="#">Settings 2</a>
</li>
</ul>
</li>
<li><a class="close-link"><i class="fa fa-close"></i></a>
</li>
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<div class="row">
<div class="col-sm-12">
<div class="temperature"><b>Monday</b>, 07:30 AM
<span>F</span>
<span><b>C</b></span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-4">
<div class="weather-icon">
<canvas height="84" width="84" id="partly-cloudy-day"></canvas>
</div>
</div>
<div class="col-sm-8">
<div class="weather-text">
<h2>Texas <br><i>Partly Cloudy Day</i></h2>
</div>
</div>
</div>
<div class="col-sm-12">
<div class="weather-text pull-right">
<h3 class="degrees">23</h3>
</div>
</div>

<div class="clearfix"></div>

<div class="row weather-days">


<div class="col-sm-2">
<div class="daily-weather">
<h2 class="day">Mon</h2>
<h3 class="degrees">25</h3>
<canvas id="clear-day" width="32" height="32"></canvas>
<h5>15 <i>km/h</i></h5>
</div>
</div>
<div class="col-sm-2">
<div class="daily-weather">
<h2 class="day">Tue</h2>
<h3 class="degrees">25</h3>
<canvas height="32" width="32" id="rain"></canvas>
<h5>12 <i>km/h</i></h5>
</div>
</div>
<div class="col-sm-2">
<div class="daily-weather">
<h2 class="day">Wed</h2>
<h3 class="degrees">27</h3>
<canvas height="32" width="32" id="snow"></canvas>
<h5>14 <i>km/h</i></h5>
</div>
</div>
<div class="col-sm-2">
<div class="daily-weather">
<h2 class="day">Thu</h2>
<h3 class="degrees">28</h3>
<canvas height="32" width="32" id="sleet"></canvas>
<h5>15 <i>km/h</i></h5>
</div>
</div>
<div class="col-sm-2">
<div class="daily-weather">
<h2 class="day">Fri</h2>
<h3 class="degrees">28</h3>
<canvas height="32" width="32" id="wind"></canvas>
<h5>11 <i>km/h</i></h5>
</div>
</div>
<div class="col-sm-2">
<div class="daily-weather">
<h2 class="day">Sat</h2>
<h3 class="degrees">26</h3>
<canvas height="32" width="32" id="cloudy"></canvas>
<h5>10 <i>km/h</i></h5>
</div>
</div>
<div class="clearfix"></div>
</div>
</div>
</div>

</div>
<!-- end of weather widget -->
</div>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Gentelella - Bootstrap Admin Template by <a
href="https://colorlib.com">Colorlib</a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'script.php'; ?>


<!-- /gauge.js -->
</body>
</html>

Branch.PHP

<?php include 'header.php';?>


<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?>
<!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">
<div class = "col-md-4 col-lg-4 col-xs-4">
<?php include 'add_branch_form.php';?>
</div>
<div class = "col-md-8 col-lg-8 col-xs-8">
<div class = "x-panel">
<table id="datatable" class="table table-striped
table-bordered">
<thead>
<tr>
<th>Name</th>
<th>Address</th>
<th>Contact</th>
<th>Skin</th>
<th>Action</th>

</tr>
</thead>
<tbody>
<?php
include 'dbcon.php';

$query1=mysqli_query($con,"select * from branch ORDER BY branch_id ASC")or


die(mysqli_error($con));
while
($row1=mysqli_fetch_array($query1)){

$id=$row1['branch_id'];

?>
<tr>
<td><?php echo
$row1['branch_name'];?></td>
<td><?php echo
$row1['branch_address'];?></td>
<td><?php echo
$row1['branch_contact'];?></td>
<td><?php echo
$row1['skin'];?></td>
<td>
<a
href="#update<?php echo $id;?>" class="btn btn-success btn-xs" data-toggle = "modal" data-
target="#update<?php echo $id;?>"><i class = "fa fa-pencil"></i> Edit</a>

</td>

</tr>
<?php include
'update_branch_modal.php';?>
<?php }?>
</tbody>

</table>
</div>
</div>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>

Application update.PHP
<?php session_start();
if(empty($_SESSION['id'])):
header('Location:../index.php');
endif;
include('../dist/includes/dbcon.php');
$id = $_POST['id'];
$status =$_POST['status'];

mysqli_query($con,"update customer set credit_status='$status' where


cust_id='$id'")or die(mysqli_error());

echo "<script type='text/javascript'>alert('Successfully updated application


status!');</script>";
echo "<script>document.location='application.php'</script>";

?>

Application.PHP

<?php include 'header.php';

$branch_id = isset($_GET['id']) ? $_GET['id'] : '';


?>
<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?> <!-- /top navigation -->

<!-- page content -->


<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">
<div class = "x-panel">
<table id="example1" class="table table-bordered table-striped">
<thead>
<tr>
<th>Last Name</th>
<th>First Name</th>
<th>Address</th>
<th>Contact #</th>
<th>Application Status</th>
<th>Action</th>
</tr>
</thead>
<tbody>
<?php
// $branch=$_SESSION['branch'];
$query=mysqli_query($con,"select * from customer where credit_status='pending'")or
die(mysqli_error());
$i=1;
while($row=mysqli_fetch_array($query)){
$cid=$row['cust_id'];
$ci=$row['ci_remarks'];
$payslip=$row['payslip']; if($payslip==1) $payslip1='checked';
$valid_id=$row['valid_id'];if($valid_id==1) $valid_id1='checked';
$cedula=$row['cedula'];if($cedula==1) $cedula1='checked';
$cert=$row['cert'];if($cert==1) $cert1='checked';
$income=$row['income'];if($income==1) $income1='checked';
?>
<tr>
<td><?php echo $row['cust_last'];?></td>
<td><?php echo $row['cust_first'];?></td>
<td><?php echo $row['cust_address'];?></td>
<td><?php echo $row['cust_contact'];?></td>
<td><?php echo $row['credit_status'];//if ($row['balance']==0)
//echo "<span class='label label-danger'>inactive</span>";
//else echo "<span class='label label-info'>active</span>";
?></td>
<td>

<a href="#updateordinance<?php echo $row['cust_id'];?>" data-


target="#updateordinance<?php echo $row['cust_id'];?>" data-toggle="modal" class="small-
box-footer"><i class="glyphicon glyphicon-edit text-orange"></i></a>
<a href="view_application.php?cid=<?php echo $row['cust_id'];?>" class="small-box-
footer"><i class="glyphicon glyphicon-eye-open text-primary"></i></a>
</td>
</tr>
<div id="updateordinance<?php echo $row['cust_id'];?>" class="modal fade in"
tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"
style="display: none;">
<div class="modal-dialog">
<div class="modal-content" style="height:auto">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">×</span></button>
<h4 class="modal-title">Application Status</h4>
</div>
<div class="modal-body">
<form class="form-horizontal" method="post" action="application_update.php"
enctype='multipart/form-data'>

<div class="form-group">
<label class="control-label col-lg-3" for="name">Application Status</label>
<div class="col-lg-9">
<input type="hidden" name="id" value="<?php echo $cid;?>">
<select class="form-control" id="id" name="status">
<option>Approved</option>
<option>Disapproved</option>
<option>Pending</option>
</select>
</div>
</div>

</div><br>
<div class="modal-footer">
<button type="submit" class="btn btn-primary">Save changes</button>
<button type="button" class="btn btn-default"
data-dismiss="modal">Close</button>
</div>
</form>
</div>

</div><!--end of modal-dialog-->
</div>
<!--end of modal-->

<?php $i++;}?>
</tbody>
<tfoot>
<tr>
<th>Customer Last Name</th>
<th>Customer First Name</th>
<th>Address</th>
<th>Contact #</th>
<th>Application Status</th>
<th>Action</th>
</tr>
</tfoot>
</table>
</div>
</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>

Ahira reports.PHP

<?php include 'header.php';?>


<body class="nav-md">
<div class="container body">
<div class="main_container">
<?php include 'main_sidebar.php';?>

<!-- top navigation -->


<?php include 'top_nav.php';?>
<!-- /top navigation -->
<!-- page content -->
<div class="right_col" role="main">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">

</div>
</div>
</div>
<!-- /page content -->

<!-- footer content -->


<footer>
<div class="pull-right">
Sales and Inventory System <a href="#"></a>
</div>
<div class="clearfix"></div>
</footer>
<!-- /footer content -->
</div>
</div>

<?php include 'datatable_script.php';?>


<!-- /gauge.js -->
</body>
</html>

Add user form.PHP


<div class="x_panel">
<div class="x_title">
<h2>Add User <i class = "fa fa-users"></i></h2>
<ul class="nav navbar-right panel_toolbox">
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<br />
<form class="form-horizontal form-label-left" action = "add_user.php" method =
"POST" enctype = "multipart/form-data">
<div class="form-group">
<label class="control-label col-md-3 col-sm-3 col-xs-3">Username</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" name = "username" required>
<span class="fa fa-key form-control-feedback right" aria-
hidden="true"required ></span>
</div>
</div>
<div class="form-group">
<label class="control-label col-md-3 col-sm-3 col-xs-3">Password</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="password" name = "password" class="form-control" required>
<span class="fa fa-key form-control-feedback right" aria-hidden="true"
required></span>
</div>
</div>
<div class="form-group">
<label class="control-label col-md-3 col-sm-3 col-xs-3" style = "font-
size:11px;">Full name</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" name = "name" required>
<span class="fa fa-user form-control-feedback right"
aria-hidden="true"></span>
</div>
</div>
<input type = "hidden" name = "status" value =
"active">
<div class="form-group">
<label class="col-md-3 col-sm-3 col-xs-3">Branch</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<select name = "branch_id" class = "form-control">
<?php
include 'dbcon.php';

$query1=mysqli_query($con,"select * from branch ORDER BY branch_id ASC")or


die(mysqli_error($con));
while
($row1=mysqli_fetch_array($query1)){

$id=$row1['branch_id'];
?>
<option value = "<?php echo
$row1['branch_id'];?>"><?php echo $row1['branch_name'];?></option>
<?php } ?>

</select>
<span class="fa form-control-feedback right" aria-hidden="true"></span>
</div>
</div>

<div class="ln_solid"></div>

<div class="form-group">
<div class="col-md-9 col-md-offset-3">

<button name = "" class="btn btn-block btn-success"><i class = "fa fa-


save"></i> Save</button>
</div>
</div>
</form>
</div>
</div>

Add user.PHP
<?php
include 'dbcon.php';
$username = $_POST['username'];
$password = $_POST['password'];
$name = $_POST['name'];
$status = $_POST['status'];
$branch_id = $_POST['branch_id'];

$pass1=md5($password);
$salt="a1Bz20ydqelm8m1wql";
$pass1=$salt.$pass1;

mysqli_query($con,"INSERT INTO user


(username,password,name,status,branch_id)
VALUES
('$username','$pass1','$name','$status', '$branch_id')")
or die(mysqli_error($con));
echo "<script type='text/javascript'>alert('Data Successfully
Saved!');</script>";
echo "<script>window.location='user.php'</script>";

?>

Add branch form.PHP


<div class="x_panel">
<div class="x_title">
<h2>Add Branch <i class = "fa fa-building"></i></h2>
<ul class="nav navbar-right panel_toolbox">
</ul>
<div class="clearfix"></div>
</div>
<div class="x_content">
<br />
<form class="form-horizontal form-label-left" action = "add_branch.php" method
= "POST" enctype = "multipart/form-data">
<div class="form-group">
<label class="control-label col-md-3 col-sm-3 col-xs-3">Name</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" name = "branch_name">
<span class="fa fa-building form-control-feedback right" aria-
hidden="true"required ></span>
</div>
</div>
<div class="form-group">
<label class="control-label col-md-3 col-sm-3 col-xs-3">Address</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<textarea style = "resize:none;" name = "branch_address" class="form-
control"></textarea>
<span class="fa fa-home form-control-feedback right" aria-hidden="true"
required></span>
</div>
</div>
<div class="form-group">
<label class="control-label col-md-3 col-sm-3 col-xs-3">Contact #</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<input type="text" class="form-control" name = "branch_contact" required>
<span class="fa fa-phone form-control-feedback right"
aria-hidden="true"></span>
</div>
</div>
<div class="form-group">
<label class="col-md-3 col-sm-3 col-xs-3">Skin Color</label>
<div class="col-md-9 col-sm-9 col-xs-9">
<select name = "skin" class = "form-control">
<option value = "" ></option>

<option value = "red">red</option>

<option value =
"purple">purple</option>
<option value = "black">black</option>

<option value = "blue">blue</option>

<option value = "green">green</option>

<option value =
"yellow">yellow</option>
</select>
<span class="fa form-control-feedback right" aria-hidden="true"></span>
</div>
</div>

<div class="ln_solid"></div>

<div class="form-group">
<div class="col-md-9 col-md-offset-3">

<button name = "" class="btn btn-block btn-success"><i class = "fa fa-


save"></i> Save</button>
</div>
</div>
</form>
</div>
</div>

Add branch.PHP
<?php
include 'dbcon.php';
$branch_name = $_POST['branch_name'];
$branch_address = $_POST['branch_address'];
$branch_contact = $_POST['branch_contact'];
$skin = $_POST['skin'];

mysqli_query($con,"INSERT INTO
branch(branch_name,branch_address,branch_contact,skin)

VALUES('$branch_name','$branch_address','$branch_contact','$skin')")or
die(mysqli_error($con));
echo "<script type='text/javascript'>alert('Data Successfully
Saved!');</script>";
echo "<script>window.location='branch.php'</script>";

?
APPENDIX H
CURRICULUM VITAE

Personal Information

Name: Regine S. Bantac

Age: 25

Gender: Female

Date of Birth: January 16, 1999

Status: Single

Citizenship: Filipino

Religion: Roman Catholic

Address: Nanga-nangan Tigbao Zamboanga Del Sur.

Father's Name: Faustino M. Bantac

Occupation: Farmer

Mother's Name: Merlinda S. Bantac

Occupation: Farmer

Educational Attainment School Name Year Graduated

Elementary Nanga - Nangan Elementary School 2012

High School Lison Valley National High School 2016

Senior High School Lison Valley National High School 2018

College Westprime Horizon Institute Inc. Present


CURRICULUM VITAE

Personal Information

Name: Ranya M. Mamangcao

Age: 25

Gender: Female

Date of Birth: December 23, 1998

Status: Single

Citizenship: Filipino

Religion: Islam

Address: Tukuran, Zamboanga Del Sur.

Father's Name: Luis A. Mamangca

Occupation: Deceased

Mother's Name: Salbaya M. Mamangcao

Occupation: House Wife

Educational Attainment School Name Year Graduated

Elementary Tukuran Central Elementary School 2012

High School Tukuran Technical Vocational High 2017


School

Senior High School Tukuran Technical Vocational High 2018


School

College Westprime Horizon Institute Inc. Present


CURRICULUM VITAE

Personal Information

Name: Sharlyn B. Panawan

Age: 22

Gender: Female

Date of Birth: October 25, 2001

Status: Single

Citizenship: Filipino

Religion: Alliance

Address: Carpoc, Lapuyan Zamboanga Del Sur.

Father's Name: Dante T. Panawan

Occupation: Farmer

Mother's Name: Norlita B. Panawan

Occupation: House Wife

Educational Attainment School Name Year Graduated

Elementary Carpoc Elementary School 2014

High School Carpoc National High School 2018

Senior High School Southeast Asian Institute - Pagadian 2020


City Campus

College Westprime Horizon Institute Inc. Present


CURRICULUM VITAE

Personal Information

Name: Jenefe B. Vente

Age: 24

Gender: Female

Date of Birth: Febraury 20, 2000

Status: Single

Citizenship: Filipino

Religion: Christian UCCP

Address: Midsalip, Zamboanga Del Sur.

Father's Name: Felipe L. Vente

Occupation: Farmer

Mother's Name: Nenita B. Vente

Occupation: House Wife

Educational Attainment School Name Year Graduated

Elementary Katipunan Midsalip Elementary 2012


School

High School Midsalip National High School 2017

Senior High School Midsalip National High School 2019

College Westprime Horizon Institute Inc. Present


CURRICULUM VITAE

Personal Information

Name: Rico N. Hermoso

Age: 24

Gender: Male

Date of Birth: April 9, 2000

Status: Single

Citizenship: Filipino

Religion: Roman Catholic

Address: Buenavista Pagadian city

Father's Name: Rosilito P. Hermoso

Occupation: Forman

Mother's Name: Madelyn N. Hermoso

Occupation: Nail Technician

Educational Attainment School Name Year Graduated

Elementary Buenavista Elementary School 2012

High School Norberta Guiller Memorial High 2018


School

Senior High School Westprime Horizon Institute Inc. 2020

College Westprime Horizon Institute Inc. Present


CURRICULUM VITAE

Personal Information

Name: Christian L. Dela Cerna

Age: 22

Gender: Male

Date of Birth: August 19, 2001

Status: Single

Citizenship: Filipino

Religion: Roman Catholic

Address: Picanan Kumalarang, Zamboanga Del Sur.

Father's Name: Rolando Dela Cerna

Occupation: Tricycle Driver

Mother's Name: Rowena Dela Cerna

Occupation: House Wife

Educational Attainment School Name Year Graduated

Elementary Picanan Elementary School 2014

High School Maestro Cornelio S.Minor National 2018


High School

Senior High School Maestro Cornelio S.Minor National 2019


High School

College Westprime Horizon Institute Inc. Present

You might also like