1,修改用户管理展示岗位信息

2,修复提成比例数据格式为浮点型
3,修复修改提成比例时业务员展示
4,金额数字逢三位加逗号
This commit is contained in:
huangdeliang
2020-10-06 20:16:58 +08:00
parent 0e3b59b12f
commit 92fc73e923
11 changed files with 839 additions and 783 deletions

View File

@ -123,8 +123,8 @@ public class SysCommisionController extends BaseController {
boolean comHit = false; boolean comHit = false;
for (int i = 0; i < tmpComList.size(); i++) { for (int i = 0; i < tmpComList.size(); i++) {
SysCommision com = tmpComList.get(i); SysCommision com = tmpComList.get(i);
long dAmount = detail.getAmount().longValue(); float dAmount = detail.getAmount().floatValue();
long cAmount = com.getAmount().longValue(); float cAmount = com.getAmount().floatValue();
if (dAmount < cAmount && i == 0) { if (dAmount < cAmount && i == 0) {
comHit = false; comHit = false;
break; break;
@ -132,17 +132,17 @@ public class SysCommisionController extends BaseController {
comHit = true; comHit = true;
detail.setRate(com.getRate()); detail.setRate(com.getRate());
break; break;
} else if (dAmount >= cAmount && dAmount < tmpComList.get(i + 1).getAmount().longValue()) { } else if (dAmount >= cAmount && dAmount < tmpComList.get(i + 1).getAmount().floatValue()) {
comHit = true; comHit = true;
detail.setRate(com.getRate()); detail.setRate(com.getRate());
} }
} }
if (!comHit) { if (!comHit) {
detail.setRate(0L); detail.setRate(0F);
detail.setCommision(BigDecimal.ZERO); detail.setCommision(BigDecimal.ZERO);
} else { } else {
long amount = detail.getAmount().longValue(); float amount = detail.getAmount().floatValue();
amount = amount * detail.getRate() / 100; amount = amount * detail.getRate() / 100F;
detail.setCommision(new BigDecimal(amount)); detail.setCommision(new BigDecimal(amount));
} }
} }

View File

