Quellcode durchsuchen

提交分页部分改变,之后会修改其他分页相关

zhangkun vor 5 Jahren
Ursprung
Commit
76513f380f

+ 15 - 0
代码/System.Common/Pagers/MyPageModel.cs

@@ -0,0 +1,15 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Linq;
4
+using System.Threading.Tasks;
5
+
6
+namespace System.Common
7
+{
8
+    public class MyPageModel
9
+    {
10
+
11
+        public int PageIndex { get; set; }
12
+        public int PageSize { get; set; }
13
+        public SqlSugar.RefAsync<int> PageCount { get; set; }
14
+    }
15
+}

+ 3 - 3
代码/TVShoppingCallCenter_ZLJ/Controllers/Product/ProductController.cs

@@ -485,8 +485,8 @@ namespace TVShoppingCallCenter_ZLJ.Controllers.Product
485 485
 
486 486
             #endregion
487 487
 
488
-            int  count = 0;
489
-            var list = await _productRepository.GetListByPage(eq,new PageModel{PageCount= count, PageSize=5,PageIndex=1 });
488
+            RefAsync<int> count = 0;
489
+            var list = await _productRepository.GetListByPage(eq, new MyPageModel() { PageIndex = 1, PageSize = 20, PageCount = count });
490 490
 
491 491
             return Success("成功", list);
492 492
 
@@ -557,7 +557,7 @@ namespace TVShoppingCallCenter_ZLJ.Controllers.Product
557 557
 
558 558
             #endregion
559 559
             int recordCount =0;
560
-            var list = await _productRepository.GetListByPage(conModels, new PageModel() { PageIndex = pageindex, PageSize = pagesize, PageCount = recordCount });
560
+            var list = await _productRepository.GetListByPage(conModels, new MyPageModel() { PageIndex = pageindex, PageSize = pagesize, PageCount = recordCount });
561 561
             var obj = new
562 562
             {
563 563
                 state = "success",

+ 0 - 34
代码/TVShoppingCallCenter_ZLJ/Properties/launchSettings.json

@@ -1,34 +0,0 @@
1
-{
2
-  "iisSettings": {
3
-    "windowsAuthentication": true,
4
-    "anonymousAuthentication": true,
5
-    "iis": {
6
-      "applicationUrl": "http://localhost/TVShoppingCallCenter_ZLJ",
7
-      "sslPort": 0
8
-    },
9
-    "iisExpress": {
10
-      "applicationUrl": "http://localhost:58162",
11
-      "sslPort": 0
12
-    }
13
-  },
14
-  "$schema": "http://json.schemastore.org/launchsettings.json",
15
-  "profiles": {
16
-    "IIS Express": {
17
-      "commandName": "IISExpress",
18
-      "launchBrowser": true,
19
-      "launchUrl": "api/info",
20
-      "environmentVariables": {
21
-        "ASPNETCORE_ENVIRONMENT": "Development"
22
-      }
23
-    },
24
-    "TVShoppingCallCenter_ZLJ": {
25
-      "commandName": "Project",
26
-      "launchBrowser": true,
27
-      "launchUrl": "api/info",
28
-      "environmentVariables": {
29
-        "ASPNETCORE_ENVIRONMENT": "Development"
30
-      },
31
-      "applicationUrl": "https://localhost:5001"
32
-    }
33
-  }
34
-}