コード例 #1
0
ファイル: GuideLineBLL.cs プロジェクト: x55756016/kmproject
 private CTMS_PARENTGUIDELINE ModelToEntity(ParentGuideLine model)
 {
     if (model != null)
     {
         var entity = new CTMS_PARENTGUIDELINE()
         {
             ID          = Guid.NewGuid().ToString(),
             GUIDELINEID = model.GuideLineId,
             PARENTID    = model.PARENTID
         };
         return(entity);
     }
     return(null);
 }
コード例 #2
0
ファイル: GuideLineBLL.cs プロジェクト: x55756016/kmproject
 private ParentGuideLine EntityToModel(CTMS_PARENTGUIDELINE entity)
 {
     if (entity != null)
     {
         var model = new ParentGuideLine()
         {
             Id          = entity.ID,
             GuideLineId = entity.GUIDELINEID,
             PARENTID    = entity.PARENTID,
             ParentName  = string.IsNullOrEmpty(entity.PARENTID) ? null : GetSimpleModel(entity.PARENTID).Name,
         };
         return(model);
     }
     return(null);
 }