123
This commit is contained in:
@@ -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() {
|
||||
|
||||
@@ -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;
|
||||
/**
|
||||
* 青少年模式密码
|
||||
|
||||
@@ -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()));
|
||||
|
||||
Reference in New Issue
Block a user