@@ -5,6 +5,7 @@ import com.iformall.common.ResultData; | |||||
import com.iformall.domain.po.base.BaseEntity; | import com.iformall.domain.po.base.BaseEntity; | ||||
import com.iformall.domain.po.sm.MouldPatch; | import com.iformall.domain.po.sm.MouldPatch; | ||||
import com.iformall.domain.po.sm.MouldPatchSign; | import com.iformall.domain.po.sm.MouldPatchSign; | ||||
import com.iformall.enums.EnumColour; | |||||
import com.iformall.enums.EnumMouldSendType; | import com.iformall.enums.EnumMouldSendType; | ||||
import com.iformall.enums.EnumaMouldPatchStatus; | import com.iformall.enums.EnumaMouldPatchStatus; | ||||
import com.iformall.service.sm.MouldPatchService; | import com.iformall.service.sm.MouldPatchService; | ||||
@@ -61,6 +62,9 @@ public class MouldPatchController extends BaseController { | |||||
List<MouldPatchSign> signList = mouldPatchSignService.getList(signQ); | List<MouldPatchSign> signList = mouldPatchSignService.getList(signQ); | ||||
mouldPatch.setMouldPatchSign(signList); | mouldPatch.setMouldPatchSign(signList); | ||||
} | } | ||||
if(mouldPatch.getColour() != null){ | |||||
mouldPatch.setColourStr(EnumColour.getEnum(mouldPatch.getColour()).getMessage()); | |||||
} | |||||
return new ResultData(mouldPatch); | return new ResultData(mouldPatch); | ||||
} | } | ||||
@@ -60,6 +60,9 @@ public class MouldPatch extends TenantEntity { | |||||
@io.swagger.annotations.ApiModelProperty(value="EnumColour",name="colour") | @io.swagger.annotations.ApiModelProperty(value="EnumColour",name="colour") | ||||
private Integer colour; | private Integer colour; | ||||
@TableField(exist = false) | |||||
private String colourStr; | |||||
@io.swagger.annotations.ApiModelProperty(value="标签",name="sceneSign") | @io.swagger.annotations.ApiModelProperty(value="标签",name="sceneSign") | ||||
private String sceneSign; | private String sceneSign; | ||||
@@ -19,6 +19,15 @@ public enum EnumColour { | |||||
private Integer code; | private Integer code; | ||||
private String message; | private String message; | ||||
public static EnumColour getEnum(Integer code) { | |||||
for (EnumColour value : values()) { | |||||
if (value.getCode().equals(code)) { | |||||
return value; | |||||
} | |||||
} | |||||
return null; | |||||
} | |||||
public String getMessage() { | public String getMessage() { | ||||
@@ -58,7 +58,7 @@ public class UserMouldVideoServiceImpl implements UserMouldVideoService { | |||||
record.setUpdateDate(now); | record.setUpdateDate(now); | ||||
userMouldVideoMapper.updateById(record); | userMouldVideoMapper.updateById(record); | ||||
} | } | ||||
return new ResultData(); | |||||
return new ResultData(record); | |||||
} | } | ||||
@Override | @Override | ||||
@@ -120,7 +120,7 @@ | |||||
select | select | ||||
`id``type`, `cover_img`, `cover_picture`, | `id``type`, `cover_img`, `cover_picture`, | ||||
`title`, `sub_title`, `sex`, `age`, `colour`, `scene_sign`, `sale_price`, `price`, | `title`, `sub_title`, `sex`, `age`, `colour`, `scene_sign`, `sale_price`, `price`, | ||||
`send_type`, `status`, `create_date`, `update_date` | |||||
`send_type`, `mould_path`, `status`, `create_date`, `update_date` | |||||
from mould_patch | from mould_patch | ||||
<include refid="dynamicWhereConditions"/> | <include refid="dynamicWhereConditions"/> | ||||
</select> | </select> | ||||
@@ -113,7 +113,7 @@ | |||||
<select id="findVideo" parameterType="java.util.HashMap" resultMap="BaseResultMap"> | <select id="findVideo" parameterType="java.util.HashMap" resultMap="BaseResultMap"> | ||||
select | select | ||||
`video_id`, `video_path`, `video_time`,`video_status` | |||||
`video_id`, `video_path`, `video_time`,`video_status`,`video_msg` | |||||
from user_mould_video | from user_mould_video | ||||
where `id` = #{id} | where `id` = #{id} | ||||
</select> | </select> | ||||