李昊 4 anos atrás
pai
commit
51e8cab418

+ 0 - 2
gx_api/GxPress/Api/GxPress.Api/WebControllers/WebGroupController.cs

@@ -4,11 +4,9 @@ using GxPress.Auth;
 using GxPress.Common.Page;
 using GxPress.Repository.Interface;
 using GxPress.Repository.Interface.Group;
-using GxPress.Request.AddressBookGroup;
 using GxPress.Request.App.Group;
 using GxPress.Request.App.GroupUser;
 using GxPress.Request.App.Topic;
-using GxPress.Result.AddressBook;
 using GxPress.Result.App.Group;
 using GxPress.Result.App.GroupUser;
 using GxPress.Result.App.Topic;

+ 6 - 0
gx_api/GxPress/Model/GxPress.Entity/Group.cs

@@ -76,5 +76,11 @@ namespace GxPress.Entity
         /// <value></value>
         [DataColumn]
         public int GroupArticleCount { get; set; }
+        /// <summary>
+        /// 标签
+        /// </summary>
+        /// <value></value>
+        [DataColumn]
+        public string LabelName { get; set; }
     }
 }

+ 12 - 7
gx_api/GxPress/Model/GxPress.Request/App/Group/GroupInRequest.cs

@@ -7,7 +7,7 @@ namespace GxPress.Request.App.Group
     /// <summary>
     /// 添加小组
     /// </summary>
-  public  class GroupInRequest
+    public class GroupInRequest
     {
         /// <summary>
         /// 小组名称
@@ -22,7 +22,7 @@ namespace GxPress.Request.App.Group
         /// <summary>
         /// 二维码
         /// </summary>
-        
+
         public string QRCoder { get; set; }
 
         /// <summary>
@@ -34,7 +34,7 @@ namespace GxPress.Request.App.Group
         /// <summary>
         /// 介绍
         /// </summary>
-       
+
         public string Introduce { get; set; }
 
         /// <summary>
@@ -45,27 +45,32 @@ namespace GxPress.Request.App.Group
         /// <summary>
         /// 是否禁言
         /// </summary>
-       
+
         public bool IsWords { get; set; }
 
         /// <summary>
         /// 是否免打扰
         /// </summary>
-     
+
         public bool IsUDisturb { get; set; }
 
         /// <summary>
         /// 小组文件夹ID
         /// </summary>
-       
+
         public int GroupFolderId { get; set; }
         /// <summary>
         /// 用户ID
         /// </summary>
         public List<int> UserIds { get; set; }
-         /// <summary>
+        /// <summary>
         /// 广场ID
         /// </summary>
         public int GroupCategroyId { get; set; }
+        /// <summary>
+        /// 标签
+        /// </summary>
+        /// <value></value>
+        public string LabelName { get; set; }
     }
 }

+ 5 - 0
gx_api/GxPress/Model/GxPress.Request/App/Group/GroupUpRequest.cs

@@ -56,5 +56,10 @@ namespace GxPress.Request.App.Group
         /// </summary>
 
         public int GroupFolderId { get; set; }
+        /// <summary>
+        /// 小组标签
+        /// </summary>
+        /// <value></value>
+        public string LabelName { get; set; }
     }
 }

+ 5 - 0
gx_api/GxPress/Model/GxPress.Result/App/Group/GroupDetailResult.cs

@@ -101,6 +101,11 @@ namespace GxPress.Result.App.Group
         /// </summary>
         /// <value></value>
         public DateTime? CreatedDate { get; set; }
+        /// <summary>
+        /// 标签
+        /// </summary>
+        /// <value></value>
+        public string LabelName { get; set; }
     }
     /// <summary>
     /// 用户小组列表

+ 4 - 1
gx_api/GxPress/Repository/GxPress.Repository.Implement/GroupRepository.cs

@@ -64,7 +64,8 @@ namespace GxPress.Repository.Implement
                 QRCoder = request.QRCoder,
                 IsWords = false,
                 UserId = request.UserId,
-                GroupCategroyId = request.GroupCategroyId
+                GroupCategroyId = request.GroupCategroyId,
+                LabelName=request.LabelName
             };
             if (!string.IsNullOrEmpty(group.AvatarUrl))
                 group.AvatarUrl = StringUtils.RemoveDomain(group.AvatarUrl);
@@ -99,6 +100,8 @@ namespace GxPress.Repository.Implement
                 group.AvatarUrl = StringUtils.RemoveDomain(request.AvatarUrl);
             if (!string.IsNullOrEmpty(request.Introduce))
                 group.Introduce = request.Introduce;
+            if (!string.IsNullOrEmpty(request.LabelName))
+                group.LabelName = request.LabelName;
             return await _repository.UpdateAsync(group);
         }