@ -5,6 +5,7 @@ import java.util.List;
import javax.validation.constraints.Email; import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank; import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size; import javax.validation.constraints.Size;
import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle; import org.apache.commons.lang3.builder.ToStringStyle;
import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnore;
@ -20,283 +21,299 @@ import com.ruoyi.common.core.domain.BaseEntity;
* *
* @author ruoyi * @author ruoyi
*/ */
public class SysUser extends BaseEntity public class SysUser extends BaseEntity {
{
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
/** 用户ID */ /**
* 用户ID
*/
@Excel(name = "用户序号", cellType = ColumnType.NUMERIC, prompt = "用户编号") @Excel(name = "用户序号", cellType = ColumnType.NUMERIC, prompt = "用户编号")
private Long userId; private Long userId;
/** 部门ID */ /**
* 部门ID
*/
@Excel(name = "部门编号", type = Type.IMPORT) @Excel(name = "部门编号", type = Type.IMPORT)
private Long deptId; private Long deptId;
/** 用户账号 */ /**
* 用户账号
*/
@Excel(name = "登录名称") @Excel(name = "登录名称")
private String userName; private String userName;
/** 用户昵称 */ /**
* 用户昵称
*/
@Excel(name = "用户名称") @Excel(name = "用户名称")
private String nickName; private String nickName;
/** 用户邮箱 */ /**
* 用户邮箱
*/
@Excel(name = "用户邮箱") @Excel(name = "用户邮箱")
private String email; private String email;
/** 手机号码 */ /**
* 手机号码
*/
@Excel(name = "手机号码") @Excel(name = "手机号码")
private String phonenumber; private String phonenumber;
/** 用户性别 */ /**
* 用户性别
*/
@Excel(name = "用户性别", readConverterExp = "0=男,1=女,2=未知") @Excel(name = "用户性别", readConverterExp = "0=男,1=女,2=未知")
private String sex; private String sex;
/** 用户头像 */ /**
* 用户头像
*/
private String avatar; private String avatar;
/** 密码 */ /**
* 密码
*/
private String password; private String password;
/** 盐加密 */ /**
* 盐加密
*/
private String salt; private String salt;
/** 帐号状态0正常 1停用 */ /**
* 帐号状态0正常 1停用
*/
@Excel(name = "帐号状态", readConverterExp = "0=正常,1=停用") @Excel(name = "帐号状态", readConverterExp = "0=正常,1=停用")
private String status; private String status;
/** 删除标志0代表存在 2代表删除 */ /**
* 删除标志0代表存在 2代表删除
*/
private String delFlag; private String delFlag;
/** 最后登录IP */ /**
* 最后登录IP
*/
@Excel(name = "最后登录IP", type = Type.EXPORT) @Excel(name = "最后登录IP", type = Type.EXPORT)
private String loginIp; private String loginIp;
/** 最后登录时间 */ /**
* 最后登录时间
*/
@Excel(name = "最后登录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", type = Type.EXPORT) @Excel(name = "最后登录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", type = Type.EXPORT)
private Date loginDate; private Date loginDate;
/** 部门对象 */ /**
* 部门对象
*/
@Excels({ @Excels({
@Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT), @Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT),
@Excel(name = "部门负责人", targetAttr = "leader", type = Type.EXPORT) @Excel(name = "部门负责人", targetAttr = "leader", type = Type.EXPORT)
}) })
private SysDept dept; private SysDept dept;
/** 角色对象 */ /**
* 角色对象
*/
private List<SysRole> roles; private List<SysRole> roles;
/** 角色组 */ /**
* 角色组
*/
private Long[] roleIds; private Long[] roleIds;
/** 岗位组 */ /**
* 岗位组
*/
private Long[] postIds; private Long[] postIds;
public SysUser() private Long postId;
{
@Excel(name = "岗位")
private String postName;
public SysUser() {
} }
public SysUser(Long userId) public Long getPostId() {
{ return postId;
}
public String getPostName() {
return postName;
}
public void setPostId(Long postId) {
this.postId = postId;
}
public void setPostName(String postName) {
this.postName = postName;
}
public SysUser(Long userId) {
this.userId = userId; this.userId = userId;
} }
public Long getUserId() public Long getUserId() {
{
return userId; return userId;
} }
public void setUserId(Long userId) public void setUserId(Long userId) {
{
this.userId = userId; this.userId = userId;
} }
public boolean isAdmin() public boolean isAdmin() {
{
return isAdmin(this.userId); return isAdmin(this.userId);
} }
public static boolean isAdmin(Long userId) public static boolean isAdmin(Long userId) {
{
return userId != null && 1L == userId; return userId != null && 1L == userId;
} }
public Long getDeptId() public Long getDeptId() {
{
return deptId; return deptId;
} }
public void setDeptId(Long deptId) public void setDeptId(Long deptId) {
{
this.deptId = deptId; this.deptId = deptId;
} }
@Size(min = 0, max = 30, message = "用户昵称长度不能超过30个字符") @Size(min = 0, max = 30, message = "用户昵称长度不能超过30个字符")
public String getNickName() public String getNickName() {
{
return nickName; return nickName;
} }
public void setNickName(String nickName) public void setNickName(String nickName) {
{
this.nickName = nickName; this.nickName = nickName;
} }
@NotBlank(message = "用户账号不能为空") @NotBlank(message = "用户账号不能为空")
@Size(min = 0, max = 30, message = "用户账号长度不能超过30个字符") @Size(min = 0, max = 30, message = "用户账号长度不能超过30个字符")
public String getUserName() public String getUserName() {
{
return userName; return userName;
} }
public void setUserName(String userName) public void setUserName(String userName) {
{
this.userName = userName; this.userName = userName;
} }
@Email(message = "邮箱格式不正确") @Email(message = "邮箱格式不正确")
@Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符") @Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符")
public String getEmail() public String getEmail() {
{
return email; return email;
} }
public void setEmail(String email) public void setEmail(String email) {
{
this.email = email; this.email = email;
} }
@Size(min = 0, max = 11, message = "手机号码长度不能超过11个字符") @Size(min = 0, max = 11, message = "手机号码长度不能超过11个字符")
public String getPhonenumber() public String getPhonenumber() {
{
return phonenumber; return phonenumber;
} }
public void setPhonenumber(String phonenumber) public void setPhonenumber(String phonenumber) {
{
this.phonenumber = phonenumber; this.phonenumber = phonenumber;
} }
public String getSex() public String getSex() {
{
return sex; return sex;
} }
public void setSex(String sex) public void setSex(String sex) {
{
this.sex = sex; this.sex = sex;
} }
public String getAvatar() public String getAvatar() {
{
return avatar; return avatar;
} }
public void setAvatar(String avatar) public void setAvatar(String avatar) {
{
this.avatar = avatar; this.avatar = avatar;
} }
@JsonIgnore @JsonIgnore
@JsonProperty @JsonProperty
public String getPassword() public String getPassword() {
{
return password; return password;
} }
public void setPassword(String password) public void setPassword(String password) {
{
this.password = password; this.password = password;
} }
public String getSalt() public String getSalt() {
{
return salt; return salt;
} }
public void setSalt(String salt) public void setSalt(String salt) {
{
this.salt = salt; this.salt = salt;
} }
public String getStatus() public String getStatus() {
{
return status; return status;
} }
public void setStatus(String status) public void setStatus(String status) {
{
this.status = status; this.status = status;
} }
public String getDelFlag() public String getDelFlag() {
{
return delFlag; return delFlag;
} }
public void setDelFlag(String delFlag) public void setDelFlag(String delFlag) {
{
this.delFlag = delFlag; this.delFlag = delFlag;
} }
public String getLoginIp() public String getLoginIp() {
{
return loginIp; return loginIp;
} }
public void setLoginIp(String loginIp) public void setLoginIp(String loginIp) {
{
this.loginIp = loginIp; this.loginIp = loginIp;
} }
public Date getLoginDate() public Date getLoginDate() {
{
return loginDate; return loginDate;
} }
public void setLoginDate(Date loginDate) public void setLoginDate(Date loginDate) {
{
this.loginDate = loginDate; this.loginDate = loginDate;
} }
public SysDept getDept() public SysDept getDept() {
{
return dept; return dept;
} }
public void setDept(SysDept dept) public void setDept(SysDept dept) {
{
this.dept = dept; this.dept = dept;
} }
public List<SysRole> getRoles() public List<SysRole> getRoles() {
{
return roles; return roles;
} }
public void setRoles(List<SysRole> roles) public void setRoles(List<SysRole> roles) {
{
this.roles = roles; this.roles = roles;
} }
public Long[] getRoleIds() public Long[] getRoleIds() {
{
return roleIds; return roleIds;
} }
public void setRoleIds(Long[] roleIds) public void setRoleIds(Long[] roleIds) {
{
this.roleIds = roleIds; this.roleIds = roleIds;
} }
public Long[] getPostIds() public Long[] getPostIds() {
{
return postIds; return postIds;
} }
public void setPostIds(Long[] postIds) public void setPostIds(Long[] postIds) {
{
this.postIds = postIds; this.postIds = postIds;
} }
@ -323,6 +340,8 @@ public class SysUser extends BaseEntity
.append("updateTime", getUpdateTime()) .append("updateTime", getUpdateTime())
.append("remark", getRemark()) .append("remark", getRemark())
.append("dept", getDept()) .append("dept", getDept())
.append("postId", getPostId())
.append("postName", getPostName())
.toString(); .toString();
} }
} }

