欢迎来到淘文阁 - 分享文档赚钱的网站! | 帮助中心 好文档才是您的得力助手!
淘文阁 - 分享文档赚钱的网站
全部分类
  • 研究报告>
  • 管理文献>
  • 标准材料>
  • 技术资料>
  • 教育专区>
  • 应用文书>
  • 生活休闲>
  • 考试试题>
  • pptx模板>
  • 工商注册>
  • 期刊短文>
  • 图片设计>
  • ImageVerifierCode 换一换

    酒店管理系统实现代码.pdf

    • 资源ID:72824860       资源大小:1.13MB        全文页数:58页
    • 资源格式: PDF        下载积分:11.9金币
    快捷下载 游客一键下载
    会员登录下载
    微信登录下载
    三方登录下载: 微信开放平台登录   QQ登录  
    二维码
    微信扫一扫登录
    下载资源需要11.9金币
    邮箱/手机:
    温馨提示:
    快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。
    如填写123,账号就是123,密码也是123。
    支付方式: 支付宝    微信支付   
    验证码:   换一换

     
    账号:
    密码:
    验证码:   换一换
      忘记密码?
        
    友情提示
    2、PDF文件下载后,可能会被浏览器默认打开,此种情况可以点击浏览器菜单,保存网页到桌面,就可以正常下载了。
    3、本站不支持迅雷下载,请使用电脑自带的IE浏览器,或者360浏览器、谷歌浏览器下载即可。
    4、本站资源下载后的文档和图纸-无水印,预览文档经过压缩,下载后原文更清晰。
    5、试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。

    酒店管理系统实现代码.pdf

    ./入住import java.awt.*;import java.awt.event.*;import javax.swing.*;import javax.swing.border.Border;import javax.swing.text.*;public class A1 extends JFrame implements WindowListener/定义各个组件JFrame frame=new JFrame(入住系统);JLabel nameLabel=new JLabel(客户姓名);JLabel idtifyLabel=new JLabel(身份证号);JLabel roomLabel=new JLabel(入住房号);JLabel moneyLabel=new JLabel(应付金额);JTextField nameField=new JTextField();JTextFieldidtifyField=new JTextField();JTextFieldroomField=new JTextField();JTextFieldmoneyField=new JTextField();JButton button1,button2;/*public static void main(String args)A1 a1=new A1();a1.go();*/public void go()UpperCaseDocument ucDocument=new UpperCaseDocument();nameField.setDocument(ucDocument);nameField.setForeground(Color.black);/frame.addWindowListener(this);nameField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String username=nameField.getText();.);JComboBox jcb1;/组合框String itemList=现金,刷卡;jcb1=new JComboBox(itemList);jcb1.setSelectedIndex(0);button1=new JButton(确认支付);button2=new JButton(取消支付);final JPanel p1=new JPanel();p1.add(jcb1);p1.add(button1);p1.add(button2);p1.setLayout(new GridLayout(3,1);Border etched=BorderFactory.createEtchedBorder();Border border=BorderFactory.createTitledBorder(etched,付款方式);p1.setBorder(border);button1.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=确认支付)JOptionPane.showMessageDialog(p1,支付成功,success,JOptionPane.INFORMA TION_MESSAGE););button2.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=取消支付)JOptionPane.showMessageDialog(p1,支付失败,failure,.JOptionPane.INFORMATION_MESSAGE););idtifyField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String idtify=idtifyField.getText();String idtifyword=new String(idtify););roomField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String room=roomField.getText();String roomword=new String(room););moneyField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String money=moneyField.getText();String idtifyword=new String(money););/面板 labelPanel 放标签JPanel labelPanel=new JPanel();labelPanel.setLayout(new GridLayout(4,1);labelPanel.add(nameLabel);.labelPanel.add(idtifyLabel);labelPanel.add(roomLabel);labelPanel.add(moneyLabel);/面板 fieldPanel 放文本框JPanel fieldPanel=new JPanel();fieldPanel.setLayout(new GridLayout(4,1);fieldPanel.add(nameField);fieldPanel.add(idtifyField);fieldPanel.add(roomField);fieldPanel.add(moneyField);/面板 northPanel 放面板 lanelPanel 和面板 fieldPanelJPanel northPanel=new JPanel();northPanel.setLayout(new GridLayout(1,2);northPanel.add(labelPanel);northPanel.add(fieldPanel);Container cp=frame.getContentPane();cp.add(northPanel,BorderLayout.NORTH);/northPanel放在 northcp.add(p1,BorderLayout.SOUTH);frame.setSize(200,250);frame.setVisible(true);public void windowClosing(WindowEvent e1)System.exit(0);public void windowOpened(WindowEvent e2)public void windowIconified(WindowEvent e3)public void windowDeiconified(WindowEvent e4)public void windowClosed(WindowEvent e5).public void windowActivated(WindowEvent e6)public void windowDeactivated(WindowEvent e7)class UpperCaseDocument extends PlainDocumentpublic void insertString(int offset,String string,AttributeSet attributeSet)throws BadLocationExceptionstring=string.toUpperCase();super.insertString(offset,string,attributeSet);第二个:/退房import java.awt.*;import java.awt.event.*;import javax.swing.*;import javax.swing.border.Border;import javax.swing.text.*;public class A2 extends JFrame/定义各个组件JFrame frame=new JFrame(退房系统);JLabel nameLabel=new JLabel(客户姓名);.JLabel idtifyLabel=new JLabel(身份证号);JLabel roomLabel=new JLabel(退房号);JLabel timeLabel=new JLabel(退房时间);JTextField nameField=new JTextField();JTextFieldidtifyField=new JTextField();JTextFieldroomField=new JTextField();JTextFieldtimeField=new JTextField();JButton button1,button2;/JTextArea ta=new JTextArea(5,20);/*public static void main(String args)A2 a2=new A2();a2.go();*/public void go()UpperCaseDocument ucDocument=new UpperCaseDocument();nameField.setDocument(ucDocument);nameField.setForeground(Color.black);nameField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String username=nameField.getText(););button1=new JButton(是);button2=new JButton(否);final JPanel p1=new JPanel();p1.add(button1);p1.add(button2);.);.p1.setLayout(new GridLayout(2,1);Border etched=BorderFactory.createEtchedBorder();Border border=BorderFactory.createTitledBorder(etched,是否结清消费账单p1.setBorder(border);button1.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=是)JOptionPane.showMessageDialog(p1,谢谢您的大力支持!,success,JOptionPane.INFORMATION_MESSAGE););button2.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=否)JOptionPane.showMessageDialog(p1,请结清消费账单,failure,JOptionPane.INFORMATION_MESSAGE););idtifyField.addActionListener(new ActionListener().public void actionPerformed(ActionEvent e)String idtify=idtifyField.getText();String idtifyword=new String(idtify););roomField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String room=roomField.getText();String roomword=new String(room););timeField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String time=timeField.getText();String timeword=new String(time););/面板 labelPanel 放标签JPanel labelPanel=new JPanel();labelPanel.setLayout(new GridLayout(4,1);labelPanel.add(nameLabel);labelPanel.add(idtifyLabel);labelPanel.add(roomLabel);labelPanel.add(timeLabel);/面板 fieldPanel 放文本框JPanel fieldPanel=new JPanel();fieldPanel.setLayout(new GridLayout(4,1);fieldPanel.add(nameField);fieldPanel.add(idtifyField);fieldPanel.add(roomField);fieldPanel.add(timeField);/面板 northPanel 放面板 lanelPanel 和面板 fieldPanelJPanel northPanel=new JPanel();northPanel.setLayout(new GridLayout(1,2);northPanel.add(labelPanel);.northPanel.add(fieldPanel);Container cp=frame.getContentPane();cp.add(northPanel,BorderLayout.NORTH);/northPanel放在 northcp.add(p1,BorderLayout.SOUTH);/frame.pack();frame.setSize(200,230);frame.setVisible(true);class UpperCaseDocument extends PlainDocumentpublic void insertString(int offset,String string,AttributeSet attributeSet)throws BadLocationExceptionstring=string.toUpperCase();super.insertString(offset,string,attributeSet);第三个:/客房预订import java.awt.*;import java.awt.event.*;import javax.swing.*;import javax.swing.border.Border;import javax.swing.text.*;public class A3 extends JFrame/定义各个组件JFrame frame=new JFrame(客房预订);JLabel nameLabel=new JLabel(预订人姓名);JLabel numberLabel=new JLabel(手机号);JTextField nameField=new JTextField();.*/.JTextFieldnumberField=new JTextField();JRadioButton rb1=new JRadioButton(来电预订);JRadioButton rb2=new JRadioButton(电话预订);JRadioButton rb3=new JRadioButton(电传预订);JRadioButton rb4=new JRadioButton(传真预订);JRadioButton rb5=new JRadioButton(信函预订);JButton button1,button2;/*public static void main(String args)A3 a3=new A3();a3.go();public void go()UpperCaseDocument ucDocument=new UpperCaseDocument();nameField.setDocument(ucDocument);nameField.setForeground(Color.black);nameField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String username=nameField.getText(););JComboBox jcb1;/组合框String itemList=总统套房,双人间,单人间;jcb1=new JComboBox(itemList);jcb1.setSelectedIndex(0);button1=new JButton(是);button2=new JButton(否);final JPanel p1=new JPanel();.p1.add(jcb1);p1.add(button1);p1.add(button2);p1.setLayout(new GridLayout(3,1);Border etched=BorderFactory.createEtchedBorder();Border border=BorderFactory.createTitledBorder(etched,预订房类型);p1.setBorder(border);button1.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=是)JOptionPane.showMessageDialog(p1,客人预订成功,success,JOptionPane.INFORMA TION_MESSAGE););button2.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=否)JOptionPane.showMessageDialog(p1,客人预订失败,failure,JOptionPane.INFORMA TION_MESSAGE););JPanel p2=new JPanel();p2.add(rb1);.p2.add(rb2);p2.add(rb3);p2.add(rb4);p2.add(rb5);p2.setLayout(new FlowLayout();border=BorderFactory.createTitledBorder(etched,预订方式);p2.setBorder(border);/创建 ButtonGroup 按钮组,并在组中添加按钮ButtonGroup group1=new ButtonGroup();group1.add(rb1);group1.add(rb2);group1.add(rb3);group1.add(rb4);group1.add(rb5);numberField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String number=numberField.getText();String numberword=new String(number););/面板 labelPanel 放标签JPanel labelPanel=new JPanel();labelPanel.setLayout(new GridLayout(2,1);labelPanel.add(nameLabel);labelPanel.add(numberLabel);/面板 fieldPanel 放文本框JPanel fieldPanel=new JPanel();fieldPanel.setLayout(new GridLayout(2,1);fieldPanel.add(nameField);fieldPanel.add(numberField);./面板 northPanel 放面板 lanelPanel 和面板 fieldPanelJPanel northPanel=new JPanel();northPanel.setLayout(new GridLayout(1,2);northPanel.add(labelPanel);northPanel.add(fieldPanel);Container cp=frame.getContentPane();cp.add(northPanel,BorderLayout.NORTH);/northPanel放在 northcp.add(p2,BorderLayout.CENTER);cp.add(p1,BorderLayout.SOUTH);frame.setSize(200,330);frame.setVisible(true);class UpperCaseDocument extends PlainDocumentpublic void insertString(int offset,String string,AttributeSet attributeSet)throws BadLocationExceptionstring=string.toUpperCase();super.insertString(offset,string,attributeSet);第四个/餐饮预订import java.awt.*;import java.awt.event.*;import javax.swing.*;import javax.swing.border.Border;import javax.swing.text.*;public class A4 extends JFrame/定义各个组件JFrame frame=new JFrame(餐饮预订);JLabel nameLabel=new JLabel(预订人姓名);.JLabel timeLabel=new JLabel(预订消费时间);JTextField nameField=new JTextField();JTextFieldtimeField=new JTextField();JCheckBox cb1=new JCheckBox(中餐);JCheckBox cb2=new JCheckBox(西餐);JCheckBox cb3=new JCheckBox(红酒);JCheckBox cb4=new JCheckBox(饮料);JCheckBox cb5=new JCheckBox(甜点);JCheckBox cb6=new JCheckBox(水果);JButton button1,button2;/*public static void main(String args)A4 a4=new A4();a4.go();*/public void go()UpperCaseDocument ucDocument=new UpperCaseDocument();nameField.setDocument(ucDocument);nameField.setForeground(Color.black);nameField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String username=nameField.getText();/ta.append(nUser Name:+username););button1=new JButton(是);button2=new JButton(否);final JPanel p1=new JPanel();.p1.add(button1);p1.add(button2);p1.setLayout(new GridLayout(3,1);Border etched=BorderFactory.createEtchedBorder();Border border=BorderFactory.createTitledBorder(etched,确认订餐);p1.setBorder(border);button1.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=是)JOptionPane.showMessageDialog(p1,订餐成功,success,JOptionPane.INFORMATION_MESSAGE););button2.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=否)JOptionPane.showMessageDialog(p1,订餐失败,failure,JOptionPane.INFORMATION_MESSAGE););.timeField.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String time=timeField.getText();String timeword=new String(time););JPanel p2=new JPanel();p2.add(cb1);p2.add(cb2);p2.add(cb3);p2.add(cb4);p2.add(cb5);p2.add(cb6);Border etched1=BorderFactory.createEtchedBorder();Border border1=BorderFactory.createTitledBorder(etched1,预订内容);p2.setBorder(border1);/面板 labelPanel 放标签JPanel labelPanel=new JPanel();labelPanel.setLayout(new GridLayout(4,1);labelPanel.add(nameLabel);labelPanel.add(timeLabel);/面板 fieldPanel 放文本框JPanel fieldPanel=new JPanel();fieldPanel.setLayout(new GridLayout(4,1);fieldPanel.add(nameField);fieldPanel.add(timeField);/面板 northPanel 放面板 lanelPanel 和面板 fieldPanelJPanel northPanel=new JPanel();northPanel.setLayout(new GridLayout(1,2);northPanel.add(labelPanel);northPanel.add(fieldPanel);.Container cp=frame.getContentPane();cp.add(northPanel,BorderLayout.NORTH);/northPanel放在 northcp.add(p2,BorderLayout.CENTER);cp.add(p1,BorderLayout.SOUTH);frame.setSize(200,350);frame.setVisible(true);class UpperCaseDocument extends PlainDocumentpublic void insertString(int offset,String string,AttributeSet attributeSet)throws BadLocationExceptionstring=string.toUpperCase();super.insertString(offset,string,attributeSet);第五个:import java.awt.*;import java.awt.event.*;import javax.swing.*;import javax.swing.border.Border;import javax.swing.text.*;public class A5 extends JFrame/定义各个组件JFrame frame=new JFrame(订单管理);JLabel a1=new JLabel(订单号);JLabel a2=new JLabel(订货名称);JLabel a3=new JLabel(收货地址);JLabel a4=new JLabel(应收金额);JLabel a5=new JLabel(客户名称);JLabel a6=new JLabel(结算方式);.JLabel a7=new JLabel(经办人);JTextField b1=new JTextField();JTextFieldb2=new JTextField();JTextFieldb3=new JTextField();JTextFieldb4=new JTextField();JTextField b5=new JTextField();JTextField b6=new JTextField();JTextField b7=new JTextField();JButton button1,button2;public static void main(String args)A5 a1=new A5();a1.go();public void go()UpperCaseDocument ucDocument=newUpperCaseDocument();b1.setDocument(ucDocument);b1.setForeground(Color.black);b1.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String username=b1.getText(););JComboBox jcb1;/组合框String itemList=现金,刷卡;.jcb1=new JComboBox(itemList);jcb1.setSelectedIndex(0);button1=new JButton(确认收款);button2=new JButton(取消收款);final JPanel p1=new JPanel();p1.add(jcb1);p1.add(button1);p1.add(button2);p1.setLayout(new GridLayout(3,1);Border etched=BorderFactory.createEtchedBorder();Border border=BorderFactory.createTitledBorder(etched,收款方式);p1.setBorder(border);button1.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=确认收款)JOptionPane.showMessageDialog(p1,收款成功,success,JOptionPane.INFORMATION_MESSAGE););button2.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)if(e.getActionCommand()=取消收款)JOptionPane.showMessageDialog(p1,收款失败,failure,JOptionPane.INFORMATION_MESSAGE);.);b1.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String idtify=a1.getText();String idtifyword=new String(idtify););b2.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String room=a2.getText();String roomword=new String(room););b3.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String money=a3.getText();String idtifyword=new String(money););b4.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String money=a4.getText();String idtifyword=new String(money););b5.addActionListener(new ActionListener()public void actionPerformed(ActionEvent e)String money=a5.getText();.String idtifyword=new String(money););/面板 labelPanel 放标签JPanel labelPanel=new JPanel();labelPanel.setLayout(new GridLayout(7,1);labelPanel.add(a1);labelPanel.add(a2);labelPanel.add(a3);labelPanel.add(a4);labelPanel.add(a5);labelPanel.add(a6);labelPa

    注意事项

    本文(酒店管理系统实现代码.pdf)为本站会员(hg158****2095)主动上传,淘文阁 - 分享文档赚钱的网站仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知淘文阁 - 分享文档赚钱的网站(点击联系客服),我们立即给予删除!

    温馨提示:如果因为网速或其他原因下载失败请重新下载,重复下载不扣分。




    关于淘文阁 - 版权申诉 - 用户使用规则 - 积分规则 - 联系我们

    本站为文档C TO C交易模式,本站只提供存储空间、用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。本站仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知淘文阁网,我们立即给予删除!客服QQ:136780468 微信:18945177775 电话:18904686070

    工信部备案号:黑ICP备15003705号 © 2020-2023 www.taowenge.com 淘文阁 

    收起
    展开