📄 tsdj.cs
字号:
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
namespace 中小型酒店管理信息系统
{
/// <summary>
/// tsdj 的摘要说明。
/// </summary>
public class tsdj : System.Windows.Forms.Form
{
private System.Windows.Forms.Label label1;
private System.Windows.Forms.ComboBox comboBox1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox textBox1;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox textBox2;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.TextBox textBox3;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.TextBox textBox4;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.ComboBox comboBox2;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.TextBox textBox5;
private System.Windows.Forms.Label label8;
private System.Windows.Forms.TextBox textBox6;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.ImageList imageList1;
private System.Windows.Forms.ToolBar toolBar1;
private System.Windows.Forms.ToolBarButton tbarBtnSave;
private System.Windows.Forms.ToolBarButton tbarBtnDelete;
private System.Windows.Forms.TextBox textBox7;
private System.Windows.Forms.Label label10;
private System.Windows.Forms.Label label11;
private System.Windows.Forms.TextBox textBox8;
private System.Windows.Forms.TextBox textBox9;
private System.Windows.Forms.Label label12;
private System.Windows.Forms.TextBox textBox10;
private System.Windows.Forms.Label label13;
private System.Windows.Forms.TextBox textBox11;
private System.Windows.Forms.Label label14;
private System.Windows.Forms.TextBox textBox12;
private System.Windows.Forms.Label label15;
private System.Windows.Forms.DateTimePicker dateTimePicker1;
private System.Windows.Forms.Label label17;
private System.Windows.Forms.RichTextBox richTextBox1;
private System.Windows.Forms.Label label18;
private System.Windows.Forms.TextBox textBox14;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Label label19;
private System.Windows.Forms.TextBox textBox15;
private System.Windows.Forms.Label label20;
private System.Windows.Forms.TextBox textBox16;
private System.Windows.Forms.DataGrid dgrd_StockerData;
private System.ComponentModel.IContainer components;
private DataSet ds = new DataSet();
private DataSet ds1 = new DataSet();
private DataSet ds2 = new DataSet();
private LinkDataBase link = new LinkDataBase();
private LinkDataBase link1 = new LinkDataBase();
private System.Windows.Forms.Button button2;
private LinkDataBase link2 = new LinkDataBase();
public tsdj()
{
//
// Windows 窗体设计器支持所必需的
//
InitializeComponent();
//
// TODO: 在 InitializeComponent 调用后添加任何构造函数代码
//
DateTime dt = DateTime.Now;
string shijian = dt.Year.ToString()+"-"+dt.Month.ToString()+"-"+dt.Day.ToString();
string sendTableName = "jud_ts";
string sendStrSQL ="select pzhm as '凭证号码',xm as '姓名',fjh as '房间号',zsrq as '住宿日期',zssj as '住宿时间',sjsf as '实际宿费',jkfs as '结款方式',zk as '折扣',yssf as '应收总额',jezj as '金额总计',yj as '押金',zsts as '住宿天数',thsf as '退还宿费',jsf as '酒水费',dhf as '电话费',psf as '赔偿费',qtfy as '其它费用',tsrq as '退宿日期',tssj '退宿时间',bz'备注',czy as '操作员' from jud_ts where tsrq='"+shijian+"'";
ds1 = link1.SelectDataBase(sendStrSQL,sendTableName);
this.dgrd_StockerData.DataSource = ds1;
this.dgrd_StockerData.DataMember = "jud_ts";
}
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
protected override void Dispose( bool disposing )
{
if( disposing )
{
if(components != null)
{
components.Dispose();
}
}
base.Dispose( disposing );
}
#region Windows 窗体设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要使用代码编辑器修改
/// 此方法的内容。
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(tsdj));
this.label1 = new System.Windows.Forms.Label();
this.comboBox1 = new System.Windows.Forms.ComboBox();
this.label2 = new System.Windows.Forms.Label();
this.textBox1 = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label();
this.textBox2 = new System.Windows.Forms.TextBox();
this.label4 = new System.Windows.Forms.Label();
this.textBox3 = new System.Windows.Forms.TextBox();
this.label5 = new System.Windows.Forms.Label();
this.textBox4 = new System.Windows.Forms.TextBox();
this.label6 = new System.Windows.Forms.Label();
this.comboBox2 = new System.Windows.Forms.ComboBox();
this.label7 = new System.Windows.Forms.Label();
this.textBox5 = new System.Windows.Forms.TextBox();
this.label8 = new System.Windows.Forms.Label();
this.textBox6 = new System.Windows.Forms.TextBox();
this.label9 = new System.Windows.Forms.Label();
this.imageList1 = new System.Windows.Forms.ImageList(this.components);
this.toolBar1 = new System.Windows.Forms.ToolBar();
this.tbarBtnSave = new System.Windows.Forms.ToolBarButton();
this.tbarBtnDelete = new System.Windows.Forms.ToolBarButton();
this.textBox7 = new System.Windows.Forms.TextBox();
this.label10 = new System.Windows.Forms.Label();
this.label11 = new System.Windows.Forms.Label();
this.textBox8 = new System.Windows.Forms.TextBox();
this.textBox9 = new System.Windows.Forms.TextBox();
this.label12 = new System.Windows.Forms.Label();
this.textBox10 = new System.Windows.Forms.TextBox();
this.label13 = new System.Windows.Forms.Label();
this.textBox11 = new System.Windows.Forms.TextBox();
this.label14 = new System.Windows.Forms.Label();
this.textBox12 = new System.Windows.Forms.TextBox();
this.label15 = new System.Windows.Forms.Label();
this.dateTimePicker1 = new System.Windows.Forms.DateTimePicker();
this.label17 = new System.Windows.Forms.Label();
this.richTextBox1 = new System.Windows.Forms.RichTextBox();
this.label18 = new System.Windows.Forms.Label();
this.textBox14 = new System.Windows.Forms.TextBox();
this.button1 = new System.Windows.Forms.Button();
this.label19 = new System.Windows.Forms.Label();
this.textBox15 = new System.Windows.Forms.TextBox();
this.label20 = new System.Windows.Forms.Label();
this.textBox16 = new System.Windows.Forms.TextBox();
this.dgrd_StockerData = new System.Windows.Forms.DataGrid();
this.button2 = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.dgrd_StockerData)).BeginInit();
this.SuspendLayout();
//
// label1
//
this.label1.Location = new System.Drawing.Point(24, 48);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(56, 32);
this.label1.TabIndex = 0;
this.label1.Text = "选择退宿的房间号";
//
// comboBox1
//
this.comboBox1.Location = new System.Drawing.Point(88, 48);
this.comboBox1.Name = "comboBox1";
this.comboBox1.Size = new System.Drawing.Size(104, 20);
this.comboBox1.TabIndex = 1;
this.comboBox1.Text = "comboBox1";
//
// label2
//
this.label2.Location = new System.Drawing.Point(264, 48);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(40, 16);
this.label2.TabIndex = 2;
this.label2.Text = "姓名";
//
// textBox1
//
this.textBox1.Enabled = false;
this.textBox1.Location = new System.Drawing.Point(304, 48);
this.textBox1.Name = "textBox1";
this.textBox1.TabIndex = 3;
this.textBox1.Text = "";
//
// label3
//
this.label3.Location = new System.Drawing.Point(416, 48);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(64, 16);
this.label3.TabIndex = 4;
this.label3.Text = "住宿日期";
//
// textBox2
//
this.textBox2.Enabled = false;
this.textBox2.Location = new System.Drawing.Point(480, 48);
this.textBox2.Name = "textBox2";
this.textBox2.Size = new System.Drawing.Size(96, 21);
this.textBox2.TabIndex = 5;
this.textBox2.Text = "";
//
// label4
//
this.label4.Location = new System.Drawing.Point(584, 48);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(32, 16);
this.label4.TabIndex = 6;
this.label4.Text = "时间";
//
// textBox3
//
this.textBox3.Enabled = false;
this.textBox3.Location = new System.Drawing.Point(624, 48);
this.textBox3.Name = "textBox3";
this.textBox3.Size = new System.Drawing.Size(72, 21);
this.textBox3.TabIndex = 7;
this.textBox3.Text = "";
//
// label5
//
this.label5.Location = new System.Drawing.Point(24, 88);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(56, 16);
this.label5.TabIndex = 8;
this.label5.Text = "实际宿费";
//
// textBox4
//
this.textBox4.Location = new System.Drawing.Point(88, 88);
this.textBox4.Name = "textBox4";
this.textBox4.TabIndex = 9;
this.textBox4.Text = "textBox4";
//
// label6
//
this.label6.Location = new System.Drawing.Point(208, 88);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(64, 16);
this.label6.TabIndex = 10;
this.label6.Text = "结款方式";
//
// comboBox2
//
this.comboBox2.Items.AddRange(new object[] {
"预 付",
"挂 账",
"结 帐"});
this.comboBox2.Location = new System.Drawing.Point(272, 88);
this.comboBox2.Name = "comboBox2";
this.comboBox2.Size = new System.Drawing.Size(72, 20);
this.comboBox2.TabIndex = 11;
this.comboBox2.Text = "结 帐";
//
// label7
//
this.label7.Location = new System.Drawing.Point(368, 88);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(32, 16);
this.label7.TabIndex = 12;
this.label7.Text = "折扣";
//
// textBox5
//
this.textBox5.Location = new System.Drawing.Point(408, 88);
this.textBox5.Name = "textBox5";
this.textBox5.Size = new System.Drawing.Size(64, 21);
this.textBox5.TabIndex = 13;
this.textBox5.Text = "textBox5";
//
// label8
//
this.label8.Location = new System.Drawing.Point(504, 88);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(32, 16);
this.label8.TabIndex = 14;
this.label8.Text = "押金";
//
// textBox6
//
this.textBox6.Enabled = false;
this.textBox6.Location = new System.Drawing.Point(552, 88);
this.textBox6.Name = "textBox6";
this.textBox6.Size = new System.Drawing.Size(96, 21);
this.textBox6.TabIndex = 15;
this.textBox6.Text = "";
//
// label9
//
this.label9.Location = new System.Drawing.Point(24, 128);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(64, 16);
this.label9.TabIndex = 16;
this.label9.Text = "住宿天数";
//
// imageList1
//
this.imageList1.ImageSize = new System.Drawing.Size(16, 16);
this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
//
// toolBar1
//
this.toolBar1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.toolBar1.Buttons.AddRange(new System.Windows.Forms.ToolBarButton[] {
this.tbarBtnSave,
this.tbarBtnDelete});
this.toolBar1.DropDownArrows = true;
this.toolBar1.ImageList = this.imageList1;
this.toolBar1.Location = new System.Drawing.Point(0, 0);
this.toolBar1.Name = "toolBar1";
this.toolBar1.ShowToolTips = true;
this.toolBar1.Size = new System.Drawing.Size(720, 29);
this.toolBar1.TabIndex = 17;
this.toolBar1.ButtonClick += new System.Windows.Forms.ToolBarButtonClickEventHandler(this.toolBar1_ButtonClick);
//
// tbarBtnSave
//
this.tbarBtnSave.ImageIndex = 0;
this.tbarBtnSave.ToolTipText = "保存修改";
//
// tbarBtnDelete
//
this.tbarBtnDelete.ImageIndex = 1;
this.tbarBtnDelete.ToolTipText = "删除数据";
//
// textBox7
//
this.textBox7.Location = new System.Drawing.Point(88, 128);
this.textBox7.Name = "textBox7";
this.textBox7.TabIndex = 18;
this.textBox7.Text = "textBox7";
//
// label10
//
this.label10.Location = new System.Drawing.Point(200, 128);
this.label10.Name = "label10";
this.label10.Size = new System.Drawing.Size(56, 24);
this.label10.TabIndex = 19;
this.label10.Text = "退还宿费";
//
// label11
//
this.label11.Location = new System.Drawing.Point(376, 128);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(48, 16);
this.label11.TabIndex = 20;
this.label11.Text = "酒水费";
//
// textBox8
//
this.textBox8.Location = new System.Drawing.Point(264, 128);
this.textBox8.Name = "textBox8";
this.textBox8.TabIndex = 21;
this.textBox8.Text = "textBox8";
//
// textBox9
//
this.textBox9.Location = new System.Drawing.Point(424, 128);
this.textBox9.Name = "textBox9";
this.textBox9.TabIndex = 22;
this.textBox9.Text = "textBox9";
//
// label12
//
this.label12.Location = new System.Drawing.Point(536, 128);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(48, 16);
this.label12.TabIndex = 23;
this.label12.Text = "电话费";
//
// textBox10
//
this.textBox10.Location = new System.Drawing.Point(600, 128);
this.textBox10.Name = "textBox10";
this.textBox10.TabIndex = 24;
this.textBox10.Text = "textBox10";
//
// label13
//
this.label13.Location = new System.Drawing.Point(32, 168);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(48, 16);
this.label13.TabIndex = 25;
this.label13.Text = "赔偿费";
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -