Ejemplo n.º 1
0
        public async Task GetBaseLog(string BaseName, string ModuleType, string StartTime, string EndTime, [ApiVal(Val.FormMode)] WhereSort whereSort)
        {
            AjaxJson _ajv = new();

            if (!string.IsNullOrEmpty(BaseName))
            {
                whereSort.Append($"and BaseName='{BaseName}'");
            }
            if (ModuleType != "all")
            {
                whereSort.Append($"and ModuleType='{ModuleType}'");
            }
            if (!string.IsNullOrEmpty(StartTime) && !string.IsNullOrEmpty(EndTime))
            {
                whereSort.Append($"and BaseTime>='{StartTime} 00:00:00' and BaseTime<='{EndTime} 23:59:59'");
            }

            var BaseLogList = FacadeManage.AideAdminFacade.GetBaseLog(whereSort);

            _ajv.code = 0;
            _ajv.msg  = "请求成功!";

            _ajv.SetPage(BaseLogList);

            _ajv.SetDataItem("list", BaseLogList.PageTable.ToDictionary());

            await JsonAsync(_ajv);
        }
Ejemplo n.º 2
0
        public async Task GetBaseUserList(string BaseName, [ApiVal(Val.FormMode)] WhereSort whereSort)
        {
            AjaxJson _ajv = new();

            if (!string.IsNullOrEmpty(BaseName))
            {
                whereSort.Append($"and BaseName='{BaseName}'");
            }
            var BaseUserList = FacadeManage.AideAdminFacade.GetBaseUserList(whereSort);

            _ajv.code = 0;
            _ajv.msg  = "请求成功!";

            _ajv.SetDataItem("PageCount", BaseUserList.PageCount);

            _ajv.SetDataItem("RecordCount", BaseUserList.RecordCount);

            _ajv.SetDataItem("PageIndex", BaseUserList.PageIndex);

            _ajv.SetDataItem("PageSize", BaseUserList.PageSize);

            _ajv.SetDataItem("list", BaseUserList.PageTable.ToDictionary());

            await JsonAsync(_ajv);
        }
Ejemplo n.º 3
0
        public async Task GetRoleDirectory(string RoleName, [ApiVal(Val.FormMode)] WhereSort whereSort)
        {
            AjaxJson _ajv = new();

            if (!string.IsNullOrWhiteSpace(RoleName))
            {
                whereSort.Append($"AND RoleName LIKE N'%{RoleName}%'");
            }

            var RoleDirectoryList = FacadeManage.AideAdminFacade.GetRoleDirectory(whereSort);

            _ajv.code = 0;
            _ajv.msg  = "请求成功!";

            _ajv.SetPage(RoleDirectoryList);

            _ajv.SetDataItem("list", RoleDirectoryList.PageTable.ToDictionary());

            await JsonAsync(_ajv);
        }