📄 configui.cs
字号:
this.btnClose.Text = "关闭";
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
//
// button1
//
this.button1.Location = new System.Drawing.Point(232, 240);
this.button1.Name = "button1";
this.button1.TabIndex = 2;
this.button1.Text = "保存设置";
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// comboSkin
//
this.comboSkin.Items.AddRange(new object[] {
"belv.urf",
"beryl.urf",
"clay.urf",
"dust.urf",
"leaf.urf",
"luna.urf",
"love.urf",
"luna.urf",
"onion.urf",
"opusos.urf",
"pixos.urf",
"plex.urf",
"spring.urf",
"spring.urp",
"wine.urf",
"winmp.urf"});
this.comboSkin.Location = new System.Drawing.Point(192, 136);
this.comboSkin.Name = "comboSkin";
this.comboSkin.Size = new System.Drawing.Size(152, 20);
this.comboSkin.TabIndex = 0;
this.comboSkin.Text = "belv.urf";
this.comboSkin.SelectedIndexChanged += new System.EventHandler(this.comboSkin_SelectedIndexChanged);
//
// button11
//
this.button11.Location = new System.Drawing.Point(88, 240);
this.button11.Name = "button11";
this.button11.TabIndex = 2;
this.button11.Text = "默认风格";
//
// ConfigUI
//
this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);
this.ClientSize = new System.Drawing.Size(576, 381);
this.Controls.Add(this.tabControl1);
this.Name = "ConfigUI";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "系统设置";
this.Load += new System.EventHandler(this.ConfigUI_Load);
this.Activated += new System.EventHandler(this.ConfigUI_Activated);
this.tabControl1.ResumeLayout(false);
this.tabPage1.ResumeLayout(false);
this.tabPage3.ResumeLayout(false);
this.tabPage2.ResumeLayout(false);
this.tabPage4.ResumeLayout(false);
this.tabPage5.ResumeLayout(false);
this.groupBox1.ResumeLayout(false);
this.groupBox2.ResumeLayout(false);
this.tabPage6.ResumeLayout(false);
this.tabPage7.ResumeLayout(false);
this.tabPage8.ResumeLayout(false);
this.ResumeLayout(false);
}
#endregion
/// <summary>
/// 加载风格
/// </summary>
private void AddSkin()
{
DirectoryInfo dir=new DirectoryInfo(Application.StartupPath+"\\skin");
FileInfo[]fileList= dir.GetFiles();
this.comboSkin.Items.Clear();
this.comboSkin.Items.AddRange(fileList);
}
/// <summary>
/// 查询房间类型
/// </summary>
public void ShowRoomtype()
{
try
{
TypeRoomData roomfata=new TypeRoomData();
SelectTypeRoom alltyperoom=new SelectTypeRoom();
alltyperoom.SelectAllTypeRoom(roomfata);
this.listView1.Items.Clear();
foreach(DataRow row in roomfata.TypeRoom.Rows)
{
ListViewItem item=new ListViewItem(row["Tid"].ToString());
item.SubItems.Add(row["TType"].ToString());
item.SubItems.Add(row["PriceByday"].ToString());
item.SubItems.Add(row["priceByhour"].ToString());
item.SubItems.Add(row["SetNum"].ToString());
item.SubItems.Add(row["IsTimeRoom"].ToString());
this.listView1.Items.Add(item);
}
}
catch(Exception ex)
{
MessageBox.Show(ex.ToString());
}
}
/// <summary>
/// 查询房间信息
/// </summary>
private void ShowRoominfo()
{
try
{
string Rtid="0";;
if(!this.isLookAll_RoomInfo)
{
if(this.listView1.SelectedItems.Count>0)
{
Rtid=this.listView1.SelectedItems[0].Text;
}
else
{
return;
}
}
RoomInfo_configData data=new RoomInfo_configData();
ShowSelectRoominfo_Config showRoom=new ShowSelectRoominfo_Config();
showRoom.SelectRoominfo_Config(data,Rtid);
this.listView2.Items.Clear();
foreach(DataRow row in data.RoomInfo_config_view.Rows)
{
ListViewItem item=new ListViewItem(row["rid"].ToString());
item.SubItems.Add(row["ttype"].ToString());
item.SubItems.Add(row["statetype"].ToString());
item.SubItems.Add(row["ingroup"].ToString());
item.SubItems.Add(row["roomtel"].ToString());
item.SubItems.Add(row["locknum"].ToString());
this.listView2.Items.Add(item);
}
}
catch(Exception ex)
{
MessageBox.Show(ex.ToString());
}
}
public void ShowShopingType()//查询商品类别
{
ConsumeTypeData data=new ConsumeTypeData();
ShowSelectShopingType select=new ShowSelectShopingType();
select.SelectShopingType(data);
this.listView3.Items.Clear();
foreach(DataRow row in data.ConsumeType.Rows)
{
ListViewItem item=new ListViewItem(row[0].ToString());
item.SubItems.Add(row[1].ToString());
this.listView3.Items.Add(item);
}
}
public void ShowWareInfo()//查询商品信息
{
WareInfoData data=new WareInfoData();
SetupSelectWareInfo ware=new SetupSelectWareInfo();
ware.SelectWareInfo(data);
this.listView4.Items.Clear();
foreach(DataRow row in data.WareInfo_view.Rows)
{
ListViewItem item=new ListViewItem(row["wid"].ToString());
item.SubItems.Add(row["wname"].ToString());
item.SubItems.Add(row["wprice"].ToString());
item.SubItems.Add(row["type"].ToString());
item.SubItems.Add(row["wchar"].ToString());
item.SubItems.Add(row["wunit"].ToString());
this.listView4.Items.Add(item);
}
}
public void ShowGradeInfo()//显示员工等级
{
DataTable grade=new DataTable();
SetupSelectGradeInfo selectg=new SetupSelectGradeInfo();
selectg.SelectGradeInfo(grade);
this.listView5.Items.Clear();
foreach(DataRow row in grade.Rows)
{
ListViewItem item=new ListViewItem(row[0].ToString());
item.SubItems.Add(row[1].ToString());
this.listView5.Items.Add(item);
}
}
public void ShowEmployee()//查询员工信息
{
EmployeeinfoData data=new EmployeeinfoData();
SetupSelectEmployee emp=new SetupSelectEmployee();
emp.SelectEmployee(data);
this.listView6.Items.Clear();
foreach(DataRow row in data.Employee_view.Rows)
{
ListViewItem item=new ListViewItem(row["eid"].ToString());
item.SubItems.Add(row["ename"].ToString().Trim());
item.SubItems.Add(row["echar"].ToString().Trim());
item.SubItems.Add(row["esex"].ToString().Trim());
item.SubItems.Add(row["eage"].ToString().Trim());
item.SubItems.Add(row["type"].ToString().Trim());
item.SubItems.Add(row["grade"].ToString().Trim());
item.SubItems.Add(row["ecardid"].ToString().Trim());
item.SubItems.Add(row["ejoin"].ToString().Trim());
this.listView6.Items.Add(item);
}
}
public void ShowGuestSort()//显示宾客来源
{
DataTable table=new DataTable();
SetupSelectGuestSort guest=new SetupSelectGuestSort();
guest.SelectGuestSort(table);
this.listView7.Items.Clear();
foreach(DataRow row in table.Rows)
{
ListViewItem item=new ListViewItem(row[0].ToString());
item.SubItems.Add(row[1].ToString());
item.SubItems.Add(row[2].ToString());
this.listView7.Items.Add(item);
}
}
public void ShowAdminInfo()//查询管理员
{
DataTable table=new DataTable();
SetupSelectAdminInfo admin=new SetupSelectAdminInfo();
admin.SelectAdminInfo(table);
this.listView8.Items.Clear();
foreach(DataRow row in table.Rows)
{
string isSuper="";
string isLock="";
if(row[2].ToString().Trim()=="1")
{
isSuper="超级管理员";
}
else
{
isSuper="管理员";
}
if(row[3].ToString().Trim()=="1")
{
isLock="可用";
}
else
{
isLock="不可用";
}
ListViewItem item=new ListViewItem(row[0].ToString());
item.SubItems.Add(row[1].ToString());
item.SubItems.Add(isSuper);
item.SubItems.Add(isLock);
this.listView8.Items.Add(item);
}
}
public void ShowOperPopedom()//查询权限
{
try
{
if(this.listView8.SelectedItems.Count>0)
{
this.listView9.Items.Clear();
aid=this.listView8.SelectedItems[0].SubItems[0].Text;
DataTable table=new DataTable();
SetupSelectOperPopedom oper=new SetupSelectOperPopedom();
oper.SelectOperPopedom(table,aid);
if(table.Rows.Count==0)
{
return;
}
if(table.Rows[0]["oper1"].ToString().Trim()=="1")
{
ListViewItem item=new ListViewItem("");
item.Checked=true;
item.SubItems.Add("散客(团体)开单");
this.listView9.Items.Add(item);
}
else
{
ListViewItem item=new ListViewItem("");
item.Checked=false;
item.SubItems.Add("散客(团体)开单");
this.listView9.Items.Add(item);
}
if(table.Rows[0]["oper2"].ToString().Trim()=="1")
{
ListViewItem item=new ListViewItem("");
item.Checked=true;
item.SubItems.Add("系统设置");
this.listView9.Items.Add(item);
}
else
{
ListViewItem item=new ListViewItem("");
item.Checked=false;
item.SubItems.Add("系统设置");
this.listView9.Items.Add(item);
}
if(table.Rows[0]["oper3"].ToString().Trim()=="1")
{
ListViewItem item=new ListViewItem("");
item.Checked=true;
item.SubItems.Add("增加消费");
this.listView9.Items.Add(item);
}
else
{
ListViewItem item=new ListViewItem("");
item.Checked=false;
item.SubItems.Add("增加消费");
this.listView9.Items.Add(item);
}
if(table.Rows[0]["oper4"].ToString().Trim()=="1")
{
ListViewItem item=new ListViewItem("");
item.Checked=true;
item.SubItems.Add("宾客结帐");
this.listView9.Items.Add(item);
}
else
{
ListViewItem item=new ListViewItem("");
item.Checked=false;
item.SubItems.Add("宾客结帐");
this.listView9.Items.Add(item);
}
if(table.Rows[0]["oper5"].ToString().Trim()=="1")
{
ListViewItem item=new ListViewItem("");
item.Checked=true;
item.SubItems.Add("预定管理");
this.listView9.Items.Add(item);
}
else
{
ListViewItem item=new ListViewItem("");
item.Checked=false;
item.SubItems.Add("预定管理");
this.listView9.Items.Add(item);
}
if(table.Rows[0]["oper6"].ToString().Trim()=="1")
{
ListViewItem i
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -