Exemplo n.º 1
0
 public bool InsertUpdate(M_CollectionInfo model)
 {
     if (model.C_IID > 0)
     {
         GetUpdate(model);
     }
     else
     {
         GetInsert(model);
     }
     return(true);
 }
Exemplo n.º 2
0
        protected void LinkButton1_Click(object sender, EventArgs e)
        {
            B_Content        bcon   = new B_Content();
            LinkButton       lb     = (LinkButton)sender;
            GridViewRow      gvr    = (GridViewRow)lb.NamingContainer;
            M_CollectionInfo mc     = bc.GetSelect(DataConverter.CLng(Egv.DataKeys[gvr.RowIndex].Value));
            DataTable        dtitem = bcon.GetCommonByItem(mc.ModeID, mc.NodeID, mc.CollID);

            if (dtitem.Rows.Count > 0)
            {
                int gid = DataConverter.CLng(dtitem.Rows[0]["GeneralID"].ToString());
                bcon.DelContent(gid);
                bc.GetDelete(mc.C_IID);
            }
            myBind();
        }
Exemplo n.º 3
0
 public int GetInsert(M_CollectionInfo model)
 {
     return(DBCenter.Insert(model));
 }
Exemplo n.º 4
0
 public bool UpdateByID(M_CollectionInfo model)
 {
     return(DBCenter.UpdateByID(model, model.C_IID));
 }
Exemplo n.º 5
0
 public int GetInsert(M_CollectionInfo model)
 {
     return(Sql.insertID(TbName, model.GetParameters(), BLLCommon.GetParas(model), BLLCommon.GetFields(model)));
 }
Exemplo n.º 6
0
 public bool UpdateByID(M_CollectionInfo model)
 {
     return(Sql.UpdateByIDs(TbName, PK, model.C_IID.ToString(), BLLCommon.GetFieldAndPara(model), model.GetParameters()));
 }