ÔÆÌ⺣ - רҵÎÄÕ·¶ÀýÎĵµ×ÊÁÏ·ÖÏíÆ½Ì¨

µ±Ç°Î»ÖãºÊ×Ò³ > »ùÓÚjavaµÄÆóÒµ½øÏú´æ¹ÜÀíϵͳ

»ùÓÚjavaµÄÆóÒµ½øÏú´æ¹ÜÀíϵͳ

  • 62 ´ÎÔĶÁ
  • 3 ´ÎÏÂÔØ
  • 2025/6/28 9:29:08

ºÚÁú½­¶«·½Ñ§Ôº±¾¿Æ±ÏÒµÂÛÎÄ£¨Éè¼Æ£©

JOptionPane.showMessageDialog(JinHuoDan_IFrame.this,

\Èë¿âÍê³É\);

}

TbRukuMain ruMain = new TbRukuMain(id, pzsStr, jeStr,

ysjlStr, gysName, rkDate, czyStr, jsrStr, jsfsStr);

Set set = ruMain.getTabRukuDetails(); int rows = table.getRowCount(); for (int i = 0; i < rows; i++) { }

boolean rs = Dao.insertRukuInfo(ruMain); if (rs) {

TbSpinfo spinfo = (TbSpinfo) table.getValueAt(i, 0); if (spinfo == null || spinfo.getId() == null

|| spinfo.getId().isEmpty()) continue;

\Ìî¼ÓÈë¿âÉÌÆ·\);

return;

String djStr = (String) table.getValueAt(i, 6); String slStr = (String) table.getValueAt(i, 7); Double dj = Double.valueOf(djStr); Integer sl = Integer.valueOf(slStr);

TbRukuDetail detail = new TbRukuDetail(); detail.setTabSpinfo(spinfo.getId()); detail.setTabRukuMain(ruMain.getRkId()); detail.setDj(dj); detail.setSl(sl); set.add(detail);

JOptionPane.showMessageDialog(JinHuoDan_IFrame.this,

DefaultTableModel dftm = new DefaultTableModel(); table.setModel(dftm); pzslField.setText(\);

-16-

ºÚÁú½­¶«·½Ñ§Ôº±¾¿Æ±ÏÒµÂÛÎÄ£¨Éè¼Æ£©

}

}

});

}

}

hpzsField.setText(\); hjjeField.setText(\);

return rukuButton;

4.2.4 ÏúÊÛµ¥Ä£¿éÉè¼Æ

ÉÌÆ·ÏúÊÛʱ½øÏú´æ¹ÜÀíÖеÄÖØÒª»·½ÚÖ®Ò»£¬½ø»õÉÌÔÚÈë¿âÖ®ºó¾Í¿ÉÒÔ¿ªÊ¼ÏúÊÛ¡£ÏúÊÛµ¥Ä£¿éÖ÷Òª¸ºÔð¸ù¾Ý¾­ÊÖÈ˵ÄÏúÊÛµ¥¾Ý£¬²Ù×÷½øÏú´æ¹ÜÀíϵͳµÄ¿â´æÉÌÆ·ºÍ¼Ç¼ÏúÊÛÐÅÏ¢£¬·½±ãÒÔºó²éѯºÍͳ¼Æ¡£

(1) Ìí¼ÓÏúÊÛÉÌÆ·£º

ÔÚÏúÊÛµ¥´°ÌåÖе¥»÷¡°Ìí¼Ó¡±£¬½«Ïòtable±í¸ñÖÐÌí¼ÓеĿÕÐУ¬²Ù×÷Ô±¿ÉÒÔÔÚ¿ÕÐеĵÚÒ»ÁÐ×ֶεÄÉÌÆ·ÏÂÀ´ÁбíÖÐÑ¡ÔñÏúÊÛµÄÉÌÆ·£¬Õâ¶ùÏÂÀ­Áбí¿òºÍ½ø»õµ¥´°ÌåµÄ²»Í¬£¬Ëü²»ÊǸù¾Ý¹©»õÉÌ×Ö¶ÎÈ·¶¨Ñ¡Ôñ¿òÄÚÈÝ£¬¶øÊǰüº¬ÁËÊý¾Ý¿âÖÐËùÓû¿ÉÒÔÏúÊÛµÄÉÌÆ·¡£ÒªÊµÏÖÌí¼ÓÉÌÆ·µÄ¹¦ÄÜ£¬ÐèҪΪ¡°Ìí¼Ó¡±°´Å¥Ìí¼Ó¶¯×÷¼àÌýÆ÷£¬ÔÚ¼àÌýÆ÷ÖÖʵÏÖÏàÓ¦µÄÒµÎñÂß¼­¡£

(2) ÏúÊÛͳ¼Æ£º

ºÍ½ø»õµ¥µÄͳ¼Æ¹¦ÄÜÀàËÆ£¬ÏúÊÛµ¥Ò²ÐèҪͳ¼Æ¹¦ÄÜ£¬Í³¼ÆµÄÄÚÈݰüÀ¨»õÆ·ÊýÁ¿¡¢Æ·ÖÖÊýÁ¿¡¢ºÏ¼Æ½ð¶îµÈÐÅÏ¢£¬ÊµÏÖ·½Ê½Ò²ÊÇͨ¹ýtable±í¸ñµÄʼþ¼àÌýÆ÷À´´¦ÀíÏàÓ¦µÄͳ¼ÆÒµÎñ

(3) ÉÌÆ·ÏúÊÛ£º

ÔÚÏúÊÛµ¥´°ÌåÖÐÌí¼ÓÍêÏúÊÛÉÌÆ·Ö®ºó£¬µ¥»÷¡°ÏúÊÛ¡±°´Å¥£¬½«Íê³É±¾´ÎÏúÊÛµ¥µÄÏúÊÛÒµÎñ¡£ÏµÍ³»á¼Ç¼±¾´ÎÏúÊÛÐÅÏ¢£¬²¢´Ó¿â´æ±íÖп۳ýÏúÊÛµÄÉÌÆ·ÊýÁ¿

Æä¹Ø¼ü´úÂëÈçÏ£º

// µ¥»÷ÏúÊÛ°´Å¥±£´æ½ø»õÐÅÏ¢

JButton sellButton = new JButton(\ÏúÊÛ\);

