示例#1
0
        private static IOrderNOSQLStrategy _ordernosql = BMAData.OrderNOSQL;//订单非关系型数据库

        #region 辅助方法

        /// <summary>
        /// 从IDataReader创建OrderActionInfo
        /// </summary>
        public static OrderActionInfo BuildOrderActionFromReader(IDataReader reader)
        {
            OrderActionInfo orderActionInfo = new OrderActionInfo();

            orderActionInfo.Oid = TypeHelper.ObjectToInt(reader["oid"]);
            orderActionInfo.Uid = TypeHelper.ObjectToInt(reader["uid"]);
            orderActionInfo.RealName = reader["realname"].ToString();
            orderActionInfo.ActionType = TypeHelper.ObjectToInt(reader["actiontype"]);
            orderActionInfo.ActionTime = TypeHelper.ObjectToDateTime(reader["actiontime"]);
            orderActionInfo.ActionDes = reader["actiondes"].ToString();

            return orderActionInfo;
        }
示例#2
0
 /// <summary>
 /// 创建订单处理
 /// </summary>
 /// <param name="orderActionInfo">订单处理信息</param>
 public static void CreateOrderAction(OrderActionInfo orderActionInfo)
 {
     BrnMall.Core.BMAData.RDBS.CreateOrderAction(orderActionInfo);
     if (_ordernosql != null)
         _ordernosql.CreateOrderAction(orderActionInfo);
 }
示例#3
0
        /// <summary>
        /// 创建订单处理
        /// </summary>
        /// <param name="orderActionInfo">订单处理信息</param>
        public void CreateOrderAction(OrderActionInfo orderActionInfo)
        {
            DbParameter[] parms = {
	                                    GenerateInParam("@oid", SqlDbType.Int,4,orderActionInfo.Oid),
	                                    GenerateInParam("@uid", SqlDbType.Int,4 ,orderActionInfo.Uid),
	                                    GenerateInParam("@realname", SqlDbType.NVarChar,10,orderActionInfo.RealName),
	                                    GenerateInParam("@actiontype", SqlDbType.TinyInt,1 ,orderActionInfo.ActionType),
                                        GenerateInParam("@actiontime", SqlDbType.DateTime, 8,orderActionInfo.ActionTime),
                                        GenerateInParam("@actiondes", SqlDbType.NVarChar, 250,orderActionInfo.ActionDes)
                                    };
            RDBSHelper.ExecuteNonQuery(CommandType.StoredProcedure,
                                       string.Format("{0}createorderaction", RDBSHelper.RDBSTablePre),
                                       parms);
        }
示例#4
0
 /// <summary>
 /// 创建订单处理
 /// </summary>
 /// <param name="orderActionInfo">订单处理信息</param>
 public static void CreateOrderAction(OrderActionInfo orderActionInfo)
 {
     BrnMall.Data.OrderActions.CreateOrderAction(orderActionInfo);
 }