⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 departmentform.aspx

📁 ASP.NET 2.0 C# +MYSQL 家电维修管理系统 功能还算齐全
💻 ASPX
字号:
<%--文件名:DepartmentForm.aspx--%>
<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="DepartmentForm.aspx.cs" Inherits="BaseManage_DepartmentForm" Title="当前位置:基本管理->部门信息管理" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <table style="width: 558px; height: 1px">
        <tr>
            <td align="left" style="font-size: 0.8em; width: 554px; font-family: 宋体; height: 17px;
                background-color: lightseagreen">
                &nbsp;部门名称:<asp:TextBox ID="TextBox1" runat="server" Width="108px"></asp:TextBox>
                负责人员:<asp:TextBox ID="TextBox2" runat="server" Width="84px"></asp:TextBox>
                联系电话:<asp:TextBox ID="TextBox3" runat="server" Width="125px"></asp:TextBox><br />
                &nbsp;工作地址:<asp:TextBox ID="TextBox4" runat="server" Width="108px"></asp:TextBox>
                主要职责:<asp:TextBox ID="TextBox5" runat="server" Width="288px">负责特约商家的保修服务</asp:TextBox><br />
                &nbsp;额定人数:<asp:TextBox ID="TextBox6" runat="server" Width="34px">1</asp:TextBox>
                补充说明:<asp:TextBox ID="TextBox7" runat="server" Width="203px">暂无</asp:TextBox>
                <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="新增" Width="70px" />&nbsp;<asp:Button
                    ID="Button2" runat="server" OnClick="Button2_Click" Text="修改" Width="70px" /></td>
        </tr>
        <tr>
            <td style="overflow: auto; width: 554px; height: 103px; background-color: gainsboro">
                <asp:Panel ID="Panel1" runat="server" Height="250px" ScrollBars="Auto" Width="555px">
                    <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:MyServiceDBConnectionString %>"
                        DeleteCommand="DELETE FROM [部门信息] WHERE [部门名称] = @部门名称" InsertCommand="INSERT INTO [部门信息] ([部门名称], [负责人员], [联系电话], [工作地址], [主要职责], [额定人数], [补充说明]) VALUES (@部门名称, @负责人员, @联系电话, @工作地址, @主要职责, @额定人数, @补充说明)"
                        SelectCommand="SELECT * FROM [部门信息]" UpdateCommand="UPDATE [部门信息] SET [负责人员] = @负责人员, [联系电话] = @联系电话, [工作地址] = @工作地址, [主要职责] = @主要职责, [额定人数] = @额定人数, [补充说明] = @补充说明 WHERE [部门名称] = @部门名称">
                        <DeleteParameters>
                            <asp:Parameter Name="部门名称" Type="String" />
                        </DeleteParameters>
                        <UpdateParameters>
                            <asp:ControlParameter ControlID="TextBox2" Name="负责人员" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox3" Name="联系电话" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox4" Name="工作地址" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox5" Name="主要职责" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox6" Name="额定人数" PropertyName="Text" Type="Int32" />
                            <asp:ControlParameter ControlID="TextBox7" Name="补充说明" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox1" Name="部门名称" PropertyName="Text" Type="String" />
                        </UpdateParameters>
                        <InsertParameters>
                            <asp:ControlParameter ControlID="TextBox1" Name="部门名称" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox2" Name="负责人员" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox3" Name="联系电话" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox4" Name="工作地址" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox5" Name="主要职责" PropertyName="Text" Type="String" />
                            <asp:ControlParameter ControlID="TextBox6" Name="额定人数" PropertyName="Text" Type="Int32" />
                            <asp:ControlParameter ControlID="TextBox7" Name="补充说明" PropertyName="Text" Type="String" />
                        </InsertParameters>
                    </asp:SqlDataSource>
                    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" BackColor="White"
                        BorderColor="White" BorderStyle="Ridge" BorderWidth="2px" CellPadding="3" CellSpacing="1"
                        DataKeyNames="部门名称" DataSourceID="SqlDataSource1" Font-Names="宋体" Font-Size="Small"
                        GridLines="None" OnRowCreated="GridView1_RowCreated" OnSelectedIndexChanged="GridView1_SelectedIndexChanged"
                        Width="1000px">
                        <FooterStyle BackColor="#C6C3C6" ForeColor="Black" />
                        <Columns>
                            <asp:CommandField ButtonType="Button" HeaderText="选择" ShowSelectButton="True" />
                            <asp:TemplateField HeaderText="删除" ShowHeader="False">
                                <ItemTemplate>
                                    <asp:Button ID="Button1" runat="server" CausesValidation="False" CommandName="Delete"
                                        Text="删除" />
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="部门名称" HeaderText="部门名称" ReadOnly="True" SortExpression="部门名称" />
                            <asp:BoundField DataField="负责人员" HeaderText="负责人员" SortExpression="负责人员" />
                            <asp:BoundField DataField="联系电话" HeaderText="联系电话" SortExpression="联系电话" />
                            <asp:BoundField DataField="工作地址" HeaderText="工作地址" SortExpression="工作地址" />
                            <asp:BoundField DataField="主要职责" HeaderText="主要职责" SortExpression="主要职责" />
                            <asp:BoundField DataField="额定人数" HeaderText="额定人数" SortExpression="额定人数" />
                            <asp:BoundField DataField="补充说明" HeaderText="补充说明" SortExpression="补充说明" />
                        </Columns>
                        <RowStyle BackColor="#DEDFDE" ForeColor="Black" />
                        <SelectedRowStyle BackColor="#9471DE" Font-Bold="True" ForeColor="White" />
                        <PagerStyle BackColor="#C6C3C6" ForeColor="Black" HorizontalAlign="Right" />
                        <HeaderStyle BackColor="Navy" Font-Bold="True" ForeColor="#E7E7FF" HorizontalAlign="Center" />
                    </asp:GridView>
                </asp:Panel>
            </td>
        </tr>
    </table>
</asp:Content>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -