Skip to content

Commit ebf498a

Browse files
committed
use PageSize property for determining RecordsPerPage
1 parent ae2a204 commit ebf498a

5 files changed

Lines changed: 7 additions & 7 deletions

File tree

Source/Applications/SystemCenter/Controllers/OpenXDA/AssetGroups/OpenXDAAssetGroupsController.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public IHttpActionResult GetAssets([FromBody] PostData postData, [FromUri] int a
6767
{
6868
try
6969
{
70-
int recordsPerPage = Take ?? 50;
70+
int recordsPerPage = PageSize ?? 50;
7171

7272
string sql = @$"SELECT
7373
DISTINCT
@@ -192,7 +192,7 @@ public IHttpActionResult GetMeters([FromBody] PostData postData, [FromUri] int a
192192
{
193193
try
194194
{
195-
int recordsPerPage = Take ?? 50;
195+
int recordsPerPage = PageSize ?? 50;
196196

197197
string sql = @$"SELECT DISTINCT
198198
Meter.ID,
@@ -350,7 +350,7 @@ public IHttpActionResult GetSubGroupsPaged([FromBody] PostData postData, [FromUr
350350
{
351351
try
352352
{
353-
int recordsPerPage = Take ?? 50;
353+
int recordsPerPage = PageSize ?? 50;
354354

355355
TableOperations<AssetGroupView> table = new TableOperations<AssetGroupView>(connection);
356356

Source/Applications/SystemCenter/Controllers/OpenXDA/Assets/OpenXDAAssetController.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -695,7 +695,7 @@ public IHttpActionResult GetAssetChannels([FromBody] PostData postData, [FromUri
695695
{
696696
using (AdoDataConnection connection = new AdoDataConnection(Connection))
697697
{
698-
int recordsPerPage = Take ?? 50;
698+
int recordsPerPage = PageSize ?? 50;
699699

700700
Asset asset = new TableOperations<Asset>(connection).QueryRecordWhere("ID={0}", assetID);
701701
if (asset is null)

Source/Applications/SystemCenter/Controllers/OpenXDA/Assets/OpenXDALineController.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ public IHttpActionResult GetLineSegmentsForLinePaged([FromBody] PostData postDat
100100
{
101101
if (GetRoles == string.Empty || User.IsInRole(GetRoles))
102102
{
103-
int recordsPerPage = Take ?? 50;
103+
int recordsPerPage = PageSize ?? 50;
104104

105105
using (AdoDataConnection connection = new AdoDataConnection(Connection))
106106
{

Source/Applications/SystemCenter/Controllers/OpenXDA/Meters/OpenXDAMeterController.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ public IHttpActionResult GetMeterChannels(int meterID, int page, string filter)
311311
if (GetRoles != string.Empty && !User.IsInRole(GetRoles))
312312
return Unauthorized();
313313

314-
int recordsPerPage = Take ?? 50;
314+
int recordsPerPage = PageSize ?? 50;
315315

316316
string ChannelQuery =
317317
"SELECT " +

Source/Applications/SystemCenter/Model/Security/SecurityGroup.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public IHttpActionResult GetPagedUsers([FromBody] PostData postData, [FromUri] S
111111
if (!sortFields.Any(f => f.Equals(postData.OrderBy, StringComparison.OrdinalIgnoreCase)))
112112
return BadRequest("Invalid 'OrderBy' field.");
113113

114-
int recordsPerPage = Take ?? 50;
114+
int recordsPerPage = PageSize ?? 50;
115115

116116
using (AdoDataConnection connection = new AdoDataConnection(Connection))
117117
{

0 commit comments

Comments
 (0)