From a9f950c0d11a687a7a940443b8c765f6d87ae4f1 Mon Sep 17 00:00:00 2001
From: jyy <935090232@qq.com>
Date: Tue, 20 Apr 2021 00:26:22 +0800
Subject: [PATCH] 合并新的修改
---
zq-erp/src/main/java/com/matrix/system/hive/action/ProjServiceController.java | 34 +++++++++++++++++++++++++++++-----
1 files changed, 29 insertions(+), 5 deletions(-)
diff --git a/zq-erp/src/main/java/com/matrix/system/hive/action/ProjServiceController.java b/zq-erp/src/main/java/com/matrix/system/hive/action/ProjServiceController.java
index 00b210a..faed6f0 100644
--- a/zq-erp/src/main/java/com/matrix/system/hive/action/ProjServiceController.java
+++ b/zq-erp/src/main/java/com/matrix/system/hive/action/ProjServiceController.java
@@ -1,6 +1,7 @@
package com.matrix.system.hive.action;
import cn.hutool.core.collection.CollUtil;
+import cn.hutool.core.util.StrUtil;
import com.matrix.core.anotations.RemoveRequestToken;
import com.matrix.core.constance.MatrixConstance;
import com.matrix.core.exception.GlobleException;
@@ -276,6 +277,7 @@
return "admin/hive/beautySalon/yypb-form";
}
+
/**
* 进入预约排班详情
*
@@ -451,6 +453,7 @@
}
}
+
/**
* 根据id取消预约
*/
@@ -489,8 +492,7 @@
@RequestMapping(value = "/addService")
public @ResponseBody
AjaxResult servicceAdd(@RequestBody SysProjServices sysProjServices) {
- SysVipInfo vipInfo = getCurrentVioInfo();
- sysProjServices.setVipId(vipInfo.getId());
+
if (CollectionUtils.isEmpty(sysProjServices.getServiceItems())) {
return new AjaxResult(AjaxResult.STATUS_FAIL, "没有选中可消耗的项目");
@@ -505,7 +507,9 @@
if (balanceverifyResult.isError()) {
return new AjaxResult(AjaxResult.STATUS_FAIL, balanceverifyResult.getMsg());
}
- sysProjServices.setState(Dictionary.SERVICE_STATU_DYY);
+ if (StrUtil.isEmpty(sysProjServices.getState())) {
+ sysProjServices.setState(Dictionary.SERVICE_STATU_DYY);
+ }
SysProjServices newSysProjServices = sysProjServicesService.addSysProjServices(sysProjServices);
if (newSysProjServices != null) {
return AjaxResult.buildSuccessInstance(Arrays.asList(newSysProjServices));
@@ -520,8 +524,8 @@
@RequestMapping(value = "/addServiceForForm")
public @ResponseBody
AjaxResult servicceAddForForm(SysProjServices sysProjServices) {
- SysVipInfo vipInfo = getCurrentVioInfo();
- sysProjServices.setVipId(vipInfo.getId());
+
+
if (CollectionUtils.isEmpty(sysProjServices.getServiceItems())) {
return new AjaxResult(AjaxResult.STATUS_FAIL, "没有选中可消耗的项目");
@@ -560,6 +564,26 @@
}
+ @RequestMapping(value = "/addServiceProj")
+ @ResponseBody
+ public AjaxResult addServiceProj(SysProjServices sysProjServices) {
+
+ return AjaxResult.buildSuccessInstance("保存成功");
+ }
+
+ /**
+ * 删除服务单项目/套餐
+ * @param id
+ * @return
+ */
+ @RequestMapping(value = "/delServiceOrderItems")
+ @ResponseBody
+ public AjaxResult delServiceOrderItems(Long id) {
+ sysProjServicesService.deleteProjServiceItemById(id);
+ return AjaxResult.buildSuccessInstance("删除成功");
+ }
+
+
// 准备页面数据
private void pageDate() {
// 根据岗位名称查询员工
--
Gitblit v1.9.1