public vDOC_PLANTILLA Get(decimal ID) { using (ctx = new Entities()) { vDOC_PLANTILLA r = new vDOC_PLANTILLA(); DOC_PLANTILLA b = ctx.DOC_PLANTILLA.Where(t => t.ID == ID).FirstOrDefault(); Mapper.Map(b, r); return r; } }
public ByARpt Insert(decimal ID_PLA,string NUM_PROC) { mPlantillas oPlantilla = new mPlantillas(); vPL_PLANTILLA Plantilla = oPlantilla.Get(ID_PLA); vDOC_PLANTILLA Reg = new vDOC_PLANTILLA(); Mapper.Map(Plantilla, Reg); Reg.EST_DOC = "AC"; Reg.FEC_DOC = DateTime.Now; Reg.NUM_PROC = NUM_PROC; Reg.ID_PLA = ID_PLA; Reg.COMPLETADO = "INI"; cmdInsert o = new cmdInsert(); o.oDto = Reg; return o.Enviar(); }
public ByARpt Update(vDOC_PLANTILLA Reg) { cmdUpdate o = new cmdUpdate(); o.oDto = Reg; return o.Enviar(); }
public ByARpt Update(vDOC_PLANTILLA Reg) { mDocumentos o = new mDocumentos(); return o.Update(Reg); }