Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
582ea7077e | ||
|
3536ed470b |
@ -9,7 +9,8 @@ ruoyi:
|
|||||||
# 实例演示开关
|
# 实例演示开关
|
||||||
demoEnabled: true
|
demoEnabled: true
|
||||||
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
|
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
|
||||||
profile: D:/ruoyi/uploadPath
|
# profile: D:/ruoyi/uploadPath
|
||||||
|
profile: /home/ruoyi/uploadPath
|
||||||
# 获取ip地址开关
|
# 获取ip地址开关
|
||||||
addressEnabled: false
|
addressEnabled: false
|
||||||
# 验证码类型 math 数组计算 char 字符验证
|
# 验证码类型 math 数组计算 char 字符验证
|
||||||
|
@ -0,0 +1,105 @@
|
|||||||
|
package com.ruoyi.crm.controller;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.crm.domain.CrmCustomerType;
|
||||||
|
import com.ruoyi.crm.service.ICrmCustomerTypeService;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户标签Controller
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-03-14
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/system/type")
|
||||||
|
public class CrmCustomerTypeController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private ICrmCustomerTypeService crmCustomerTypeService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询客户标签列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:type:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(CrmCustomerType crmCustomerType)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<CrmCustomerType> list = crmCustomerTypeService.selectCrmCustomerTypeList(crmCustomerType);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出客户标签列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:type:export')")
|
||||||
|
@Log(title = "客户标签", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(HttpServletResponse response, CrmCustomerType crmCustomerType)
|
||||||
|
{
|
||||||
|
List<CrmCustomerType> list = crmCustomerTypeService.selectCrmCustomerTypeList(crmCustomerType);
|
||||||
|
ExcelUtil<CrmCustomerType> util = new ExcelUtil<CrmCustomerType>(CrmCustomerType.class);
|
||||||
|
util.exportExcel(response, list, "客户标签数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取客户标签详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:type:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||||
|
{
|
||||||
|
return AjaxResult.success(crmCustomerTypeService.selectCrmCustomerTypeById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增客户标签
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:type:add')")
|
||||||
|
@Log(title = "客户标签", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody CrmCustomerType crmCustomerType)
|
||||||
|
{
|
||||||
|
return toAjax(crmCustomerTypeService.insertCrmCustomerType(crmCustomerType));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改客户标签
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:type:edit')")
|
||||||
|
@Log(title = "客户标签", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody CrmCustomerType crmCustomerType)
|
||||||
|
{
|
||||||
|
return toAjax(crmCustomerTypeService.updateCrmCustomerType(crmCustomerType));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除客户标签
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:type:remove')")
|
||||||
|
@Log(title = "客户标签", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable Long[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(crmCustomerTypeService.deleteCrmCustomerTypeByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,81 @@
|
|||||||
|
package com.ruoyi.crm.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户标签对象 crm_customer_type
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-03-14
|
||||||
|
*/
|
||||||
|
public class CrmCustomerType extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** $column.columnComment */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 标签名称 */
|
||||||
|
@Excel(name = "标签名称")
|
||||||
|
private String typeName;
|
||||||
|
|
||||||
|
/** 标签级别 */
|
||||||
|
@Excel(name = "标签级别")
|
||||||
|
private String typeLv;
|
||||||
|
|
||||||
|
/** 备注 */
|
||||||
|
@Excel(name = "备注")
|
||||||
|
private String notes;
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setTypeName(String typeName)
|
||||||
|
{
|
||||||
|
this.typeName = typeName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTypeName()
|
||||||
|
{
|
||||||
|
return typeName;
|
||||||
|
}
|
||||||
|
public void setTypeLv(String typeLv)
|
||||||
|
{
|
||||||
|
this.typeLv = typeLv;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTypeLv()
|
||||||
|
{
|
||||||
|
return typeLv;
|
||||||
|
}
|
||||||
|
public void setNotes(String notes)
|
||||||
|
{
|
||||||
|
this.notes = notes;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNotes()
|
||||||
|
{
|
||||||
|
return notes;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("typeName", getTypeName())
|
||||||
|
.append("typeLv", getTypeLv())
|
||||||
|
.append("notes", getNotes())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package com.ruoyi.crm.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.crm.domain.CrmCustomerType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户标签Mapper接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-03-14
|
||||||
|
*/
|
||||||
|
public interface CrmCustomerTypeMapper
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询客户标签
|
||||||
|
*
|
||||||
|
* @param id 客户标签主键
|
||||||
|
* @return 客户标签
|
||||||
|
*/
|
||||||
|
public CrmCustomerType selectCrmCustomerTypeById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询客户标签列表
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 客户标签集合
|
||||||
|
*/
|
||||||
|
public List<CrmCustomerType> selectCrmCustomerTypeList(CrmCustomerType crmCustomerType);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增客户标签
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertCrmCustomerType(CrmCustomerType crmCustomerType);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改客户标签
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateCrmCustomerType(CrmCustomerType crmCustomerType);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除客户标签
|
||||||
|
*
|
||||||
|
* @param id 客户标签主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteCrmCustomerTypeById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除客户标签
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteCrmCustomerTypeByIds(Long[] ids);
|
||||||
|
}
|
@ -0,0 +1,63 @@
|
|||||||
|
package com.ruoyi.crm.service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.crm.domain.CrmCustomerType;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户标签Service接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-03-14
|
||||||
|
*/
|
||||||
|
public interface ICrmCustomerTypeService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询客户标签
|
||||||
|
*
|
||||||
|
* @param id 客户标签主键
|
||||||
|
* @return 客户标签
|
||||||
|
*/
|
||||||
|
public CrmCustomerType selectCrmCustomerTypeById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询客户标签列表
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 客户标签集合
|
||||||
|
*/
|
||||||
|
public List<CrmCustomerType> selectCrmCustomerTypeList(CrmCustomerType crmCustomerType);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增客户标签
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertCrmCustomerType(CrmCustomerType crmCustomerType);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改客户标签
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateCrmCustomerType(CrmCustomerType crmCustomerType);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除客户标签
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的客户标签主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteCrmCustomerTypeByIds(Long[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除客户标签信息
|
||||||
|
*
|
||||||
|
* @param id 客户标签主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteCrmCustomerTypeById(Long id);
|
||||||
|
}
|
@ -0,0 +1,97 @@
|
|||||||
|
package com.ruoyi.crm.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import com.ruoyi.crm.domain.CrmCustomerType;
|
||||||
|
import com.ruoyi.crm.mapper.CrmCustomerTypeMapper;
|
||||||
|
import com.ruoyi.crm.service.ICrmCustomerTypeService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 客户标签Service业务层处理
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-03-14
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CrmCustomerTypeServiceImpl implements ICrmCustomerTypeService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private CrmCustomerTypeMapper crmCustomerTypeMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询客户标签
|
||||||
|
*
|
||||||
|
* @param id 客户标签主键
|
||||||
|
* @return 客户标签
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public CrmCustomerType selectCrmCustomerTypeById(Long id)
|
||||||
|
{
|
||||||
|
return crmCustomerTypeMapper.selectCrmCustomerTypeById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询客户标签列表
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 客户标签
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<CrmCustomerType> selectCrmCustomerTypeList(CrmCustomerType crmCustomerType)
|
||||||
|
{
|
||||||
|
return crmCustomerTypeMapper.selectCrmCustomerTypeList(crmCustomerType);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增客户标签
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertCrmCustomerType(CrmCustomerType crmCustomerType)
|
||||||
|
{
|
||||||
|
crmCustomerType.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return crmCustomerTypeMapper.insertCrmCustomerType(crmCustomerType);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改客户标签
|
||||||
|
*
|
||||||
|
* @param crmCustomerType 客户标签
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateCrmCustomerType(CrmCustomerType crmCustomerType)
|
||||||
|
{
|
||||||
|
crmCustomerType.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return crmCustomerTypeMapper.updateCrmCustomerType(crmCustomerType);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除客户标签
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的客户标签主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteCrmCustomerTypeByIds(Long[] ids)
|
||||||
|
{
|
||||||
|
return crmCustomerTypeMapper.deleteCrmCustomerTypeByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除客户标签信息
|
||||||
|
*
|
||||||
|
* @param id 客户标签主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteCrmCustomerTypeById(Long id)
|
||||||
|
{
|
||||||
|
return crmCustomerTypeMapper.deleteCrmCustomerTypeById(id);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,74 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.ruoyi.crm.mapper.CrmCustomerTypeMapper">
|
||||||
|
|
||||||
|
<resultMap type="CrmCustomerType" id="CrmCustomerTypeResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="typeName" column="type_name" />
|
||||||
|
<result property="typeLv" column="type_lv" />
|
||||||
|
<result property="notes" column="notes" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectCrmCustomerTypeVo">
|
||||||
|
select id, type_name, type_lv, notes, create_time, update_time from crm_customer_type
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectCrmCustomerTypeList" parameterType="CrmCustomerType" resultMap="CrmCustomerTypeResult">
|
||||||
|
<include refid="selectCrmCustomerTypeVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="typeName != null and typeName != ''"> and type_name like concat('%', #{typeName}, '%')</if>
|
||||||
|
<if test="typeLv != null and typeLv != ''"> and type_lv = #{typeLv}</if>
|
||||||
|
<if test="notes != null and notes != ''"> and notes = #{notes}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectCrmCustomerTypeById" parameterType="Long" resultMap="CrmCustomerTypeResult">
|
||||||
|
<include refid="selectCrmCustomerTypeVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertCrmCustomerType" parameterType="CrmCustomerType" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into crm_customer_type
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="typeName != null">type_name,</if>
|
||||||
|
<if test="typeLv != null">type_lv,</if>
|
||||||
|
<if test="notes != null">notes,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="typeName != null">#{typeName},</if>
|
||||||
|
<if test="typeLv != null">#{typeLv},</if>
|
||||||
|
<if test="notes != null">#{notes},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateCrmCustomerType" parameterType="CrmCustomerType">
|
||||||
|
update crm_customer_type
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="typeName != null">type_name = #{typeName},</if>
|
||||||
|
<if test="typeLv != null">type_lv = #{typeLv},</if>
|
||||||
|
<if test="notes != null">notes = #{notes},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteCrmCustomerTypeById" parameterType="Long">
|
||||||
|
delete from crm_customer_type where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteCrmCustomerTypeByIds" parameterType="String">
|
||||||
|
delete from crm_customer_type where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
BIN
ruoyi-ui/public/favicon.jpg
Normal file
BIN
ruoyi-ui/public/favicon.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 16 KiB |
@ -8,7 +8,7 @@
|
|||||||
name="viewport"
|
name="viewport"
|
||||||
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
|
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
|
||||||
/>
|
/>
|
||||||
<link rel="icon" href="<%= BASE_URL %>favicon.png" />
|
<link rel="icon" href="<%= BASE_URL %>favicon.jpg" />
|
||||||
<title><%= webpackConfig.name %></title>
|
<title><%= webpackConfig.name %></title>
|
||||||
<!--[if lt IE 11
|
<!--[if lt IE 11
|
||||||
]><script>
|
]><script>
|
||||||
|
@ -10,6 +10,18 @@ export function indexData(){
|
|||||||
|
|
||||||
export function infoDate(date){
|
export function infoDate(date){
|
||||||
return request({
|
return request({
|
||||||
url:'/crm/index-data/infoDate?'+date,
|
url:'/crm/index-data/infoDate?createTime='+date,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function infoTop(){
|
||||||
|
return request({
|
||||||
|
url:'/crm/order/someAmount'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function infoTotalTop(){
|
||||||
|
return request({
|
||||||
|
url:'/crm/order/totalAmount'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
44
ruoyi-ui/src/api/crm/type.js
Normal file
44
ruoyi-ui/src/api/crm/type.js
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
// 查询客户标签列表
|
||||||
|
export function listType(query) {
|
||||||
|
return request({
|
||||||
|
url: '/system/type/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询客户标签详细
|
||||||
|
export function getType(id) {
|
||||||
|
return request({
|
||||||
|
url: '/system/type/' + id,
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 新增客户标签
|
||||||
|
export function addType(data) {
|
||||||
|
return request({
|
||||||
|
url: '/system/type',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 修改客户标签
|
||||||
|
export function updateType(data) {
|
||||||
|
return request({
|
||||||
|
url: '/system/type',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除客户标签
|
||||||
|
export function delType(id) {
|
||||||
|
return request({
|
||||||
|
url: '/system/type/' + id,
|
||||||
|
method: 'delete'
|
||||||
|
})
|
||||||
|
}
|
Binary file not shown.
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 16 KiB |
276
ruoyi-ui/src/views/crm/pool/index.vue
Normal file
276
ruoyi-ui/src/views/crm/pool/index.vue
Normal file
@ -0,0 +1,276 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||||
|
<el-form-item label="标签名称" prop="typeName">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.typeName"
|
||||||
|
placeholder="请输入标签名称"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="标签级别" prop="typeLv">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.typeLv"
|
||||||
|
placeholder="请输入标签级别"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="备注" prop="notes">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.notes"
|
||||||
|
placeholder="请输入备注"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<el-row :gutter="10" class="mb8">
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
plain
|
||||||
|
icon="el-icon-plus"
|
||||||
|
size="mini"
|
||||||
|
@click="handleAdd"
|
||||||
|
v-hasPermi="['system:type:add']"
|
||||||
|
>新增</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="success"
|
||||||
|
plain
|
||||||
|
icon="el-icon-edit"
|
||||||
|
size="mini"
|
||||||
|
:disabled="single"
|
||||||
|
@click="handleUpdate"
|
||||||
|
v-hasPermi="['system:type:edit']"
|
||||||
|
>修改</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="danger"
|
||||||
|
plain
|
||||||
|
icon="el-icon-delete"
|
||||||
|
size="mini"
|
||||||
|
:disabled="multiple"
|
||||||
|
@click="handleDelete"
|
||||||
|
v-hasPermi="['system:type:remove']"
|
||||||
|
>删除</el-button>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="1.5">
|
||||||
|
<el-button
|
||||||
|
type="warning"
|
||||||
|
plain
|
||||||
|
icon="el-icon-download"
|
||||||
|
size="mini"
|
||||||
|
@click="handleExport"
|
||||||
|
v-hasPermi="['system:type:export']"
|
||||||
|
>导出</el-button>
|
||||||
|
</el-col>
|
||||||
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" :data="typeList" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column label="标签id" align="center" prop="id" />
|
||||||
|
<el-table-column label="标签名称" align="center" prop="typeName" />
|
||||||
|
<el-table-column label="标签级别" align="center" prop="typeLv" />
|
||||||
|
<el-table-column label="备注" align="center" prop="notes" />
|
||||||
|
<el-table-column label="创建时间" align="center" prop="createTime" />
|
||||||
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-edit"
|
||||||
|
@click="handleUpdate(scope.row)"
|
||||||
|
v-hasPermi="['system:type:edit']"
|
||||||
|
>修改</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-delete"
|
||||||
|
@click="handleDelete(scope.row)"
|
||||||
|
v-hasPermi="['system:type:remove']"
|
||||||
|
>删除</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination
|
||||||
|
v-show="total>0"
|
||||||
|
:total="total"
|
||||||
|
:page.sync="queryParams.pageNum"
|
||||||
|
:limit.sync="queryParams.pageSize"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<!-- 添加或修改客户标签对话框 -->
|
||||||
|
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||||
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||||
|
<el-form-item label="标签名称" prop="typeName">
|
||||||
|
<el-input v-model="form.typeName" placeholder="请输入标签名称" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="标签级别" prop="typeLv">
|
||||||
|
<el-input v-model="form.typeLv" placeholder="请输入标签级别" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="备注" prop="notes">
|
||||||
|
<el-input v-model="form.notes" placeholder="请输入备注" />
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||||
|
<el-button @click="cancel">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { listType, getType, delType, addType, updateType } from "@/api/crm/type";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "Type",
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 选中数组
|
||||||
|
ids: [],
|
||||||
|
// 非单个禁用
|
||||||
|
single: true,
|
||||||
|
// 非多个禁用
|
||||||
|
multiple: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 客户标签表格数据
|
||||||
|
typeList: [],
|
||||||
|
// 弹出层标题
|
||||||
|
title: "",
|
||||||
|
// 是否显示弹出层
|
||||||
|
open: false,
|
||||||
|
// 查询参数
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
typeName: null,
|
||||||
|
typeLv: null,
|
||||||
|
notes: null,
|
||||||
|
},
|
||||||
|
// 表单参数
|
||||||
|
form: {},
|
||||||
|
// 表单校验
|
||||||
|
rules: {
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/** 查询客户标签列表 */
|
||||||
|
getList() {
|
||||||
|
this.loading = true;
|
||||||
|
listType(this.queryParams).then(response => {
|
||||||
|
this.typeList = response.rows;
|
||||||
|
this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
// 取消按钮
|
||||||
|
cancel() {
|
||||||
|
this.open = false;
|
||||||
|
this.reset();
|
||||||
|
},
|
||||||
|
// 表单重置
|
||||||
|
reset() {
|
||||||
|
this.form = {
|
||||||
|
id: null,
|
||||||
|
typeName: null,
|
||||||
|
typeLv: null,
|
||||||
|
notes: null,
|
||||||
|
createTime: null,
|
||||||
|
updateTime: null
|
||||||
|
};
|
||||||
|
this.resetForm("form");
|
||||||
|
},
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
handleQuery() {
|
||||||
|
this.queryParams.pageNum = 1;
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
resetQuery() {
|
||||||
|
this.resetForm("queryForm");
|
||||||
|
this.handleQuery();
|
||||||
|
},
|
||||||
|
// 多选框选中数据
|
||||||
|
handleSelectionChange(selection) {
|
||||||
|
this.ids = selection.map(item => item.id)
|
||||||
|
this.single = selection.length!==1
|
||||||
|
this.multiple = !selection.length
|
||||||
|
},
|
||||||
|
/** 新增按钮操作 */
|
||||||
|
handleAdd() {
|
||||||
|
this.reset();
|
||||||
|
this.open = true;
|
||||||
|
this.title = "添加客户标签";
|
||||||
|
},
|
||||||
|
/** 修改按钮操作 */
|
||||||
|
handleUpdate(row) {
|
||||||
|
this.reset();
|
||||||
|
const id = row.id || this.ids
|
||||||
|
getType(id).then(response => {
|
||||||
|
this.form = response.data;
|
||||||
|
this.open = true;
|
||||||
|
this.title = "修改客户标签";
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 提交按钮 */
|
||||||
|
submitForm() {
|
||||||
|
this.$refs["form"].validate(valid => {
|
||||||
|
if (valid) {
|
||||||
|
if (this.form.id != null) {
|
||||||
|
updateType(this.form).then(response => {
|
||||||
|
this.$modal.msgSuccess("修改成功");
|
||||||
|
this.open = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
addType(this.form).then(response => {
|
||||||
|
this.$modal.msgSuccess("新增成功");
|
||||||
|
this.open = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 删除按钮操作 */
|
||||||
|
handleDelete(row) {
|
||||||
|
const ids = row.id || this.ids;
|
||||||
|
this.$modal.confirm('是否确认删除客户标签编号为"' + ids + '"的数据项?').then(function() {
|
||||||
|
return delType(ids);
|
||||||
|
}).then(() => {
|
||||||
|
this.getList();
|
||||||
|
this.$modal.msgSuccess("删除成功");
|
||||||
|
}).catch(() => {});
|
||||||
|
},
|
||||||
|
/** 导出按钮操作 */
|
||||||
|
handleExport() {
|
||||||
|
this.download('system/type/export', {
|
||||||
|
...this.queryParams
|
||||||
|
}, `type_${new Date().getTime()}.xlsx`)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
@ -1,34 +1,139 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="dashboard-editor-container">
|
<div class="dashboard-editor-container">
|
||||||
|
|
||||||
<panel-group :customer-data="customerData" />
|
<div class="cards-container">
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>跟进线索数</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{18 }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>跟进客户数</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{13 }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>新增客户数</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{13 }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>新增联系人</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{11 }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>新增商机数</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{11 }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>商机预测金额</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{44.59+'万' }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>赢单数</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{11 }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card class="cards-box">
|
||||||
|
<div class="clearfix2">
|
||||||
|
<span>新增跟进数</span>
|
||||||
|
</div>
|
||||||
|
<div class="text-item">
|
||||||
|
{{27 }}
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- <panel-group :customer-data="customerData" />-->
|
||||||
|
|
||||||
<el-row :gutter="10">
|
<el-row :gutter="10">
|
||||||
|
<el-col :xs="24" :sm="24" :lg="8">
|
||||||
|
<el-card class="box-card" style="margin-bottom: 10px">
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span>今日待办</span>
|
||||||
|
</div>
|
||||||
|
<table class="followup-table">
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<th>今日已跟进</th>
|
||||||
|
<td>{{followupData.today_followup}}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>未跟进个数</th>
|
||||||
|
<td>{{followupData.no_followup}}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>跟进率</th>
|
||||||
|
<td>{{followupData.followup_rate}} %</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
<el-card class="box-card" style="margin-bottom: 10px">
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span>业绩销售额</span>
|
||||||
|
</div>
|
||||||
|
<div ref="chart" style="max-width: 500px;height:450px;"></div>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<!-- <el-col :xs="20" :sm="20" :lg="6">-->
|
||||||
|
<!-- <el-card class="box-card" >-->
|
||||||
|
<!-- <div slot="header" class="clearfix">-->
|
||||||
|
<!-- <span>销售额-个人TOP榜</span>-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<!-- <table class="no-table" >-->
|
||||||
|
<!-- <tbody>-->
|
||||||
|
<!-- <tr>-->
|
||||||
|
<!-- <th>共记</th>-->
|
||||||
|
<!-- <td style="text-align: right;" slot="header">{{followupData.today_followup}}</td>-->
|
||||||
|
<!-- </tr>-->
|
||||||
|
<!-- <tr>-->
|
||||||
|
<!-- <th>Hokin</th>-->
|
||||||
|
<!-- <td style="text-align: right;">{{followupData.today_followup}}</td>-->
|
||||||
|
<!-- </tr>-->
|
||||||
|
<!-- <tr>-->
|
||||||
|
<!-- <th>里琉璃</th>-->
|
||||||
|
<!-- <td style="text-align: right;">{{followupData.today_followup}}</td>-->
|
||||||
|
<!-- </tr>-->
|
||||||
|
<!-- </tbody>-->
|
||||||
|
<!-- </table>-->
|
||||||
|
<!-- </el-card>-->
|
||||||
|
<!-- </el-col>-->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<el-col :xs="24" :sm="24" :lg="8">
|
<el-col :xs="24" :sm="24" :lg="8">
|
||||||
<el-card class="box-card">
|
<el-card class="box-card" style="margin-bottom: 10px">
|
||||||
<div slot="header" class="clearfix">
|
|
||||||
<span>今日待办</span>
|
|
||||||
</div>
|
|
||||||
<table class="followup-table">
|
|
||||||
<tbody>
|
|
||||||
<tr>
|
|
||||||
<th>今日已跟进</th>
|
|
||||||
<td>{{followupData.today_followup}}</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th>未跟进个数</th>
|
|
||||||
<td>{{followupData.no_followup}}</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th>跟进率</th>
|
|
||||||
<td>{{followupData.followup_rate}} %</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</el-card>
|
|
||||||
</el-col>
|
|
||||||
<el-col :xs="24" :sm="24" :lg="8">
|
|
||||||
<el-card class="box-card">
|
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
<span>今日跟进提醒</span>
|
<span>今日跟进提醒</span>
|
||||||
</div>
|
</div>
|
||||||
@ -37,8 +142,21 @@
|
|||||||
<span class="time">下次跟进时间:{{parseTime(followup.nextFollowupTime)}}</span>
|
<span class="time">下次跟进时间:{{parseTime(followup.nextFollowupTime)}}</span>
|
||||||
</div>
|
</div>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
<el-card class="box-card">
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span>跟进计划日程</span>
|
||||||
|
</div>
|
||||||
|
<el-calendar :cellSize="30" STYLE="max-width:400px;max-height: 420px" >
|
||||||
|
<template
|
||||||
|
slot="dateCell"
|
||||||
|
slot-scope="{date, data}">
|
||||||
|
<div @click="handleClick(data.day)">{{data.day.split('-').slice(1)[1]}}</div>
|
||||||
|
</template>
|
||||||
|
</el-calendar>
|
||||||
|
</el-card>
|
||||||
|
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :xs="24" :sm="24" :lg="8">
|
<el-col :xs="24" :sm="24" :lg="8" class="scrollable">
|
||||||
<el-card class="box-card">
|
<el-card class="box-card">
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
<span>动态</span>
|
<span>动态</span>
|
||||||
@ -48,48 +166,399 @@
|
|||||||
<span class="content">跟进记录:</span>{{updates.content}}<br>
|
<span class="content">跟进记录:</span>{{updates.content}}<br>
|
||||||
<span class="time">跟进时间:{{parseTime(updates.createTime)}}</span>
|
<span class="time">跟进时间:{{parseTime(updates.createTime)}}</span>
|
||||||
</div>
|
</div>
|
||||||
|
<el-button type="primary" plain style="margin-top: 5px" @click="handleAdd">提交日程</el-button>
|
||||||
</el-card>
|
</el-card>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
</el-row>
|
</el-row>
|
||||||
|
<div >
|
||||||
|
<el-row :gutter="10">
|
||||||
|
<!-- <el-col :xs="20" :sm="20" :lg="6">-->
|
||||||
|
<!-- <el-card class="box-card" >-->
|
||||||
|
<!-- <div slot="header" class="clearfix">-->
|
||||||
|
<!-- <span>销售额-个人TOP榜</span>-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<!-- <table class="no-table" >-->
|
||||||
|
<!-- <tbody>-->
|
||||||
|
<!-- <tr>-->
|
||||||
|
<!-- <th>共记</th>-->
|
||||||
|
<!-- <td style="text-align: right;" slot="header">{{followupData.today_followup}}</td>-->
|
||||||
|
<!-- </tr>-->
|
||||||
|
<!-- <tr>-->
|
||||||
|
<!-- <th>Hokin</th>-->
|
||||||
|
<!-- <td style="text-align: right;">{{followupData.today_followup}}</td>-->
|
||||||
|
<!-- </tr>-->
|
||||||
|
<!-- <tr>-->
|
||||||
|
<!-- <th>里琉璃</th>-->
|
||||||
|
<!-- <td style="text-align: right;">{{followupData.today_followup}}</td>-->
|
||||||
|
<!-- </tr>-->
|
||||||
|
<!-- </tbody>-->
|
||||||
|
<!-- </table>-->
|
||||||
|
<!-- </el-card>-->
|
||||||
|
<!-- </el-col>-->
|
||||||
|
<!-- <el-col :xs="24" :sm="24" :lg="8">-->
|
||||||
|
<!-- <el-card class="box-card">-->
|
||||||
|
<!-- <div slot="header" class="clearfix">-->
|
||||||
|
<!-- <span>跟进计划日程</span>-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<!-- <el-calendar STYLE="max-width:400px;max-height: 500px"></el-calendar>-->
|
||||||
|
<!-- </el-card>-->
|
||||||
|
<!-- </el-col>-->
|
||||||
|
<el-col :xs="24" :sm="24" :lg="8">
|
||||||
|
<el-card class="box-card" style="height: 408px">
|
||||||
|
<div slot="header" class="clearfix">
|
||||||
|
<span>销售额-个人TOP榜</span>
|
||||||
|
</div>
|
||||||
|
<table class="no-table" >
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<th>共记</th>
|
||||||
|
<td style="text-align: right;" slot="header">{{totalAmount}}</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tr v-for="(item, index) in topPeople" :key="index">
|
||||||
|
<th>{{ item.createBy }}</th>
|
||||||
|
<td style="text-align: right;">{{ item.totalAmount}}</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</el-card>
|
||||||
|
</el-col>
|
||||||
|
|
||||||
|
<el-col :xs="24" :sm="24" :lg="16">
|
||||||
|
|
||||||
|
<div ref="echarts1" ></div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 添加或修改应收款对话框 -->
|
||||||
|
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||||
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||||
|
|
||||||
|
<el-form-item label="客户名称" prop="customerName">
|
||||||
|
<el-select v-model="form.customerId" placeholder="请选择客户" @change="getPersonOrderList">
|
||||||
|
<el-option v-for="customer in customerList" :key="customer.id" :label="customer.name" :value="customer.id"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="跟进内容" prop="content">
|
||||||
|
<el-input v-model="form.content" placeholder="请输入跟进内容" />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||||
|
<el-button @click="cancel">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import PanelGroup from './dashboard/PanelGroup'
|
import PanelGroup from './dashboard/PanelGroup'
|
||||||
|
import ECharts from 'echarts'
|
||||||
import { indexData } from '@/api/crm/index'
|
import {indexData, infoDate, infoTop, infoTotalTop} from '@/api/crm/index'
|
||||||
|
import { Card, Calendar } from 'element-ui';
|
||||||
|
import echarts from 'echarts';
|
||||||
|
// 引入地图
|
||||||
|
import 'echarts/lib/chart/map';
|
||||||
|
// 引入js
|
||||||
|
import "echarts/map/js/china.js";
|
||||||
|
import {customerList} from "@/api/crm/order";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Index',
|
|
||||||
components: {
|
components: {
|
||||||
PanelGroup
|
PanelGroup,
|
||||||
|
// WeekCalendar
|
||||||
|
ElCard: Card,
|
||||||
|
ElCalendar: Calendar,
|
||||||
|
|
||||||
},
|
},
|
||||||
data () {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
// 表单参数
|
||||||
|
form: {},
|
||||||
|
// 是否显示弹出层
|
||||||
|
open: false,
|
||||||
customerData: {},
|
customerData: {},
|
||||||
followupData: {},
|
followupData: {},
|
||||||
todayFollowupList: [],
|
todayFollowupList: [],
|
||||||
todayUpdates: []
|
todayUpdates: [],
|
||||||
|
topPeople: [],
|
||||||
|
totalAmount: '',
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
mounted() {
|
||||||
|
this.drawChart();
|
||||||
|
this.initMap();
|
||||||
|
},
|
||||||
|
created() {
|
||||||
this.initData();
|
this.initData();
|
||||||
|
this.initTop();
|
||||||
|
this.totalTop();
|
||||||
|
// this.initMap();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
initData () {
|
/** 查询订单的客户列表 */
|
||||||
indexData().then((response) => {
|
getPersonOrderList () {
|
||||||
this.customerData = response.data.customer_info;
|
this.loading = true
|
||||||
this.followupData = response.data.followup_info;
|
customerList(this.form.customerId).then((response) => {
|
||||||
this.todayFollowupList = response.data.today_followup_list;
|
this.orderList = response.data;
|
||||||
|
this.loading = false
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 取消按钮
|
||||||
|
cancel() {
|
||||||
|
this.open = false;
|
||||||
|
this.reset();
|
||||||
|
},
|
||||||
|
/** 提交日程 */
|
||||||
|
handleAdd() {
|
||||||
|
this.reset();
|
||||||
|
this.open = true;
|
||||||
|
this.title = "添加跟进记录";
|
||||||
|
},
|
||||||
|
//获取个人金额
|
||||||
|
initTop() {
|
||||||
|
infoTop().then((response) => {
|
||||||
|
this.topPeople = response.data;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//获取总金额
|
||||||
|
totalTop() {
|
||||||
|
infoTotalTop().then((response) => {
|
||||||
|
this.totalAmount = response.data;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//点击日历并渲染数据
|
||||||
|
handleClick(date) {
|
||||||
|
console.log('点击的日期是:', date);
|
||||||
|
infoDate(date).then((response) => {
|
||||||
this.todayUpdates = response.data.today_updates;
|
this.todayUpdates = response.data.today_updates;
|
||||||
})
|
})
|
||||||
}
|
console.log(response.data.today_updates)
|
||||||
}
|
},
|
||||||
|
|
||||||
|
// initMap() {
|
||||||
|
// let myChart = ECharts.init(this.$refs.echarts1);
|
||||||
|
// let option = {
|
||||||
|
// tooltip: {
|
||||||
|
// // 鼠标移到图里面的浮动提示框
|
||||||
|
// formatter(params) {
|
||||||
|
// let htmlStr = `
|
||||||
|
// <div style='font-size:18px;'> ${params.name}</div>
|
||||||
|
// `;
|
||||||
|
// return htmlStr;
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// // geo配置详解: https://echarts.baidu.com/option.html#geo
|
||||||
|
// geo: {
|
||||||
|
// map: 'china',
|
||||||
|
// show: true,
|
||||||
|
// roam: true,
|
||||||
|
// top: 0,
|
||||||
|
// label: {
|
||||||
|
// emphasis: {
|
||||||
|
// show: false
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// // 地图的背景色
|
||||||
|
// itemStyle: {
|
||||||
|
// normal: {
|
||||||
|
// areaColor: '#091632',
|
||||||
|
// borderColor: '#9adcfa',
|
||||||
|
// shadowColor: '#09184F',
|
||||||
|
// shadowBlur: 20
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// series: [
|
||||||
|
// // 地图部分
|
||||||
|
// {
|
||||||
|
// type: 'map',
|
||||||
|
// map: 'china',
|
||||||
|
// geoIndex: 1,
|
||||||
|
// aspectScale: 0.75, // 长宽比
|
||||||
|
// showLegendSymbol: true, // 存在legend时显示
|
||||||
|
// top: 0,
|
||||||
|
// label: {
|
||||||
|
// normal: {
|
||||||
|
// show: false
|
||||||
|
// },
|
||||||
|
// emphasis: {
|
||||||
|
// show: false,
|
||||||
|
// textStyle: {
|
||||||
|
// color: '#fff'
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// //是否开启鼠标缩放和平移漫游
|
||||||
|
// roam: false,
|
||||||
|
// //默认样式
|
||||||
|
// itemStyle: {
|
||||||
|
// normal: {
|
||||||
|
// areaColor: '#031525',
|
||||||
|
// borderColor: '#3B5077',
|
||||||
|
// borderWidth: 1
|
||||||
|
// },
|
||||||
|
// emphasis: {
|
||||||
|
// areaColor: '#0f2c70'
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// data: [
|
||||||
|
// {
|
||||||
|
// name: '黑龙江',
|
||||||
|
// //自定义省的颜色
|
||||||
|
// itemStyle: {
|
||||||
|
// normal: {
|
||||||
|
// areaColor: '#F50508',
|
||||||
|
// borderColor: '#1773c3', // 区域边框
|
||||||
|
// shadowColor: '#1773c3', // 阴影
|
||||||
|
// shadowBlur: 20
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// ],
|
||||||
|
// zlevel: 0
|
||||||
|
// },
|
||||||
|
// // 气泡
|
||||||
|
// {
|
||||||
|
// type: 'effectScatter',
|
||||||
|
// coordinateSystem: 'geo',
|
||||||
|
// //要有对应的经纬度才显示,先经度再维度
|
||||||
|
// data: [{name: '哈尔滨', value: [126.63, 45.75]}],
|
||||||
|
// showEffectOn: 'render',
|
||||||
|
// rippleEffect: {
|
||||||
|
// scale: 4, // 波纹的最大缩放比例
|
||||||
|
// brushType: 'stroke'
|
||||||
|
// },
|
||||||
|
// hoverAnimation: true,
|
||||||
|
// label: {
|
||||||
|
// normal: {
|
||||||
|
// show: true,
|
||||||
|
// formatter: '{b}',
|
||||||
|
// position: 'right',
|
||||||
|
// fontWeight: 500,
|
||||||
|
// fontSize: 14
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// itemStyle: {
|
||||||
|
// normal: {
|
||||||
|
// color: '#32cd32',
|
||||||
|
// shadowBlur: 10,
|
||||||
|
// shadowColor: '#333'
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// emphasis: {
|
||||||
|
// itemStyle: {
|
||||||
|
// color: '#f4e925' // 高亮颜色
|
||||||
|
// }
|
||||||
|
// },
|
||||||
|
// zlevel: 1
|
||||||
|
// }
|
||||||
|
// ]
|
||||||
|
// };
|
||||||
|
// myChart.setOption(option);
|
||||||
|
// // window.addEventListener('resize', function () {
|
||||||
|
// // myChart.resize();
|
||||||
|
// // });
|
||||||
|
// },
|
||||||
|
|
||||||
|
drawChart() {
|
||||||
|
// 基于准备好的dom,初始化echarts实例
|
||||||
|
let myChart = ECharts.init(this.$refs.chart)
|
||||||
|
// 指定图表的配置项和数据
|
||||||
|
let option = {
|
||||||
|
title: {
|
||||||
|
text: '业绩销售额'
|
||||||
|
},
|
||||||
|
// tooltip: {},
|
||||||
|
legend: {
|
||||||
|
data: ['业绩金额']
|
||||||
|
},
|
||||||
|
xAxis: {
|
||||||
|
data: ["2023年9月", "2023年10月", "2023年11月"]
|
||||||
|
},
|
||||||
|
yAxis: {},
|
||||||
|
series: [{
|
||||||
|
name: '业绩金额',
|
||||||
|
type: 'line',
|
||||||
|
data: [50000, 100000, 150000, 200000, 250000, 300000]
|
||||||
|
}]
|
||||||
|
};
|
||||||
|
// 使用刚指定的配置项和数据显示图表。
|
||||||
|
myChart.setOption(option);
|
||||||
|
},
|
||||||
|
initData() {
|
||||||
|
indexData().then((response) => {
|
||||||
|
this.customerData = response.data.customer_info;
|
||||||
|
this.followupData = response.data.followup_info;
|
||||||
|
this.todayFollowupList = response.data.today_followup_list;
|
||||||
|
// this.todayUpdates = response.data.today_updates;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 表单重置
|
||||||
|
reset() {
|
||||||
|
this.form = {
|
||||||
|
content: null,
|
||||||
|
createTime: null,
|
||||||
|
customerName: null,
|
||||||
|
id: null
|
||||||
|
};
|
||||||
|
this.resetForm("form");
|
||||||
|
},
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
.clearfix2 {
|
||||||
|
font-weight: bold;
|
||||||
|
color: black;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.text-item {
|
||||||
|
font-size: 24px;
|
||||||
|
color: #00a6ff;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cards-container {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: nowrap;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
.cards-box{
|
||||||
|
width: 25%;
|
||||||
|
display: inline-block;
|
||||||
|
margin-right: 5px; /* 可根据需要调整间距 */
|
||||||
|
}
|
||||||
|
.no-table {
|
||||||
|
//max-width: 300px;
|
||||||
|
width: 100%;
|
||||||
|
border-collapse: collapse;
|
||||||
|
border: 0 solid #eee;
|
||||||
|
}
|
||||||
|
|
||||||
|
.no-table th {
|
||||||
|
width: 150px;
|
||||||
|
}
|
||||||
|
.no-table th,
|
||||||
|
td {
|
||||||
|
color: #7e7e7e;
|
||||||
|
border: 0 solid #eee;
|
||||||
|
text-align: left;
|
||||||
|
padding: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
.dashboard-editor-container {
|
.dashboard-editor-container {
|
||||||
padding: 32px;
|
padding: 32px;
|
||||||
// background-color: rgb(240, 242, 245);
|
// background-color: rgb(240, 242, 245);
|
||||||
@ -106,6 +575,7 @@ export default {
|
|||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
border: 1px solid #eee;
|
border: 1px solid #eee;
|
||||||
}
|
}
|
||||||
|
|
||||||
.followup-table th {
|
.followup-table th {
|
||||||
width: 150px;
|
width: 150px;
|
||||||
}
|
}
|
||||||
@ -129,7 +599,9 @@ td {
|
|||||||
.today-updates .content {
|
.today-updates .content {
|
||||||
color: #ee8323;
|
color: #ee8323;
|
||||||
}
|
}
|
||||||
|
::v-deep .el-calendar-table .el-calendar-day{
|
||||||
|
height: 50px;
|
||||||
|
}
|
||||||
.today-followup {
|
.today-followup {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
padding: 18px 0;
|
padding: 18px 0;
|
||||||
@ -139,7 +611,10 @@ td {
|
|||||||
.time {
|
.time {
|
||||||
color: #7e7e7e;
|
color: #7e7e7e;
|
||||||
}
|
}
|
||||||
|
.scrollable {
|
||||||
|
overflow-y: auto;
|
||||||
|
max-height: 612px; /* 根据需要调整最大高度 */
|
||||||
|
}
|
||||||
@media (max-width: 1024px) {
|
@media (max-width: 1024px) {
|
||||||
.chart-wrapper {
|
.chart-wrapper {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
|
@ -37,9 +37,9 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<!-- 底部 -->
|
<!-- 底部 -->
|
||||||
<div class="el-login-footer">
|
<!-- <div class="el-login-footer">-->
|
||||||
<span>Copyright © 2022 devjd.com</span>
|
<!-- <span>Copyright © 2022 devjd.com</span>-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
0
ruoyi-ui/src/views/tool/ChinaMap.vue
Normal file
0
ruoyi-ui/src/views/tool/ChinaMap.vue
Normal file
@ -35,7 +35,7 @@ module.exports = {
|
|||||||
proxy: {
|
proxy: {
|
||||||
// detail: https://cli.vuejs.org/config/#devserver-proxy
|
// detail: https://cli.vuejs.org/config/#devserver-proxy
|
||||||
[process.env.VUE_APP_BASE_API]: {
|
[process.env.VUE_APP_BASE_API]: {
|
||||||
target: `http://localhost:8080`,
|
target: `http://localhost:8080/api`,
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
['^' + process.env.VUE_APP_BASE_API]: ''
|
['^' + process.env.VUE_APP_BASE_API]: ''
|
||||||
|
Loading…
Reference in New Issue
Block a user