|
@@ -106,19 +106,6 @@ public class WxMagnetController extends BaseController
|
|
|
@ResponseBody
|
|
@ResponseBody
|
|
|
public AjaxResult addSave(@Validated WxMagnet wxMagnet)
|
|
public AjaxResult addSave(@Validated WxMagnet wxMagnet)
|
|
|
{
|
|
{
|
|
|
- String newMagnetName = wxMagnet.getMagnetName();
|
|
|
|
|
- String newOrderNum = "";
|
|
|
|
|
- if ("0".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(立邦员工)";
|
|
|
|
|
- }else if ("1".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(经销商)";
|
|
|
|
|
- }else if ("2".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(服务商)";
|
|
|
|
|
- }else if ("3".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(金牌店)";
|
|
|
|
|
- }
|
|
|
|
|
- wxMagnet.setMagnetName(newMagnetName);
|
|
|
|
|
- wxMagnet.setOrderNum(newOrderNum);
|
|
|
|
|
if (UserConstants.MENU_NAME_NOT_UNIQUE.equals(wxMagnetService.checkMagnetNameUnique(wxMagnet)))
|
|
if (UserConstants.MENU_NAME_NOT_UNIQUE.equals(wxMagnetService.checkMagnetNameUnique(wxMagnet)))
|
|
|
{
|
|
{
|
|
|
return error("新增磁贴'" + wxMagnet.getMagnetName() + "'失败,磁贴名称已存在");
|
|
return error("新增磁贴'" + wxMagnet.getMagnetName() + "'失败,磁贴名称已存在");
|
|
@@ -147,20 +134,6 @@ public class WxMagnetController extends BaseController
|
|
|
@ResponseBody
|
|
@ResponseBody
|
|
|
public AjaxResult editSave(@Validated WxMagnet wxMagnet)
|
|
public AjaxResult editSave(@Validated WxMagnet wxMagnet)
|
|
|
{
|
|
{
|
|
|
- String newMagnetName = wxMagnet.getMagnetName();
|
|
|
|
|
- String newOrderNum = "";
|
|
|
|
|
- // 根据用户类型设置磁铁名称和订单号前缀
|
|
|
|
|
- if ("0".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(立邦员工)";
|
|
|
|
|
- }else if ("1".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(经销商)";
|
|
|
|
|
- }else if ("2".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(服务商)";
|
|
|
|
|
- }else if ("3".equals(wxMagnet.getUserType())){
|
|
|
|
|
- newMagnetName = newMagnetName + "(金牌店)";
|
|
|
|
|
- }
|
|
|
|
|
- wxMagnet.setMagnetName(newMagnetName);
|
|
|
|
|
- wxMagnet.setOrderNum(newOrderNum);
|
|
|
|
|
if (UserConstants.MENU_NAME_NOT_UNIQUE.equals(wxMagnetService.checkMagnetNameUnique(wxMagnet)))
|
|
if (UserConstants.MENU_NAME_NOT_UNIQUE.equals(wxMagnetService.checkMagnetNameUnique(wxMagnet)))
|
|
|
{
|
|
{
|
|
|
return error("修改磁贴'" + wxMagnet.getMagnetName() + "'失败,磁贴名称已存在");
|
|
return error("修改磁贴'" + wxMagnet.getMagnetName() + "'失败,磁贴名称已存在");
|