Commit 9a48edb6 by 李秋伟

Merge branch 'dev' into 'master'

Dev

See merge request mall/arch/matrix!18
parents 6870379d b55f0852
......@@ -46,9 +46,22 @@
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<scope>provided</scope>
<optional>true</optional>
</dependency>
</dependencies>
......
......@@ -23,6 +23,7 @@ public class BeanUtil extends BeanUtils {
return ArrayUtils.contains(arr, obj);
}
public static <T> Object getFieldValueByName(T obj, String fieldName) throws Exception {
Class clazz = obj.getClass();
Field field = clazz.getDeclaredField(fieldName);
......
......@@ -5,8 +5,9 @@ import java.util.Map;
import java.util.Set;
/**
* Created by liumingming on 2018/6/13.
* 推荐使用CollectionUtil相关方法
*/
@Deprecated
public class ObjectUtils {
/**
......
package com.secoo.mall.common.util.response;
import com.secoo.mall.common.constant.CommonConstant;
import com.secoo.mall.common.core.bean.BizResponse;
import com.secoo.mall.common.core.bean.Response;
import com.secoo.mall.common.core.exception.BusinessException;
......@@ -21,4 +22,16 @@ public interface ResponseUtil {
return response;
}
/**
* 业务BizResponse处理
*
* @param data
* @param <T>
* @return
*/
static <T> BizResponse getSuccessBizResponse(T data) {
BizResponse response = new BizResponse(CommonConstant.Success.CODE, CommonConstant.Success.MSG);
response.setData(data);
return response;
}
}
package com.secoo.mall.web.util;
package com.secoo.mall.common.util.web;
import org.springframework.web.context.request.RequestAttributes;
import org.springframework.web.context.request.RequestContextHolder;
......
......@@ -210,6 +210,23 @@
</exclusion>
</exclusions>
</dependency>
<!--zookeeper-->
<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-dependencies-zookeeper</artifactId>
<version>${dubbo.version}</version>
<type>pom</type>
<exclusions>
<exclusion>
<artifactId>log4j</artifactId>
<groupId>log4j</groupId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</exclusion>
</exclusions>
</dependency>
<!--rocketmq-->
<dependency>
<groupId>org.apache.rocketmq</groupId>
......
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