Exemplo n.º 1
0
        ////新增(不知道有没有调用?)
        ////public bool AddItems(string Name, string AgoraPrice, string MemberPrice, string VipPrice, string SeckillPrice, string Area, string Details, string Days, string Hours, string Minutes, string Seconds)
        ////{
        ////    //ProductID,BrandID,Name,AgoraPrice,MemberPrice,VipPrice,SeckillPrice,Area,Details,IsSecondKill,LimitTime
        ////    if (helper.ExcuteCommandInt("insert into Items(Name,AgoraPrice,MemberPrice,VipPrice,SeckillPrice,Area,Details,Days,Hours,Minutes,Seconds) values ('"
        ////        + Name + "','" + AgoraPrice + "','" + MemberPrice + "','" + VipPrice + "','" + SeckillPrice + "','" + Area + "','" + Details + "','" + Days + "','" + Hours + "','" + Minutes + "','" + Seconds + "')") > 0)
        ////        return true;
        ////    else
        ////        return false;
        ////}
        //public bool AddItems(Entity.Items items) {
        //    return helper.ExcuteCommandInt("insert into Items(Name,AgoraPrice,MemberPrice,VipPrice,SeckillPrice,Area,Details,Days,Hours,Minutes,Seconds) values ('"
        //            + items.getName() + "','"
        //            + items.getAgoraPrice() + "','"
        //            + items.getMemberPrice() + "','"
        //            + items.getVipPrice()+ "','"
        //            + items.getSeckillPrice()+ "','"
        //            + items.getArea() + "','"
        //            + items.getDetails() + "','"
        //            + items.getDays() + "','"
        //            + items.getHours()+ "','"
        //            + items.getMinutes() + "','"
        //            + items.getSeconds()+ "')") > 0;
        //}

        //新增
        public bool AddItemsInfo(Entity.Items items)
        {
            //ProductID,BrandID,Name,AgoraPrice,MemberPrice,VipPrice,SeckillPrice,Area,Details,IsSecondKill,LimitTime
            return(helper.ExcuteCommandInt("insert into Items(ProductID,BrandID,Name,AgoraPrice,MemberPrice,VipPrice,SeckillPrice,Area,Details,Days,Hours,Minutes,Seconds) values ("
                                           + items.getProductID() + ","
                                           + items.getBrandID() + ",'"
                                           + items.getName() + "','"
                                           + items.getAgoraPrice() + "','"
                                           + items.getMemberPrice() + "','"
                                           + items.getVipPrice() + "','"
                                           + items.getSeckillPrice() + "','"
                                           + items.getArea() + "','"
                                           + items.getDetails() + "','"
                                           + items.getDays() + "','"
                                           + items.getHours() + "','"
                                           + items.getMinutes() + "','"
                                           + items.getSeconds() + "')") > 0);
        }