计划逻辑迁移
This commit is contained in:
		@@ -6,26 +6,7 @@ import (
 | 
			
		||||
	"git.huangwc.com/pig/pig-farm-controller/internal/app/dto"
 | 
			
		||||
	"git.huangwc.com/pig/pig-farm-controller/internal/domain/plan"
 | 
			
		||||
	"git.huangwc.com/pig/pig-farm-controller/internal/infra/logs"
 | 
			
		||||
	"git.huangwc.com/pig/pig-farm-controller/internal/infra/models"
 | 
			
		||||
	"git.huangwc.com/pig/pig-farm-controller/internal/infra/repository"
 | 
			
		||||
	"gorm.io/gorm"
 | 
			
		||||
)
 | 
			
		||||
 | 
			
		||||
var (
 | 
			
		||||
	// ErrPlanNotFound 表示未找到计划
 | 
			
		||||
	ErrPlanNotFound = errors.New("计划不存在")
 | 
			
		||||
	// ErrPlanCannotBeModified 表示计划不允许修改
 | 
			
		||||
	ErrPlanCannotBeModified = errors.New("系统计划不允许修改")
 | 
			
		||||
	// ErrPlanCannotBeDeleted 表示计划不允许删除
 | 
			
		||||
	ErrPlanCannotBeDeleted = errors.New("系统计划不允许删除")
 | 
			
		||||
	// ErrPlanCannotBeStarted 表示计划不允许手动启动
 | 
			
		||||
	ErrPlanCannotBeStarted = errors.New("系统计划不允许手动启动")
 | 
			
		||||
	// ErrPlanAlreadyEnabled 表示计划已处于启动状态
 | 
			
		||||
	ErrPlanAlreadyEnabled = errors.New("计划已处于启动状态,无需重复操作")
 | 
			
		||||
	// ErrPlanNotEnabled 表示计划未处于启动状态
 | 
			
		||||
	ErrPlanNotEnabled = errors.New("计划当前不是启用状态")
 | 
			
		||||
	// ErrPlanCannotBeStopped 表示计划不允许停止
 | 
			
		||||
	ErrPlanCannotBeStopped = errors.New("系统计划不允许停止")
 | 
			
		||||
)
 | 
			
		||||
 | 
			
		||||
// PlanService 定义了计划相关的应用服务接口
 | 
			
		||||
