|
|
@@ -21,6 +21,8 @@ import java.util.Map;
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
/**
|
|
|
+ * 用户在项目的配置 管理服务
|
|
|
+ *
|
|
|
* @author TRX
|
|
|
* @date 2024/11/26
|
|
|
*/
|
|
|
@@ -62,11 +64,7 @@ public class ProjectUserConfigService extends SuperService {
|
|
|
List<ProjectUserConfig> list = getUserProjectConfigs(userId, projectId, keys);
|
|
|
Map<String, Object> tempMap = new HashMap<>();
|
|
|
if (ObjectUtils.isNotEmpty(list)) {
|
|
|
- tempMap = list.stream().collect(Collectors.toMap(
|
|
|
- it -> it.getKey(),
|
|
|
- it -> it.getData(),
|
|
|
- (v1, v2) -> v1
|
|
|
- ));
|
|
|
+ tempMap = list.stream().collect(Collectors.toMap(it -> it.getKey(), it -> it.getData(), (v1, v2) -> v1));
|
|
|
}
|
|
|
for (String key : keys) {
|
|
|
if (tempMap.containsKey(key)) {
|
|
|
@@ -78,6 +76,25 @@ public class ProjectUserConfigService extends SuperService {
|
|
|
return map;
|
|
|
}
|
|
|
|
|
|
+ //-------------------------------保存配置 start-----------------------
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 标记完成绑定卡片
|
|
|
+ *
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public ResultContent isFinishBindCard() {
|
|
|
+ return saveUserConfig(UserProjectTaskConfig.userBindCardKey, Boolean.TRUE);
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 标记完成开通无感支付
|
|
|
+ *
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public ResultContent isOpenUnPay() {
|
|
|
+ return saveUserConfig(UserProjectTaskConfig.userOpenUnconsciousPayment, Boolean.TRUE);
|
|
|
+ }
|
|
|
|
|
|
public ResultContent saveUserConfig(String key, Object data) {
|
|
|
ProjectUserConfigParam param = new ProjectUserConfigParam();
|