Exemplo n.º 1
0
        public static bool AddDefault(ParkBox model)
        {
            if (model == null)
            {
                throw new ArgumentNullException("model");
            }


            IParkBox factory = ParkBoxFactory.GetFactory();
            bool     result  = factory.Add(model);

            if (result)
            {
                OperateLogServices.AddOperateLog <ParkBox>(model, OperateType.Add);
            }
            return(result);
        }
Exemplo n.º 2
0
        public static bool Add(ParkBox model)
        {
            if (model == null)
            {
                throw new ArgumentNullException("model");
            }

            model.BoxID = GuidGenerator.GetGuid().ToString();
            IParkBox factory = ParkBoxFactory.GetFactory();
            bool     result  = factory.Add(model);

            if (result)
            {
                OperateLogServices.AddOperateLog <ParkBox>(model, OperateType.Add);
            }
            return(result);
        }