diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/AssStorageRoom/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/AssStorageRoom/Index.js index 52e878448..159a24e6c 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/AssStorageRoom/Index.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/AssStorageRoom/Index.js @@ -131,7 +131,9 @@ var bootstrap = function ($, learun) { ], mainId:'RId', - isPage: true + isPage: true, + sidx: 'RCode', + sord: 'ASC' }); page.search(); }, diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_Storage_Room/AssStorageRoomService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_Storage_Room/AssStorageRoomService.cs index d34870c38..70d0fedc3 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_Storage_Room/AssStorageRoomService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/Ass_Storage_Room/AssStorageRoomService.cs @@ -58,7 +58,7 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem } if (!queryParam["StorageId"].IsEmpty()) { - dp.Add("StorageId",queryParam["StorageId"].ToString(), DbType.String); + dp.Add("StorageId", queryParam["StorageId"].ToString(), DbType.String); strSql.Append(" AND t.StorageId = @StorageId "); } if (!queryParam["RFunction"].IsEmpty()) @@ -71,7 +71,7 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem dp.Add("RArea", "%" + queryParam["RArea"].ToString() + "%", DbType.String); strSql.Append(" AND t.RArea Like @RArea "); } - return this.BaseRepository().FindList(strSql.ToString(),dp, pagination); + return this.BaseRepository().FindList(strSql.ToString(), dp, pagination); } catch (Exception ex) { @@ -109,7 +109,7 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem } } } - + /// /// 获取树形数据 /// @@ -144,6 +144,7 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem try { string sql = $"select RId,RCode+'('+RFunction+')' as RCode from Ass_Storage_Room where StorageId='{storageId}'"; + sql += " order by RCode"; return this.BaseRepository().FindList(sql); } catch (Exception ex) @@ -170,7 +171,7 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem { try { - this.BaseRepository().Delete(t=>t.RId == keyValue); + this.BaseRepository().Delete(t => t.RId == keyValue); } catch (Exception ex) {