sellButton.addActionListener(new ActionListener() {

public void actionPerformed(ActionEvent e) {

-17-

ºÚÁú½­¶«·½Ñ§Ôº±¾¿Æ±ÏÒµÂÛÎÄ£¨Éè¼Æ£©

stopTableCellEditing(); // ½áÊø±í¸ñÖÐûÓбàдµÄµ¥Ôª clearEmptyRow(); // Çå³ý¿ÕÐÐ

String hpzsStr = hpzs.getText(); // »õÆ·×ÜÊý String pzsStr = pzs.getText(); // Æ·ÖÖÊý String jeStr = hjje.getText(); // ºÏ¼Æ½ð¶î

String jsfsStr = jsfs.getSelectedItem().toString(); // ½áË㷽ʽ String jsrStr = jsr.getSelectedItem() + \; // ¾­ÊÖÈË String czyStr = czy.getText(); // ²Ù×÷Ô±

String rkDate = jhsjDate.toLocaleString(); // ÏúÊÛʱ¼ä String ysjlStr = ysjl.getText().trim(); // ÑéÊÕ½áÂÛ String id = piaoHao.getText(); // ƱºÅ

String kehuName = kehu.getSelectedItem().toString();// ¹©Ó¦ÉÌÃû×Ö if (jsrStr == null || jsrStr.isEmpty()) { }

if (ysjlStr == null || ysjlStr.isEmpty()) { }

if (table.getRowCount() <= 0) { }

TbSellMain sellMain = new TbSellMain(id, pzsStr, jeStr,

ysjlStr, kehuName, rkDate, czyStr, jsrStr, jsfsStr);

Set set = sellMain.getTbSellDetails(); int rows = table.getRowCount(); for (int i = 0; i < rows; i++) {

TbSpinfo spinfo = (TbSpinfo) table.getValueAt(i, 0); String djStr = (String) table.getValueAt(i, 6);

-18- JOptionPane.showMessageDialog(XiaoShouDan.this,

return;

JOptionPane.showMessageDialog(XiaoShouDan.this,

return;

JOptionPane.showMessageDialog(XiaoShouDan.this,

return;

ºÚÁú½­¶«·½Ñ§Ôº±¾¿Æ±ÏÒµÂÛÎÄ£¨Éè¼Æ£©

} });

}

String slStr = (String) table.getValueAt(i, 7); Double dj = Double.valueOf(djStr); Integer sl = Integer.valueOf(slStr); TbSellDetail detail = new TbSellDetail(); detail.setSpid(spinfo.getId());

detail.setTbSellMain(sellMain.getSellId()); detail.setDj(dj); detail.setSl(sl); set.add(detail);

boolean rs = Dao.insertSellInfo(sellMain); if (rs) { }

JOptionPane.showMessageDialog(XiaoShouDan.this, \ÏúÊÛÍê³É\); DefaultTableModel dftm = new DefaultTableModel(); table.setModel(dftm); initTable(); pzs.setText(\); hpzs.setText(\); hjje.setText(\);

4.2.5 ¿â´æÅ̵ãÄ£¿éÉè¼Æ

¿â´æÅ̵ãÄ£¿éÖ÷Òª¸ºÔð¼ÆËã¿â¹ÜÀíÈËÔ±µÄÉÌÆ·Å̵ãÊýÁ¿ºÍ¿â´æÊýÁ¿µÄËðÒæ¡£³ÌÐò½çÃæ½«Ìáʾµ±Ç°ÈÕÆÚºÃ¿â´æ²úÆ·µÄÆ·ÖÖÊýÁ¿£¬²¢ÔÚ±í¸ñÖÐÏÔʾËùÓÐ¿â´æ²úÆ·£¬ÔÚ±í¸ñµÄ¡°Å̵ãÊýÁ¿¡±Ò»ÁÐÖÐÊäÈëÏàÓ¦²úÆ·µÄÅ̵ãÊýÁ¿£¬¡°ËðÒæÊýÁ¿¡±×ֶλá×Ô¶¯¼ÆËã¸ÃÉÌÆ·µÄÊ£Óà²úÆ·ÊýÁ¿£¬Èç¹û¸ÃÊýÁ¿ÎªÕûÊý£¬ËµÃ÷¿â´æÊýÁ¿¶àÓÚÅ̵ãÊýÁ¿¡£

(1) ¶ÁÈ¡¿â´æÉÌÆ·£º

±¾Ä£¿é´°ÌåµÄÉÌÆ·±í¸ñtable×é¼þÓÃÓÚÏÔʾ¿â´æÖеÄËùÓÐÉÌÆ·ÐÅÏ¢£¬ÕâÐèÒªÔÚinitTable()·½·¨Öгõʼ»¯±í¸ñ×Ö¶ÎÃû£¬²¢µ÷ÓÃDaoÀàµÄgetKucunInfos()·½·¨¶ÁÈ¡¿â´æÊý¾Ý×ܵÄËùÓÐÉÌÆ·ÁÐ±í£¬Ìí¼Óµ½tableÉÌÆ·±í¸ñ×é¼þÖС£

-19-

ËÑË÷¸ü¶à¹ØÓÚ£º »ùÓÚjavaµÄÆóÒµ½øÏú´æ¹ÜÀíϵͳ µÄÎĵµ
  • ÊÕ²Ø
  • Î¥¹æ¾Ù±¨
  • °æÈ¨ÈÏÁì
ÏÂÔØÎĵµ10.00 Ôª ¼ÓÈëVIPÃâ·ÑÏÂÔØ
ÍÆ¼öÏÂÔØ
±¾ÎÄ×÷Õߣº...

¹²·ÖÏí92ƪÏà¹ØÎĵµ

Îĵµ¼ò½é£º

ºÚÁú½­¶«·½Ñ§Ôº±¾¿Æ±ÏÒµÂÛÎÄ£¨Éè¼Æ£© JOptionPane.showMessageDialog(JinHuoDan_IFrame.this, \Èë¿âÍê³É\); } TbRukuMain ruMain = new TbRukuMain(id, pzsStr, jeStr, ysjlStr, gysName, rkDat

¡Á ÓοͿì½ÝÏÂÔØÍ¨µÀ£¨ÏÂÔØºó¿ÉÒÔ×ÔÓɸ´ÖƺÍÅŰ棩
µ¥Æª¸¶·ÑÏÂÔØ
ÏÞÊ±ÌØ¼Û£º10 Ôª/·Ý Ô­¼Û:20Ôª
VIP°üÔÂÏÂÔØ
ÌØ¼Û£º29 Ôª/Ô ԭ¼Û:99Ôª
µÍÖÁ 0.3 Ôª/·Ý ÿÔÂÏÂÔØ150·Ý
ȫվÄÚÈÝÃâ·Ñ×ÔÓɸ´ÖÆ
VIP°üÔÂÏÂÔØ
ÌØ¼Û£º29 Ôª/Ô ԭ¼Û:99Ôª
µÍÖÁ 0.3 Ôª/·Ý ÿÔÂÏÂÔØ150·Ý
ȫվÄÚÈÝÃâ·Ñ×ÔÓɸ´ÖÆ
×¢£ºÏÂÔØÎĵµÓпÉÄÜ¡°Ö»ÓÐĿ¼»òÕßÄÚÈݲ»È«¡±µÈÇé¿ö£¬ÇëÏÂÔØÖ®Ç°×¢Òâ±æ±ð£¬Èç¹ûÄúÒѸ¶·ÑÇÒÎÞ·¨ÏÂÔØ»òÄÚÈÝÓÐÎÊÌ⣬ÇëÁªÏµÎÒÃÇЭÖúÄã´¦Àí¡£
΢ÐÅ£ºfanwen365 QQ£º370150219
Copyright © ÔÆÌ⺣ All Rights Reserved. ËÕICP±¸16052595ºÅ-3 ÍøÕ¾µØÍ¼ ¿Í·þQQ£º370150219 ÓÊÏ䣺370150219@qq.com