家族列表增加我的家族权限
This commit is contained in:
parent
f4f315bc08
commit
263e2834ea
@ -5,6 +5,7 @@ import com.red.circle.other.infra.database.rds.dao.task.SpinsTaskConfigDAO;
|
|||||||
import com.red.circle.other.infra.database.rds.dao.task.SpinsUserTaskProgressDAO;
|
import com.red.circle.other.infra.database.rds.dao.task.SpinsUserTaskProgressDAO;
|
||||||
import com.red.circle.other.infra.database.rds.entity.task.SpinsTaskConfig;
|
import com.red.circle.other.infra.database.rds.entity.task.SpinsTaskConfig;
|
||||||
import com.red.circle.other.infra.database.rds.entity.task.SpinsUserTaskProgress;
|
import com.red.circle.other.infra.database.rds.entity.task.SpinsUserTaskProgress;
|
||||||
|
import com.red.circle.tool.core.date.ZonedDateTimeAsiaRiyadhUtils;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
@ -144,7 +145,7 @@ public class SpinsTaskProgressIncrementExe {
|
|||||||
* 获取当前周期key
|
* 获取当前周期key
|
||||||
*/
|
*/
|
||||||
private String getCurrentCycleKey(Integer cycleType) {
|
private String getCurrentCycleKey(Integer cycleType) {
|
||||||
LocalDate now = LocalDate.now();
|
LocalDate now = ZonedDateTimeAsiaRiyadhUtils.now().toLocalDate();
|
||||||
if (cycleType == 1) {
|
if (cycleType == 1) {
|
||||||
// 每日任务:格式 yyyyMMdd
|
// 每日任务:格式 yyyyMMdd
|
||||||
return now.format(DateTimeFormatter.ofPattern("yyyyMMdd"));
|
return now.format(DateTimeFormatter.ofPattern("yyyyMMdd"));
|
||||||
|
|||||||
@ -6,6 +6,7 @@ import com.red.circle.other.infra.database.rds.dao.task.SpinsTaskConfigDAO;
|
|||||||
import com.red.circle.other.infra.database.rds.dao.task.SpinsUserTaskProgressDAO;
|
import com.red.circle.other.infra.database.rds.dao.task.SpinsUserTaskProgressDAO;
|
||||||
import com.red.circle.other.infra.database.rds.entity.task.SpinsTaskConfig;
|
import com.red.circle.other.infra.database.rds.entity.task.SpinsTaskConfig;
|
||||||
import com.red.circle.other.infra.database.rds.entity.task.SpinsUserTaskProgress;
|
import com.red.circle.other.infra.database.rds.entity.task.SpinsUserTaskProgress;
|
||||||
|
import com.red.circle.tool.core.date.ZonedDateTimeAsiaRiyadhUtils;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
@ -146,7 +147,7 @@ public class SpinsTaskProgressUpdateExe {
|
|||||||
* 获取当前周期key
|
* 获取当前周期key
|
||||||
*/
|
*/
|
||||||
private String getCurrentCycleKey(Integer cycleType) {
|
private String getCurrentCycleKey(Integer cycleType) {
|
||||||
LocalDate now = LocalDate.now();
|
LocalDate now = ZonedDateTimeAsiaRiyadhUtils.now().toLocalDate();
|
||||||
if (cycleType == 1) {
|
if (cycleType == 1) {
|
||||||
// 每日任务:格式 yyyyMMdd
|
// 每日任务:格式 yyyyMMdd
|
||||||
return now.format(DateTimeFormatter.ofPattern("yyyyMMdd"));
|
return now.format(DateTimeFormatter.ofPattern("yyyyMMdd"));
|
||||||
|
|||||||
@ -117,6 +117,8 @@ public class FamilyHomeListExe {
|
|||||||
List<ActiveVoiceRoom> onlineRooms = activeVoiceRoomService.listByFamilyId(family.getId(), 30);
|
List<ActiveVoiceRoom> onlineRooms = activeVoiceRoomService.listByFamilyId(family.getId(), 30);
|
||||||
List<FamilyHomeRoomCO> roomCOs = buildRoomCOs(onlineRooms);
|
List<FamilyHomeRoomCO> roomCOs = buildRoomCOs(onlineRooms);
|
||||||
|
|
||||||
|
FamilyMemberInfo myFamilyInfo = familyMemberInfoService.getFamilyMemberByUserId(cmd.getReqUserId());
|
||||||
|
|
||||||
return new FamilyHomeListCO()
|
return new FamilyHomeListCO()
|
||||||
.setFamilyId(family.getId())
|
.setFamilyId(family.getId())
|
||||||
.setFamilyName(family.getFamilyName())
|
.setFamilyName(family.getFamilyName())
|
||||||
@ -130,6 +132,7 @@ public class FamilyHomeListExe {
|
|||||||
.setAvatarFrameCover(levelDetails.getAvatarFrameCover())
|
.setAvatarFrameCover(levelDetails.getAvatarFrameCover())
|
||||||
.setAvatarFrameSvg(levelDetails.getAvatarFrameSvg())
|
.setAvatarFrameSvg(levelDetails.getAvatarFrameSvg())
|
||||||
.setDisplayMembers(displayMembers)
|
.setDisplayMembers(displayMembers)
|
||||||
|
.setMyFamilyRole(Optional.ofNullable(myFamilyInfo).map(FamilyMemberInfo::getMemberRole).orElse(null))
|
||||||
.setOnlineRooms(roomCOs);
|
.setOnlineRooms(roomCOs);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -82,4 +82,10 @@ public class FamilyHomeListCO implements Serializable {
|
|||||||
*/
|
*/
|
||||||
private List<FamilyHomeRoomCO> onlineRooms;
|
private List<FamilyHomeRoomCO> onlineRooms;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 我的家族权限
|
||||||
|
*/
|
||||||
|
private String myFamilyRole;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user