Design of the Management System of Book Center

Welcome to scan through WeChat to exchange and learn from each other!

QR code

Project source code: https://gitee.com/oklongmm/biye

Abstract
With the acceleration of the information age, all walks of life have adopted modern management methods. For the book center, it is of course also indispensable, because it can improve the management level, speed up the operation, and conduct various statistics quickly and accurately, thereby improving the competitiveness in the industry. The basic task of this system is to complete the basic management functions of the book center, including the purchase function of the book center, the sales function, the price query, the price management, the modification of the password, the addition of users and many other functions, which are of great practical value.
The development tool used by this system is Microsoft Visual Studio 2010, which is realized by C# technology, and the back-end database of the system is supported by Microsoft SQL Server 2005.


Keywords sales, database analysis and design, front-end interface, ER entity diagram, data table relationship diagram

Title  Supermarket Management System     
Abstract
    With the speeding up of the pace of the information age, the from all walks of life have adopted modern management means. It is also necessary for supermarkets, of course, because it can improve the level of management, speed up the operation, fast and accurate for various statistics, etc, so as to improve the competitiveness of the industry. This system to complete the basic task is to complete the supermarket's basic management functions, including functions of supermarket replenish onr's stock, sales function, price inquiry, price management, change passwords, add users and so on many functions, and great practical value.
    Development tools used in this system is a Microsoft Visual Studio 2010, through the c # technology to realize, the background database of the system is a Microsoft SQL Server 2005 to support.


Keyword  sell, database analysis and design, the front desk interface, E - R entity graph, data table diagram 

           


Table of Contents 
1 Introduction 1
2 Project Requirements Analysis 1
2.1 System Administrators' Functional Requirements 1
2.2 Sales Staff's Functional Requirements 1
2.3 Book Center Manager's Functional Requirements 1
2.4 The Feasibility of the Scheme 2
3 Project Conceptual Design 2
3.1 System Function Description 2
3.2 Functional module division 2
4 Project logical structure design 5
5 Coding 7
6 Project testing 12
6.1 Login interface 12
6.2 Main interface login 12
6.3 Commodity management 13
6.4 Book center member management 13
6.5 Sales entry 13
Acknowledgements 16
References 17

 
1 Introduction The
    book purchasing center management system is a system of great practical value, especially in the era when modern management is adopted in all walks of life. The basic function of this system is to help the staff of the book buying center handle daily basic work, including general purchase work, price management and other aspects of work, which can reduce the workload of staff and work costs. The main business is to handle purchases. Selling your management, the development goal is to achieve a powerful system to help the book center obtain greater benefits.
2 Project needs analysis The
    book center management system is a very practical system. Now almost all large book centers have their own management system. This system is widely used, so the needs of users are very large. The basic problem to be solved by this system is the entry and inquiry of goods, the establishment of prices, the investigation of prices, the inquiry and archiving of sales records, and the classification of goods during the entry process to facilitate and inquire.
2.1 System administrator's requirements for functions
2.1.1 User information management: manage the information of all logged-in users in the system, and assign user levels.
2.1.2 Member information management: you can browse, add, and search for member information.
2.1.3 Commodity information management: commodity information can be added.
2.1.4 Inquiry of commodity information: All inventory commodity information can be inquired.
2.1.5 Password modification: modify the login password.
2.2 Demands of sales staff for functions
2.2.1 Entry of sales status: browse and add information about sold products.
2.2.2 Password modification: modify the login password.
2.3 The function requirements of the book center manager
2.3.1 Member information management: you can browse, add, and search for member information.
2.3.2 Commodity information management: commodity information can be added.
2.3.3 Query of product information: You can query all inventory product information.
2.3.4 Sales status query: You can browse the information of sold products.
2.3.5 Password modification: modify the login password.

2.4 The feasibility of the plan
After consideration, the reform plan is feasible. It should be because this program basically meets the basic operating requirements of some current book shopping centers.
3 Project Conceptual Design
3.1 System Function Description
3.1.1 User Login
Since this system involves different user levels, different authority pages should be assigned to users who do not need to log in, and each user ID and level data should be recorded.
3.1.2 View user information After the
system administrator logs in to the system, the main interface system settings-user management, displays user code, user name, and user authority information.
3.1.3 Maintaining user information The
system administrator can add new user information, including user code, user name, and user authority. The administrator can also modify or delete a user's information record.
3.1.4 View product information
You can browse the list of item product inventory, including item product number, product name, price, inventory volume, inventory alarm number, planned purchase number, promotional price, promotional start date, and vendor address.
3.1.5 Purchase management The purchase
order can be generated by checking the inventory quantity, including the purchase number, product number, product unit price, total product amount, purchase date, etc.
3.1.6 Member Information Management of Book Center
You can add members and query member information, including member number, card number, name, phone number, address, consumption amount, and registration date.
3.1.7 Sales product entry management
You can view information such as the number of the sold product, the date of sale, the number of sales, the amount of sales, the payment method, the salesperson, and the membership card number.
3.1.8
Modification of password information You can modify the password information, fill in the old password, and then fill in the new updated password, or update the old password to a new password.
3.2 Functional module division
3.2.1 User login management The
user logs in to the system and divides the user's management authority.
3.2.2 User information management
View user information, add, modify, and delete item information.
3.2.3 Commodity information management
View commodity information, add, modify, and delete item information.
3.2.4 Member addition management
Add member information of the Book Center.
3.2.5 Sales status query management
    Add, modify, and query the status of sold commodities.
3.2.6 Password modification management
Modify the login password information.


3.3 Explanation of algorithm principle
3.3.1 Commodity information management
Commodity information is maintained and managed by system administrators. The commodity information management provides a list of commodity information, in which the record information of the commodity can be viewed, modified, and deleted. In the add product information interface, you can add a new product information record. The flow chart of the user information management function is as follows.


3.3.2 Member management
Member management provides the administrator's functions such as adding, modifying and querying book center members. The function flow chart is as follows.

3.3.3 Sales staff management
    of sold goods provides sales staff with a record function of sold goods, allowing sales staff to record the time, price, payment method and other information of the sold goods.
3.3.4 Password modification management
The main function of password modification management is to modify the password of the logged-in user. The user periodically changes the password to ensure the security of his login.
3.4 ER model diagram
3.4.1 Commodity ER entity diagram
The entity of a commodity has 9 attributes: product number, product name, inventory quantity, inventory alert, planned purchase quantity, sales permission, manufacturer number, sales unit price, and promotional price. The employee entity diagram is as follows Figure.

3.4.2 Member ER entity diagram The entity of the
book center member has seven attributes: membership number, card number, name, phone number, address, registration time, and consumption amount. The log ER entity diagram is as shown in the figure below.

4 Project logical structure design
4.1 Data table creation
4.1.1 Commodity information table
Merchandise information table (Merch) is used to store various information of commodities. The management of commodity information is an essential part of the book center management system. The specific table is as follows.
 
 

4.1.2 Member Information Form The
Member Information Form (MarketMember) is used to store the information of the members of the Book Center. The important part of the Book Center management is as follows.
 
 


4.1.3 Inventory Information Table The
inventory information table (Stock) is used to store the information of the goods in the warehouse, and the inventory goods are the main basis for purchasing. The specific table is as follows.
  

4.2 Data table relationship diagram The relationship diagram
of each data table in the book purchasing center management system is shown in the figure below.
 


5 Coding
5.1 Login background code
namespace Book center management information system
{     /// <summary>     /// Summary description of Login.     /// </summary>     public class Login: System.Windows.Forms.Form     {         private System.Windows.Forms.Button Exitlogin;         private System.Windows.Forms.Button loginbutt;         private System.Windows.Forms.GroupBox groupBox1;         private System.Windows.Forms.TextBox PwdTxt;         private System.Windows.Forms.Label label3;         private System.Windows.Forms.TextBox UserNameTxt;         private System.Windows.Forms.Label label2;         public static bool CanLogin = false; //Login can Pass the test












        

