Showing
3 changed files
with
15 additions
and
4 deletions
@@ -92,7 +92,7 @@ public class ChannelUserServiceImpl implements IChannelUserService, IBusinessExp | @@ -92,7 +92,7 @@ public class ChannelUserServiceImpl implements IChannelUserService, IBusinessExp | ||
92 | 92 | ||
93 | protected static Map<String, Object> getCondition(ChannelUserRequest request) { | 93 | protected static Map<String, Object> getCondition(ChannelUserRequest request) { |
94 | Map<String, Object> condition = Maps.newHashMap(); | 94 | Map<String, Object> condition = Maps.newHashMap(); |
95 | - condition.put("channelSource", request.getChannelSource()); | 95 | + condition.put("channelSource", StringUtils.isBlank(request.getChannelSource())? null: request.getChannelSource().split(",")); |
96 | condition.put("channelOrderCode", request.getChannelOrderCode()); | 96 | condition.put("channelOrderCode", request.getChannelOrderCode()); |
97 | condition.put("beginChannelOrderTime", request.getBeginChannelOrderTime()); | 97 | condition.put("beginChannelOrderTime", request.getBeginChannelOrderTime()); |
98 | condition.put("endChannelOrderTime", request.getEndChannelOrderTime()); | 98 | condition.put("endChannelOrderTime", request.getEndChannelOrderTime()); |
@@ -263,7 +263,10 @@ | @@ -263,7 +263,10 @@ | ||
263 | <trim prefix="where" prefixOverrides="and | or"> | 263 | <trim prefix="where" prefixOverrides="and | or"> |
264 | 1 = 1 | 264 | 1 = 1 |
265 | <if test="condition.channelSource != null"> | 265 | <if test="condition.channelSource != null"> |
266 | - AND channel_source = #{condition.channelSource} | 266 | + and channel_source in |
267 | + <foreach item="item" index="index" collection="condition.channelSource" open="(" separator="," close=")"> | ||
268 | + #{item} | ||
269 | + </foreach> | ||
267 | </if> | 270 | </if> |
268 | <if test="condition.channelOrderCode != null"> | 271 | <if test="condition.channelOrderCode != null"> |
269 | AND channel_order_code like CONCAT('%', #{condition.channelOrderCode}, '%') | 272 | AND channel_order_code like CONCAT('%', #{condition.channelOrderCode}, '%') |
@@ -21,9 +21,10 @@ | @@ -21,9 +21,10 @@ | ||
21 | <input id="channelSourceCombobox" name="channelSource" class="easyui-combobox" data-options=" | 21 | <input id="channelSourceCombobox" name="channelSource" class="easyui-combobox" data-options=" |
22 | valueField: 'id', | 22 | valueField: 'id', |
23 | editable: false, | 23 | editable: false, |
24 | + multiple: true, | ||
24 | textField: 'text', | 25 | textField: 'text', |
26 | + prompt:'选择泛渠道来源', | ||
25 | data: [ | 27 | data: [ |
26 | - { id: '', text: '选择泛渠道来源' }, | ||
27 | { id: '5', text: '淘宝B店订单' }, | 28 | { id: '5', text: '淘宝B店订单' }, |
28 | { id: '8', text: '淘宝C店订单' }, | 29 | { id: '8', text: '淘宝C店订单' }, |
29 | { id: '9', text: '淘宝LAL店订单' }, | 30 | { id: '9', text: '淘宝LAL店订单' }, |
@@ -228,11 +229,18 @@ | @@ -228,11 +229,18 @@ | ||
228 | 229 | ||
229 | function getParams() { | 230 | function getParams() { |
230 | var paramsArray = $("#searchForm").serializeArray(); | 231 | var paramsArray = $("#searchForm").serializeArray(); |
231 | - console.log(paramsArray); | ||
232 | var params = {}; | 232 | var params = {}; |
233 | + var channelSource = ""; | ||
233 | for (var i = 0; i < paramsArray.length; i++ ) { | 234 | for (var i = 0; i < paramsArray.length; i++ ) { |
235 | + if (paramsArray[i].name == "channelSource") { | ||
236 | + channelSource += paramsArray[i].value + ","; | ||
237 | + } else { | ||
234 | params[paramsArray[i].name] = paramsArray[i].value; | 238 | params[paramsArray[i].name] = paramsArray[i].value; |
235 | } | 239 | } |
240 | + } | ||
241 | + if (channelSource.length != 0) { | ||
242 | + params["channelSource"] = channelSource.substring(0, channelSource.length -1); | ||
243 | + } | ||
236 | return params; | 244 | return params; |
237 | } | 245 | } |
238 | 246 |
-
Please register or login to post a comment