Пример #1
0
 /// <summary>
 /// 刪除期刊
 /// </summary>
 /// <param name="publication">被刪除的期刊</param>
 public void DeletePublication(Publication publication)
 {
     FTISDao.DeletePublication(publication);
 }
Пример #2
0
 /// <summary>
 /// 更新期刊
 /// </summary>
 /// <param name="publication">被更新的期刊</param>
 /// <returns>更新後的期刊</returns>
 public Publication UpdatePublication(Publication publication)
 {
     return FTISDao.UpdatePublication(publication);
 }
Пример #3
0
 /// <summary>
 /// 期刊
 /// </summary>
 /// <param name="publication">被新增的期刊</param>
 /// <returns>新增後的期刊</returns>
 public Publication CreatePublication(Publication publication)
 {
     return FTISDao.CreatePublication(publication);
 }
Пример #4
0
 protected void LoadEntity(Publication entity)
 {
     if (entity != null)
     {
         EntityId = entity.PublicationId;
         Name = entity.Name;
         SortId = entity.SortId;
         Status = entity.Status;                
         Content = entity.Content;
         PubNo = entity.PubNo;
         Pic1 = entity.Pic1;
         AFile1 = entity.AFile1;
         LinkFile = entity.LinkFile;
         Spec1 = entity.Spec1;
         Spec2 = entity.Spec2;
         Spec3 = entity.Spec3;
         Spec4 = entity.Spec4;
         Spec5 = entity.Spec5;
         Spec6 = entity.Spec6;
         MainCode = entity.MainCode;
         MainName = entity.MainName;
         AdminCode = entity.AdminCode;
         AdminName = entity.AdminName;
         ServiceCode = entity.ServiceCode;
         ServiceName = entity.ServiceName;
         if (entity.PublicationClass != null)
         {
             PublicationClass = entity.PublicationClass;
             PublicationClassId = entity.PublicationClass.PublicationClassId;
         }
     }
 }
Пример #5
0
        private void Save(Publication entity)
        {
            if (PublicationClassId > 0)
            {
                entity.PublicationClass = m_FTISService.GetPublicationClassById(PublicationClassId);
            }
            else
            {
                entity.PublicationClass = null;
            }

            entity.Name = Name;
            entity.SortId = SortId;
            entity.Status = Status;
            entity.Content = Content;
            entity.PubNo = PubNo;
            entity.Pic1 = Pic1;
            entity.AFile1 = AFile1;
            entity.LinkFile = LinkFile;
            entity.Spec1 = Spec1;
            entity.Spec2 = Spec2;
            entity.Spec3 = Spec3;
            entity.Spec4 = Spec4;
            entity.Spec5 = Spec5;
            entity.Spec6 = Spec6;
            entity.MainCode = MainCode;
            entity.MainName = MainName;
            entity.AdminCode = AdminCode;
            entity.AdminName = AdminName;
            entity.ServiceCode = ServiceCode;
            entity.ServiceName = ServiceName;

            if (entity.PublicationId == 0)
            {
                m_FTISService.CreatePublication(entity);
            }
            else
            {
                m_FTISService.UpdatePublication(entity);
            }

            LoadEntity(entity.PublicationId);
        }
Пример #6
0
 public void Insert()
 {
     Publication entity = new Publication();
     Save(entity);
 }