Вы находитесь на странице: 1из 9

PROJECT REPORT ON

GYM MANAGEMENT SYSTEM USING SHELL SCRIPTING AND CASE


STATEMENTS

COURSE CODE- ECE 340

COURSE NAME - WORKSHOP ON EMBEDDED SYSTEMS

SUBMITTED BY-
PRACHYA SOURAV PANDA
REG-11607233
ROLL-40
ABSTRACT-
This work was centered on the design and implementation of a gym management system using
shell scripting in Linux. This project “Gym Management System” is solution fitness centres to
manage the customers in an easier and more convenient way. The administrator, is able to view
all the members of fitness centre as well as their details. The basic structure of the system as
follows. This project is a computer-based program and it manages the gym members, the
personnel and the inventory. This system also maintains the client details, to provide the
valuable reports regarding the progress of the gym member.

INTRODUCTION

Objectives of the project This Gym Management System shall enable the user to add members
to a gym and manage the fee payment of the gym user. It is a very simple interface developed
using .net. The user of the system shall be able to add a new gym member. The tool shall add
all the necessary details like name, admission date, contact details into the system. The Gym
Management System shall also monitor the timings for the member. It shall allow the user to
make fee payments. This tool shall hold all the details of gym members. It shall enable the user
to make payments monthly, quarterly or annually.

.
Code:
#! /bin/bash
record_file="GYMRecords.ldb"
temp_file=/tmp/ldb.$$
touch $temp_file;
chmod 644 $temp_file
trap 'rm -f $temp_file' EXIT

echo "__________________________________________________/n"
echo "**************Welcome to Fitness Edge Gym*************"
echo "__________________________________________________"
echo "Gym timing: 5.00AM to 10.00PM"

read -p "Enter the applicant's Name:" applicant_name


echo
read -p "Enter the regd. no of applicant:" regd_no
echo
read -p "Enter the age of applicant:" age
echo
read -p "Enter the weight of applicant:" weight
echo
read -p "Enter the Gender of applicant:" Gender
echo
read -p "Enter the Address of applicant:" address
echo
read -p "Enter the Application number of applicant:" application_no
echo

echo "***The details of applicant's given Below:***"


echo $applicant_name
echo $regd_no
echo $age
echo $weight
echo $Gender
echo $address
echo $application_no
echo
echo "----------------Time slot-------------------"
echo "1. The no. of gymmers in 5:00am-6:00am is 25"
echo "2. The no. of gymmers in 6:00am-7:00am is 20"
echo "3. The no. of gymmers in 7:00am-8:00am is 35"
echo "4. The no. of gymmers in 8:00am-9:00am is 35"
echo "5. The no. of gymmers in 5:00pm-6:00pm is 25"
echo "6. The no. of gymmers in 6:00pm-7:00pm is 45"
echo "7. The no. of gymmers in 7:00pm-8:00pm is 45"
echo "8. The no. of gymmers in 8:00pm-9:00pm is 15"
echo
echo "Enter the time slot of gymmer:"
read g_slot
echo $g_slot
fees= 0;

echo "______________________________________"
echo " Types of exercise "
echo "______________________________________"
echo "1. Strength"
echo "2. cardio"
echo "3. Strength+cardio"
echo "4. Strength+trainer"
echo "5. cardio+trainer"
echo "6. Strength+cardio+trainer"
echo "7. Strength+cardio+crossfit"
echo

echo "Choose the type of exercise"


read choice
case $choice in

1)
echo "You have entered the strength type of exercise"
echo "press y if yes or press n to go back in menu"
read option
if [ "$option" == 'y' ]
then
echo "The fees of this type is 400/month"
fees=`expr $fees + 400 `
echo $fees
else
echo "We are directing you to the previous menu"
fi
;;
2)
echo "You have entered the cardio type of exercise"
echo "press y if yes or press n to go back in menu"
read option
if [ "$option" == 'y' ]
then
echo "The fees of this type is 600/month"
fees=`expr $fees + 600 `
echo $fees
else
echo "We are directing you to the previous menu"
fi
;;
3)
echo "You have entered the strenth+cardio type of exercise"
echo "press y if yes or press n to go back in menu"
read option
if [ "$option" == 'y' ]
then
echo "The fees of this strength+cardio type is 800/month"
fees=`expr $fees + 800 `
echo $fees
else
echo "We are directing you to the previous menu"
fi
;;
4)
echo "You have entered the strength+trainer type of exercise"
echo "press y if yes or press n to go back in menu"
read option
if [ "$option" == 'y' ]
then
echo "The fees of this type is 1000/month"
fees=`expr $fees + 1000 `
echo $fees
else
echo "We are directing you to the previous menu"
fi
;;
5)
echo "You have entered the cardio+trainer type of exercise"
echo "press y if yes or press n to go back in menu"
read option
if [ "$option" == 'y' ]
then
echo "The fees of this type is 1200/month"
fees=`expr $fees + 1200 `
echo $fees
else
echo "We are directing you to the previous menu"
fi
;;
6)
echo "You have entered the strenth+cardio+trainer type of exercise"
echo "press y if yes or press n to go back in menu"
read option
if [ "$option" == 'y' ]
then
echo "The fees of this type is 1400/month"
fees=`expr $fees + 1400 `
echo $fees
else
echo "We are directing you to the previous menu"
fi
;;
7)
echo "You have entered the strenth+cardio+crossfit type of exercise"
echo "press y if yes or press n to go back in menu"
read option
if [ "$option" == 'y' ]
then
echo "The fees of this type is 1600/month"
fees=`expr $fees + 1600 `
echo $fees
else
echo "We are directing you to the previous menu"
fi
;;
*)
echo "You have not choosen any option. Please fil your choice"
return
esac

echo "what is your body goal?"


echo "1.lose weight"
echo "2.lose fat"
echo "3.gain weight"
echo "4.gain muscle"
echo
echo "select your body goal"
read b_goal
echo $b_goal
echo
diet_plan()
{
echo "---------------------------------------------"
echo " Diet plan "
echo "---------------------------------------------"
echo "1.Veg"
echo "2.Non-veg"
echo
echo "select the type of diet plan:"
read diet_plan
echo "You have choosen $diet_plan type"
case $diet_plan in
1)
echo "for confirm press y else n"
read ch
if [ "$ch" == 'y' ]
then
echo "Fees for $diet_plan diet is: 1500"
fees=`expr $fees + 1500 `
echo $fees
fi
;;
2)
echo "for confirm press y else n"
read ch
if [ "$ch" == 'y' ]
then
echo "Fees for $diet_plan diet is: 2500"
fees=`expr $fees + 2500 `
echo "total fees= $fees"
fi
;;
esac
}

echo

echo "Press yes for entering to diet plans"


read ch1
if [ "$ch1" == 'yes' ]
then
diet_plan
else
echo "Please fill any choice to proceed further"
fi
Result:
CONCLUSION
As the objective of the project was to calculate the total fees of a client by including all the
parameters such as body type desired, type of diet etc.

So, we can conclude that all the objectives of this project was attained and our designed system
is completely capable of determining the total cost a client need to spent to avail all the facilities
and our designed system is totally flexible as it can be used to determine all the types of factors
and calculate the total cost depending upon it.

Вам также может понравиться