Beispiel #1
0
        public ActionResult SaveForm(string keyValue, string strEntity)
        {
            PrincipleEntity entity = strEntity.ToObject <PrincipleEntity>();

            principleIBLL.SaveEntity(keyValue, entity);
            return(Success("保存成功!"));
        }
Beispiel #2
0
        public PrincipleEntity ToEntity(Principle domain)
        {
            PrincipleEntity entity = new PrincipleEntity {
            };

            _itemMapper.ToEntity(domain, entity);

            return(entity);
        }
Beispiel #3
0
        public Principle ToDomain(PrincipleEntity entity)
        {
            Principle domain = new Principle {
            };

            _itemMapper.ToDomain(entity, domain);

            return(domain);
        }
        public Principle GetById(long id)
        {
            PrincipleEntity entity = _lifeManagerRepository.LoadEntity <PrincipleEntity>(id);

            if (entity == null)
            {
                return(null);
            }

            return(_principleMapper.ToDomain(entity));
        }