Exemplo n.º 1
0
        static void CoreTestAdd()
        {
            Core model = new Core();

            model.Author       = "author";
            model.Cover        = "cover";
            model.CreateTime   = DateTime.Now;
            model.DingCount    = 1;
            model.FrameLink    = "frameLink";
            model.HContent     = "hcontent";
            model.Intro        = "Intro";
            model.OriginalLink = "originallink";
            model.RedirectLink = "redirectlink";
            model.ShowTime     = DateTime.Now;
            model.Title        = "title";
            model.ViewCount    = 2;
            model.Type         = 2;
            model.Status       = 3;

            CoreDal dal = new CoreDal();
            int     id  = dal.Add(model);

            int j = id;
        }
Exemplo n.º 2
0
 /// <summary>
 /// add
 /// </summary>
 /// <param name="model"></param>
 /// <returns></returns>
 public int Add(Core model)
 {
     return(dal.Add(model));
 }