Authored by Lixiaodi

鉴定服务排除品牌等

... ... @@ -33,6 +33,8 @@ public class Brand implements Serializable {
private String searchShowImage;
private String exRaise;
public Integer getId() {
return id;
}
... ... @@ -121,6 +123,14 @@ public class Brand implements Serializable {
this.brandNameCn = brandNameCn;
}
public String getExRaise() {
return exRaise;
}
public void setExRaise(String exRaise) {
this.exRaise = exRaise;
}
@Override
public String toString() {
return "Brand{" +
... ...
... ... @@ -14,15 +14,16 @@
<result property="createTime" column="create_time"/>
<result property="editPid" column="edit_pid"/>
<result property="search_show_image" column="searchShowImage"/>
<result property="ex_raise" column="exRaise"/>
</resultMap>
<sql id="queryColumns">
id, brand_name, brand_name_cn, brand_name_en, brand_logo, brand_search, status, create_time, search_show_image
id, brand_name, brand_name_cn, brand_name_en, brand_logo, brand_search, status, create_time, search_show_image,ex_raise
</sql>
<insert id="insertBrand" parameterType="com.yoho.ufo.model.brand.Brand">
insert into brand(id, brand_name, brand_name_cn, brand_name_en, brand_logo, search_show_image, brand_search, status, create_time, edit_time, edit_pid)
values (#{id}, #{brandName},#{brandNameCn}, #{brandNameEn}, #{brandLogo}, #{searchShowImage}, #{brandSearch}, #{status}, #{createTime}, #{editTime}, #{editPid})
insert into brand(id, brand_name, brand_name_cn, brand_name_en, brand_logo, search_show_image, brand_search, status, create_time, edit_time, edit_pid,ex_raise)
values (#{id}, #{brandName},#{brandNameCn}, #{brandNameEn}, #{brandLogo}, #{searchShowImage}, #{brandSearch}, #{status}, #{createTime}, #{editTime}, #{editPid}, #{exRaise})
</insert>
<update id="updateBrandStatus" parameterType="com.yoho.ufo.model.brand.Brand">
... ... @@ -56,6 +57,9 @@
<if test="brand.editPid != null">
edit_pid = #{brand.editPid},
</if>
<if test="brand.exRaise != null">
ex_raise = #{brand.exRaise},
</if>
brand_search = #{brand.brandSearch},
search_show_image = #{brand.searchShowImage}
</set>
... ...
... ... @@ -40,6 +40,7 @@ public class BrandServiceImpl implements IBrandService {
brand.setEditPid(getUserId());
brand.setBrandLogo(ImagesHelper.getImageRelativeUrl(brand.getBrandLogo(), ImagesConstant.BUCKET_BRAND_LOGO));
brand.setSearchShowImage(ImagesHelper.getImageRelativeUrl(brand.getSearchShowImage(), ImagesConstant.BUCKET_SEARCH_SHOW_IMAGE));
brand.setExRaise(brandRequestBo.getExRaise());
if (brand.getId() == null || brand.getId() == 0) {
// 默认开启状态
brand.setStatus(1);
... ... @@ -84,6 +85,7 @@ public class BrandServiceImpl implements IBrandService {
brandResponseBo.setCreateTime(DateUtil.getDateStrBySecond(brand.getCreateTime(), DateUtil.DATE_TIME_FORMAT));
brandResponseBo.setBrandLogo(ImagesHelper.getImageAbsoluteUrl(brand.getBrandLogo(), ImagesConstant.BUCKET_BRAND_LOGO));
brandResponseBo.setSearchShowImage(ImagesHelper.getImageAbsoluteUrl(brand.getSearchShowImage(), ImagesConstant.BUCKET_SEARCH_SHOW_IMAGE));
brandResponseBo.setExRaise(brand.getExRaise());
return brandResponseBo;
}
... ...
... ... @@ -54,6 +54,13 @@
<div style="color: #ab1e1e;margin-top: 0px">*多个搜索词中间用英文逗号分隔</div>
</td>
</tr>
<tr style="line-height: 0px">
<td width="20%">实物鉴定是否排除该品牌</td>
<td width="50%">
<input type="radio" name="exRaise" value="1"> 排除
<input type="radio" name="exRaise" value="0" checked>不排除
</td>
</tr>
</table>
</div>
</form>
... ... @@ -146,6 +153,7 @@
$("#brandEditForm").form("load", data.data);
$("#brandEditForm #brandLogoUpload").imageUpload("setValue", data.data.brandLogo);
$("#brandEditForm #searchShowImageUpload").imageUpload("setValue", data.data.searchShowImage);
$(":radio[name='exRaise'][value='" + data.data.exRaise + "']").prop("checked", "checked");
});
}
});
... ...