基于ASP.NET的家教系统的设计与实现

目 录

摘 要 I
Abstract II
第一章 绪论 - 1 -
1.1研究背景及意义 - 1 -
1.2系统主要内容 - 1 -
1.3论文组织结构 - 2 -
第二章 技术相关简介 - 3 -
2.1管理信息系统的开发过程 - 3 -
2.2 B/S 开发模式 - 3 -
2.3 C#程序设计语言 - 4 -
2.4 ASP.NET 技术 - 5 -
2.5 Microsoft Visual Studio 2013 - 5 -
2.6 Microsoft SQL Server 2008R2数据库 - 6 -
第三章 系统分析 - 7 -
3.1系统的可行性分析 - 7 -
3.2系统功能需求分析 - 7 -
3.2.1系统用户角色说明 - 7 -
3.2.2系统功能需求说明 - 7 -
第四章 系统设计 - 10 -
4.1系统设计概述 - 10 -
4.2 系统主要类图及说明 - 10 -
4.3系统功能设计 - 11 -
4.3.1系统主要功能设计 - 11 -
4.3.2系统建模设计 - 12 -
4.4数据库设计 - 15 -
4.4.1 概念设计 - 15 -
4.3.2 逻辑设计 - 15 -
4.4.3 物理设计 - 15 -
第五章 系统实现 - 20 -
5.1网站主页 - 20 -
5.2 登录注册功能的实现 - 21 -
5.3用户中心功能的实现 - 22 -
5.4搜索信息功能的实现 - 25 -
5.5新闻资讯信息功能的实现 - 27 -
5.6家教推荐功能的实现 - 27 -
5.7在线贴吧功能的实现 - 28 -
5.8后台管理功能的实现 - 28 -
5.8.1 后台管理员登录功能的实现 - 29 -
5.8.2 用户信息管理功能的实现 - 30 -
5.8.3 需求信息管理功能的实现 - 30 -
5.8.4 新闻资讯管理功能的实现 - 31 -
5.8.5 贴吧信息管理功能的实现 - 31 -
第六章 系统测试 - 33 -
6.1 测试目的 - 33 -
6.2 测试过程 - 33 -
6.3 测试结果 - 34 -
结束语 - 35 -
致 谢 - 36 -
参考文献 - 37 -
第五章 系统实现
家教信息管理系统的使用简单易懂,用户连上网络就随时可以登录使用系统。本章主要介绍了系统主要功能的实现。
5.1网站主页
家教信息管理系统的首页是网站的第一个页面,首页界面分为3小块。其中,主菜单栏是用position的属性定义在顶端,主菜单分布着网站的功能链接,包括:教员信息、学生信息、需求信息、新闻资讯、家教推荐、在线贴吧、用户中心七个功能区。网站首页顶端是网站的大图轮播。左下界面分为两部分,分别是用户注册登录区和信息搜索区。右下界面是功能模块的信息显示区。网站首页底端部分有相关网站的链接,也更便于各位用户寻求更好的信息帮助学习。

<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" Title="Untitled Page" %>

<%@ Register Src="Search.ascx" TagName="Search" TagPrefix="uc1" %>
<%@ Register Src="userlogin.ascx" TagName="userlogin" TagPrefix="uc4" %>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <table cellpadding="0" cellspacing="0" style="width: 100%;">
        <tr>
            <td colspan="3" style="height: 5px;background-color: rgb(250,250,250)"></td>
        </tr>
        <tr>
            <td class="shouye" rowspan="3" valign="top" style="width: 233px" >
                <table border="0" cellpadding="0" cellspacing="0" style="width: 100%;">
                    <tr>
                        <td height="32" style="background: -webkit-linear-gradient(top,#96b4fa,#96c4f6); color: white; background-repeat: no-repeat; background-size: 100% 100%; font-size: medium" align="center">&nbsp;
                             用户中心</td>
                    </tr>
                    <tr>
                        <td height="120"
                            width="225" class="mytb" valign="top">
                            <uc4:userlogin ID="userlogin1" runat="server" />
                        </td>
                    </tr>
                    <tr>
                        <td style="background: -webkit-linear-gradient(top,#96b4fa,#96c4f6); color: white; background-repeat: no-repeat; background-size: 100% 100%; font-size: medium; height: 33px" align="center">
                            搜索信息</td>
                    </tr>
                    <tr>
                        <td class="mytb" valign="top">
                            <uc1:Search ID="Search1" runat="server" />

                        </td>
                    </tr>
                </table>
            </td>
            <td class="style2"></td>
            <td rowspan="3" valign="top" style="background-color: rgb(250,250,250)">
                <table style="width: 100%;">
                    <tr>
                        <td style="height: 30px; background: #eee9e9/*#fafafa*/ /*-webkit-linear-gradient(top,#96c4f6,#fafafa)*/; color: #618ffa; font-size: medium; text-align: center">
                            最新需求信息
                            <%--<asp:Image ID="Image11" runat="server" ImageUrl="~/images/theme_top.gif"
                                Width="701px" />--%>
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left;" valign="top" align="left">
                            <asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False"
                                CellPadding="4" EmptyDataText="暂无信息"
                                PageSize="13" Width="716px" EnableModelValidation="True" ForeColor="#333333" GridLines="None" Height="152px">
                                <AlternatingRowStyle BackColor="White" />
                                <Columns>
                                    <asp:TemplateField>
                                        <ItemTemplate>
                                            <asp:Image ID="Image12" runat="server" ImageUrl="~/images/to.gif" />
                                        </ItemTemplate>
                                        <ItemStyle Width="2px" />
                                    </asp:TemplateField>
                                    <asp:HyperLinkField DataNavigateUrlFields="id" DataNavigateUrlFormatString="ShowXQ.aspx?id={0}"
                                        DataTextField="UserName" HeaderText="发布人">
                                        <HeaderStyle Height="30px" Width="60px" />
                                        <ItemStyle Height="30px" Width="60px" />
                                    </asp:HyperLinkField>
                                    <asp:BoundField DataField="KeMu" HeaderText="科目">
                                        <HeaderStyle Height="30px" Width="60px" />
                                        <ItemStyle Height="30px" Width="60px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="Sex" HeaderText="性别要求">
                                        <HeaderStyle Height="30px" Width="70px" />
                                        <ItemStyle Height="30px" Width="70px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="FeiYong" HeaderText="费用">
                                        <HeaderStyle Height="30px" Width="60px" />
                                        <ItemStyle Height="30px" Width="60px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="DiDian" HeaderText="地点">
                                        <HeaderStyle Height="30px" Width="60px" />
                                        <ItemStyle Height="30px" Width="60px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="xqtime" HeaderText="上课时间">
                                        <HeaderStyle Height="30px" Width="80px" />
                                        <ItemStyle Height="30px" Width="80px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="AddTime" HeaderText="发布时间">
                                        <HeaderStyle Height="30px" Width="80px" />
                                        <ItemStyle Height="30px" Width="80px" />
                                    </asp:BoundField>
                                </Columns>
                                <EditRowStyle BackColor="#2461BF" />
                                <FooterStyle BackColor="#507CD1" Font-Size="Small" Font-Bold="True" ForeColor="White" />
                                <HeaderStyle BackColor="#96b4fa" Font-Bold="True" Font-Size="Medium" ForeColor="white" />
                                <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
                                <RowStyle BackColor="#EFF3FB" />
                                <SelectedRowStyle BackColor="#D1DDF1" ForeColor="#333333" Font-Bold="True" />
                            </asp:GridView>

                        </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Image ID="Image2" Height="2px" runat="server" ImageUrl="~/images/111.png" Width="716px" />
                        </td>
                    </tr>
                </table>
                <table style="width: 100%;">
                    <tr>
                        <td style="height: 30px; width: auto; background: #eee9e9/*#fafafa*/ /*-webkit-linear-gradient(top,#96c4f6,#fafafa)*/; color: #618ffa; font-size: medium; text-align: center">最新教员信息
                            <%--<asp:Image ID="Image11" runat="server" ImageUrl="~/images/theme_top.gif"
                                Width="701px" />--%>
                        </td>
                    </tr>
                        <tr>
                        <td>
                            <table id="Table7" width="716" border="0" cellpadding="0" cellspacing="0" style="height: 220px">
                                <tr>
                                    <td>
                                        <%--runat="server"把标签变为服务器控件,没加上runat="server",在后台将不能直接对此控件进行操作,RepeatColumns 属性用于获取或设置当显示单选按钮列表时所用的列数--%>
                                        <asp:DataList ID="DataList1" runat="server" Height="100%" RepeatColumns="5" Width="100%">
                                            <ItemTemplate>
                                                <table align="center" border="0" bordercolor="#00FFFF" cellpadding="3" cellspacing="1"
                                                    style="border-collapse: collapse" width="120">
                                                    <%--border-collapse:边框会合并为一个单一的边框--%>
                                                    <tr>
                                                        <td align="center" height="140">
                                                            <a href='ShowJY.aspx?id=<%#DataBinder.Eval(Container.DataItem, "t_id") %>'>
                                                                <asp:Image ID="Image1" runat="server" Height="100%" ImageUrl='<%# Eval("ImageUrl") %>'
                                                                    Width="116" /></a></td>
                                                    </tr>
                                                    <tr>
                                                        <td align="center">
                                                            <asp:Label ID="Label1" runat="server" Text='<%# Eval("realname") %>'></asp:Label></td>
                                                    </tr>
                                                </table>
                                            </ItemTemplate>
                                        </asp:DataList></td>
                                </tr>
                                <tr>
                                    <td>
                                        <asp:Image ID="Image11" Height="2px" runat="server" ImageUrl="~/images/111.png" Width="716px" />
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                    <tr>
                        <td style="height: 30px; width: auto; background: #eee9e9; color: #618ffa; font-size: medium; text-align: center">
                           最新资讯

                        </td>
                    </tr>
                 
                    <tr>
                        <td style="text-align: left;" valign="top" align="left"> 
                            <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
                                CellPadding="4" EmptyDataText="暂无信息"
                                PageSize="13" Width="716px" EnableModelValidation="True" ForeColor="#333333" GridLines="None" Height="16px">
                                <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                                <Columns>
                                    <asp:TemplateField>
                                        <ItemTemplate>
                                            <asp:Image ID="Image12" runat="server" ImageUrl="~/images/to.gif" />
                                        </ItemTemplate>
                                        <ItemStyle Width="2px" />
                                    </asp:TemplateField>
                                   <%-- <asp:HyperLinkField DataNavigateUrlFields="id" DataNavigateUrlFormatString="NewsContent.aspx?id={0}"
                                        DataTextField="Type" HeaderText="新闻类型">
                                        <HeaderStyle Height="30px" Width="100px" />
                                        <ItemStyle Height="30px" Width="100px" />
                                    </asp:HyperLinkField>
                                    <asp:BoundField DataField="Sex" HeaderText="性别">
                                        <HeaderStyle Height="30px" Width="40px" />
                                        <ItemStyle Height="30px" Width="40px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="phone" HeaderText="联系电话">
                                        <HeaderStyle Height="30px" Width="70px" />
                                        <ItemStyle Height="30px" Width="70px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="age" HeaderText="年龄">
                                        <HeaderStyle Height="30px" Width="40px" />
                                        <ItemStyle Height="30px" Width="40px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="email" HeaderText="电子邮件">
                                        <HeaderStyle Height="30px" Width="80px" />
                                        <ItemStyle Height="30px" Width="80px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="Istime" HeaderText="辅导时间">
                                        <HeaderStyle Height="30px" Width="90px" />
                                        <ItemStyle Height="30px" Width="90px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="address" HeaderText="所在地">
                                        <HeaderStyle Height="30px" Width="50px" />
                                        <ItemStyle Height="30px" Width="50px" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="school" HeaderText="学校">
                                        <HeaderStyle Height="30px" Width="50px" />
                                        <ItemStyle Height="30px" Width="50px" />
                                    </asp:BoundField>--%>
                                    <asp:TemplateField>
                                    <ItemTemplate>
                                     [ <asp:HyperLink ID="HyperLink2" runat="server" NavigateUrl='<%# "~/NewsList.aspx?id=" + Eval("id") %>'
                                            Text='<%# Eval("Type") %>'></asp:HyperLink> ] 
                                        <asp:HyperLink ID="Title" runat="server" NavigateUrl='<%# "~/NewsContent.aspx?ID=" + Eval("id") %>'
                                            Text='<%# Eval("title") %>'></asp:HyperLink>
                                        <span class="cccc">发布时间:
                                            <asp:Label ID="Time" runat="server" Text='<%# Eval("addtime") %>'></asp:Label></span>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                </Columns>
                                <EditRowStyle BackColor="#2461BF" />
                                <FooterStyle BackColor="#507CD1" Font-Size="Small" Font-Bold="True" ForeColor="White" />
                                <HeaderStyle BackColor="#96b4fa" Font-Bold="True" Font-Size="Medium" ForeColor="white" />
                                <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
                                <RowStyle BackColor="#EFF3FB" />
                                <SelectedRowStyle BackColor="#D1DDF1" ForeColor="#333333" Font-Bold="True" />
                            </asp:GridView>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>


    </table>
    <table cellpadding="0" cellspacing="0" style="width: 100%; height: 10px;">
        <tr>
            <td rowspan="3" valign="top" style="background-color: rgb(250,250,250)"></td>
        </tr>


    </table>
</asp:Content>


在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

猜你喜欢

转载自blog.csdn.net/sheziqiong/article/details/131752749