protected void LoadEntity(LinksClass entity)
 {
     if (entity != null)
     {
         EntityId = entity.LinksClassId;
         Name = entity.Name;
         SortId = entity.SortId;
         Status = entity.Status;
         LangId = entity.LangId;
     }
 }
        private void Save(LinksClass entity)
        {
            entity.Name = Name;            
            entity.SortId = SortId;
            entity.Status = Status;
            entity.LangId = LangId;

            if (entity.LinksClassId == 0)
            {
                m_FTISService.CreateLinksClass(entity);
            }
            else
            {
                m_FTISService.UpdateLinksClass(entity);
            }

            LoadEntity(entity.LinksClassId);
        }
Example #3
0
 /// <summary>
 /// 刪除網路資源分類
 /// </summary>
 /// <param name="linksClass">被刪除的網路資源分類</param>
 public void DeleteLinksClass(LinksClass linksClass)
 {
     FTISDao.DeleteLinksClass(linksClass);
 }
Example #4
0
 /// <summary>
 /// 更新網路資源分類
 /// </summary>
 /// <param name="linksClass">被更新的網路資源分類</param>
 /// <returns>更新後的網路資源分類</returns>
 public LinksClass UpdateLinksClass(LinksClass linksClass)
 {
     return FTISDao.UpdateLinksClass(linksClass);
 }
Example #5
0
 /// <summary>
 /// 新增網路資源分類
 /// </summary>
 /// <param name="linksClass">被新增的網路資源分類</param>
 /// <returns>新增後的網路資源分類</returns>
 public LinksClass CreateLinksClass(LinksClass linksClass)
 {
     return FTISDao.CreateLinksClass(linksClass);
 }
 public void Insert()
 {
     LinksClass entity = new LinksClass();
     Save(entity);
 }