添加会员模块的主要代码与上述的添加员工模块的设计代码类似。
2.修改会员资料模块设计
修改会员资料模块设计是修改“添加会员”之后的信息,修改会员资料要有权限的限制(本系统只有管理员有修改会员资料的权限),不得任意修改。修改的主要功能是随时更新会员信息。
修改会员模块的主要代码如下:
<!-****************editvip2.asp*****************->
ssql="updatevipset vip_num='"&newvipnum&"',vip_name='"&vipname&"',vip_sex='"&vipsex&"',vip_phone='"
ssql=ssql&vipphone&"',vip_rank='"&viprank&"',vip_date='"
ssql=ssql&vipdate&"',vip_money='"&vipmoney&"',other_money='"&othermomey&"',vip_remark='"&remark&"'
where vip_num='"&request.Form("txtvipnum")&"'"
cnn.execute ssql,,adcmdtext
3.删除会员资料模块设计
删除会员资料模块(仅限操作员和系统管理员)主要是根据会员信息进行删除,主要代码如下:
4.查询会员资料模块设计
在理发店的经营管理中,会员一项是重中之重,顾客才是上帝,上帝才能为理发店获得财富。所以本系统的重中之重也是“查询会员资料模块设计”。
查询会员资料模块设计流程图:
查询会员资料模块设计可以对会员情况进行查询,也是查询会员资料的快捷方式。在**.asp的界面中,输入查询会员的编号,单击“查询会员资料”,将很快的查询到会员的详细信息。可以对会员资料进行一个直观的总结,该页面主要用来完成会员信息的检索,有利于理发店的盈利。
会员查询资料模块设计涉及到调用数据库中的会员信息表。查询会员资料模块设计的主要代码如下:
<!-****************browsevip.asp*****************->
<%
dim ssql,currentpage,rowcount,i
if request.form("btnsubmit")="" then
response.end
end if
currentpage=request.querystring("currentpage")
if currentpage=""then
currentpage=1
end if
rst.cursortype=adopenstatic
rst.pagesize=5
field=request.form("istfld")
value=trim(request.form("txtvalue"))
if field="all" then
ssql="select*from vip order by vip_num"
end if
if field<>"all" and value<>"" then
ssql="select*fromvip where"&field&"='"&value&"'order by vip_num"
end if
rst.open ssql,cnn
if rst.eof then
ressponse.write"<p><font color=red>没有找到符合条件的记录! </font></p>"
else
rst.absolutepage=cint(currentpage)
rowcount=0
%>
参考文献
[1] 丁贵广 《ASP编程基础与实例》2002年 机械工业出版社
[2] 曾清国 《Windows 2000+ ASP SQL Server案例教程》 2001年 中科多媒体电子出版社
[3] 樊健平《ASP高级编程及其项目应用开发》2003年 中国水利水电出版社
[4] 袁宁 《网上商店大制作》2001年 重庆大学出版社
[5] 许卫林《VBScript+ASP动态网页制作》2002年 中国电力出版社
[6]廖信彦《ASP应用经典》2000年 中国铁道出版社会
[7]盖天宇《ASP数据库系统开发案例精选》2006年 人民邮电出版社
[8]赵增敏 《ASP动态网页设计》2003年 电子工业出版