package org.springblade.gateway.common_gateway.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.DecimalMin;
import java.math.BigDecimal;
import java.util.List;

/**
 * @Author: Silent
 * @Description
 * @Date: Created in 16:54 2021/11/9
 * @Modified By:
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@ApiModel("活动设置")
public class ActiveSettingDto {
	@ApiModelProperty("主页标题")
	private String indexTitle;

	@ApiModelProperty("功能按钮")
	private List<ImageItem> functionItemList;

	@ApiModelProperty("主页轮播图")
	private List<ImageItem> indexImageList;

	@ApiModelProperty("授权标题")
	private String cmccAuthTitle;

	@ApiModelProperty("授权内容")
	private String cmccAuthContent;

	@ApiModelProperty("默认的活动ID")
	@DecimalMin("0")
	private Long defaultActiveId;

	@ApiModelProperty("热力值/票")
	@DecimalMin("0")
	private BigDecimal voteAndHeatRate;

	@ApiModelProperty("普法积分值/票")
	@DecimalMin("0")
	private BigDecimal voteAndPointRate;

	@ApiModelProperty("排行显示总数")
	private Long rankTotal;

	@ApiModelProperty("我的作品图片")
	private String myProductImage;

	@ApiModelProperty("助力说明")
	private List<String> helpExplainList;

	@ApiModel("功能按钮")
	@Data
	@AllArgsConstructor
	@NoArgsConstructor
	public static class ImageItem{
		@ApiModelProperty("图片地址")
		private String url;

		@ApiModelProperty("类型")
		private String type;

		@ApiModelProperty("需要跳转的地址")
		private String path;
	}

	@ApiModel("轮播图选项")
	@Data
	@AllArgsConstructor
	@NoArgsConstructor
	public static class FunctionItem {
		@ApiModelProperty("图片地址")
		private String icon;

		@ApiModelProperty("名称")
		private String name;

		@ApiModelProperty("需要跳转的地址")
		private String path;

		@ApiModelProperty("是否展示")
		private String show;
	}
}
