| | |
| | | package com.generater; |
| | | |
| | | import org.springframework.data.annotation.Id; |
| | | import org.springframework.data.mongodb.core.mapping.Document; |
| | | import org.yeshi.utils.generater.annotation.admin.AdminController; |
| | | import org.yeshi.utils.generater.annotation.admin.DaoQueryCondition; |
| | | import org.yeshi.utils.generater.annotation.admin.Show; |
| | |
| | | import org.yeshi.utils.generater.annotation.admin.form.Text; |
| | | import org.yeshi.utils.generater.entity.admin.FormVerifyType; |
| | | |
| | | import java.util.Date; |
| | | |
| | | /** |
| | | * @author Administrator |
| | | * @title: TestEntity |
| | | * @description: 测试entity |
| | | * @date 2021/9/23 14:22 |
| | | */ |
| | | @Document(collection = "test") |
| | | @AdminController(mapping = "admin/api/test", title = "测试", searchForm = TestEntity.SearchForm.class,jsonp = true) |
| | | public class TestEntity { |
| | | @Id |
| | |
| | | @DaoQueryCondition |
| | | @Show(order = 1, title = "类型") |
| | | @Select(values = {"1:男", "2:女"}, title = "类型") |
| | | private int type; |
| | | private Integer type; |
| | | |
| | | @DaoQueryCondition |
| | | @Show(order = 2, title = "性别") |
| | | @RadioGroup(values = {"1:男", "2:女"}, title = "性别") |
| | | private int sex; |
| | | private Integer sex; |
| | | |
| | | @Show(order = 3, title = "头像", showType = Show.ShowType.IMG, imgWidth = 50, imgHeight = 50) |
| | | @Img(height = 50, title = "头像", uploadApi = "/admin/uploadimg", uploadApiParams = {"id:123123","type:2"}) |
| | |
| | | @Show(order = 4, title = "省") |
| | | @Select(values = {"cq:重庆","js:江苏"}, title = "省", apiParams = {"page:1", "pageSize:10", "id:\"test\""}) |
| | | private String province; |
| | | |
| | | @DaoQueryCondition |
| | | private Date createTime; |
| | | |
| | | private Date updateTime; |
| | | |
| | | |
| | | public String getId() { |
| | |
| | | this.nickName = nickName; |
| | | } |
| | | |
| | | public int getType() { |
| | | public Integer getType() { |
| | | return type; |
| | | } |
| | | |
| | | public void setType(int type) { |
| | | public void setType(Integer type) { |
| | | this.type = type; |
| | | } |
| | | |
| | | public int getSex() { |
| | | public Integer getSex() { |
| | | return sex; |
| | | } |
| | | |
| | | public void setSex(int sex) { |
| | | public void setSex(Integer sex) { |
| | | this.sex = sex; |
| | | } |
| | | |
| | |
| | | this.province = province; |
| | | } |
| | | |
| | | public Date getCreateTime() { |
| | | return createTime; |
| | | } |
| | | |
| | | public void setCreateTime(Date createTime) { |
| | | this.createTime = createTime; |
| | | } |
| | | |
| | | public Date getUpdateTime() { |
| | | return updateTime; |
| | | } |
| | | |
| | | public void setUpdateTime(Date updateTime) { |
| | | this.updateTime = updateTime; |
| | | } |
| | | |
| | | public class SearchForm { |
| | | |