        public static string strUser = ""; //Record user name
        public static string strUserRole = ""; //Record user permissions    
        public static string strUserId = ""; //Record user number    
        private string connectionString = "workstation id=localhost;Integrated Security=SSPI;database=MarketMagSys";
        //Connection with the database
        private SqlConnection myConnection;
        private SqlDataAdapter da;
        
        private DataSet ds = new DataSet();
        private DataTable LogTable;
        private DataRow LogRow;

        private string StrSQL = "SELECT * from SyUser";
        /// <summary>
        /// Required designer variables.
        /// </summary>
        private System.ComponentModel.Container components = null;

        public Login()
        {             //             // Required for Windows Forms Designer support             //             InitializeComponent();



            //
            // TODO: Add any constructor code after InitializeComponent call
            //
            this.myConnection = new SqlConnection(connectionString);
            this.da = new SqlDataAdapter(this.StrSQL,this.myConnection);
            this.ds.Clear() ;
            this.da.Fill(ds,"SyUser");
            this.LogTable = ds.Tables[0];
            
        }

        /// <summary>
        /// Clean up all resources in use.
        /// </summary>
        protected override void Dispose( bool disposing)
        {             if( disposing)             {                 if(components != null)                 {                     components.Dispose();                 }             }             base.Dispose( disposing );         }








