Commit fdec9202 authored by 郭姣's avatar 郭姣

总监离职校验、销售间客户动态取消隔离

parent f7aa86cf
......@@ -184,4 +184,15 @@ public class Manager {
boolean data = response.jsonPath().getBoolean("data");
Assert.assertTrue(data,network.message(params,BasicConfig.MANAGER_oto_updateCompany,"修改工作状态为请假中失败",response.body().asString()));
}
@Test(description = "总监下有销售离职失败",priority = 13)
public void 总监下有销售离职失败(){
HashMap<String,Object> params = new HashMap<>();
params.put("id", 43);
params.put("dimissionStatus", 1);
Response response = network.postResponse(params,BasicConfig.MANAGER_oto_switchDimissionStatus);
boolean success = response.jsonPath().getBoolean("success");
Assert.assertFalse(success,network.message(params,BasicConfig.MANAGER_oto_switchDimissionStatus,"总监名下存在销售但离职成功",response.body().asString()));
}
}
......@@ -15,6 +15,7 @@ import java.util.HashMap;
import java.util.Map;
import static com.kjj.config.BasicConfig.SELLER_ID;
import static com.kjj.config.BasicConfig.LEADER_ID;
import static com.kjj.utils.BaseUtils.*;
import static com.kjj.utils.ThreadSleepUtils.sleep;
......@@ -22,7 +23,7 @@ public class Work implements Authorization {
private static final NetworkUtils network = NetworkUtils.getInstance();
public int tagId; //标签ID
public int custId; //客户ID
public int collectCustId = 2129; //客户ID
public int collectCustId = 2801; //客户ID
public String name; //客户手机号
public String phone; //客户手机号
public int followTimes; //跟进次数
......@@ -772,6 +773,24 @@ public class Work implements Authorization {
Assert.assertFalse(success,network.message(BasicConfig.WORK_logout,"总监修改非名下销售工作状态成功",response.body().asString()));
}
@Test(description = "销售间客户动态取消隔离",priority = 58)
public void 销售间客户动态取消隔离(){
//将客户重新分配给总监
HashMap<String,Object> params = new HashMap<>();
params.put("customerId",custId);
params.put("sellerId",LEADER_ID);
Response response = network.postResponse(params,BasicConfig.MANAGER_oto_assignSeller);
boolean data = response.jsonPath().getBoolean("data");
Assert.assertTrue(data,network.message(BasicConfig.MANAGER_oto_assignSeller,"重新分配失败",response.body().asString()));
//总监查看客户动态
params.clear();
params.put("custId",custId);
params.put("logDays",1);
Response logRes = network.getResponse(params,BasicConfig.WORK_operation);
int logSize = logRes.jsonPath().getInt("data.list.size()");
Assert.assertTrue(logSize>0,network.message(BasicConfig.WORK_operation,"客户动态隔离失败",logRes.body().asString()));
}
@Test(description = "删除客户",priority = 79)
public void 删除客户(){
HashMap<String,Object> params = new HashMap<>();
......
......@@ -1324,6 +1324,8 @@ public class BasicConfig {
public static final String MANAGER_oto_customerPhone = MANAGER_HOST +"/kjy/manager/pub/form/customer/customerPhone";
public static final String MANAGER_oto_qaDetail = MANAGER_HOST +"/kjy/manager/pub/form/customer/qaDetail";
public static final String MANAGER_oto_channelList = MANAGER_HOST +"/kjy/manager/pub/form/channelList";
public static final String MANAGER_oto_switchDimissionStatus = MANAGER_HOST +"/kjy/manager/oto/seller/switchDimissionStatus";
public static final String WORK_getCaptcha = WORK_HOST + "/kjy/oto/manager/auth/captcha";
public static final String WORK_login = WORK_HOST + "/kjy/oto/manager/auth/login";
......
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