Commit 75772f04 by guojuxing

页面装修调整:页面背景颜色字段改为字符串

parent 5d7f0822
......@@ -36,7 +36,7 @@ public class AppletCustomPageDTO implements Serializable{
/**
* 背景颜色 1:灰色 2:白色 ,默认灰色(会员中心页面、积分服务页面、自定义页面、商城装首页 有该设置)
*/
private Integer backgroundColor;
private String backgroundColor;
/**
* 1:自定义 2:会员中心,3:客服页面
......@@ -173,11 +173,11 @@ public class AppletCustomPageDTO implements Serializable{
this.componentStr = componentStr;
}
public Integer getBackgroundColor() {
public String getBackgroundColor() {
return backgroundColor;
}
public AppletCustomPageDTO setBackgroundColor(Integer backgroundColor) {
public AppletCustomPageDTO setBackgroundColor(String backgroundColor) {
this.backgroundColor = backgroundColor;
return this;
}
......
......@@ -27,9 +27,9 @@ public class TabAppletCustomPage {
private Integer entryCondition;
/**
* 背景颜色 1:灰色 2:白色 ,默认灰色(会员中心页面、积分服务页面、自定义页面、商城装首页 有该设置)
* 背景颜色 灰色 白色 ,默认灰色(会员中心页面、积分服务页面、自定义页面、商城装首页 有该设置)
*/
private Integer backgroundColor;
private String backgroundColor;
/**
* 1:自定义 2:会员卡 3:积分 4:特权 5:集团 6:会员中心,7:客服页面,8:积分服务页
......@@ -154,11 +154,11 @@ public class TabAppletCustomPage {
this.setting = setting;
}
public Integer getBackgroundColor() {
public String getBackgroundColor() {
return backgroundColor;
}
public TabAppletCustomPage setBackgroundColor(Integer backgroundColor) {
public TabAppletCustomPage setBackgroundColor(String backgroundColor) {
this.backgroundColor = backgroundColor;
return this;
}
......
......@@ -91,13 +91,10 @@ public class AppletCustomPageApiServiceImpl implements AppletCustomPageApiServic
return ServiceResponse.failure(ErrorCode.PARAMETER_ERROR.getCode(), "页面类型错误");
}
Integer backgroundColor = jsonObject.getInteger("backgroundColor");
String backgroundColor = jsonObject.getString("backgroundColor");
if (AppletPageTypeEnum.hasBackgroundColor(pageType)) {
if (backgroundColor == null) {
backgroundColor = 1;
}
if (backgroundColor.intValue() != 1 && backgroundColor.intValue() != 2) {
return ServiceResponse.failure(ErrorCode.PARAMETER_ERROR.getCode(), "页面背景值非法");
backgroundColor = "#A9A9A9";
}
} else {
//其他页面默认设置null
......
......@@ -6,7 +6,7 @@
<result column="enterprise_id" jdbcType="INTEGER" property="enterpriseId" />
<result column="title" jdbcType="VARCHAR" property="title" />
<result column="entry_condition" jdbcType="INTEGER" property="entryCondition" />
<result column="background_color" jdbcType="INTEGER" property="backgroundColor" />
<result column="background_color" jdbcType="VARCHAR" property="backgroundColor" />
<result column="page_type" jdbcType="INTEGER" property="pageType" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="app_type" jdbcType="INTEGER" property="appType" />
......@@ -42,7 +42,7 @@
app_id, create_time, update_time,
setting)
values (#{pageId,jdbcType=INTEGER}, #{enterpriseId,jdbcType=INTEGER}, #{title,jdbcType=VARCHAR},
#{entryCondition,jdbcType=INTEGER}, #{backgroundColor,jdbcType=INTEGER}, #{pageType,jdbcType=INTEGER},
#{entryCondition,jdbcType=INTEGER}, #{backgroundColor,jdbcType=VARCHAR}, #{pageType,jdbcType=INTEGER},
#{status,jdbcType=INTEGER}, #{appType,jdbcType=INTEGER},
#{appId,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP},
#{setting,jdbcType=LONGVARCHAR})
......@@ -101,7 +101,7 @@
#{entryCondition,jdbcType=INTEGER},
</if>
<if test="backgroundColor != null">
#{backgroundColor,jdbcType=INTEGER},
#{backgroundColor,jdbcType=VARCHAR},
</if>
<if test="pageType != null">
#{pageType,jdbcType=INTEGER},
......@@ -139,7 +139,7 @@
entry_condition = #{entryCondition,jdbcType=INTEGER},
</if>
<if test="backgroundColor != null">
background_color = #{backgroundColor,jdbcType=INTEGER},
background_color = #{backgroundColor,jdbcType=VARCHAR},
</if>
<if test="pageType != null">
page_type = #{pageType,jdbcType=INTEGER},
......@@ -170,7 +170,7 @@
set enterprise_id = #{enterpriseId,jdbcType=INTEGER},
title = #{title,jdbcType=VARCHAR},
entry_condition = #{entryCondition,jdbcType=INTEGER},
background_color = #{backgroundColor,jdbcType=INTEGER},
background_color = #{backgroundColor,jdbcType=VARCHAR},
page_type = #{pageType,jdbcType=INTEGER},
status = #{status,jdbcType=INTEGER},
app_type = #{appType,jdbcType=INTEGER},
......@@ -185,7 +185,7 @@
set enterprise_id = #{enterpriseId,jdbcType=INTEGER},
title = #{title,jdbcType=VARCHAR},
entry_condition = #{entryCondition,jdbcType=INTEGER},
background_color = #{backgroundColor,jdbcType=INTEGER},
background_color = #{backgroundColor,jdbcType=VARCHAR},
page_type = #{pageType,jdbcType=INTEGER},
status = #{status,jdbcType=INTEGER},
app_type = #{appType,jdbcType=INTEGER},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment