Exemple #1
0
        public SiteChannelEntity GetModel(SiteChannelQuery query)
        {
            ISiteChannelService service = ServiceContainer.Instance.Container.Resolve <ISiteChannelService>();
            SiteChannelEntity   model   = service.GetSiteChannel(query);

            return(model);
        }
Exemple #2
0
        public ExecResult Save(SiteChannelEntity model)
        {
            ExecResult          execResult = new ExecResult();
            ISiteChannelService service    = ServiceContainer.Instance.Container.Resolve <ISiteChannelService>();

            return(service.Save(model));
        }
Exemple #3
0
        public IList <SiteChannelEntity> GetList(SiteChannelQuery query)
        {
            ISiteChannelService       service = ServiceContainer.Instance.Container.Resolve <ISiteChannelService>();
            IList <SiteChannelEntity> list    = service.GetSiteChannelList(query);

            return(list);
        }
Exemple #4
0
        public ExecResult Del(SiteChannelQuery query)
        {
            ExecResult          execResult = new ExecResult();
            ISiteChannelService service    = ServiceContainer.Instance.Container.Resolve <ISiteChannelService>();
            bool result = service.DeleteSiteChannel(query.ChannelID.Value);

            if (result)
            {
                execResult.result = EnumJsonResult.success.ToString();
                execResult.msg    = "删除栏目成功!";
            }
            else
            {
                execResult.result = EnumJsonResult.failure.ToString();
                execResult.msg    = "删除栏目失败!";
            }
            return(execResult);
        }