📄 st_entity.cs
字号:
using System;
namespace STGROUP.ST_BookBiz
{
/// <summary>
/// 实体结构的定义。
/// </summary>
[Serializable]
//商品的实体结构
public struct ST_ProductEntity
{
#region 私有字段
private int _ST_ProductID;
private string _ST_ProductName;
private float _ST_Price;
private float _ST_SoldPrice;
private string _ST_Publisher;
private string _ST_ISBN;
private int _ST_Page;
private DateTime _ST_PublishDate;
private int _ST_ClassID;
private string _ST_Image;
private bool _ST_IsSelling;
private string _ST_Author;
#endregion
#region 属性
/// <summary>
/// 商品ID
/// </summary>
public int ST_ProductID
{
get
{
return this._ST_ProductID;
}
set
{
this._ST_ProductID = value;
}
}
/// <summary>
/// 商品名称
/// </summary>
public string ST_ProductName
{
get
{
return this._ST_ProductName;
}
set
{
this._ST_ProductName = value;
}
}
/// <summary>
/// 商品售价
/// </summary>
public float ST_SoldPrice
{
get
{
return this._ST_SoldPrice;
}
set
{
this._ST_SoldPrice = value;
}
}
/// <summary>
/// 商品原价
/// </summary>
public float ST_Price
{
get
{
return this._ST_Price;
}
set
{
this._ST_Price = value;
}
}
/// <summary>
/// 出版社
/// </summary>
public string ST_Publisher
{
get
{
return this._ST_Publisher;
}
set
{
this._ST_Publisher = value;
}
}
/// <summary>
/// 作者
/// </summary>
public string ST_Author
{
get
{
return this._ST_Author;
}
set
{
this._ST_Author = value;
}
}
/// <summary>
/// ISBN号
/// </summary>
public string ST_ISBN
{
get
{
return this._ST_ISBN;
}
set
{
this._ST_ISBN = value;
}
}
/// <summary>
/// 图书页数
/// </summary>
public int ST_Page
{
get
{
return this._ST_Page;
}
set
{
this._ST_Page = value;
}
}
/// <summary>
/// 出版日期
/// </summary>
public DateTime ST_PublishDate
{
get
{
return this._ST_PublishDate;
}
set
{
this._ST_PublishDate = value;
}
}
/// <summary>
/// 所属分类ID
/// </summary>
public int ST_ClassID
{
get
{
return this._ST_ClassID;
}
set
{
this._ST_ClassID = value;
}
}
/// <summary>
/// 商品图片链接
/// </summary>
public string ST_Image
{
get
{
return this._ST_Image;
}
set
{
this._ST_Image = value;
}
}
/// <summary>
/// 商品上下架状态,1为上架,0为下架
/// </summary>
public bool ST_IsSelling
{
get
{
return this._ST_IsSelling;
}
set
{
this._ST_IsSelling = value;
}
}
#endregion
}
[Serializable]
//订单的实体结构
public struct ST_OrderEntity
{
#region 私有字段
private int _ST_OrderID;
private int _ST_UserID;
private DateTime _ST_CreateTime;
private string _ST_Ship;
private string _ST_Payment;
private float _ST_Sum;
private string _ST_Desciption;
private short _ST_Status;
private string _ST_Consignee;
private string _ST_ConsingeeEmail;
private string _ST_ConsingeePhone;
private string _ST_ConsingeeAddress;
private string _ST_ConsingeePostcode;
private string _ST_ConsingeeGender;
#endregion
#region 属性
/// <summary>
/// 订单ID
/// </summary>
public int ST_OrderID
{
get
{
return this._ST_OrderID;
}
set
{
this._ST_OrderID = value;
}
}
/// <summary>
/// 消费者ID
/// </summary>
public int ST_UserID
{
get
{
return this._ST_UserID;
}
set
{
this._ST_UserID = value;
}
}
/// <summary>
/// 订单生成时间
/// </summary>
public DateTime ST_CreateTime
{
get
{
return this._ST_CreateTime;
}
set
{
this._ST_CreateTime = value;
}
}
/// <summary>
/// 配送方式,包括送货上门,平邮,EMS
/// </summary>
public string ST_Ship
{
get
{
return this._ST_Ship;
}
set
{
this._ST_Ship = value;
}
}
/// <summary>
/// 支付方式,包括银行电汇、邮局汇款、货到付款
/// </summary>
public string ST_Payment
{
get
{
return this._ST_Payment;
}
set
{
this._ST_Payment = value;
}
}
/// <summary>
/// 订单金额
/// </summary>
public float ST_Sum
{
get
{
return this._ST_Sum;
}
set
{
this._ST_Sum = value;
}
}
/// <summary>
/// 订单说明
/// </summary>
public string ST_Desciption
{
get
{
return this._ST_Desciption;
}
set
{
this._ST_Desciption = value;
}
}
/// <summary>
/// 订单状态,0是新订单,1是发货,2是作废
/// </summary>
public short ST_Status
{
get
{
return this._ST_Status;
}
set
{
this._ST_Status = value;
}
}
/// <summary>
/// 订单收货人
/// </summary>
public string ST_Consignee
{
get
{
return this._ST_Consignee;
}
set
{
this._ST_Consignee = value;
}
}
/// <summary>
/// 订单收货人Email
/// </summary>
public string ST_ConsingeeEmail
{
get
{
return this._ST_ConsingeeEmail;
}
set
{
this._ST_ConsingeeEmail = value;
}
}
/// <summary>
/// 订单收货人电话
/// </summary>
public string ST_ConsingeePhone
{
get
{
return this._ST_ConsingeePhone;
}
set
{
this._ST_ConsingeePhone = value;
}
}
/// <summary>
/// 订单收货人地址
/// </summary>
public string ST_ConsingeeAddress
{
get
{
return this._ST_ConsingeeAddress;
}
set
{
this._ST_ConsingeeAddress = value;
}
}
/// <summary>
/// 订单收货人邮编
/// </summary>
public string ST_ConsingeePostcode
{
get
{
return this._ST_ConsingeePostcode;
}
set
{
this._ST_ConsingeePostcode = value;
}
}
/// <summary>
/// 订单收货人性别
/// </summary>
public string ST_ConsingeeGender
{
get
{
return this._ST_ConsingeeGender;
}
set
{
this._ST_ConsingeeGender = value;
}
}
#endregion
}
[Serializable]
//消费者的实体结构
public struct ST_UserEntity
{
#region 私有字段
private int _ST_UserID;
private string _ST_LoginName;
private string _ST_Pass;
private string _ST_TrueName;
private string _ST_Address;
private string _ST_Telephone;
private string _ST_Email;
private string _ST_Postcode;
private string _ST_Gender;
#endregion
#region 属性
/// <summary>
/// 消费者ID
/// </summary>
public int ST_UserID
{
get
{
return this._ST_UserID;
}
set
{
this._ST_UserID = value;
}
}
/// <summary>
/// 登录名
/// </summary>
public string ST_Name
{
get
{
return this._ST_LoginName;
}
set
{
this._ST_LoginName = value;
}
}
/// <summary>
/// 密码
/// </summary>
public string ST_Pass
{
get
{
return this._ST_Pass;
}
set
{
this._ST_Pass = value;
}
}
/// <summary>
/// 消费者姓名
/// </summary>
public string ST_TrueName
{
get
{
return this._ST_TrueName;
}
set
{
this._ST_TrueName = value;
}
}
/// <summary>
/// 消费者地址
/// </summary>
public string ST_Address
{
get
{
return this._ST_Address;
}
set
{
this._ST_Address = value;
}
}
/// <summary>
/// 消费者电话
/// </summary>
public string ST_Telephone
{
get
{
return this._ST_Telephone;
}
set
{
this._ST_Telephone = value;
}
}
/// <summary>
/// 消费者Email
/// </summary>
public string ST_Email
{
get
{
return this._ST_Email;
}
set
{
this._ST_Email = value;
}
}
/// <summary>
/// 消费者邮编
/// </summary>
public string ST_Postcode
{
get
{
return this._ST_Postcode;
}
set
{
this._ST_Postcode = value;
}
}
/// <summary>
/// 消费者性别
/// </summary>
public string ST_Gender
{
get
{
return this._ST_Gender;
}
set
{
this._ST_Gender = value;
}
}
#endregion
}
public class ST_Utility
{
/// <summary>
/// 数据库联接字符串
/// </summary>
public static string ST_ConnString
{
get
{
return System.Configuration.ConfigurationSettings.AppSettings["ConnString"];
}
}
/// <summary>
/// 图片网络根地址
/// </summary>
public static string ST_ImagePath
{
get
{
return System.Configuration.ConfigurationSettings.AppSettings["ImagePath"];
}
}
/// <summary>
/// 图片物理根地址
/// </summary>
public static string ST_ImagePhyPath
{
get
{
return System.Configuration.ConfigurationSettings.AppSettings["ImagePhyPath"];
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -