Просмотр исходного кода

[会员查询][修改]查询条件修改

release_toaliyun_real
jinguo24@163.com 7 лет назад
Родитель
Сommit
956efa5945
4 измененных файлов: 22 добавлений и 21 удалений
  1. +4
    -1
      mallinkAdmin/src/main/java/com/simple/controller/WxUserStructureController.java
  2. +12
    -12
      mallinkService/src/main/java/com/simple/domain/po/WxUserVisit.java
  3. +3
    -0
      mallinkService/src/main/resources/mapper/WxCUserMapper.xml
  4. +3
    -8
      mallinkService/src/main/resources/mapper/WxUserVisitMapper.xml

+ 4
- 1
mallinkAdmin/src/main/java/com/simple/controller/WxUserStructureController.java Просмотреть файл

@@ -42,7 +42,7 @@ import io.swagger.annotations.ApiOperation;
@RestController
@Api(description="会员洞察")
@RequestMapping("userAnalysis")
public class WxUserStructureController {
public class WxUserStructureController extends BaseController{
@Autowired
private WxCUserBasicInfoService wxCUserBasicInfoService;
@@ -58,6 +58,7 @@ public class WxUserStructureController {
Date startTime,Date endTime
) {
WxCuerBasicInfoDto dto = new WxCuerBasicInfoDto();
dto.setTenantId(getTenantId());
dto.setStartTime(startTime);
if(endTime!=null) {
Calendar c = Calendar.getInstance();
@@ -84,6 +85,7 @@ public class WxUserStructureController {
@GetMapping("/findUserAgeStructure")
public ResultData findUserAgeStructure( Date startTime,Date endTime) {
WxCuerBasicInfoDto dto = new WxCuerBasicInfoDto();
dto.setTenantId(getTenantId());
dto.setStartTime(startTime);
if(endTime!=null) {
Calendar c = Calendar.getInstance();
@@ -111,6 +113,7 @@ public class WxUserStructureController {
@GetMapping("/findUserDataCount")
public ResultData findUserCount(Date startTime,Date endTime) {
WxCuerBasicInfoDto dto = new WxCuerBasicInfoDto();
dto.setTenantId(getTenantId());
dto.setStartTime(startTime);
if(endTime!=null) {
Calendar c = Calendar.getInstance();


+ 12
- 12
mallinkService/src/main/java/com/simple/domain/po/WxUserVisit.java Просмотреть файл

@@ -39,12 +39,12 @@ public class WxUserVisit implements Serializable {
public void setIds(List<Long> ids) {
this.ids = ids;
}


/*租户ID**/
@io.swagger.annotations.ApiModelProperty(value="租户ID",name="tenantId")
/***/
@io.swagger.annotations.ApiModelProperty(value="",name="tenantId")
private String tenantId;

/*日期字符串**/
@io.swagger.annotations.ApiModelProperty(value="日期字符串",name="refDate")
private String refDate;
@@ -78,6 +78,12 @@ public class WxUserVisit implements Serializable {
/*创建时间**/
@io.swagger.annotations.ApiModelProperty(value="创建时间",name="createDate")
private Date createDate;
public String getTenantId() {
return tenantId;
}
public void setTenantId(String _tenantId) {
tenantId = _tenantId;
}
public String getRefDate() {
return refDate;
}
@@ -144,19 +150,13 @@ public class WxUserVisit implements Serializable {
public void setCreateDate(Date _createDate) {
createDate = _createDate;
}
public String getTenantId() {
return tenantId;
}

public void setTenantId(String tenantId) {
this.tenantId = tenantId;
}



public static enum Field
{
Id_ASC("`id` ASC"),Id_DESC("`id` DESC")
,TenantId_ASC("`tenantId` ASC"),TenantId_DESC("`tenantId` DESC")
,RefDate_ASC("`refDate` ASC"),RefDate_DESC("`refDate` DESC")
,DayDate_ASC("`dayDate` ASC"),DayDate_DESC("`dayDate` DESC")
,SessionCnt_ASC("`sessionCnt` ASC"),SessionCnt_DESC("`sessionCnt` DESC")


+ 3
- 0
mallinkService/src/main/resources/mapper/WxCUserMapper.xml Просмотреть файл

@@ -195,6 +195,9 @@
<if test=" null != endTime">
and create_date &lt;= #{endTime}
</if>
<if test="null != tenantId">
and tenant_id =#{tenantId}
</if>
</select>
<select id ="listByChannel" resultMap="BaseResultMap" parameterType="java.util.List">


+ 3
- 8
mallinkService/src/main/resources/mapper/WxUserVisitMapper.xml Просмотреть файл

@@ -29,12 +29,12 @@
</if>
<if test=" null != tenantId ">
and `tenant_id` like concat('%', #{tenantId},'%')
and `tenant_id` =#{tenantId}

</if>
<if test=" null != refDate ">
and `ref_date` like concat('%', #{refDate},'%')
and `ref_date` = #{refDate}
</if>
@@ -79,7 +79,7 @@
</if>
<if test=" null != appId ">
and `app_id` like concat('%', #{appId},'%')
and `app_id` = #{appId}
</if>
@@ -106,9 +106,4 @@
from wx_user_visit where tenant_id=#{tenantId} AND day_date &gt;= #{startTime} and day_date &lt;= #{endTime} order by day_date ASC
</select>
</mapper>

Загрузка…
Отмена
Сохранить