DRUG表有的字段是drug_id,drug_name,drug_cost.
drug_basic_unit这个数据库表中现在有300条记录。
我想使用下拉式选单当选择drug_name时,出现300条记录的drug_name.这个我已经实现了.我想现在实现的是当选择一个drug_name,对应的drug_cost和drug_basic_unit也联动显示出来.
我看了js的例子,看不太懂,请大家帮忙改下我的代码.我代码如下.
<%@ page import= "java.sql.*,java.util.* "%>
<%@ include file= "../include/ccs.inc "%>
<%@ page language= "java "
import= "java.util.*,com.mytest.Hospital.Patient,com.mytest.Hospital.Doctor,com.mytest.Hospital.Drug "
pageEncoding= "gbk "%>
<%@ page contentType= "text/html;charset=GBK "%>
<jsp:useBean id= "NurseBeanBusiness "
class= "com.mytest.Hospital.NurseBean " scope= "page "> </jsp:useBean>
<jsp:useBean id= "patient " class= "com.mytest.Hospital.Patient "
scope= "page "> </jsp:useBean>
<jsp:useBean id= "drug " class= "com.mytest.Hospital.Drug " scope= "page "> </jsp:useBean>
<jsp:setProperty name= "patient " property= "* " />
<html>
<head>
</head>
<body bgcolor= "#FFFFFF ">
<table width= "770 " height= "423 " border= "0 " align= "center "
cellpadding= "0 " cellspacing= "1 " bgcolor= "#000000 ">
<tr>
<td height= "421 " bgcolor= "#FFFFFF ">
<table width= "770 " border= "0 " align= "center " cellpadding= "0 "
cellspacing= "0 ">
<tr>
<td>
<br>
</td>
<td width= "411 ">
</td>
</tr>
<tr>
<td width= "359 ">
<img src= "/Hospital/images/LEFTBAR.gif " width= "359 " height= "39 ">
</td>
<td align= "right " bgcolor= "336CA1 ">
</td>
</tr>
<tr>
<td colspan= "2 ">
<img src= "/Hospital/images/TOPBAR.gif " width= "770 " height= "69 ">
</td>
</tr>
<tr>
<td colspan= "2 ">
<table width= "770 " height= "290 " border= "0 " align= "center "
cellpadding= "0 " cellspacing= "0 ">
<tr>
<%@ include file= "../include/nurse.inc "%>
<td width= "603 " align= "center " valign= "top ">
<table width= "100% " height= "85% " border= "0 " cellpadding= "3 "
cellspacing= "1 " bgcolor= "#666666 ">
<tr>
<td width= "100% " height= "257 " align= "left " valign= "top "
bgcolor= "E3EDFF ">