网上餐厅系统专业设计 - 图文(8)

2019-01-26 18:39

天津理工大学2012级本科专业设计

return SqlHelper.ExecuteDataTable(\餐品名称',Price as '价格',Number as '数量',CompanyName as '公司名称' from CustomerShopcar where CustomerLoginName=@CustomerLoginName\,

new SqlParameter(\, SqlDbType.NVarChar) { Value = CustomerLoinName } ); }

#endregion

图7.5 购物车功能逻辑顺序图

Figure 7.5 Shopping cart function logic sequence diagram

7.1.3 商家餐品添加

该功能模块是顾客在确认完毕注册餐厅的信息之后,进行餐品添加的一个操作过程,顾客需要填写完整订单信息,以方便送餐员的派送,顾客在订单信息中也需要进行选择支付方式,以将订单提交到不同的表中。该功能模块的功能逻辑顺序图如图7.6所示:

32

天津理工大学2012级本科专业设计

图7.6 订单提交功能逻辑顺序图

Figure 7.6 Order submission function logic sequence diagram

该功能模块的界面如图7.7所示,部分代码如下所示: DAL层:

#region 在线支付情况下的订餐

public int DistributionLinePay(int StaffId, string DistributionAddress, string DistributionFood, int DistributionNum, string GetFoodManName, string GetFoodManTel) {

return SqlHelper.ExecuteNonQuery(\

values(@StaffId,@DistributionAddress,@DistributionFood,@DistributionNum,@GetFoodManName,@GetFoodManTel)\,

new SqlParameter(\, SqlDbType.Int) { Value = StaffId }, new SqlParameter(\, SqlDbType.NVarChar) { Value = DistributionAddress },

new SqlParameter(\, SqlDbType.NVarChar) { Value = DistributionFood },

new SqlParameter(\, SqlDbType.Int) { Value = DistributionNum },

new SqlParameter(\, SqlDbType.NVarChar) { Value = GetFoodManName },

new SqlParameter(\, SqlDbType.VarChar) { Value =

33

天津理工大学2012级本科专业设计

GetFoodManTel } ); }

#endregion

#region 餐到付款情况下的订餐

public int InsertIntoDistributionRealityPay(int StaffId, string DistributionAddress, string DistributionFood, int DistributionNum, string DistributionPrice, string GetFoodManName, string GetFoodManTel) {

return SqlHelper.ExecuteNonQuery(\(@StaffId,@DistributionAddress,@DistributionFood,@DistributionNum,@DistributionPrice,@GetFoodManName,@GetFoodManTel)\,

new SqlParameter(\, SqlDbType.Int) { Value = StaffId }, new SqlParameter(\, SqlDbType.NVarChar) { Value = DistributionAddress },

new SqlParameter(\, SqlDbType.NVarChar) { Value = DistributionFood },

new SqlParameter(\, SqlDbType.Int) { Value = DistributionNum },

new SqlParameter(\, SqlDbType.VarChar) { Value = DistributionPrice },

new SqlParameter(\, SqlDbType.NVarChar) { Value = GetFoodManName },

new SqlParameter(\, SqlDbType.VarChar) { Value = GetFoodManTel } ); #endregion }

public DataTable getBuyFoodInformation(string CustomerLoginName) {

return SqlHelper.ExecuteDataTable(\餐品名称',Price as '价格',Number as '数量' from CustomerShopcar where CustomerLoginName=@CustomerLoginName\, new SqlParameter(\, SqlDbType.NVarChar) { Value=CustomerLoginName} ); }

public int deleteShopCarInformation(string CustomerLoginName) {

return SqlHelper.ExecuteNonQuery(\CustomerLoginName=@CustomerLoginName\,

new SqlParameter(\, SqlDbType.NVarChar) { Value=CustomerLoginName} );

34

天津理工大学2012级本科专业设计

}

图7.7 订餐功能模块界面

Figure 7.7 Reservation function module interface

35

天津理工大学2012级本科专业设计

7.2 本章小结

本章内容是在数据库设计完毕之后,对程序开始进行详细的设计步骤,对界面以及程序的交互性功能的设计,通过功能逻辑顺序图来描述用户与系统的交互信息,然后通过程序用代码进行具体的实现,完成系统的实现。

36


网上餐厅系统专业设计 - 图文(8).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:高考作文历史人物素材“竹林七贤”之嵇康

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: