新增服务中心3
This commit is contained in:
parent
51f973a679
commit
60f67dcd57
|
|
@ -1,7 +1,7 @@
|
|||
# 项目相关配置
|
||||
ruoyi:
|
||||
# 名称
|
||||
name: RuoYi
|
||||
name: BMW
|
||||
# 版本
|
||||
version: 3.4.0
|
||||
# 版权年份
|
||||
|
|
@ -9,7 +9,7 @@ ruoyi:
|
|||
# 实例演示开关
|
||||
demoEnabled: true
|
||||
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
|
||||
profile: D:/ruoyi/uploadPath
|
||||
profile: D:/bmw/uploadPath
|
||||
# 获取ip地址开关
|
||||
addressEnabled: true
|
||||
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ gen:
|
|||
# 作者
|
||||
author: bmw
|
||||
# 默认生成包路径 system 需改成自己的模块名称 如 system monitor tool
|
||||
packageName: com.bmw.system
|
||||
packageName: com.bmw.servicecenter
|
||||
# 自动去除表前缀,默认是true
|
||||
autoRemovePre: true
|
||||
# 表前缀(类名不会包含表前缀)
|
||||
tablePrefix: sys_
|
||||
tablePrefix: sc_
|
||||
|
|
@ -0,0 +1,127 @@
|
|||
package com.bmw.servicecenter.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.bmw.common.annotation.Log;
|
||||
import com.bmw.common.enums.BusinessType;
|
||||
import com.bmw.servicecenter.domain.Attendant;
|
||||
import com.bmw.servicecenter.service.IAttendantService;
|
||||
import com.bmw.common.core.controller.BaseController;
|
||||
import com.bmw.common.core.page.TableDataInfo;
|
||||
import com.bmw.common.core.domain.AjaxResult;
|
||||
import com.bmw.common.utils.poi.ExcelUtil;
|
||||
|
||||
/**
|
||||
* 服务员 信息操作处理
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/servicecenter/attendant")
|
||||
public class AttendantController extends BaseController
|
||||
{
|
||||
private String prefix = "servicecenter/attendant";
|
||||
|
||||
@Autowired
|
||||
private IAttendantService attendantService;
|
||||
|
||||
@RequiresPermissions("servicecenter:attendant:view")
|
||||
@GetMapping()
|
||||
public String attendant()
|
||||
{
|
||||
return prefix + "/attendant";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询服务员列表
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:attendant:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(Attendant attendant)
|
||||
{
|
||||
startPage();
|
||||
List<Attendant> list = attendantService.selectAttendantList(attendant);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 导出服务员列表
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:attendant:export")
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(Attendant attendant)
|
||||
{
|
||||
List<Attendant> list = attendantService.selectAttendantList(attendant);
|
||||
ExcelUtil<Attendant> util = new ExcelUtil<Attendant>(Attendant.class);
|
||||
return util.exportExcel(list, "attendant");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增服务员
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存服务员
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:attendant:add")
|
||||
@Log(title = "服务员", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(Attendant attendant)
|
||||
{
|
||||
return toAjax(attendantService.insertAttendant(attendant));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改服务员
|
||||
*/
|
||||
@GetMapping("/edit/{attendantId}")
|
||||
public String edit(@PathVariable("attendantId") Long attendantId, ModelMap mmap)
|
||||
{
|
||||
Attendant attendant = attendantService.selectAttendantById(attendantId);
|
||||
mmap.put("attendant", attendant);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存服务员
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:attendant:edit")
|
||||
@Log(title = "服务员", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(Attendant attendant)
|
||||
{
|
||||
return toAjax(attendantService.updateAttendant(attendant));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除服务员
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:attendant:remove")
|
||||
@Log(title = "服务员", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(attendantService.deleteAttendantByIds(ids));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,127 @@
|
|||
package com.bmw.servicecenter.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.bmw.common.annotation.Log;
|
||||
import com.bmw.common.enums.BusinessType;
|
||||
import com.bmw.servicecenter.domain.Member;
|
||||
import com.bmw.servicecenter.service.IMemberService;
|
||||
import com.bmw.common.core.controller.BaseController;
|
||||
import com.bmw.common.core.page.TableDataInfo;
|
||||
import com.bmw.common.core.domain.AjaxResult;
|
||||
import com.bmw.common.utils.poi.ExcelUtil;
|
||||
|
||||
/**
|
||||
* 客户 信息操作处理
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/servicecenter/member")
|
||||
public class MemberController extends BaseController
|
||||
{
|
||||
private String prefix = "servicecenter/member";
|
||||
|
||||
@Autowired
|
||||
private IMemberService memberService;
|
||||
|
||||
@RequiresPermissions("servicecenter:member:view")
|
||||
@GetMapping()
|
||||
public String member()
|
||||
{
|
||||
return prefix + "/member";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询客户列表
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:member:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(Member member)
|
||||
{
|
||||
startPage();
|
||||
List<Member> list = memberService.selectMemberList(member);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 导出客户列表
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:member:export")
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(Member member)
|
||||
{
|
||||
List<Member> list = memberService.selectMemberList(member);
|
||||
ExcelUtil<Member> util = new ExcelUtil<Member>(Member.class);
|
||||
return util.exportExcel(list, "member");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增客户
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存客户
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:member:add")
|
||||
@Log(title = "客户", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(Member member)
|
||||
{
|
||||
return toAjax(memberService.insertMember(member));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改客户
|
||||
*/
|
||||
@GetMapping("/edit/{memberId}")
|
||||
public String edit(@PathVariable("memberId") Long memberId, ModelMap mmap)
|
||||
{
|
||||
Member member = memberService.selectMemberById(memberId);
|
||||
mmap.put("member", member);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存客户
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:member:edit")
|
||||
@Log(title = "客户", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(Member member)
|
||||
{
|
||||
return toAjax(memberService.updateMember(member));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除客户
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:member:remove")
|
||||
@Log(title = "客户", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(memberService.deleteMemberByIds(ids));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,127 @@
|
|||
package com.bmw.servicecenter.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.bmw.common.annotation.Log;
|
||||
import com.bmw.common.enums.BusinessType;
|
||||
import com.bmw.servicecenter.domain.Order;
|
||||
import com.bmw.servicecenter.service.IOrderService;
|
||||
import com.bmw.common.core.controller.BaseController;
|
||||
import com.bmw.common.core.page.TableDataInfo;
|
||||
import com.bmw.common.core.domain.AjaxResult;
|
||||
import com.bmw.common.utils.poi.ExcelUtil;
|
||||
|
||||
/**
|
||||
* 订单 信息操作处理
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/servicecenter/order")
|
||||
public class OrderController extends BaseController
|
||||
{
|
||||
private String prefix = "servicecenter/order";
|
||||
|
||||
@Autowired
|
||||
private IOrderService orderService;
|
||||
|
||||
@RequiresPermissions("servicecenter:order:view")
|
||||
@GetMapping()
|
||||
public String order()
|
||||
{
|
||||
return prefix + "/order";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询订单列表
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:order:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(Order order)
|
||||
{
|
||||
startPage();
|
||||
List<Order> list = orderService.selectOrderList(order);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 导出订单列表
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:order:export")
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(Order order)
|
||||
{
|
||||
List<Order> list = orderService.selectOrderList(order);
|
||||
ExcelUtil<Order> util = new ExcelUtil<Order>(Order.class);
|
||||
return util.exportExcel(list, "order");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增订单
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存订单
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:order:add")
|
||||
@Log(title = "订单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(Order order)
|
||||
{
|
||||
return toAjax(orderService.insertOrder(order));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改订单
|
||||
*/
|
||||
@GetMapping("/edit/{orderId}")
|
||||
public String edit(@PathVariable("orderId") Long orderId, ModelMap mmap)
|
||||
{
|
||||
Order order = orderService.selectOrderById(orderId);
|
||||
mmap.put("order", order);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存订单
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:order:edit")
|
||||
@Log(title = "订单", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(Order order)
|
||||
{
|
||||
return toAjax(orderService.updateOrder(order));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除订单
|
||||
*/
|
||||
@RequiresPermissions("servicecenter:order:remove")
|
||||
@Log(title = "订单", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(orderService.deleteOrderByIds(ids));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -1,29 +0,0 @@
|
|||
package com.bmw.servicecenter.controller;
|
||||
import com.bmw.common.core.controller.BaseController;
|
||||
import com.bmw.common.core.page.TableDataInfo;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
|
||||
/**
|
||||
* @author mwu
|
||||
* @date 2019/7/26
|
||||
*/
|
||||
|
||||
@Controller
|
||||
@RequestMapping("/order")
|
||||
public class OrderViewController extends BaseController {
|
||||
|
||||
@RequiresPermissions("order:list:view")
|
||||
@GetMapping ("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list()
|
||||
{
|
||||
System.out.println("订单列表");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,174 @@
|
|||
package com.bmw.servicecenter.domain;
|
||||
|
||||
|
||||
import com.bmw.common.core.domain.BaseEntity;
|
||||
import com.bmw.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 服务员表 sc_attendant
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public class Attendant extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 客户ID */
|
||||
private Long attendantId;
|
||||
/** 用户昵称 */
|
||||
private String attendantName;
|
||||
/** 用户邮箱 */
|
||||
private String email;
|
||||
/** 手机号码 */
|
||||
private String phonenumber;
|
||||
/** 用户性别(0男 1女 2未知) */
|
||||
private String sex;
|
||||
/** 头像路径 */
|
||||
private String avatar;
|
||||
/** 密码 */
|
||||
private String password;
|
||||
/** 盐加密 */
|
||||
private String salt;
|
||||
/** 帐号状态(0正常 1停用) */
|
||||
private String status;
|
||||
/** 删除标志(0代表存在 2代表删除) */
|
||||
private String delFlag;
|
||||
/** 最后登陆IP */
|
||||
private String loginIp;
|
||||
/** 最后登陆时间 */
|
||||
private Date loginDate;
|
||||
|
||||
public void setAttendantId(Long attendantId)
|
||||
{
|
||||
this.attendantId = attendantId;
|
||||
}
|
||||
|
||||
public Long getAttendantId()
|
||||
{
|
||||
return attendantId;
|
||||
}
|
||||
public void setAttendantName(String attendantName)
|
||||
{
|
||||
this.attendantName = attendantName;
|
||||
}
|
||||
|
||||
public String getAttendantName()
|
||||
{
|
||||
return attendantName;
|
||||
}
|
||||
public void setEmail(String email)
|
||||
{
|
||||
this.email = email;
|
||||
}
|
||||
|
||||
public String getEmail()
|
||||
{
|
||||
return email;
|
||||
}
|
||||
public void setPhonenumber(String phonenumber)
|
||||
{
|
||||
this.phonenumber = phonenumber;
|
||||
}
|
||||
|
||||
public String getPhonenumber()
|
||||
{
|
||||
return phonenumber;
|
||||
}
|
||||
public void setSex(String sex)
|
||||
{
|
||||
this.sex = sex;
|
||||
}
|
||||
|
||||
public String getSex()
|
||||
{
|
||||
return sex;
|
||||
}
|
||||
public void setAvatar(String avatar)
|
||||
{
|
||||
this.avatar = avatar;
|
||||
}
|
||||
|
||||
public String getAvatar()
|
||||
{
|
||||
return avatar;
|
||||
}
|
||||
public void setPassword(String password)
|
||||
{
|
||||
this.password = password;
|
||||
}
|
||||
|
||||
public String getPassword()
|
||||
{
|
||||
return password;
|
||||
}
|
||||
public void setSalt(String salt)
|
||||
{
|
||||
this.salt = salt;
|
||||
}
|
||||
|
||||
public String getSalt()
|
||||
{
|
||||
return salt;
|
||||
}
|
||||
public void setStatus(String status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
public void setDelFlag(String delFlag)
|
||||
{
|
||||
this.delFlag = delFlag;
|
||||
}
|
||||
|
||||
public String getDelFlag()
|
||||
{
|
||||
return delFlag;
|
||||
}
|
||||
public void setLoginIp(String loginIp)
|
||||
{
|
||||
this.loginIp = loginIp;
|
||||
}
|
||||
|
||||
public String getLoginIp()
|
||||
{
|
||||
return loginIp;
|
||||
}
|
||||
public void setLoginDate(Date loginDate)
|
||||
{
|
||||
this.loginDate = loginDate;
|
||||
}
|
||||
|
||||
public Date getLoginDate()
|
||||
{
|
||||
return loginDate;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("attendantId", getAttendantId())
|
||||
.append("attendantName", getAttendantName())
|
||||
.append("email", getEmail())
|
||||
.append("phonenumber", getPhonenumber())
|
||||
.append("sex", getSex())
|
||||
.append("avatar", getAvatar())
|
||||
.append("password", getPassword())
|
||||
.append("salt", getSalt())
|
||||
.append("status", getStatus())
|
||||
.append("delFlag", getDelFlag())
|
||||
.append("loginIp", getLoginIp())
|
||||
.append("loginDate", getLoginDate())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,173 @@
|
|||
package com.bmw.servicecenter.domain;
|
||||
|
||||
|
||||
import com.bmw.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 客户表 sc_member
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public class Member extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 客户ID */
|
||||
private Long memberId;
|
||||
/** 用户昵称 */
|
||||
private String memberName;
|
||||
/** 用户邮箱 */
|
||||
private String email;
|
||||
/** 手机号码 */
|
||||
private String phonenumber;
|
||||
/** 用户性别(0男 1女 2未知) */
|
||||
private String sex;
|
||||
/** 头像路径 */
|
||||
private String avatar;
|
||||
/** 密码 */
|
||||
private String password;
|
||||
/** 盐加密 */
|
||||
private String salt;
|
||||
/** 帐号状态(0正常 1停用) */
|
||||
private String status;
|
||||
/** 删除标志(0代表存在 2代表删除) */
|
||||
private String delFlag;
|
||||
/** 最后登陆IP */
|
||||
private String loginIp;
|
||||
/** 最后登陆时间 */
|
||||
private Date loginDate;
|
||||
|
||||
public void setMemberId(Long memberId)
|
||||
{
|
||||
this.memberId = memberId;
|
||||
}
|
||||
|
||||
public Long getMemberId()
|
||||
{
|
||||
return memberId;
|
||||
}
|
||||
public void setMemberName(String memberName)
|
||||
{
|
||||
this.memberName = memberName;
|
||||
}
|
||||
|
||||
public String getMemberName()
|
||||
{
|
||||
return memberName;
|
||||
}
|
||||
public void setEmail(String email)
|
||||
{
|
||||
this.email = email;
|
||||
}
|
||||
|
||||
public String getEmail()
|
||||
{
|
||||
return email;
|
||||
}
|
||||
public void setPhonenumber(String phonenumber)
|
||||
{
|
||||
this.phonenumber = phonenumber;
|
||||
}
|
||||
|
||||
public String getPhonenumber()
|
||||
{
|
||||
return phonenumber;
|
||||
}
|
||||
public void setSex(String sex)
|
||||
{
|
||||
this.sex = sex;
|
||||
}
|
||||
|
||||
public String getSex()
|
||||
{
|
||||
return sex;
|
||||
}
|
||||
public void setAvatar(String avatar)
|
||||
{
|
||||
this.avatar = avatar;
|
||||
}
|
||||
|
||||
public String getAvatar()
|
||||
{
|
||||
return avatar;
|
||||
}
|
||||
public void setPassword(String password)
|
||||
{
|
||||
this.password = password;
|
||||
}
|
||||
|
||||
public String getPassword()
|
||||
{
|
||||
return password;
|
||||
}
|
||||
public void setSalt(String salt)
|
||||
{
|
||||
this.salt = salt;
|
||||
}
|
||||
|
||||
public String getSalt()
|
||||
{
|
||||
return salt;
|
||||
}
|
||||
public void setStatus(String status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
public void setDelFlag(String delFlag)
|
||||
{
|
||||
this.delFlag = delFlag;
|
||||
}
|
||||
|
||||
public String getDelFlag()
|
||||
{
|
||||
return delFlag;
|
||||
}
|
||||
public void setLoginIp(String loginIp)
|
||||
{
|
||||
this.loginIp = loginIp;
|
||||
}
|
||||
|
||||
public String getLoginIp()
|
||||
{
|
||||
return loginIp;
|
||||
}
|
||||
public void setLoginDate(Date loginDate)
|
||||
{
|
||||
this.loginDate = loginDate;
|
||||
}
|
||||
|
||||
public Date getLoginDate()
|
||||
{
|
||||
return loginDate;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("memberId", getMemberId())
|
||||
.append("memberName", getMemberName())
|
||||
.append("email", getEmail())
|
||||
.append("phonenumber", getPhonenumber())
|
||||
.append("sex", getSex())
|
||||
.append("avatar", getAvatar())
|
||||
.append("password", getPassword())
|
||||
.append("salt", getSalt())
|
||||
.append("status", getStatus())
|
||||
.append("delFlag", getDelFlag())
|
||||
.append("loginIp", getLoginIp())
|
||||
.append("loginDate", getLoginDate())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,63 @@
|
|||
package com.bmw.servicecenter.domain;
|
||||
|
||||
|
||||
import com.bmw.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 订单表 sc_order
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public class Order extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 订单ID */
|
||||
private Long orderId;
|
||||
/** 客户ID */
|
||||
private Long memberId;
|
||||
/** 服务员ID */
|
||||
private Long attendantId;
|
||||
|
||||
public void setOrderId(Long orderId)
|
||||
{
|
||||
this.orderId = orderId;
|
||||
}
|
||||
|
||||
public Long getOrderId()
|
||||
{
|
||||
return orderId;
|
||||
}
|
||||
public void setMemberId(Long memberId)
|
||||
{
|
||||
this.memberId = memberId;
|
||||
}
|
||||
|
||||
public Long getMemberId()
|
||||
{
|
||||
return memberId;
|
||||
}
|
||||
public void setAttendantId(Long attendantId)
|
||||
{
|
||||
this.attendantId = attendantId;
|
||||
}
|
||||
|
||||
public Long getAttendantId()
|
||||
{
|
||||
return attendantId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("orderId", getOrderId())
|
||||
.append("memberId", getMemberId())
|
||||
.append("attendantId", getAttendantId())
|
||||
.append("remark", getRemark())
|
||||
.append("createTime", getCreateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.bmw.servicecenter.mapper;
|
||||
|
||||
import com.bmw.servicecenter.domain.Attendant;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 服务员 数据层
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public interface AttendantMapper
|
||||
{
|
||||
/**
|
||||
* 查询服务员信息
|
||||
*
|
||||
* @param attendantId 服务员ID
|
||||
* @return 服务员信息
|
||||
*/
|
||||
public Attendant selectAttendantById(Long attendantId);
|
||||
|
||||
/**
|
||||
* 查询服务员列表
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 服务员集合
|
||||
*/
|
||||
public List<Attendant> selectAttendantList(Attendant attendant);
|
||||
|
||||
/**
|
||||
* 新增服务员
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertAttendant(Attendant attendant);
|
||||
|
||||
/**
|
||||
* 修改服务员
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateAttendant(Attendant attendant);
|
||||
|
||||
/**
|
||||
* 删除服务员
|
||||
*
|
||||
* @param attendantId 服务员ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAttendantById(Long attendantId);
|
||||
|
||||
/**
|
||||
* 批量删除服务员
|
||||
*
|
||||
* @param attendantIds 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAttendantByIds(String[] attendantIds);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.bmw.servicecenter.mapper;
|
||||
|
||||
import com.bmw.servicecenter.domain.Member;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 客户 数据层
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public interface MemberMapper
|
||||
{
|
||||
/**
|
||||
* 查询客户信息
|
||||
*
|
||||
* @param memberId 客户ID
|
||||
* @return 客户信息
|
||||
*/
|
||||
public Member selectMemberById(Long memberId);
|
||||
|
||||
/**
|
||||
* 查询客户列表
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 客户集合
|
||||
*/
|
||||
public List<Member> selectMemberList(Member member);
|
||||
|
||||
/**
|
||||
* 新增客户
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMember(Member member);
|
||||
|
||||
/**
|
||||
* 修改客户
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMember(Member member);
|
||||
|
||||
/**
|
||||
* 删除客户
|
||||
*
|
||||
* @param memberId 客户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMemberById(Long memberId);
|
||||
|
||||
/**
|
||||
* 批量删除客户
|
||||
*
|
||||
* @param memberIds 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMemberByIds(String[] memberIds);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.bmw.servicecenter.mapper;
|
||||
|
||||
import com.bmw.servicecenter.domain.Order;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 订单 数据层
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public interface OrderMapper
|
||||
{
|
||||
/**
|
||||
* 查询订单信息
|
||||
*
|
||||
* @param orderId 订单ID
|
||||
* @return 订单信息
|
||||
*/
|
||||
public Order selectOrderById(Long orderId);
|
||||
|
||||
/**
|
||||
* 查询订单列表
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 订单集合
|
||||
*/
|
||||
public List<Order> selectOrderList(Order order);
|
||||
|
||||
/**
|
||||
* 新增订单
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertOrder(Order order);
|
||||
|
||||
/**
|
||||
* 修改订单
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateOrder(Order order);
|
||||
|
||||
/**
|
||||
* 删除订单
|
||||
*
|
||||
* @param orderId 订单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteOrderById(Long orderId);
|
||||
|
||||
/**
|
||||
* 批量删除订单
|
||||
*
|
||||
* @param orderIds 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteOrderByIds(String[] orderIds);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
package com.bmw.servicecenter.service;
|
||||
|
||||
import com.bmw.servicecenter.domain.Attendant;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 服务员 服务层
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public interface IAttendantService
|
||||
{
|
||||
/**
|
||||
* 查询服务员信息
|
||||
*
|
||||
* @param attendantId 服务员ID
|
||||
* @return 服务员信息
|
||||
*/
|
||||
public Attendant selectAttendantById(Long attendantId);
|
||||
|
||||
/**
|
||||
* 查询服务员列表
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 服务员集合
|
||||
*/
|
||||
public List<Attendant> selectAttendantList(Attendant attendant);
|
||||
|
||||
/**
|
||||
* 新增服务员
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertAttendant(Attendant attendant);
|
||||
|
||||
/**
|
||||
* 修改服务员
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateAttendant(Attendant attendant);
|
||||
|
||||
/**
|
||||
* 删除服务员信息
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAttendantByIds(String ids);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
package com.bmw.servicecenter.service;
|
||||
|
||||
import com.bmw.servicecenter.domain.Member;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 客户 服务层
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public interface IMemberService
|
||||
{
|
||||
/**
|
||||
* 查询客户信息
|
||||
*
|
||||
* @param memberId 客户ID
|
||||
* @return 客户信息
|
||||
*/
|
||||
public Member selectMemberById(Long memberId);
|
||||
|
||||
/**
|
||||
* 查询客户列表
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 客户集合
|
||||
*/
|
||||
public List<Member> selectMemberList(Member member);
|
||||
|
||||
/**
|
||||
* 新增客户
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMember(Member member);
|
||||
|
||||
/**
|
||||
* 修改客户
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMember(Member member);
|
||||
|
||||
/**
|
||||
* 删除客户信息
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMemberByIds(String ids);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
package com.bmw.servicecenter.service;
|
||||
|
||||
import com.bmw.servicecenter.domain.Order;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 订单 服务层
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
public interface IOrderService
|
||||
{
|
||||
/**
|
||||
* 查询订单信息
|
||||
*
|
||||
* @param orderId 订单ID
|
||||
* @return 订单信息
|
||||
*/
|
||||
public Order selectOrderById(Long orderId);
|
||||
|
||||
/**
|
||||
* 查询订单列表
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 订单集合
|
||||
*/
|
||||
public List<Order> selectOrderList(Order order);
|
||||
|
||||
/**
|
||||
* 新增订单
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertOrder(Order order);
|
||||
|
||||
/**
|
||||
* 修改订单
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateOrder(Order order);
|
||||
|
||||
/**
|
||||
* 删除订单信息
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteOrderByIds(String ids);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,83 @@
|
|||
package com.bmw.servicecenter.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.bmw.servicecenter.mapper.AttendantMapper;
|
||||
import com.bmw.servicecenter.domain.Attendant;
|
||||
import com.bmw.servicecenter.service.IAttendantService;
|
||||
import com.bmw.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 服务员 服务层实现
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
@Service
|
||||
public class AttendantServiceImpl implements IAttendantService
|
||||
{
|
||||
@Autowired
|
||||
private AttendantMapper attendantMapper;
|
||||
|
||||
/**
|
||||
* 查询服务员信息
|
||||
*
|
||||
* @param attendantId 服务员ID
|
||||
* @return 服务员信息
|
||||
*/
|
||||
@Override
|
||||
public Attendant selectAttendantById(Long attendantId)
|
||||
{
|
||||
return attendantMapper.selectAttendantById(attendantId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询服务员列表
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 服务员集合
|
||||
*/
|
||||
@Override
|
||||
public List<Attendant> selectAttendantList(Attendant attendant)
|
||||
{
|
||||
return attendantMapper.selectAttendantList(attendant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增服务员
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertAttendant(Attendant attendant)
|
||||
{
|
||||
return attendantMapper.insertAttendant(attendant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改服务员
|
||||
*
|
||||
* @param attendant 服务员信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateAttendant(Attendant attendant)
|
||||
{
|
||||
return attendantMapper.updateAttendant(attendant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除服务员对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteAttendantByIds(String ids)
|
||||
{
|
||||
return attendantMapper.deleteAttendantByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,83 @@
|
|||
package com.bmw.servicecenter.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.bmw.servicecenter.mapper.MemberMapper;
|
||||
import com.bmw.servicecenter.domain.Member;
|
||||
import com.bmw.servicecenter.service.IMemberService;
|
||||
import com.bmw.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 客户 服务层实现
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
@Service
|
||||
public class MemberServiceImpl implements IMemberService
|
||||
{
|
||||
@Autowired
|
||||
private MemberMapper memberMapper;
|
||||
|
||||
/**
|
||||
* 查询客户信息
|
||||
*
|
||||
* @param memberId 客户ID
|
||||
* @return 客户信息
|
||||
*/
|
||||
@Override
|
||||
public Member selectMemberById(Long memberId)
|
||||
{
|
||||
return memberMapper.selectMemberById(memberId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询客户列表
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 客户集合
|
||||
*/
|
||||
@Override
|
||||
public List<Member> selectMemberList(Member member)
|
||||
{
|
||||
return memberMapper.selectMemberList(member);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增客户
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertMember(Member member)
|
||||
{
|
||||
return memberMapper.insertMember(member);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改客户
|
||||
*
|
||||
* @param member 客户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateMember(Member member)
|
||||
{
|
||||
return memberMapper.updateMember(member);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除客户对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteMemberByIds(String ids)
|
||||
{
|
||||
return memberMapper.deleteMemberByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,83 @@
|
|||
package com.bmw.servicecenter.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.bmw.servicecenter.mapper.OrderMapper;
|
||||
import com.bmw.servicecenter.domain.Order;
|
||||
import com.bmw.servicecenter.service.IOrderService;
|
||||
import com.bmw.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 订单 服务层实现
|
||||
*
|
||||
* @author bmw
|
||||
* @date 2019-07-26
|
||||
*/
|
||||
@Service
|
||||
public class OrderServiceImpl implements IOrderService
|
||||
{
|
||||
@Autowired
|
||||
private OrderMapper orderMapper;
|
||||
|
||||
/**
|
||||
* 查询订单信息
|
||||
*
|
||||
* @param orderId 订单ID
|
||||
* @return 订单信息
|
||||
*/
|
||||
@Override
|
||||
public Order selectOrderById(Long orderId)
|
||||
{
|
||||
return orderMapper.selectOrderById(orderId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询订单列表
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 订单集合
|
||||
*/
|
||||
@Override
|
||||
public List<Order> selectOrderList(Order order)
|
||||
{
|
||||
return orderMapper.selectOrderList(order);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增订单
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertOrder(Order order)
|
||||
{
|
||||
return orderMapper.insertOrder(order);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改订单
|
||||
*
|
||||
* @param order 订单信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateOrder(Order order)
|
||||
{
|
||||
return orderMapper.updateOrder(order);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除订单对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteOrderByIds(String ids)
|
||||
{
|
||||
return orderMapper.deleteOrderByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,118 @@
|
|||
<?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.bmw.servicecenter.mapper.AttendantMapper">
|
||||
|
||||
<resultMap type="Attendant" id="AttendantResult">
|
||||
<result property="attendantId" column="attendant_id" />
|
||||
<result property="attendantName" column="attendant_name" />
|
||||
<result property="email" column="email" />
|
||||
<result property="phonenumber" column="phonenumber" />
|
||||
<result property="sex" column="sex" />
|
||||
<result property="avatar" column="avatar" />
|
||||
<result property="password" column="password" />
|
||||
<result property="salt" column="salt" />
|
||||
<result property="status" column="status" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
<result property="loginIp" column="login_ip" />
|
||||
<result property="loginDate" column="login_date" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectAttendantVo">
|
||||
select attendant_id, attendant_name, email, phonenumber, sex, avatar, password, salt, status, del_flag, login_ip, login_date, create_time, remark from sc_attendant
|
||||
</sql>
|
||||
|
||||
<select id="selectAttendantList" parameterType="Attendant" resultMap="AttendantResult">
|
||||
<include refid="selectAttendantVo"/>
|
||||
<where>
|
||||
<if test="attendantId != null "> and attendant_id = #{attendantId}</if>
|
||||
<if test="attendantName != null and attendantName != '' "> and attendant_name = #{attendantName}</if>
|
||||
<if test="email != null and email != '' "> and email = #{email}</if>
|
||||
<if test="phonenumber != null and phonenumber != '' "> and phonenumber = #{phonenumber}</if>
|
||||
<if test="sex != null and sex != '' "> and sex = #{sex}</if>
|
||||
<if test="avatar != null and avatar != '' "> and avatar = #{avatar}</if>
|
||||
<if test="password != null and password != '' "> and password = #{password}</if>
|
||||
<if test="salt != null and salt != '' "> and salt = #{salt}</if>
|
||||
<if test="status != null and status != '' "> and status = #{status}</if>
|
||||
<if test="delFlag != null and delFlag != '' "> and del_flag = #{delFlag}</if>
|
||||
<if test="loginIp != null and loginIp != '' "> and login_ip = #{loginIp}</if>
|
||||
<if test="loginDate != null "> and login_date = #{loginDate}</if>
|
||||
<if test="createTime != null "> and create_time = #{createTime}</if>
|
||||
<if test="remark != null and remark != '' "> and remark = #{remark}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectAttendantById" parameterType="Long" resultMap="AttendantResult">
|
||||
<include refid="selectAttendantVo"/>
|
||||
where attendant_id = #{attendantId}
|
||||
</select>
|
||||
|
||||
<insert id="insertAttendant" parameterType="Attendant" useGeneratedKeys="true" keyProperty="attendantId">
|
||||
insert into sc_attendant
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="attendantName != null and attendantName != '' ">attendant_name,</if>
|
||||
<if test="email != null and email != '' ">email,</if>
|
||||
<if test="phonenumber != null and phonenumber != '' ">phonenumber,</if>
|
||||
<if test="sex != null and sex != '' ">sex,</if>
|
||||
<if test="avatar != null and avatar != '' ">avatar,</if>
|
||||
<if test="password != null and password != '' ">password,</if>
|
||||
<if test="salt != null and salt != '' ">salt,</if>
|
||||
<if test="status != null and status != '' ">status,</if>
|
||||
<if test="delFlag != null and delFlag != '' ">del_flag,</if>
|
||||
<if test="loginIp != null and loginIp != '' ">login_ip,</if>
|
||||
<if test="loginDate != null ">login_date,</if>
|
||||
<if test="createTime != null ">create_time,</if>
|
||||
<if test="remark != null and remark != '' ">remark,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="attendantName != null and attendantName != '' ">#{attendantName},</if>
|
||||
<if test="email != null and email != '' ">#{email},</if>
|
||||
<if test="phonenumber != null and phonenumber != '' ">#{phonenumber},</if>
|
||||
<if test="sex != null and sex != '' ">#{sex},</if>
|
||||
<if test="avatar != null and avatar != '' ">#{avatar},</if>
|
||||
<if test="password != null and password != '' ">#{password},</if>
|
||||
<if test="salt != null and salt != '' ">#{salt},</if>
|
||||
<if test="status != null and status != '' ">#{status},</if>
|
||||
<if test="delFlag != null and delFlag != '' ">#{delFlag},</if>
|
||||
<if test="loginIp != null and loginIp != '' ">#{loginIp},</if>
|
||||
<if test="loginDate != null ">#{loginDate},</if>
|
||||
<if test="createTime != null ">#{createTime},</if>
|
||||
<if test="remark != null and remark != '' ">#{remark},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateAttendant" parameterType="Attendant">
|
||||
update sc_attendant
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="attendantName != null and attendantName != '' ">attendant_name = #{attendantName},</if>
|
||||
<if test="email != null and email != '' ">email = #{email},</if>
|
||||
<if test="phonenumber != null and phonenumber != '' ">phonenumber = #{phonenumber},</if>
|
||||
<if test="sex != null and sex != '' ">sex = #{sex},</if>
|
||||
<if test="avatar != null and avatar != '' ">avatar = #{avatar},</if>
|
||||
<if test="password != null and password != '' ">password = #{password},</if>
|
||||
<if test="salt != null and salt != '' ">salt = #{salt},</if>
|
||||
<if test="status != null and status != '' ">status = #{status},</if>
|
||||
<if test="delFlag != null and delFlag != '' ">del_flag = #{delFlag},</if>
|
||||
<if test="loginIp != null and loginIp != '' ">login_ip = #{loginIp},</if>
|
||||
<if test="loginDate != null ">login_date = #{loginDate},</if>
|
||||
<if test="createTime != null ">create_time = #{createTime},</if>
|
||||
<if test="remark != null and remark != '' ">remark = #{remark},</if>
|
||||
</trim>
|
||||
where attendant_id = #{attendantId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteAttendantById" parameterType="Long">
|
||||
delete from sc_attendant where attendant_id = #{attendantId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteAttendantByIds" parameterType="String">
|
||||
delete from sc_attendant where attendant_id in
|
||||
<foreach item="attendantId" collection="array" open="(" separator="," close=")">
|
||||
#{attendantId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
</mapper>
|
||||
|
|
@ -0,0 +1,118 @@
|
|||
<?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.bmw.servicecenter.mapper.MemberMapper">
|
||||
|
||||
<resultMap type="Member" id="MemberResult">
|
||||
<result property="memberId" column="member_id" />
|
||||
<result property="memberName" column="member_name" />
|
||||
<result property="email" column="email" />
|
||||
<result property="phonenumber" column="phonenumber" />
|
||||
<result property="sex" column="sex" />
|
||||
<result property="avatar" column="avatar" />
|
||||
<result property="password" column="password" />
|
||||
<result property="salt" column="salt" />
|
||||
<result property="status" column="status" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
<result property="loginIp" column="login_ip" />
|
||||
<result property="loginDate" column="login_date" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectMemberVo">
|
||||
select member_id, member_name, email, phonenumber, sex, avatar, password, salt, status, del_flag, login_ip, login_date, create_time, remark from sc_member
|
||||
</sql>
|
||||
|
||||
<select id="selectMemberList" parameterType="Member" resultMap="MemberResult">
|
||||
<include refid="selectMemberVo"/>
|
||||
<where>
|
||||
<if test="memberId != null "> and member_id = #{memberId}</if>
|
||||
<if test="memberName != null and memberName != '' "> and member_name = #{memberName}</if>
|
||||
<if test="email != null and email != '' "> and email = #{email}</if>
|
||||
<if test="phonenumber != null and phonenumber != '' "> and phonenumber = #{phonenumber}</if>
|
||||
<if test="sex != null and sex != '' "> and sex = #{sex}</if>
|
||||
<if test="avatar != null and avatar != '' "> and avatar = #{avatar}</if>
|
||||
<if test="password != null and password != '' "> and password = #{password}</if>
|
||||
<if test="salt != null and salt != '' "> and salt = #{salt}</if>
|
||||
<if test="status != null and status != '' "> and status = #{status}</if>
|
||||
<if test="delFlag != null and delFlag != '' "> and del_flag = #{delFlag}</if>
|
||||
<if test="loginIp != null and loginIp != '' "> and login_ip = #{loginIp}</if>
|
||||
<if test="loginDate != null "> and login_date = #{loginDate}</if>
|
||||
<if test="createTime != null "> and create_time = #{createTime}</if>
|
||||
<if test="remark != null and remark != '' "> and remark = #{remark}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectMemberById" parameterType="Long" resultMap="MemberResult">
|
||||
<include refid="selectMemberVo"/>
|
||||
where member_id = #{memberId}
|
||||
</select>
|
||||
|
||||
<insert id="insertMember" parameterType="Member" useGeneratedKeys="true" keyProperty="memberId">
|
||||
insert into sc_member
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="memberName != null and memberName != '' ">member_name,</if>
|
||||
<if test="email != null and email != '' ">email,</if>
|
||||
<if test="phonenumber != null and phonenumber != '' ">phonenumber,</if>
|
||||
<if test="sex != null and sex != '' ">sex,</if>
|
||||
<if test="avatar != null and avatar != '' ">avatar,</if>
|
||||
<if test="password != null and password != '' ">password,</if>
|
||||
<if test="salt != null and salt != '' ">salt,</if>
|
||||
<if test="status != null and status != '' ">status,</if>
|
||||
<if test="delFlag != null and delFlag != '' ">del_flag,</if>
|
||||
<if test="loginIp != null and loginIp != '' ">login_ip,</if>
|
||||
<if test="loginDate != null ">login_date,</if>
|
||||
<if test="createTime != null ">create_time,</if>
|
||||
<if test="remark != null and remark != '' ">remark,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="memberName != null and memberName != '' ">#{memberName},</if>
|
||||
<if test="email != null and email != '' ">#{email},</if>
|
||||
<if test="phonenumber != null and phonenumber != '' ">#{phonenumber},</if>
|
||||
<if test="sex != null and sex != '' ">#{sex},</if>
|
||||
<if test="avatar != null and avatar != '' ">#{avatar},</if>
|
||||
<if test="password != null and password != '' ">#{password},</if>
|
||||
<if test="salt != null and salt != '' ">#{salt},</if>
|
||||
<if test="status != null and status != '' ">#{status},</if>
|
||||
<if test="delFlag != null and delFlag != '' ">#{delFlag},</if>
|
||||
<if test="loginIp != null and loginIp != '' ">#{loginIp},</if>
|
||||
<if test="loginDate != null ">#{loginDate},</if>
|
||||
<if test="createTime != null ">#{createTime},</if>
|
||||
<if test="remark != null and remark != '' ">#{remark},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateMember" parameterType="Member">
|
||||
update sc_member
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="memberName != null and memberName != '' ">member_name = #{memberName},</if>
|
||||
<if test="email != null and email != '' ">email = #{email},</if>
|
||||
<if test="phonenumber != null and phonenumber != '' ">phonenumber = #{phonenumber},</if>
|
||||
<if test="sex != null and sex != '' ">sex = #{sex},</if>
|
||||
<if test="avatar != null and avatar != '' ">avatar = #{avatar},</if>
|
||||
<if test="password != null and password != '' ">password = #{password},</if>
|
||||
<if test="salt != null and salt != '' ">salt = #{salt},</if>
|
||||
<if test="status != null and status != '' ">status = #{status},</if>
|
||||
<if test="delFlag != null and delFlag != '' ">del_flag = #{delFlag},</if>
|
||||
<if test="loginIp != null and loginIp != '' ">login_ip = #{loginIp},</if>
|
||||
<if test="loginDate != null ">login_date = #{loginDate},</if>
|
||||
<if test="createTime != null ">create_time = #{createTime},</if>
|
||||
<if test="remark != null and remark != '' ">remark = #{remark},</if>
|
||||
</trim>
|
||||
where member_id = #{memberId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteMemberById" parameterType="Long">
|
||||
delete from sc_member where member_id = #{memberId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteMemberByIds" parameterType="String">
|
||||
delete from sc_member where member_id in
|
||||
<foreach item="memberId" collection="array" open="(" separator="," close=")">
|
||||
#{memberId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
</mapper>
|
||||
|
|
@ -0,0 +1,73 @@
|
|||
<?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.bmw.servicecenter.mapper.OrderMapper">
|
||||
|
||||
<resultMap type="Order" id="OrderResult">
|
||||
<result property="orderId" column="order_id" />
|
||||
<result property="memberId" column="member_id" />
|
||||
<result property="attendantId" column="attendant_id" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createTime" column="create_time" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectOrderVo">
|
||||
select order_id, member_id, attendant_id, remark, create_time from sc_order
|
||||
</sql>
|
||||
|
||||
<select id="selectOrderList" parameterType="Order" resultMap="OrderResult">
|
||||
<include refid="selectOrderVo"/>
|
||||
<where>
|
||||
<if test="orderId != null "> and order_id = #{orderId}</if>
|
||||
<if test="memberId != null "> and member_id = #{memberId}</if>
|
||||
<if test="attendantId != null "> and attendant_id = #{attendantId}</if>
|
||||
<if test="remark != null and remark != '' "> and remark = #{remark}</if>
|
||||
<if test="createTime != null "> and create_time = #{createTime}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectOrderById" parameterType="Long" resultMap="OrderResult">
|
||||
<include refid="selectOrderVo"/>
|
||||
where order_id = #{orderId}
|
||||
</select>
|
||||
|
||||
<insert id="insertOrder" parameterType="Order" useGeneratedKeys="true" keyProperty="orderId">
|
||||
insert into sc_order
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="memberId != null ">member_id,</if>
|
||||
<if test="attendantId != null ">attendant_id,</if>
|
||||
<if test="remark != null and remark != '' ">remark,</if>
|
||||
<if test="createTime != null ">create_time,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="memberId != null ">#{memberId},</if>
|
||||
<if test="attendantId != null ">#{attendantId},</if>
|
||||
<if test="remark != null and remark != '' ">#{remark},</if>
|
||||
<if test="createTime != null ">#{createTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateOrder" parameterType="Order">
|
||||
update sc_order
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="memberId != null ">member_id = #{memberId},</if>
|
||||
<if test="attendantId != null ">attendant_id = #{attendantId},</if>
|
||||
<if test="remark != null and remark != '' ">remark = #{remark},</if>
|
||||
<if test="createTime != null ">create_time = #{createTime},</if>
|
||||
</trim>
|
||||
where order_id = #{orderId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteOrderById" parameterType="Long">
|
||||
delete from sc_order where order_id = #{orderId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteOrderByIds" parameterType="String">
|
||||
delete from sc_order where order_id in
|
||||
<foreach item="orderId" collection="array" open="(" separator="," close=")">
|
||||
#{orderId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
</mapper>
|
||||
|
|
@ -0,0 +1,108 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('新增服务员')" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-attendant-add">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户昵称:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="attendantName" name="attendantName" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户邮箱:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="email" name="email" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">手机号码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="phonenumber" name="phonenumber" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户性别(0男 1女 2未知):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="sex" name="sex" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">头像路径:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="avatar" name="avatar" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">密码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="password" name="password" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">盐加密:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="salt" name="salt" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">帐号状态(0正常 1停用):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="status" name="status" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">删除标志(0代表存在 2代表删除):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="delFlag" name="delFlag" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆IP:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginIp" name="loginIp" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginDate" name="loginDate" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">创建时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="createTime" name="createTime" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">备注:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="remark" name="remark" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div th:include="include::footer"></div>
|
||||
<script type="text/javascript">
|
||||
var prefix = ctx + "servicecenter/attendant"
|
||||
$("#form-attendant-add").validate({
|
||||
rules:{
|
||||
xxxx:{
|
||||
required:true,
|
||||
},
|
||||
},
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
if ($.validate.form()) {
|
||||
$.operate.save(prefix + "/add", $('#form-attendant-add').serialize());
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,196 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||
<head>
|
||||
<th:block th:include="include :: header('服务员列表')" />
|
||||
</head>
|
||||
<body class="gray-bg">
|
||||
<div class="container-div">
|
||||
<div class="row">
|
||||
<div class="col-sm-12 search-collapse">
|
||||
<form id="formId">
|
||||
<div class="select-list">
|
||||
<ul>
|
||||
<li>
|
||||
用户昵称:<input type="text" name="attendantName"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
用户邮箱:<input type="text" name="email"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
手机号码:<input type="text" name="phonenumber"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
用户性别(0男 1女 2未知):<input type="text" name="sex"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
头像路径:<input type="text" name="avatar"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
密码:<input type="text" name="password"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
盐加密:<input type="text" name="salt"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
帐号状态(0正常 1停用):<input type="text" name="status"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
删除标志(0代表存在 2代表删除):<input type="text" name="delFlag"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
最后登陆IP:<input type="text" name="loginIp"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
最后登陆时间:<input type="text" name="loginDate"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
创建时间:<input type="text" name="createTime"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
备注:<input type="text" name="remark"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="btn-group-sm" id="toolbar" role="group">
|
||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="servicecenter:attendant:add">
|
||||
<i class="fa fa-plus"></i> 添加
|
||||
</a>
|
||||
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="servicecenter:attendant:edit">
|
||||
<i class="fa fa-edit"></i> 修改
|
||||
</a>
|
||||
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="servicecenter:attendant:remove">
|
||||
<i class="fa fa-remove"></i> 删除
|
||||
</a>
|
||||
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="servicecenter:attendant:export">
|
||||
<i class="fa fa-download"></i> 导出
|
||||
</a>
|
||||
</div>
|
||||
<div class="col-sm-12 select-table table-striped">
|
||||
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div th:include="include :: footer"></div>
|
||||
<script th:inline="javascript">
|
||||
var editFlag = [[${@permission.hasPermi('servicecenter:attendant:edit')}]];
|
||||
var removeFlag = [[${@permission.hasPermi('servicecenter:attendant:remove')}]];
|
||||
var prefix = ctx + "servicecenter/attendant";
|
||||
|
||||
$(function() {
|
||||
var options = {
|
||||
url: prefix + "/list",
|
||||
createUrl: prefix + "/add",
|
||||
updateUrl: prefix + "/edit/{id}",
|
||||
removeUrl: prefix + "/remove",
|
||||
exportUrl: prefix + "/export",
|
||||
modalName: "服务员",
|
||||
showExport: true,
|
||||
columns: [{
|
||||
checkbox: true
|
||||
},
|
||||
{
|
||||
field : 'attendantId',
|
||||
title : '客户ID',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field : 'attendantName',
|
||||
title : '用户昵称',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'email',
|
||||
title : '用户邮箱',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'phonenumber',
|
||||
title : '手机号码',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'sex',
|
||||
title : '用户性别(0男 1女 2未知)',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'avatar',
|
||||
title : '头像路径',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'password',
|
||||
title : '密码',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'salt',
|
||||
title : '盐加密',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'status',
|
||||
title : '帐号状态(0正常 1停用)',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'delFlag',
|
||||
title : '删除标志(0代表存在 2代表删除)',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'loginIp',
|
||||
title : '最后登陆IP',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'loginDate',
|
||||
title : '最后登陆时间',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'createTime',
|
||||
title : '创建时间',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'remark',
|
||||
title : '备注',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
formatter: function(value, row, index) {
|
||||
var actions = [];
|
||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.attendantId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.attendantId + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||
return actions.join('');
|
||||
}
|
||||
}]
|
||||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,109 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('修改服务员')" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-attendant-edit" th:object="${attendant}">
|
||||
<input id="attendantId" name="attendantId" th:field="*{attendantId}" type="hidden">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户昵称:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="attendantName" name="attendantName" th:field="*{attendantName}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户邮箱:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="email" name="email" th:field="*{email}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">手机号码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="phonenumber" name="phonenumber" th:field="*{phonenumber}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户性别(0男 1女 2未知):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="sex" name="sex" th:field="*{sex}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">头像路径:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="avatar" name="avatar" th:field="*{avatar}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">密码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="password" name="password" th:field="*{password}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">盐加密:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="salt" name="salt" th:field="*{salt}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">帐号状态(0正常 1停用):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="status" name="status" th:field="*{status}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">删除标志(0代表存在 2代表删除):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="delFlag" name="delFlag" th:field="*{delFlag}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆IP:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginIp" name="loginIp" th:field="*{loginIp}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginDate" name="loginDate" th:field="*{loginDate}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">创建时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="createTime" name="createTime" th:field="*{createTime}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">备注:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="remark" name="remark" th:field="*{remark}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div th:include="include::footer"></div>
|
||||
<script type="text/javascript">
|
||||
var prefix = ctx + "servicecenter/attendant";
|
||||
$("#form-attendant-edit").validate({
|
||||
rules:{
|
||||
xxxx:{
|
||||
required:true,
|
||||
},
|
||||
},
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
if ($.validate.form()) {
|
||||
$.operate.save(prefix + "/edit", $('#form-attendant-edit').serialize());
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,108 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('新增客户')" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-member-add">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户昵称:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="memberName" name="memberName" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户邮箱:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="email" name="email" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">手机号码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="phonenumber" name="phonenumber" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户性别(0男 1女 2未知):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="sex" name="sex" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">头像路径:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="avatar" name="avatar" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">密码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="password" name="password" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">盐加密:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="salt" name="salt" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">帐号状态(0正常 1停用):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="status" name="status" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">删除标志(0代表存在 2代表删除):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="delFlag" name="delFlag" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆IP:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginIp" name="loginIp" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginDate" name="loginDate" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">创建时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="createTime" name="createTime" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">备注:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="remark" name="remark" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div th:include="include::footer"></div>
|
||||
<script type="text/javascript">
|
||||
var prefix = ctx + "servicecenter/member"
|
||||
$("#form-member-add").validate({
|
||||
rules:{
|
||||
xxxx:{
|
||||
required:true,
|
||||
},
|
||||
},
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
if ($.validate.form()) {
|
||||
$.operate.save(prefix + "/add", $('#form-member-add').serialize());
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,109 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('修改客户')" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-member-edit" th:object="${member}">
|
||||
<input id="memberId" name="memberId" th:field="*{memberId}" type="hidden">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户昵称:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="memberName" name="memberName" th:field="*{memberName}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户邮箱:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="email" name="email" th:field="*{email}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">手机号码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="phonenumber" name="phonenumber" th:field="*{phonenumber}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">用户性别(0男 1女 2未知):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="sex" name="sex" th:field="*{sex}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">头像路径:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="avatar" name="avatar" th:field="*{avatar}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">密码:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="password" name="password" th:field="*{password}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">盐加密:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="salt" name="salt" th:field="*{salt}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">帐号状态(0正常 1停用):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="status" name="status" th:field="*{status}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">删除标志(0代表存在 2代表删除):</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="delFlag" name="delFlag" th:field="*{delFlag}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆IP:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginIp" name="loginIp" th:field="*{loginIp}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">最后登陆时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="loginDate" name="loginDate" th:field="*{loginDate}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">创建时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="createTime" name="createTime" th:field="*{createTime}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">备注:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="remark" name="remark" th:field="*{remark}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div th:include="include::footer"></div>
|
||||
<script type="text/javascript">
|
||||
var prefix = ctx + "servicecenter/member";
|
||||
$("#form-member-edit").validate({
|
||||
rules:{
|
||||
xxxx:{
|
||||
required:true,
|
||||
},
|
||||
},
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
if ($.validate.form()) {
|
||||
$.operate.save(prefix + "/edit", $('#form-member-edit').serialize());
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,196 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||
<head>
|
||||
<th:block th:include="include :: header('客户列表')" />
|
||||
</head>
|
||||
<body class="gray-bg">
|
||||
<div class="container-div">
|
||||
<div class="row">
|
||||
<div class="col-sm-12 search-collapse">
|
||||
<form id="formId">
|
||||
<div class="select-list">
|
||||
<ul>
|
||||
<li>
|
||||
用户昵称:<input type="text" name="memberName"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
用户邮箱:<input type="text" name="email"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
手机号码:<input type="text" name="phonenumber"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
用户性别(0男 1女 2未知):<input type="text" name="sex"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
头像路径:<input type="text" name="avatar"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
密码:<input type="text" name="password"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
盐加密:<input type="text" name="salt"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
帐号状态(0正常 1停用):<input type="text" name="status"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
删除标志(0代表存在 2代表删除):<input type="text" name="delFlag"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
最后登陆IP:<input type="text" name="loginIp"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
最后登陆时间:<input type="text" name="loginDate"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
创建时间:<input type="text" name="createTime"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
备注:<input type="text" name="remark"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="btn-group-sm" id="toolbar" role="group">
|
||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="servicecenter:member:add">
|
||||
<i class="fa fa-plus"></i> 添加
|
||||
</a>
|
||||
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="servicecenter:member:edit">
|
||||
<i class="fa fa-edit"></i> 修改
|
||||
</a>
|
||||
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="servicecenter:member:remove">
|
||||
<i class="fa fa-remove"></i> 删除
|
||||
</a>
|
||||
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="servicecenter:member:export">
|
||||
<i class="fa fa-download"></i> 导出
|
||||
</a>
|
||||
</div>
|
||||
<div class="col-sm-12 select-table table-striped">
|
||||
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div th:include="include :: footer"></div>
|
||||
<script th:inline="javascript">
|
||||
var editFlag = [[${@permission.hasPermi('servicecenter:member:edit')}]];
|
||||
var removeFlag = [[${@permission.hasPermi('servicecenter:member:remove')}]];
|
||||
var prefix = ctx + "servicecenter/member";
|
||||
|
||||
$(function() {
|
||||
var options = {
|
||||
url: prefix + "/list",
|
||||
createUrl: prefix + "/add",
|
||||
updateUrl: prefix + "/edit/{id}",
|
||||
removeUrl: prefix + "/remove",
|
||||
exportUrl: prefix + "/export",
|
||||
modalName: "客户",
|
||||
showExport: true,
|
||||
columns: [{
|
||||
checkbox: true
|
||||
},
|
||||
{
|
||||
field : 'memberId',
|
||||
title : '客户ID',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field : 'memberName',
|
||||
title : '用户昵称',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'email',
|
||||
title : '用户邮箱',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'phonenumber',
|
||||
title : '手机号码',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'sex',
|
||||
title : '用户性别(0男 1女 2未知)',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'avatar',
|
||||
title : '头像路径',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'password',
|
||||
title : '密码',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'salt',
|
||||
title : '盐加密',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'status',
|
||||
title : '帐号状态(0正常 1停用)',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'delFlag',
|
||||
title : '删除标志(0代表存在 2代表删除)',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'loginIp',
|
||||
title : '最后登陆IP',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'loginDate',
|
||||
title : '最后登陆时间',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'createTime',
|
||||
title : '创建时间',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'remark',
|
||||
title : '备注',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
formatter: function(value, row, index) {
|
||||
var actions = [];
|
||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.memberId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.memberId + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||
return actions.join('');
|
||||
}
|
||||
}]
|
||||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('新增订单')" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-order-add">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">客户ID:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="memberId" name="memberId" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">服务员ID:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="attendantId" name="attendantId" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">备注:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="remark" name="remark" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">创建时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="createTime" name="createTime" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div th:include="include::footer"></div>
|
||||
<script type="text/javascript">
|
||||
var prefix = ctx + "servicecenter/order"
|
||||
$("#form-order-add").validate({
|
||||
rules:{
|
||||
xxxx:{
|
||||
required:true,
|
||||
},
|
||||
},
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
if ($.validate.form()) {
|
||||
$.operate.save(prefix + "/add", $('#form-order-add').serialize());
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('修改订单')" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-order-edit" th:object="${order}">
|
||||
<input id="orderId" name="orderId" th:field="*{orderId}" type="hidden">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">客户ID:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="memberId" name="memberId" th:field="*{memberId}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">服务员ID:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="attendantId" name="attendantId" th:field="*{attendantId}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">备注:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="remark" name="remark" th:field="*{remark}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">创建时间:</label>
|
||||
<div class="col-sm-8">
|
||||
<input id="createTime" name="createTime" th:field="*{createTime}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div th:include="include::footer"></div>
|
||||
<script type="text/javascript">
|
||||
var prefix = ctx + "servicecenter/order";
|
||||
$("#form-order-edit").validate({
|
||||
rules:{
|
||||
xxxx:{
|
||||
required:true,
|
||||
},
|
||||
},
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
if ($.validate.form()) {
|
||||
$.operate.save(prefix + "/edit", $('#form-order-edit').serialize());
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,115 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||
<head>
|
||||
<th:block th:include="include :: header('订单列表')" />
|
||||
</head>
|
||||
<body class="gray-bg">
|
||||
<div class="container-div">
|
||||
<div class="row">
|
||||
<div class="col-sm-12 search-collapse">
|
||||
<form id="formId">
|
||||
<div class="select-list">
|
||||
<ul>
|
||||
<li>
|
||||
客户ID:<input type="text" name="memberId"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
服务员ID:<input type="text" name="attendantId"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
备注:<input type="text" name="remark"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
创建时间:<input type="text" name="createTime"/>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="btn-group-sm" id="toolbar" role="group">
|
||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="servicecenter:order:add">
|
||||
<i class="fa fa-plus"></i> 添加
|
||||
</a>
|
||||
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="servicecenter:order:edit">
|
||||
<i class="fa fa-edit"></i> 修改
|
||||
</a>
|
||||
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="servicecenter:order:remove">
|
||||
<i class="fa fa-remove"></i> 删除
|
||||
</a>
|
||||
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="servicecenter:order:export">
|
||||
<i class="fa fa-download"></i> 导出
|
||||
</a>
|
||||
</div>
|
||||
<div class="col-sm-12 select-table table-striped">
|
||||
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div th:include="include :: footer"></div>
|
||||
<script th:inline="javascript">
|
||||
var editFlag = [[${@permission.hasPermi('servicecenter:order:edit')}]];
|
||||
var removeFlag = [[${@permission.hasPermi('servicecenter:order:remove')}]];
|
||||
var prefix = ctx + "servicecenter/order";
|
||||
|
||||
$(function() {
|
||||
var options = {
|
||||
url: prefix + "/list",
|
||||
createUrl: prefix + "/add",
|
||||
updateUrl: prefix + "/edit/{id}",
|
||||
removeUrl: prefix + "/remove",
|
||||
exportUrl: prefix + "/export",
|
||||
modalName: "订单",
|
||||
showExport: true,
|
||||
columns: [{
|
||||
checkbox: true
|
||||
},
|
||||
{
|
||||
field : 'orderId',
|
||||
title : '订单ID',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field : 'memberId',
|
||||
title : '客户ID',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'attendantId',
|
||||
title : '服务员ID',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'remark',
|
||||
title : '备注',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
field : 'createTime',
|
||||
title : '创建时间',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
formatter: function(value, row, index) {
|
||||
var actions = [];
|
||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.orderId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.orderId + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||
return actions.join('');
|
||||
}
|
||||
}]
|
||||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -0,0 +1,116 @@
|
|||
drop table if exists sc_order;
|
||||
CREATE TABLE
|
||||
sc_order
|
||||
(
|
||||
order_id bigint NOT NULL AUTO_INCREMENT COMMENT '订单ID',
|
||||
member_id bigint COMMENT '客户ID',
|
||||
attendant_id bigint COMMENT '服务员ID',
|
||||
remark VARCHAR(500) COMMENT '备注',
|
||||
create_time DATETIME COMMENT '创建时间',
|
||||
PRIMARY KEY (order_id)
|
||||
)
|
||||
ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='订单信息表';
|
||||
|
||||
drop table if exists sc_member;
|
||||
CREATE TABLE
|
||||
sc_member
|
||||
(
|
||||
member_id bigint NOT NULL AUTO_INCREMENT COMMENT '客户ID',
|
||||
member_name VARCHAR(30) NOT NULL COMMENT '用户昵称',
|
||||
email VARCHAR(50) COMMENT '用户邮箱',
|
||||
phonenumber VARCHAR(11) COMMENT '手机号码',
|
||||
sex CHAR(1) DEFAULT '0' COMMENT '用户性别(0男 1女 2未知)',
|
||||
avatar VARCHAR(100) COMMENT '头像路径',
|
||||
password VARCHAR(50) COMMENT '密码',
|
||||
salt VARCHAR(20) COMMENT '盐加密',
|
||||
status CHAR(1) DEFAULT '0' COMMENT '帐号状态(0正常 1停用)',
|
||||
del_flag CHAR(1) DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
|
||||
login_ip VARCHAR(50) COMMENT '最后登陆IP',
|
||||
login_date DATETIME COMMENT '最后登陆时间',
|
||||
create_time DATETIME COMMENT '创建时间',
|
||||
remark VARCHAR(500) COMMENT '备注',
|
||||
PRIMARY KEY (member_id)
|
||||
)
|
||||
ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='客户信息表';
|
||||
|
||||
drop table if exists sc_attendant;
|
||||
CREATE TABLE
|
||||
sc_attendant
|
||||
(
|
||||
attendant_id bigint NOT NULL AUTO_INCREMENT COMMENT '客户ID',
|
||||
attendant_name VARCHAR(30) NOT NULL COMMENT '用户昵称',
|
||||
email VARCHAR(50) COMMENT '用户邮箱',
|
||||
phonenumber VARCHAR(11) COMMENT '手机号码',
|
||||
sex CHAR(1) DEFAULT '0' COMMENT '用户性别(0男 1女 2未知)',
|
||||
avatar VARCHAR(100) COMMENT '头像路径',
|
||||
password VARCHAR(50) COMMENT '密码',
|
||||
salt VARCHAR(20) COMMENT '盐加密',
|
||||
status CHAR(1) DEFAULT '0' COMMENT '帐号状态(0正常 1停用)',
|
||||
del_flag CHAR(1) DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
|
||||
login_ip VARCHAR(50) COMMENT '最后登陆IP',
|
||||
login_date DATETIME COMMENT '最后登陆时间',
|
||||
create_time DATETIME COMMENT '创建时间',
|
||||
remark VARCHAR(500) COMMENT '备注',
|
||||
PRIMARY KEY (attendant_id)
|
||||
)
|
||||
ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='服务员信息表';
|
||||
|
||||
-- 菜单 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('客户', '3', '1', '/servicecenter/member', 'C', '0', 'servicecenter:member:view', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '客户菜单');
|
||||
|
||||
-- 按钮父菜单ID
|
||||
SELECT @parentId := LAST_INSERT_ID();
|
||||
|
||||
-- 按钮 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('客户查询', @parentId, '1', '#', 'F', '0', 'servicecenter:member:list', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('客户新增', @parentId, '2', '#', 'F', '0', 'servicecenter:member:add', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('客户修改', @parentId, '3', '#', 'F', '0', 'servicecenter:member:edit', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('客户删除', @parentId, '4', '#', 'F', '0', 'servicecenter:member:remove', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
-- 菜单 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('订单', '3', '1', '/servicecenter/order', 'C', '0', 'servicecenter:order:view', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '订单菜单');
|
||||
|
||||
-- 按钮父菜单ID
|
||||
SELECT @parentId := LAST_INSERT_ID();
|
||||
|
||||
-- 按钮 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('订单查询', @parentId, '1', '#', 'F', '0', 'servicecenter:order:list', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('订单新增', @parentId, '2', '#', 'F', '0', 'servicecenter:order:add', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('订单修改', @parentId, '3', '#', 'F', '0', 'servicecenter:order:edit', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('订单删除', @parentId, '4', '#', 'F', '0', 'servicecenter:order:remove', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
-- 菜单 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('服务员', '3', '1', '/servicecenter/attendant', 'C', '0', 'servicecenter:attendant:view', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '服务员菜单');
|
||||
|
||||
-- 按钮父菜单ID
|
||||
SELECT @parentId := LAST_INSERT_ID();
|
||||
|
||||
-- 按钮 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('服务员查询', @parentId, '1', '#', 'F', '0', 'servicecenter:attendant:list', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('服务员新增', @parentId, '2', '#', 'F', '0', 'servicecenter:attendant:add', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('服务员修改', @parentId, '3', '#', 'F', '0', 'servicecenter:attendant:edit', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url,menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('服务员删除', @parentId, '4', '#', 'F', '0', 'servicecenter:attendant:remove', '#', 'admin', '2018-03-01', 'ry', '2018-03-01', '');
|
||||
Loading…
Reference in New Issue