中扬CRM客户关系管理系统
#
LSH
2023-12-01 09ee5added9d59e90310a2586e846137ea597b19
src/main/java/com/zy/crm/manager/entity/Order.java
@@ -8,6 +8,7 @@
import com.core.common.SpringUtils;
import com.zy.crm.manager.service.CompanyService;
import com.zy.crm.manager.service.CstmrService;
import com.zy.crm.manager.service.OrderProductTypeService;
import com.zy.crm.system.entity.Dept;
import com.zy.crm.system.entity.Dic;
import com.zy.crm.system.entity.Host;
@@ -59,9 +60,9 @@
    private Long userId;
    /**
     * 甲方单位
     * 客户信息
     */
    @ApiModelProperty(value= "甲方单位")
    @ApiModelProperty(value= "客户信息")
    @TableField("cstmr_id")
    private Long cstmrId;
@@ -138,9 +139,9 @@
    private String files;
    /**
     * 状态 1: 正常  0: 禁用
     * 项目状态{0:跟踪中,1:完成,2:关闭}
     */
    @ApiModelProperty(value= "状态 1: 正常  0: 禁用  ")
    @ApiModelProperty(value= "项目状态{0:跟踪中,1:完成,2:关闭}")
    private Integer status;
    /**
@@ -173,15 +174,40 @@
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date updateTime;
    @ApiModelProperty(value= "项目进度流程{1:项目创建,2:核价处理,3:产品费用明细,4:报价预算单,5:报价单}")
    @TableField("step")
    private int step;
    /**
     * 注释
     */
    @ApiModelProperty(value= "注释")
    private String memo;
    /**
     * 注释
     */
    @ApiModelProperty(value= "心得体会")
    @TableField("memo_experience")
    private String memoExperience;
    /**
     * 预计成交率
     */
    @ApiModelProperty(value= "预计成交率")
    private String transactionRate;
    /**
     * 添加人员
     */
    @ApiModelProperty(value= "产品类型")
    @TableField("order_product_type_id")
    private Long orderProductTypeId;
    public Order() {}
    public Order(Long hostId,Long deptId,Long userId,Long cstmrId,String uuid,String name,Double money,Long company,String remarks,Long director,String province,String city,String district,String town,String addr,String files,Integer status,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo) {
    public Order(Long id, Long hostId, Long deptId, Long userId, Long cstmrId, String uuid, String name, Double money, Long company, String remarks, Long director, String province, String city, String district, String town, String addr, String files, Integer status, Long createBy, Date createTime, Long updateBy, Date updateTime, int step, String memo, String transactionRate, String pcd,Long orderProductTypeId) {
        this.id = id;
        this.hostId = hostId;
        this.deptId = deptId;
        this.userId = userId;
@@ -203,14 +229,18 @@
        this.createTime = createTime;
        this.updateBy = updateBy;
        this.updateTime = updateTime;
        this.step = step;
        this.memo = memo;
        this.transactionRate = transactionRate;
        this.pcd = pcd;
        this.orderProductTypeId = orderProductTypeId;
    }
//    Order order = new Order(
//            null,    // 所属商户
//            null,    // 所属部门
//            null,    // 所属人员
//            null,    // 甲方单位
//            null,    // 客户信息
//            null,    // 客户代号[非空]
//            null,    // 客户名称[非空]
//            null,    // 总金额
@@ -236,6 +266,15 @@
        Host host = service.selectById(this.hostId);
        if (!Cools.isEmpty(host)){
            return String.valueOf(host.getName());
        }
        return null;
    }
    public String getOrderProductTypeId$(){
        OrderProductTypeService orderProductTypeService = SpringUtils.getBean(OrderProductTypeService.class);
        OrderProductType orderProductType = orderProductTypeService.selectById(this.orderProductTypeId);
        if (!Cools.isEmpty(orderProductType)){
            return String.valueOf(orderProductType.getName());
        }
        return null;
    }
@@ -288,10 +327,12 @@
    public String getStatus$(){
        if (null == this.status){ return null; }
        switch (this.status){
            case 1:
                return "正常";
            case 0:
                return "禁用";
                return "跟踪中";
            case 1:
                return "完成";
            case 2:
                return "关闭";
            default:
                return String.valueOf(this.status);
        }
@@ -310,7 +351,7 @@
        if (Cools.isEmpty(this.createTime)){
            return "";
        }
        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.createTime);
        return new SimpleDateFormat("yyyy-MM-dd HH:mm").format(this.createTime);
    }
    public String getUpdateBy$(){
@@ -326,7 +367,7 @@
        if (Cools.isEmpty(this.updateTime)){
            return "";
        }
        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.updateTime);
        return new SimpleDateFormat("yyyy-MM-dd HH:mm").format(this.updateTime);
    }
    @TableField(exist = false)