        #region The code generated by the Windows Forms designer
        /// <summary>
        /// The designer supports the required method-do not use the code editor to modify
        /// the content of this method.
        /// </summary>
        private void InitializeComponent()
        {             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Login));             this.Exitlogin = new System.Windows.Forms.Button();             this. loginbutt = new System.Windows.Forms.Button();             this.groupBox1 = new System.Windows.Forms.GroupBox();             this.PwdTxt = new System.Windows.Forms.TextBox();             this.label3 = new System. Windows.Forms.Label();






            this.UserNameTxt = new System.Windows.Forms.TextBox();
            this.label2 = new System.Windows.Forms.Label();
            this.groupBox1.SuspendLayout();
            this.SuspendLayout();
            // 
            // Exitlogin
            // 
            this.Exitlogin.BackColor = System.Drawing.Color.Transparent;
            this.Exitlogin.Location = new System.Drawing.Point(279, 252);
            this.Exitlogin.Name = "Exitlogin";
            this.Exitlogin.Size = new System.Drawing.Size(88, 24);
            this.Exitlogin.TabIndex = 12;
            this.Exitlogin.Text = "退出";
            this.Exitlogin.UseVisualStyleBackColor = false;
            this.Exitlogin.Click += new System.EventHandler(this.Exitlogin_Click);
            // 
            // loginbutt
            // 
            this.loginbutt.BackColor = System.Drawing.Color.Transparent;
            this.loginbutt.Location = new System.Drawing.Point(46, 252);
            this.loginbutt.Name = "loginbutt";
            this.loginbutt.Size = new System.Drawing.Size(88, 24);
            this.loginbutt.TabIndex = 11;
            this.loginbutt.Text = "登陆";
            this.loginbutt.UseVisualStyleBackColor = false;
            this.loginbutt.Click += new System.EventHandler(this.loginbutt_Click);
            // 
            // groupBox1
            // 
            this.groupBox1.BackColor = System.Drawing.Color.Transparent;
            this.groupBox1.Controls.Add(this.PwdTxt);
            this.groupBox1.Controls.Add(this.label3);
            this.groupBox1.Controls.Add(this.UserNameTxt);
            this.groupBox1.Controls.Add(this.label2);
            this.groupBox1.Location = new System.Drawing.Point(110, 96);
            this.groupBox1.Name = "groupBox1";
            this.groupBox1.Size = new System.Drawing.Size(208, 100);
            this.groupBox1.TabIndex = 10;
            this.groupBox1.TabStop = false;
            this.groupBox1.Text = "用户信息输入";
            // 
            // PwdTxt
            // 
            this.PwdTxt.Location = new System.Drawing.Point(88, 56);
            this.PwdTxt.Name = "PwdTxt";
            this.PwdTxt.PasswordChar = '*';
            this.PwdTxt.Size = new System.Drawing.Size(104, 21);
            this.PwdTxt.TabIndex = 4;
            // 
            // label3
            // 
            this.label3.Location = new System.Drawing.Point(8, 64);
            this.label3.Name = "label3";
            this.label3.Size = new System.Drawing.Size(72, 16);
            this.label3.TabIndex = 3;
            this.label3.Text = "*用户密码:";
            // 
            // UserNameTxt
            // 
            this.UserNameTxt.Location = new System.Drawing.Point(88, 32);
            this.UserNameTxt.Name = "UserNameTxt";
            this.UserNameTxt.Size = new System.Drawing.Size(104, 21);
            this.UserNameTxt.TabIndex = 2;
            // 
            // label2
            // 
            this.label2.Location = new System.Drawing.Point(8, 40);
            this.label2.Name = "label2";
            this.label2.Size = new System.Drawing.Size(72, 16);
            this.label2.TabIndex = 1;
            this.label2.Text = "*用户姓名:";
            // 
            // Login
            // 
            this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);
            this.BackColor = System.Drawing.Color.Cornsilk;
            this.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("$this.BackgroundImage")));
            this.ClientSize = new System.Drawing.Size(430, 372);
            this.Controls.Add(this.Exitlogin);
            this.Controls.Add(this.loginbutt);
            this.Controls.Add(this.groupBox1);
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
            this.MaximizeBox = false;
            this.Name = "Login";
            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
            this.Text = "Welcome to the Book Center Management System";
            this.Load += new System.EventHandler(this.Login_Load);
            this.groupBox1.ResumeLayout(false);
            this.groupBox1.PerformLayout();
            this.ResumeLayout( false);

        }
        #endregion

        private void loginbutt_Click(object sender, System.EventArgs e)
        {             for (int i=0;i<LogTable.Rows.Count;i++)             {                 this.LogRow = LogTable.Rows[i];                 //Only when the entered user name and                 Only when the password corresponds to the record in the database can it pass the verification if (LogRow[1].ToString().Trim()==this.UserNameTxt.Text.ToString().Trim() && LogRow[2].ToString( ).Trim()==this.PwdTxt.Text.ToString().Trim())                 {                                         CanLogin = true;                     strUser = LogRow[1].ToString().Trim();//Save the username                     strUserRole = LogRow[ 3].ToString().Trim();//Save user permissions                     strUserId=LogRow[0].ToString().Trim();//Save user permissions










                    this.Close();//Close the form
                    return;
                }
            }
            MessageBox.Show( "The user ID or password you entered is incorrect!");
            return;
        }

        private void Exitlogin_Click(object sender, System.EventArgs e)
        {
            CanLogin = false;
            this.Close();
        }

        private void Login_Load(object sender, EventArgs e)
        {

        }

        private void textBox1_TextChanged(object sender, EventArgs e)
        {

        }
    }
}


6 Project testing
6.1 Login interface
 
6.2 Main interface login
 
6.3 Commodity management
 
6.4 Book center membership management
 

6.5 Sales entry
 
6.6 User management
 
6.7 Password modification
 


in conclusion

The working time of this system is mainly focused on demand analysis, as far as possible to achieve the completeness and rationality of the table structure, but the actual situation is different. In continuous learning, with the accumulation of relevant technical knowledge, the understanding of the design It is also constantly changing. The most fundamental reason is the modification of the table structure, especially with the realization of views and stored procedures, constantly thinking about the problems that need to be solved in the system, and constantly discovering and solving problems, so It saves a lot of energy and time in the final design stage. Through this database course design, we have a more in-depth understanding of the database, and how to use the database and C# language to connect, when we encounter problems that we do not know, we must first check the textbooks and go online to solve them. Questions that can't be dropped, ask teachers and classmates. In the process of constantly encountering and solving problems, we have learned a lot of knowledge. For now, we can't apply the database freely, so we should continue to work hard to learn the relevant knowledge of the database.
 

Guess you like

Origin blog.csdn.net/weixin_55459367/article/details/113924246