|
@ -1,54 +1,26 @@ |
|
|
const request = require('../../../utils/request') |
|
|
const request = require('../../../utils/request') |
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* 创建社群 |
|
|
|
|
|
* @params { |
|
|
|
|
|
* groupNamegroupName 社群名称 |
|
|
|
|
|
* groupAvatar 社群头像 |
|
|
|
|
|
* groupIntroduction 社群介绍 |
|
|
|
|
|
* } |
|
|
|
|
|
*/ |
|
|
|
|
|
export function createAssociation ({ groupName, groupAvatar, groupIntroduction }) { |
|
|
|
|
|
return request.post('group/group/create', { |
|
|
|
|
|
groupName, |
|
|
|
|
|
groupAvatar, |
|
|
|
|
|
groupIntroduction |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 社群详情 |
|
|
* 社群详情 |
|
|
*/ |
|
|
*/ |
|
|
export function getAssociationDetail (id) { |
|
|
export function getAssociationDetail (id) { |
|
|
return request.get(`group/group/detail/${id}`) |
|
|
return request.get(`property/group/detail/${id}`) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 修改群头像 |
|
|
* 修改群头像 |
|
|
*/ |
|
|
*/ |
|
|
export function modifyAvatar ({id, groupAvatar}) { |
|
|
export function modifyAvatar ({id, groupAvatar}) { |
|
|
return request.post('group/group/modifyAvatar', { |
|
|
return request.post('property/group/modifyAvatar', { |
|
|
id, |
|
|
id, |
|
|
groupAvatar |
|
|
groupAvatar |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* 解散群 |
|
|
|
|
|
*/ |
|
|
|
|
|
export function disbandAssociation({id, processingOpinions}) { |
|
|
|
|
|
return request.post('group/group/disband', { |
|
|
|
|
|
id, |
|
|
|
|
|
processingOpinions |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 加入社群 |
|
|
* 加入社群 |
|
|
*/ |
|
|
*/ |
|
|
|
|
|
|
|
|
export function joinAssociation (groupId) { |
|
|
export function joinAssociation (groupId) { |
|
|
return request.post('group/group/applyForGroup', { |
|
|
return request.post('property/group/applyForGroup', { |
|
|
groupId |
|
|
groupId |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
@ -57,7 +29,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 修改群介绍 |
|
|
* 修改群介绍 |
|
|
*/ |
|
|
*/ |
|
|
export function changeIntroduce ({id, groupIntroduction}) { |
|
|
export function changeIntroduce ({id, groupIntroduction}) { |
|
|
return request.post('group/group/modifyIntroduction', { |
|
|
return request.post('property/group/modifyIntroduction', { |
|
|
id, |
|
|
id, |
|
|
groupIntroduction |
|
|
groupIntroduction |
|
|
}) |
|
|
}) |
|
@ -67,7 +39,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 群成员列表 审核通过/待审核 |
|
|
* 群成员列表 审核通过/待审核 |
|
|
*/ |
|
|
*/ |
|
|
export function getAssociationMember ({groupId, state}) { |
|
|
export function getAssociationMember ({groupId, state}) { |
|
|
return request.get('group/group/listOfMember', { |
|
|
return request.get('property/group/listOfMember', { |
|
|
groupId, |
|
|
groupId, |
|
|
state |
|
|
state |
|
|
}) |
|
|
}) |
|
@ -77,7 +49,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 删除群成员 |
|
|
* 删除群成员 |
|
|
*/ |
|
|
*/ |
|
|
export function deleteMember ({groupId, userId}) { |
|
|
export function deleteMember ({groupId, userId}) { |
|
|
return request.post('group/group/removeMember', { |
|
|
return request.post('property/group/removeMember', { |
|
|
groupId, |
|
|
groupId, |
|
|
userId |
|
|
userId |
|
|
}) |
|
|
}) |
|
@ -87,7 +59,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 审核入群成员 |
|
|
* 审核入群成员 |
|
|
*/ |
|
|
*/ |
|
|
export function incomingVerify ({ groupId, members }) { |
|
|
export function incomingVerify ({ groupId, members }) { |
|
|
return request.post('group/group/reviewApply', { |
|
|
return request.post('property/group/reviewApply', { |
|
|
groupId, |
|
|
groupId, |
|
|
members |
|
|
members |
|
|
}) |
|
|
}) |
|
@ -97,7 +69,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 添加好友列表 |
|
|
* 添加好友列表 |
|
|
*/ |
|
|
*/ |
|
|
export function getInviteList ({groupId, mobile, road, lastName}) { |
|
|
export function getInviteList ({groupId, mobile, road, lastName}) { |
|
|
return request.get('group/group/getInviteList', { |
|
|
return request.get('property/group/getInviteList', { |
|
|
groupId, |
|
|
groupId, |
|
|
mobile, |
|
|
mobile, |
|
|
road, |
|
|
road, |
|
@ -109,7 +81,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 添加好友 |
|
|
* 添加好友 |
|
|
*/ |
|
|
*/ |
|
|
export function addMember ({ groupId, members}) { |
|
|
export function addMember ({ groupId, members}) { |
|
|
return request.post('group/group/addMember', { |
|
|
return request.post('property/group/addMember', { |
|
|
groupId, |
|
|
groupId, |
|
|
members |
|
|
members |
|
|
}) |
|
|
}) |
|
@ -119,7 +91,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 发布话题 |
|
|
* 发布话题 |
|
|
*/ |
|
|
*/ |
|
|
export function addTopic ({topicContent, topicAddress, topicLatitude, topicLongitude, groupId, groupName, images}) { |
|
|
export function addTopic ({topicContent, topicAddress, topicLatitude, topicLongitude, groupId, groupName, images}) { |
|
|
return request.post('group/topic/submit', { |
|
|
return request.post('property/topic/submit', { |
|
|
topicContent, |
|
|
topicContent, |
|
|
topicAddress, |
|
|
topicAddress, |
|
|
topicLatitude, |
|
|
topicLatitude, |
|
@ -134,7 +106,7 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
* 话题列表 |
|
|
* 话题列表 |
|
|
*/ |
|
|
*/ |
|
|
export function getTopicList ({ pageIndex, pageSize, timestamp, groupId, topicId }) { |
|
|
export function getTopicList ({ pageIndex, pageSize, timestamp, groupId, topicId }) { |
|
|
return request.get('group/topic/list', { |
|
|
return request.get('property/topic/list', { |
|
|
pageIndex, |
|
|
pageIndex, |
|
|
pageSize, |
|
|
pageSize, |
|
|
timestamp, |
|
|
timestamp, |
|
@ -146,8 +118,8 @@ export function disbandAssociation({id, processingOpinions}) { |
|
|
/** |
|
|
/** |
|
|
* 话题详情 |
|
|
* 话题详情 |
|
|
*/ |
|
|
*/ |
|
|
export function getTopicDetail (detailId) { |
|
|
export function getTopicDetail (id) { |
|
|
return request.get(`group/topic/detail/${detailId}`) |
|
|
return request.get(`property/topic/detail/${id}`) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
@ -155,7 +127,7 @@ export function getTopicDetail (detailId) { |
|
|
* @param groupId |
|
|
* @param groupId |
|
|
*/ |
|
|
*/ |
|
|
export function withdrawGroup (groupId) { |
|
|
export function withdrawGroup (groupId) { |
|
|
return request.post('group/group/quitGroup', { |
|
|
return request.post('property/group/quitGroup', { |
|
|
groupId |
|
|
groupId |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
@ -164,7 +136,7 @@ export function withdrawGroup (groupId) { |
|
|
* 评论最新最热列表 |
|
|
* 评论最新最热列表 |
|
|
*/ |
|
|
*/ |
|
|
export function getRemarkList({ pageIndex, pageSize, timestamp, orderType, topicId }) { |
|
|
export function getRemarkList({ pageIndex, pageSize, timestamp, orderType, topicId }) { |
|
|
return request.get('group/comment/list', { |
|
|
return request.get('property/comment/list', { |
|
|
pageIndex, |
|
|
pageIndex, |
|
|
pageSize, |
|
|
pageSize, |
|
|
timestamp, |
|
|
timestamp, |
|
@ -177,7 +149,7 @@ export function getRemarkList({ pageIndex, pageSize, timestamp, orderType, topic |
|
|
* 评论或者回复 |
|
|
* 评论或者回复 |
|
|
*/ |
|
|
*/ |
|
|
export function remarkOrReply ({ topicId, faCommentId, content }) { |
|
|
export function remarkOrReply ({ topicId, faCommentId, content }) { |
|
|
return request.post('group/comment/submit', { |
|
|
return request.post('property/comment/submit', { |
|
|
topicId, |
|
|
topicId, |
|
|
faCommentId, |
|
|
faCommentId, |
|
|
content |
|
|
content |
|
@ -188,7 +160,7 @@ export function remarkOrReply ({ topicId, faCommentId, content }) { |
|
|
* 关闭话题 |
|
|
* 关闭话题 |
|
|
*/ |
|
|
*/ |
|
|
export function closeTopic ({ id, processingOpinions }) { |
|
|
export function closeTopic ({ id, processingOpinions }) { |
|
|
return request.post('group/topic/close', { |
|
|
return request.post('property/topic/close', { |
|
|
id, |
|
|
id, |
|
|
processingOpinions |
|
|
processingOpinions |
|
|
}) |
|
|
}) |
|
@ -205,7 +177,7 @@ export function getClassifyList () { |
|
|
* 话题转议题 |
|
|
* 话题转议题 |
|
|
*/ |
|
|
*/ |
|
|
export function changeToIssue ({ id, categoryId, advice }) { |
|
|
export function changeToIssue ({ id, categoryId, advice }) { |
|
|
return request.post('group/topic/changeToIssue', { |
|
|
return request.post('property/topic/changeToIssue', { |
|
|
id, |
|
|
id, |
|
|
categoryId, |
|
|
categoryId, |
|
|
advice |
|
|
advice |
|
@ -216,7 +188,7 @@ export function changeToIssue ({ id, categoryId, advice }) { |
|
|
* 支持/反对 表态 |
|
|
* 支持/反对 表态 |
|
|
*/ |
|
|
*/ |
|
|
export function publishStatement ({ attitude, commentId, topicId }) { |
|
|
export function publishStatement ({ attitude, commentId, topicId }) { |
|
|
return request.post('group/comment/statement', { |
|
|
return request.post('property/comment/statement', { |
|
|
attitude, |
|
|
attitude, |
|
|
commentId, |
|
|
commentId, |
|
|
topicId |
|
|
topicId |
|
@ -238,5 +210,5 @@ export function publishStatement ({ attitude, commentId, topicId }) { |
|
|
* 获取关闭原因 |
|
|
* 获取关闭原因 |
|
|
*/ |
|
|
*/ |
|
|
export function getCloseReason (topicId) { |
|
|
export function getCloseReason (topicId) { |
|
|
return request.get(`group/topic/auditRecord/${topicId}`) |
|
|
return request.get(`property/topic/auditRecord/${topicId}`) |
|
|
} |
|
|
} |