This commit is contained in:
张良(004796)
2024-01-23 16:20:40 +08:00
parent c0ef9da677
commit 5254dce420
3 changed files with 7 additions and 8 deletions

View File

@@ -81,7 +81,7 @@ public class SettingAppController {
return R.ok(new AgreementDTO(userAgreement));
}
@GetMapping("/agreement/user")
@GetMapping("/agreement/anchorJoin")
@Operation(summary = "用户主播入驻协议")
@Log(title = "用户主播入驻协议", businessType = BusinessType.OTHER, isSaveDb = false)
public R<AgreementDTO> anchorJoinAgreement() {

View File

@@ -1,14 +1,12 @@
package com.ruoyi.cai.domain;
import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;
import java.math.BigDecimal;
import com.ruoyi.common.core.domain.BaseEntity;
/**
* 青少年模式对象 cai_adolescent
@@ -25,11 +23,11 @@ public class Adolescent implements Serializable {
/**
* ID
*/
@TableId(value = "id",type = IdType.AUTO)
private Long id;
/**
* 用户user_id
*/
@TableId(value = "user_id")
private Long userId;
/**
* 青少年模式密码

View File

@@ -40,6 +40,7 @@ public class AdolescentServiceImpl extends ServiceImpl<AdolescentMapper,Adolesce
Adolescent adolescent = this.getByUserId(userId);
if(adolescent == null){
adolescent = new Adolescent();
adolescent.setUserId(userId);
}
adolescent.setOpen(1);
adolescent.setPassword(BCrypt.hashpw(setting.getPassword()));