View File

@ -27,7 +27,7 @@ public class SysCommision extends BaseEntity {
private Long userId; private Long userId;
/** /**
* 位id * 位id
*/ */
private Long postId; private Long postId;
@ -37,7 +37,7 @@ public class SysCommision extends BaseEntity {
@Excel(name = "业务员") @Excel(name = "业务员")
private String userName; private String userName;
@Excel(name = "") @Excel(name = "")
private String postName; private String postName;
/** /**
@ -50,7 +50,7 @@ public class SysCommision extends BaseEntity {
* 分成比例 * 分成比例
*/ */
@Excel(name = "比例", suffix = "%") @Excel(name = "比例", suffix = "%")
private Long rate; private Float rate;
/** /**
* 提成 * 提成
@ -114,11 +114,11 @@ public class SysCommision extends BaseEntity {
return amount; return amount;
} }
public void setRate(Long rate) { public void setRate(Float rate) {
this.rate = rate; this.rate = rate;
} }
public Long getRate() { public Float getRate() {
return rate; return rate;
} }

View File

@ -28,6 +28,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateBy" column="update_by" /> <result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="remark" column="remark" /> <result property="remark" column="remark" />
<result property="postId" column="post_id" />
<result property="postName" column="post_name" />
<association property="dept" column="dept_id" javaType="SysDept" resultMap="deptResult" /> <association property="dept" column="dept_id" javaType="SysDept" resultMap="deptResult" />
<collection property="roles" javaType="java.util.List" resultMap="RoleResult" /> <collection property="roles" javaType="java.util.List" resultMap="RoleResult" />
</resultMap> </resultMap>
@ -63,16 +65,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<sql id="selectUserVo"> <sql id="selectUserVo">
select u.user_id, u.dept_id, u.user_name, u.nick_name, u.email, u.avatar, u.phonenumber, u.password, u.sex, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark, select u.user_id, u.dept_id, u.user_name, u.nick_name, u.email, u.avatar, u.phonenumber, u.password, u.sex, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark,
d.dept_id, d.parent_id, d.dept_name, d.order_num, d.leader, d.status as dept_status, d.dept_id, d.parent_id, d.dept_name, d.order_num, d.leader, d.status as dept_status,
r.role_id, r.role_name, r.role_key, r.role_sort, r.data_scope, r.status as role_status r.role_id, r.role_name, r.role_key, r.role_sort, r.data_scope, r.status as role_status, p.post_id, p.post_name
from sys_user u from sys_user u
left join sys_dept d on u.dept_id = d.dept_id left join sys_dept d on u.dept_id = d.dept_id
left join sys_user_role ur on u.user_id = ur.user_id left join sys_user_role ur on u.user_id = ur.user_id
left join sys_role r on r.role_id = ur.role_id left join sys_role r on r.role_id = ur.role_id
left join sys_user_post up on up.user_id = u.user_id
left join sys_post p on p.post_id = up.post_id
</sql> </sql>
<select id="selectUserList" parameterType="SysUser" resultMap="SysUserResult"> <select id="selectUserList" parameterType="SysUser" resultMap="SysUserResult">
select u.user_id, u.dept_id, u.nick_name, u.user_name, u.email, u.avatar, u.phonenumber, u.password, u.sex, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark, d.dept_name, d.leader from sys_user u select u.user_id, u.dept_id, u.nick_name, u.user_name, u.email, u.avatar, u.phonenumber, u.password, u.sex, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark, d.dept_name, d.leader, p.post_id, p.post_name from sys_user u
left join sys_dept d on u.dept_id = d.dept_id left join sys_dept d on u.dept_id = d.dept_id
left join sys_user_post up on up.user_id = u.user_id
left join sys_post p on p.post_id = up.post_id
where u.del_flag = '0' where u.del_flag = '0'
<if test="userName != null and userName != ''"> <if test="userName != null and userName != ''">
AND u.user_name like concat('%', #{userName}, '%') AND u.user_name like concat('%', #{userName}, '%')

View File

@ -18,7 +18,7 @@ import './assets/icons' // icon
import './permission' // permission control import './permission' // permission control
import { getDicts } from "@/api/system/dict/data"; import { getDicts } from "@/api/system/dict/data";
import { getConfigKey } from "@/api/system/config"; import { getConfigKey } from "@/api/system/config";
import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, download, handleTree } from "@/utils/ruoyi"; import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, download, handleTree, toThousands } from "@/utils/ruoyi";
import Pagination from "@/components/Pagination"; import Pagination from "@/components/Pagination";
//自定义表格工具扩展 //自定义表格工具扩展
import RightToolbar from "@/components/RightToolbar" import RightToolbar from "@/components/RightToolbar"
@ -33,6 +33,7 @@ Vue.prototype.selectDictLabel = selectDictLabel
Vue.prototype.selectDictLabels = selectDictLabels Vue.prototype.selectDictLabels = selectDictLabels
Vue.prototype.download = download Vue.prototype.download = download
Vue.prototype.handleTree = handleTree Vue.prototype.handleTree = handleTree
Vue.prototype.toThousands = toThousands
Vue.prototype.msgSuccess = function (msg) { Vue.prototype.msgSuccess = function (msg) {
this.$message({ showClose: true, message: msg, type: "success" }); this.$message({ showClose: true, message: msg, type: "success" });

View File

@ -153,3 +153,14 @@ export function handleTree(data, id, parentId, children, rootId) {
}); });
return treeData != '' ? treeData : data; return treeData != '' ? treeData : data;
} }
/** 数字逢三位加逗号 */
export function toThousands(num) {
var num = (num || 0).toString(), result = '';
while (num.length > 3) {
result = ',' + num.slice(-3) + result;
num = num.slice(0, num.length - 3);
}
if (num) { result = num + result; }
return result;
}

View File

@ -1,8 +1,8 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px"> <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="位" prop="postId"> <el-form-item label="位" prop="postId">
<el-select v-model="queryParams.postId" placeholder="请选择位" clearable size="small" @change="searchPostChange"> <el-select v-model="queryParams.postId" placeholder="请选择位" clearable size="small" @change="searchPostChange">
<el-option <el-option
v-for="dict in postIdOptions" v-for="dict in postIdOptions"
:key="dict.dictValue" :key="dict.dictValue"
@ -76,8 +76,12 @@
<el-table v-loading="loading" :data="commisionList" :span-method="objectSpanMethod" <el-table v-loading="loading" :data="commisionList" :span-method="objectSpanMethod"
@selection-change="handleSelectionChange"> @selection-change="handleSelectionChange">
<el-table-column label="业务员" align="center" prop="userName"/> <el-table-column label="业务员" align="center" prop="userName"/>
<el-table-column label="位" align="center" prop="postName"/> <el-table-column label="位" align="center" prop="postName"/>
<el-table-column label="金额" align="center" prop="amount"/> <el-table-column label="金额" align="center" prop="amount">
<template scope="scope">
{{toThousands(scope.row.amount)}}
</template>
</el-table-column>
<el-table-column label="比例" align="center" prop="rate"> <el-table-column label="比例" align="center" prop="rate">
<template scope="scope"> <template scope="scope">
{{scope.row.rate + '%'}} {{scope.row.rate + '%'}}
@ -119,8 +123,8 @@
<el-row :gutter="15"> <el-row :gutter="15">
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-col :span="12"> <el-col :span="12">
<el-form-item label="位" prop="postId"> <el-form-item label="位" prop="postId">
<el-select v-model="form.postId" placeholder="请选择位" @change="postChange"> <el-select v-model="form.postId" placeholder="请选择位" @change="postChange">
<el-option <el-option
v-for="dict in postIdOptions" v-for="dict in postIdOptions"
:key="dict.dictValue" :key="dict.dictValue"
@ -228,7 +232,7 @@
{required: true, message: "业务员不能为空", trigger: "change"} {required: true, message: "业务员不能为空", trigger: "change"}
], ],
postId: [ postId: [
{required: true, message: "位不能为空", trigger: "change"} {required: true, message: "位不能为空", trigger: "change"}
], ],
amount: [ amount: [
{required: true, message: "金额不能为空", trigger: "blur"} {required: true, message: "金额不能为空", trigger: "blur"}
@ -368,6 +372,7 @@
const ruleId = row.ruleId || this.ids const ruleId = row.ruleId || this.ids
getCommision(ruleId).then(response => { getCommision(ruleId).then(response => {
this.form = response.data; this.form = response.data;
this.userIdOptions = this.options[this.form.postId];
this.open = true; this.open = true;
this.title = "修改业务提成比例"; this.title = "修改业务提成比例";
}); });

View File

@ -1,8 +1,8 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px"> <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="位" prop="postId"> <el-form-item label="位" prop="postId">
<el-select v-model="queryParams.postId" placeholder="请选择位" clearable size="small" @change="searchPostChange"> <el-select v-model="queryParams.postId" placeholder="请选择位" clearable size="small" @change="searchPostChange">
<el-option <el-option
v-for="dict in postIdOptions" v-for="dict in postIdOptions"
:key="dict.dictValue" :key="dict.dictValue"
@ -52,14 +52,23 @@
<el-table v-loading="loading" :data="commisionList" <el-table v-loading="loading" :data="commisionList"
@selection-change="handleSelectionChange"> @selection-change="handleSelectionChange">
<el-table-column label="业务员" align="center" prop="userName"/> <el-table-column label="业务员" align="center" prop="userName"/>
<el-table-column label="位" align="center" prop="postName"/> <el-table-column label="位" align="center" prop="postName"/>
<el-table-column label="总金额" align="center" prop="amount"/> <el-table-column label="总金额" align="center" prop="amount">
<template scope="scope">
{{toThousands(scope.row.amount)}}
</template>
</el-table-column>
<el-table-column label="比例" align="center" prop="rate"> <el-table-column label="比例" align="center" prop="rate">
<template scope="scope"> <template scope="scope">
{{scope.row.rate + '%'}} {{scope.row.rate + '%'}}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="提成" align="center" prop="commision"/> <el-table-column label="提成" align="center" prop="commision">
<template scope="scope">
{{toThousands(scope.row.commision)}}
</template>
</el-table-column>
</el-table> </el-table>
<pagination <pagination

View File

@ -190,7 +190,11 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="客户姓名" align="center" prop="customer" width="120" fixed="left"/> <el-table-column label="客户姓名" align="center" prop="customer" width="120" fixed="left"/>
<el-table-column label="金额" align="center" prop="amount" width="120" fixed="left"/> <el-table-column label="金额" align="center" prop="amount" width="120" fixed="left">
<template scope="scope">
{{toThousands(scope.row.amount)}}
</template>
</el-table-column>
<el-table-column label="电话" align="center" prop="phone" width="120"/> <el-table-column label="电话" align="center" prop="phone" width="120"/>
<el-table-column label="服务月数" align="center" prop="serveMonth" width="80"/> <el-table-column label="服务月数" align="center" prop="serveMonth" width="80"/>
<el-table-column label="收款方式" align="center" prop="payType" width="120"/> <el-table-column label="收款方式" align="center" prop="payType" width="120"/>
@ -408,6 +412,7 @@
<script> <script>
import {listOrder, getOrder, delOrder, addOrder, updateOrder, exportOrder, getOptions} from "@/api/custom/order"; import {listOrder, getOrder, delOrder, addOrder, updateOrder, exportOrder, getOptions} from "@/api/custom/order";
import dayjs from 'dayjs'; import dayjs from 'dayjs';
const beginTime = dayjs().startOf('month').format('YYYY-MM-DD'); const beginTime = dayjs().startOf('month').format('YYYY-MM-DD');
const endTime = dayjs().format('YYYY-MM-DD'); const endTime = dayjs().format('YYYY-MM-DD');

View File

@ -57,7 +57,7 @@
<el-table-column label="用户编号" align="center" prop="userId" /> <el-table-column label="用户编号" align="center" prop="userId" />
<el-table-column label="用户名称" align="center" prop="userName" :show-overflow-tooltip="true" /> <el-table-column label="用户名称" align="center" prop="userName" :show-overflow-tooltip="true" />
<el-table-column label="用户昵称" align="center" prop="nickName" :show-overflow-tooltip="true" /> <el-table-column label="用户昵称" align="center" prop="nickName" :show-overflow-tooltip="true" />
<el-table-column label="部门" align="center" prop="dept.deptName" :show-overflow-tooltip="true" /> <el-table-column label="岗位" align="center" prop="postName" :show-overflow-tooltip="true" />
<el-table-column label="手机号码" align="center" prop="phonenumber" width="120" /> <el-table-column label="手机号码" align="center" prop="phonenumber" width="120" />
<el-table-column label="状态" align="center"> <el-table-column label="状态" align="center">
<template slot-scope="scope"> <template slot-scope="scope">

View File

@ -692,7 +692,7 @@ drop table if exists sys_commision;
create table sys_commision ( create table sys_commision (
rule_id bigint(20) not null auto_increment comment '编号', rule_id bigint(20) not null auto_increment comment '编号',
user_id bigint(20) comment '用户ID', user_id bigint(20) comment '用户ID',
post_id bigint(20) comment '位ID', post_id bigint(20) comment '位ID',
amount decimal(10,2) comment '金额', amount decimal(10,2) comment '金额',
rate float comment '分成比例', rate float comment '分成比例',
create_by varchar(64) default '' comment '创建者', create_by varchar(64) default '' comment '创建者',