| | |
| | | import com.baomidou.mybatisplus.mapper.Wrapper; |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.core.common.DateUtils; |
| | | import com.zy.crm.manager.entity.Item; |
| | | import com.zy.crm.manager.entity.Order; |
| | | import com.zy.crm.manager.entity.Pri; |
| | | import com.zy.crm.manager.entity.PriOnline; |
| | | import com.zy.crm.manager.service.ItemService; |
| | | import com.zy.crm.manager.service.OrderService; |
| | | import com.zy.crm.manager.service.PriOnlineService; |
| | | import com.zy.crm.manager.entity.*; |
| | | import com.zy.crm.manager.service.*; |
| | | import com.core.annotations.ManagerAuth; |
| | | import com.core.common.BaseRes; |
| | | import com.core.common.Cools; |
| | | import com.core.common.R; |
| | | import com.core.domain.KeyValueVo; |
| | | import com.zy.crm.common.web.BaseController; |
| | | import com.zy.crm.manager.service.PriService; |
| | | import com.zy.crm.system.entity.Role; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.core.io.ClassPathResource; |
| | |
| | | private PriService priService; |
| | | |
| | | @Autowired |
| | | private OrderService orderService; |
| | | private PlanService planService; |
| | | |
| | | @RequestMapping(value = "/priOnline/{id}/auth") |
| | | @ManagerAuth |
| | |
| | | priOnline.setStatus(0); |
| | | //业务员 |
| | | // Item item = itemService.selectById(priOnline.getItemId()); |
| | | Order order = orderService.selectById(priOnline.getItemId()); |
| | | priOnline.setMemberId(order.getUserId()); |
| | | Plan plan = planService.selectById(priOnline.getItemId()); |
| | | priOnline.setMemberId(plan.getUserId()); |
| | | |
| | | |
| | | //设置项目流程 |
| | | order.setStep(2); |
| | | orderService.updateById(order); |
| | | plan.setStep(2); |
| | | planService.updateById(plan); |
| | | |
| | | priOnlineService.insert(priOnline); |
| | | return R.ok(); |
| | |
| | | priOnline.setDeptId(getDeptId()); |
| | | //业务员 |
| | | // Item item = itemService.selectById(priOnline.getItemId()); |
| | | Order order = orderService.selectById(priOnline.getItemId()); |
| | | priOnline.setMemberId(order.getUserId()); |
| | | Plan plan = planService.selectById(priOnline.getItemId()); |
| | | priOnline.setMemberId(plan.getUserId()); |
| | | |
| | | priOnlineService.insert(priOnline); |
| | | return R.ok(); |
| | |
| | | for (PriOnline priOnline : page.getRecords()){ |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("id", priOnline.getId()); |
| | | map.put("value", priOnline.getOrderNum() + "/" + priOnline.getOrderId$() + "/" + priOnline.getMemberId$()); |
| | | map.put("value", priOnline.getOrderNum() + "/" + priOnline.getPlanId$() + "/" + priOnline.getMemberId$()); |
| | | result.add(map); |
| | | } |
| | | return R.ok(result); |