Commit 20efa4e0 by 水库浪子

客户轨迹相关接口提交

1 parent 2d183fb7
...@@ -70,8 +70,8 @@ public class WeCommunityNewGroupController extends BaseController { ...@@ -70,8 +70,8 @@ public class WeCommunityNewGroupController extends BaseController {
@ApiOperation(value = "获取新客自动拉群详细信息", httpMethod = "GET") @ApiOperation(value = "获取新客自动拉群详细信息", httpMethod = "GET")
@PreAuthorize("@ss.hasPermi('wecom:communityNewGroup:query')") @PreAuthorize("@ss.hasPermi('wecom:communityNewGroup:query')")
@GetMapping(value = "/{id}") @GetMapping(value = "/{id}")
public AjaxResult<WeCommunityNewGroupVo> getInfo(@PathVariable("newGroupId") @ApiParam("主键ID") Long newGroupId) { public AjaxResult<WeCommunityNewGroupVo> getInfo(@PathVariable("newGroupId") @ApiParam("主键ID") String newGroupId) {
return AjaxResult.success(weCommunityNewGroupService.selectWeCommunityNewGroupById(newGroupId)); return AjaxResult.success(weCommunityNewGroupService.selectWeCommunityNewGroupById(new Long(newGroupId)));
} }
/** /**
......
package com.linkwechat.web.controller.wecom; package com.linkwechat.web.controller.wecom;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.linkwechat.common.constant.Constants;
import com.linkwechat.common.core.controller.BaseController; import com.linkwechat.common.core.controller.BaseController;
import com.linkwechat.common.core.domain.AjaxResult; import com.linkwechat.common.core.domain.AjaxResult;
import com.linkwechat.common.core.page.TableDataInfo; import com.linkwechat.common.core.page.TableDataInfo;
...@@ -151,16 +152,62 @@ public class WeCustomerPortraitController extends BaseController { ...@@ -151,16 +152,62 @@ public class WeCustomerPortraitController extends BaseController {
*/ */
@GetMapping(value = "/findTrajectory") @GetMapping(value = "/findTrajectory")
public TableDataInfo findTrajectory(Integer trajectoryType){ public TableDataInfo findTrajectory(Integer trajectoryType){
startPage(); startPage();
return getDataTable( return getDataTable(
iWeCustomerTrajectoryService.list(new LambdaQueryWrapper<WeCustomerTrajectory>() iWeCustomerTrajectoryService.list(new LambdaQueryWrapper<WeCustomerTrajectory>()
.eq(WeCustomerTrajectory::getTrajectoryType,trajectoryType)) .eq(WeCustomerTrajectory::getTrajectoryType,trajectoryType)
.ne(WeCustomerTrajectory::getStatus,Constants.DELETE_CODE))
); );
} }
/**
* 添加或编辑轨迹
* @param trajectory
* @return
*/
@PostMapping(value = "/addOrEditWaitHandle")
public AjaxResult addOrEditWaitHandle(@RequestBody WeCustomerTrajectory trajectory){
iWeCustomerTrajectoryService.saveOrUpdate(trajectory);
return AjaxResult.success();
}
/**
* 删除轨迹
* @param trajectoryId
* @return
*/
@DeleteMapping(value = "/removeTrajectory/{trajectoryId}")
public AjaxResult removeTrajectory(@PathVariable String trajectoryId){
iWeCustomerTrajectoryService.updateById(WeCustomerTrajectory.builder()
.id(trajectoryId)
.status(Constants.DELETE_CODE)
.build());
return AjaxResult.success();
}
/**
* 完成待办
* @param trajectoryId
* @return
*/
@DeleteMapping(value = "/handleWait/{trajectoryId}")
public AjaxResult handleWait(@PathVariable String trajectoryId){
iWeCustomerTrajectoryService.updateById(WeCustomerTrajectory.builder()
.id(trajectoryId)
.status(Constants.HANDLE_SUCCESS)
.build());
return AjaxResult.success();
}
......
...@@ -156,6 +156,11 @@ public class Constants ...@@ -156,6 +156,11 @@ public class Constants
/**完成待办*/
public static final String HANDLE_SUCCESS="1";
......
...@@ -2,7 +2,10 @@ package com.linkwechat.wecom.domain; ...@@ -2,7 +2,10 @@ package com.linkwechat.wecom.domain;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data; import lombok.Data;
import lombok.NoArgsConstructor;
import java.sql.Time; import java.sql.Time;
import java.util.Date; import java.util.Date;
...@@ -12,9 +15,12 @@ import java.util.Date; ...@@ -12,9 +15,12 @@ import java.util.Date;
*/ */
@Data @Data
@TableName("we_customer_trajectory") @TableName("we_customer_trajectory")
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class WeCustomerTrajectory { public class WeCustomerTrajectory {
@TableId @TableId
private Long id; private String id;
//轨迹类型(1:信息动态;2:社交动态;3:活动规则;4:待办动态) //轨迹类型(1:信息动态;2:社交动态;3:活动规则;4:待办动态)
private Integer trajectoryType; private Integer trajectoryType;
//外部联系人id //外部联系人id
...@@ -26,5 +32,5 @@ public class WeCustomerTrajectory { ...@@ -26,5 +32,5 @@ public class WeCustomerTrajectory {
//处理时间 //处理时间
private Time createTime; private Time createTime;
//0:正常;1:删除;2:完成 //0:正常;1:删除;2:完成
private Integer status; private String status;
} }
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!