@@ -48,84 +29,62 @@ type PlanService interface {
 | 
			
		||||
 | 
			
		||||
// planService 是 PlanService 接口的实现
 | 
			
		||||
type planService struct {
 | 
			
		||||
	logger                  *logs.Logger
 | 
			
		||||
	planRepo                repository.PlanRepository
 | 
			
		||||
	analysisPlanTaskManager plan.AnalysisPlanTaskManager
 | 
			
		||||
	logger            *logs.Logger
 | 
			
		||||
	domainPlanService plan.Service // 替换为领域层的服务接口
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// NewPlanService 创建一个新的 PlanService 实例
 | 
			
		||||
func NewPlanService(
 | 
			
		||||
	logger *logs.Logger,
 | 
			
		||||
	planRepo repository.PlanRepository,
 | 
			
		||||
	analysisPlanTaskManager plan.AnalysisPlanTaskManager,
 | 
			
		||||
	domainPlanService plan.Service, // 接收领域层服务
 | 
			
		||||
) PlanService {
 | 
			
		||||
	return &planService{
 | 
			
		||||
		logger:                  logger,
 | 
			
		||||
		planRepo:                planRepo,
 | 
			
		||||
		analysisPlanTaskManager: analysisPlanTaskManager,
 | 
			
		||||
		logger:            logger,
 | 
			
		||||
		domainPlanService: domainPlanService, // 注入领域层服务
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// CreatePlan 创建一个新的计划
 | 
			
		||||
func (s *planService) CreatePlan(req *dto.CreatePlanRequest) (*dto.PlanResponse, error) {
 | 
			
		||||
	const actionType = "服务层:创建计划"
 | 
			
		||||
	const actionType = "应用服务层:创建计划"
 | 
			
		||||
 | 
			
		||||
	// 使用已有的转换函数,它已经包含了验证和重排逻辑
 | 
			
		||||
	// 使用 DTO 转换函数将请求转换为领域实体
 | 
			
		||||
	planToCreate, err := dto.NewPlanFromCreateRequest(req)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 计划数据校验失败: %v", actionType, err)
 | 
			
		||||
		return nil, err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// --- 业务规则处理 ---
 | 
			
		||||
	// 1. 设置计划类型:用户创建的计划永远是自定义计划
 | 
			
		||||
	planToCreate.PlanType = models.PlanTypeCustom
 | 
			
		||||
 | 
			
		||||
	// 2. 自动判断 ContentType
 | 
			
		||||
	if len(req.SubPlanIDs) > 0 {
 | 
			
		||||
		planToCreate.ContentType = models.PlanContentTypeSubPlans
 | 
			
		||||
	} else {
 | 
			
		||||
		// 如果 SubPlanIDs 未提供,则默认为 Tasks 类型(即使 Tasks 字段也未提供)
 | 
			
		||||
		planToCreate.ContentType = models.PlanContentTypeTasks
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 调用仓库方法创建计划
 | 
			
		||||
	if err := s.planRepo.CreatePlan(planToCreate); err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 数据库创建计划失败: %v", actionType, err)
 | 
			
		||||
		return nil, err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 创建成功后,调用 manager 确保触发器任务定义存在,但不立即加入待执行队列
 | 
			
		||||
	if err := s.analysisPlanTaskManager.EnsureAnalysisTaskDefinition(planToCreate.ID); err != nil {
 | 
			
		||||
		// 这是一个非阻塞性错误,我们只记录日志,因为主流程(创建计划)已经成功
 | 
			
		||||
		s.logger.Errorf("为新创建的计划 %d 确保触发器任务定义失败: %v", planToCreate.ID, err)
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 使用已有的转换函数将创建后的模型转换为响应对象
 | 
			
		||||
	resp, err := dto.NewPlanToResponse(planToCreate)
 | 
			
		||||
	// 调用领域服务创建计划
 | 
			
		||||
	createdPlan, err := s.domainPlanService.CreatePlan(planToCreate)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 序列化响应失败: %v, Plan: %+v", actionType, err, planToCreate)
 | 
			
		||||
		s.logger.Errorf("%s: 领域服务创建计划失败: %v", actionType, err)
 | 
			
		||||
		return nil, err // 直接返回领域层错误
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 将领域实体转换为响应 DTO
 | 
			
		||||
	resp, err := dto.NewPlanToResponse(createdPlan)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 序列化响应失败: %v, Plan: %+v", actionType, err, createdPlan)
 | 
			
		||||
		return nil, errors.New("计划创建成功,但响应生成失败")
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	s.logger.Infof("%s: 计划创建成功, ID: %d", actionType, planToCreate.ID)
 | 
			
		||||
	s.logger.Infof("%s: 计划创建成功, ID: %d", actionType, createdPlan.ID)
 | 
			
		||||
	return resp, nil
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// GetPlanByID 根据ID获取计划详情
 | 
			
		||||
func (s *planService) GetPlanByID(id uint) (*dto.PlanResponse, error) {
 | 
			
		||||
	const actionType = "服务层:获取计划详情"
 | 
			
		||||
	const actionType = "应用服务层:获取计划详情"
 | 
			
		||||
 | 
			
		||||
	plan, err := s.planRepo.GetPlanByID(id)
 | 
			
		||||
	// 调用领域服务获取计划
 | 
			
		||||
	plan, err := s.domainPlanService.GetPlanByID(id)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		if errors.Is(err, gorm.ErrRecordNotFound) {
 | 
			
		||||
			s.logger.Warnf("%s: 计划不存在, ID: %d", actionType, id)
 | 
			
		||||
			return nil, ErrPlanNotFound
 | 
			
		||||
		}
 | 
			
		||||
		s.logger.Errorf("%s: 数据库查询失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return nil, err
 | 
			
		||||
		s.logger.Errorf("%s: 领域服务获取计划详情失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return nil, err // 直接返回领域层错误
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 将领域实体转换为响应 DTO
 | 
			
		||||
	resp, err := dto.NewPlanToResponse(plan)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 序列化响应失败: %v, Plan: %+v", actionType, err, plan)
 | 
			
		||||
@@ -138,15 +97,19 @@ func (s *planService) GetPlanByID(id uint) (*dto.PlanResponse, error) {
 | 
			
		||||
 | 
			
		||||
// ListPlans 获取计划列表,支持过滤和分页
 | 
			
		||||
func (s *planService) ListPlans(query *dto.ListPlansQuery) (*dto.ListPlansResponse, error) {
 | 
			
		||||
	const actionType = "服务层:获取计划列表"
 | 
			
		||||
	const actionType = "应用服务层:获取计划列表"
 | 
			
		||||
 | 
			
		||||
	// 将 DTO 查询参数转换为领域层可接受的选项
 | 
			
		||||
	opts := repository.ListPlansOptions{PlanType: query.PlanType}
 | 
			
		||||
	plans, total, err := s.planRepo.ListPlans(opts, query.Page, query.PageSize)
 | 
			
		||||
 | 
			
		||||
	// 调用领域服务获取计划列表
 | 
			
		||||
	plans, total, err := s.domainPlanService.ListPlans(opts, query.Page, query.PageSize)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 数据库查询失败: %v", actionType, err)
 | 
			
		||||
		return nil, err
 | 
			
		||||
		s.logger.Errorf("%s: 领域服务获取计划列表失败: %v", actionType, err)
 | 
			
		||||
		return nil, err // 直接返回领域层错误
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 将领域实体列表转换为响应 DTO 列表
 | 
			
		||||
	planResponses := make([]dto.PlanResponse, 0, len(plans))
 | 
			
		||||
	for _, p := range plans {
 | 
			
		||||
		resp, err := dto.NewPlanToResponse(&p)
 | 
			
		||||
@@ -168,23 +131,9 @@ func (s *planService) ListPlans(query *dto.ListPlansQuery) (*dto.ListPlansRespon
 | 
			
		||||
 | 
			
		||||
// UpdatePlan 更新计划
 | 
			
		||||
func (s *planService) UpdatePlan(id uint, req *dto.UpdatePlanRequest) (*dto.PlanResponse, error) {
 | 
			
		||||
	const actionType = "服务层:更新计划"
 | 
			
		||||
 | 
			
		||||
	existingPlan, err := s.planRepo.GetBasicPlanByID(id)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		if errors.Is(err, gorm.ErrRecordNotFound) {
 | 
			
		||||
			s.logger.Warnf("%s: 计划不存在, ID: %d", actionType, id)
 | 
			
		||||
			return nil, ErrPlanNotFound
 | 
			
		||||
		}
 | 
			
		||||
		s.logger.Errorf("%s: 获取计划信息失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return nil, err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if existingPlan.PlanType == models.PlanTypeSystem {
 | 
			
		||||
		s.logger.Warnf("%s: 尝试修改系统计划, ID: %d", actionType, id)
 | 
			
		||||
		return nil, ErrPlanCannotBeModified
 | 
			
		||||
	}
 | 
			
		||||
	const actionType = "应用服务层:更新计划"
 | 
			
		||||
 | 
			
		||||
	// 使用 DTO 转换函数将请求转换为领域实体
 | 
			
		||||
	planToUpdate, err := dto.NewPlanFromUpdateRequest(req)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 计划数据校验失败: %v", actionType, err)
 | 
			
		||||
@@ -192,31 +141,14 @@ func (s *planService) UpdatePlan(id uint, req *dto.UpdatePlanRequest) (*dto.Plan
 | 
			
		||||
	}
 | 
			
		||||
	planToUpdate.ID = id // 确保ID被设置
 | 
			
		||||
 | 
			
		||||
	if len(req.SubPlanIDs) > 0 {
 | 
			
		||||
		planToUpdate.ContentType = models.PlanContentTypeSubPlans
 | 
			
		||||
	} else {
 | 
			
		||||
		planToUpdate.ContentType = models.PlanContentTypeTasks
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 只要是更新任务,就重置执行计数器
 | 
			
		||||
	planToUpdate.ExecuteCount = 0
 | 
			
		||||
	s.logger.Infof("计划 #%d 被更新,执行计数器已重置为 0。", planToUpdate.ID)
 | 
			
		||||
 | 
			
		||||
	if err := s.planRepo.UpdatePlanMetadataAndStructure(planToUpdate); err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 数据库更新计划失败: %v, Plan: %+v", actionType, err, planToUpdate)
 | 
			
		||||
		return nil, err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if err := s.analysisPlanTaskManager.EnsureAnalysisTaskDefinition(planToUpdate.ID); err != nil {
 | 
			
		||||
		s.logger.Errorf("为更新后的计划 %d 确保触发器任务定义失败: %v", planToUpdate.ID, err)
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	updatedPlan, err := s.planRepo.GetPlanByID(id)
 | 
			
		||||
	// 调用领域服务更新计划
 | 
			
		||||
	updatedPlan, err := s.domainPlanService.UpdatePlan(planToUpdate)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 获取更新后计划详情失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return nil, errors.New("获取更新后计划详情时发生内部错误")
 | 
			
		||||
		s.logger.Errorf("%s: 领域服务更新计划失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return nil, err // 直接返回领域层错误
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// 将领域实体转换为响应 DTO
 | 
			
		||||
	resp, err := dto.NewPlanToResponse(updatedPlan)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 序列化响应失败: %v, Updated Plan: %+v", actionType, err, updatedPlan)
 | 
			
		||||
@@ -229,33 +161,13 @@ func (s *planService) UpdatePlan(id uint, req *dto.UpdatePlanRequest) (*dto.Plan
 | 
			
		||||
 | 
			
		||||
// DeletePlan 删除计划(软删除)
 | 
			
		||||
func (s *planService) DeletePlan(id uint) error {
 | 
			
		||||
	const actionType = "服务层:删除计划"
 | 
			
		||||
	const actionType = "应用服务层:删除计划"
 | 
			
		||||
 | 
			
		||||
	plan, err := s.planRepo.GetBasicPlanByID(id)
 | 
			
		||||
	// 调用领域服务删除计划
 | 
			
		||||
	err := s.domainPlanService.DeletePlan(id)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		if errors.Is(err, gorm.ErrRecordNotFound) {
 | 
			
		||||
			s.logger.Warnf("%s: 计划不存在, ID: %d", actionType, id)
 | 
			
		||||
			return ErrPlanNotFound
 | 
			
		||||
		}
 | 
			
		||||
		s.logger.Errorf("%s: 获取计划信息失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if plan.PlanType == models.PlanTypeSystem {
 | 
			
		||||
		s.logger.Warnf("%s: 尝试删除系统计划, ID: %d", actionType, id)
 | 
			
		||||
		return ErrPlanCannotBeDeleted
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if plan.Status == models.PlanStatusEnabled {
 | 
			
		||||
		if err := s.planRepo.StopPlanTransactionally(id); err != nil {
 | 
			
		||||
			s.logger.Errorf("%s: 停止计划失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
			return err
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if err := s.planRepo.DeletePlan(id); err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 数据库删除失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err
 | 
			
		||||
		s.logger.Errorf("%s: 领域服务删除计划失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err // 直接返回领域层错误
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	s.logger.Infof("%s: 计划删除成功, ID: %d", actionType, id)
 | 
			
		||||
@@ -264,46 +176,13 @@ func (s *planService) DeletePlan(id uint) error {
 | 
			
		||||
 | 
			
		||||
// StartPlan 启动计划
 | 
			
		||||
func (s *planService) StartPlan(id uint) error {
 | 
			
		||||
	const actionType = "服务层:启动计划"
 | 
			
		||||
	const actionType = "应用服务层:启动计划"
 | 
			
		||||
 | 
			
		||||
	plan, err := s.planRepo.GetBasicPlanByID(id)
 | 
			
		||||
	// 调用领域服务启动计划
 | 
			
		||||
	err := s.domainPlanService.StartPlan(id)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		if errors.Is(err, gorm.ErrRecordNotFound) {
 | 
			
		||||
			s.logger.Warnf("%s: 计划不存在, ID: %d", actionType, id)
 | 
			
		||||
			return ErrPlanNotFound
 | 
			
		||||
		}
 | 
			
		||||
		s.logger.Errorf("%s: 获取计划信息失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if plan.PlanType == models.PlanTypeSystem {
 | 
			
		||||
		s.logger.Warnf("%s: 尝试手动启动系统计划, ID: %d", actionType, id)
 | 
			
		||||
		return ErrPlanCannotBeStarted
 | 
			
		||||
	}
 | 
			
		||||
	if plan.Status == models.PlanStatusEnabled {
 | 
			
		||||
		s.logger.Warnf("%s: 计划已处于启动状态,无需重复操作, ID: %d", actionType, id)
 | 
			
		||||
		return ErrPlanAlreadyEnabled
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if plan.Status != models.PlanStatusEnabled {
 | 
			
		||||
		if plan.ExecuteCount > 0 {
 | 
			
		||||
			if err := s.planRepo.UpdateExecuteCount(plan.ID, 0); err != nil {
 | 
			
		||||
				s.logger.Errorf("%s: 重置计划执行计数失败: %v, ID: %d", actionType, err, plan.ID)
 | 
			
		||||
				return err
 | 
			
		||||
			}
 | 
			
		||||
			s.logger.Infof("计划 #%d 的执行计数器已重置为 0。", plan.ID)
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		if err := s.planRepo.UpdatePlanStatus(plan.ID, models.PlanStatusEnabled); err != nil {
 | 
			
		||||
			s.logger.Errorf("%s: 更新计划状态失败: %v, ID: %d", actionType, err, plan.ID)
 | 
			
		||||
			return err
 | 
			
		||||
		}
 | 
			
		||||
		s.logger.Infof("已成功更新计划 #%d 的状态为 '已启动'。", plan.ID)
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if err := s.analysisPlanTaskManager.CreateOrUpdateTrigger(plan.ID); err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 创建或更新触发器失败: %v, ID: %d", actionType, err, plan.ID)
 | 
			
		||||
		return err
 | 
			
		||||
		s.logger.Errorf("%s: 领域服务启动计划失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err // 直接返回领域层错误
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	s.logger.Infof("%s: 计划已成功启动, ID: %d", actionType, id)
 | 
			
		||||
@@ -312,31 +191,13 @@ func (s *planService) StartPlan(id uint) error {
 | 
			
		||||
 | 
			
		||||
// StopPlan 停止计划
 | 
			
		||||
func (s *planService) StopPlan(id uint) error {
 | 
			
		||||
	const actionType = "服务层:停止计划"
 | 
			
		||||
	const actionType = "应用服务层:停止计划"
 | 
			
		||||
 | 
			
		||||
	plan, err := s.planRepo.GetBasicPlanByID(id)
 | 
			
		||||
	// 调用领域服务停止计划
 | 
			
		||||
	err := s.domainPlanService.StopPlan(id)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		if errors.Is(err, gorm.ErrRecordNotFound) {
 | 
			
		||||
			s.logger.Warnf("%s: 计划不存在, ID: %d", actionType, id)
 | 
			
		||||
			return ErrPlanNotFound
 | 
			
		||||
		}
 | 
			
		||||
		s.logger.Errorf("%s: 获取计划信息失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if plan.PlanType == models.PlanTypeSystem {
 | 
			
		||||
		s.logger.Warnf("%s: 尝试停止系统计划, ID: %d", actionType, id)
 | 
			
		||||
		return ErrPlanCannotBeStopped
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if plan.Status != models.PlanStatusEnabled {
 | 
			
		||||
		s.logger.Warnf("%s: 计划当前不是启用状态, ID: %d, Status: %s", actionType, id, plan.Status)
 | 
			
		||||
		return ErrPlanNotEnabled
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if err := s.planRepo.StopPlanTransactionally(id); err != nil {
 | 
			
		||||
		s.logger.Errorf("%s: 停止计划失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err
 | 
			
		||||
		s.logger.Errorf("%s: 领域服务停止计划失败: %v, ID: %d", actionType, err, id)
 | 
			
		||||
		return err // 直接返回领域层错误
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	s.logger.Infof("%s: 计划已成功停止, ID: %d", actionType, id)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user