Commit 4ecf37c4 by huluobin

update

parent 433fdc01
......@@ -12,6 +12,7 @@ import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import javax.annotation.Resource;
import java.math.BigDecimal;
import java.util.List;
/**
......@@ -37,5 +38,11 @@ public class OaDepartmentController {
return CostResult.success(oaDepartmentList);
}
@ApiOperation("更新部门审核金额")
@GetMapping("/updateDepartmentMinimumReviewAmount")
public CostResult<Void> updateDepartmentMinimumReviewAmount(@RequestParam Integer oaDepartmentId,
@RequestParam BigDecimal amount) {
oaDepartmentService.updateDepartmentMinimumReviewAmount(oaDepartmentId, amount);
return CostResult.success();
}
}
......@@ -6,6 +6,7 @@ import com.blt.other.module.auth.dto.request.DepartmentReviewerListReq;
import com.blt.other.module.auth.model.OaDepartment;
import org.springframework.lang.NonNull;
import java.math.BigDecimal;
import java.util.List;
/**
......@@ -45,8 +46,16 @@ public interface IOaDepartmentService extends IService<OaDepartment> {
* </p>
*
* @param userId 当前用户id
* @param oaDepartmentId oa公司主体id
* @param oaDepartmentId oa部门id
* @param departmentReviewerUserIds 部门审核oa userid list
*/
void modifyFinancialReviewer(Integer userId, Integer oaDepartmentId, List<Integer> departmentReviewerUserIds);
/**
* 更新部门审核金额
*
* @param oaDepartmentId oa部门id
* @param amount 金额
*/
void updateDepartmentMinimumReviewAmount(Integer oaDepartmentId, BigDecimal amount);
}
......@@ -17,6 +17,7 @@ import org.springframework.lang.NonNull;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Map;
......@@ -95,4 +96,11 @@ public class OaDepartmentServiceImpl extends ServiceImpl<OaDepartmentMapper, OaD
costReviewerMapper.insert(costReviewer);
});
}
@Override
public void updateDepartmentMinimumReviewAmount(Integer oaDepartmentId, BigDecimal amount) {
OaDepartment oaDepartment = baseMapper.selectByDepartmentId(oaDepartmentId);
oaDepartment.setDepartmentMinimumReviewAmount(amount);
baseMapper.updateById(oaDepartment);
}
}
package com.blt.other.module.cost.controller;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
@Deprecated
@RestController
@RequestMapping("cost/list/add/")
public class CostListAddController {
private static Logger logger = LoggerFactory.getLogger(CostListAddController.class);
}
//package com.blt.other.module.cost.controller;
//
//import org.slf4j.Logger;
//import org.slf4j.LoggerFactory;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RestController;
//
//@Deprecated
//@RestController
//@RequestMapping("cost/list/add/")
//public class CostListAddController {
//
// private static Logger logger = LoggerFactory.getLogger(CostListAddController.class);
//
//}
package com.blt.other.module.cost.controller;
import com.blt.other.common.util.AxiosUtil;
import com.bailuntec.cost.api.dto.CostCompanyFinansysDto;
import com.blt.other.module.cost.service.CostCompanyFinansysService;
import com.blt.other.module.cost.service.CostCompanyService;
import com.blt.other.module.cost.vo.CostCompanyVo;
import com.blt.other.module.database.model.CostCompanyDomain;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Deprecated
@RestController
@RequestMapping("cost/list/add")
public class CostListAddReceiptController {
@Autowired
private CostCompanyService costCompanyService;
@Autowired
private CostCompanyFinansysService costCompanyFinansysService;
@PostMapping("/getCompanyFinansysByNo")
public Map<String,Object> getCompanyFinansysByNo(HttpServletResponse response, HttpServletRequest request){
AxiosUtil.setCors(response,request);
String companyNo = request.getParameter("companyNo");
CostCompanyDomain companyByCompanyNo = costCompanyService.getCompanyByCompanyNo(companyNo);
CostCompanyVo costCompanyVo = costCompanyFinansysService.getCostCompanyVo(companyByCompanyNo.getValue());
List<CostCompanyFinansysDto> costCompanyFinansysDto = null;
if (null != costCompanyVo){
costCompanyFinansysDto = costCompanyFinansysService.getCostCompanyFinansysDto(costCompanyVo);
}
Map<String,Object> result = new HashMap<>();
result.put("finansysList",costCompanyFinansysDto);
result.put("success",true);
return result;
}
@PostMapping("/getMainFinansys")
public Map<String,Object> getMainFinansys(HttpServletResponse response,HttpServletRequest request){
AxiosUtil.setCors(response,request);
Map<String,Object> result = new HashMap<>();
String mValue = request.getParameter("mValue");
String[] split = mValue.split("~");
CostCompanyVo costCompanyVo = costCompanyFinansysService.getCostCompanyVo(Integer.parseInt(split[0]));
List<CostCompanyFinansysDto> costCompanyFinansysDto = costCompanyFinansysService.getCostCompanyFinansysDto(costCompanyVo);
if (null != costCompanyFinansysDto && costCompanyFinansysDto.size() >= 1){
for (CostCompanyFinansysDto costCompanyFinansys : costCompanyFinansysDto){
if (costCompanyFinansys.getId() == Integer.parseInt(split[1])){
result.put("success",true);
result.put("msg","");
result.put("finansys",costCompanyFinansys);
return result;
}
}
}
return null;
}
}
//package com.blt.other.module.cost.controller;
//
//import com.blt.other.common.util.AxiosUtil;
//import com.bailuntec.cost.api.dto.CostCompanyFinansysDto;
//import com.blt.other.module.cost.service.CostCompanyFinansysService;
//import com.blt.other.module.cost.service.CostCompanyService;
//import com.blt.other.module.cost.vo.CostCompanyVo;
//import com.blt.other.module.database.model.CostCompanyDomain;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.web.bind.annotation.PostMapping;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RestController;
//
//import javax.servlet.http.HttpServletRequest;
//import javax.servlet.http.HttpServletResponse;
//import java.util.HashMap;
//import java.util.List;
//import java.util.Map;
//
//@Deprecated
//@RestController
//@RequestMapping("cost/list/add")
//public class CostListAddReceiptController {
//
// @Autowired
// private CostCompanyService costCompanyService;
//
// @Autowired
// private CostCompanyFinansysService costCompanyFinansysService;
//
// @PostMapping("/getCompanyFinansysByNo")
// public Map<String,Object> getCompanyFinansysByNo(HttpServletResponse response, HttpServletRequest request){
// AxiosUtil.setCors(response,request);
// String companyNo = request.getParameter("companyNo");
//
// CostCompanyDomain companyByCompanyNo = costCompanyService.getCompanyByCompanyNo(companyNo);
//
// CostCompanyVo costCompanyVo = costCompanyFinansysService.getCostCompanyVo(companyByCompanyNo.getValue());
// List<CostCompanyFinansysDto> costCompanyFinansysDto = null;
// if (null != costCompanyVo){
// costCompanyFinansysDto = costCompanyFinansysService.getCostCompanyFinansysDto(costCompanyVo);
// }
//
// Map<String,Object> result = new HashMap<>();
// result.put("finansysList",costCompanyFinansysDto);
// result.put("success",true);
// return result;
// }
//
// @PostMapping("/getMainFinansys")
// public Map<String,Object> getMainFinansys(HttpServletResponse response,HttpServletRequest request){
// AxiosUtil.setCors(response,request);
// Map<String,Object> result = new HashMap<>();
//
// String mValue = request.getParameter("mValue");
// String[] split = mValue.split("~");
// CostCompanyVo costCompanyVo = costCompanyFinansysService.getCostCompanyVo(Integer.parseInt(split[0]));
// List<CostCompanyFinansysDto> costCompanyFinansysDto = costCompanyFinansysService.getCostCompanyFinansysDto(costCompanyVo);
//
// if (null != costCompanyFinansysDto && costCompanyFinansysDto.size() >= 1){
// for (CostCompanyFinansysDto costCompanyFinansys : costCompanyFinansysDto){
// if (costCompanyFinansys.getId() == Integer.parseInt(split[1])){
// result.put("success",true);
// result.put("msg","");
// result.put("finansys",costCompanyFinansys);
// return result;
// }
// }
// }
// return null;
// }
//}
package com.blt.other.module.cost.controller;
import com.bailuntec.cost.api.dto.CostDto;
import com.bailuntec.cost.api.dto.CostListPrintDto;
import com.blt.other.module.auth.service.UserService;
import com.blt.other.common.util.AxiosUtil;
import com.blt.other.common.util.MoneyUtil;
import com.blt.other.common.util.MyMapperUtil;
import com.blt.other.module.cost.service.CostService;
import com.blt.other.module.cost.vo.CostListPrintVo;
import com.blt.other.module.database.model.UserDomain;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.*;
@Deprecated
@Api(tags = "打印费用单")
@RestController
@RequestMapping("/cost/list/print")
public class CostListPrintController {
}
//package com.blt.other.module.cost.controller;
//
//import com.bailuntec.cost.api.dto.CostDto;
//import com.bailuntec.cost.api.dto.CostListPrintDto;
//import com.blt.other.module.auth.service.UserService;
//import com.blt.other.common.util.AxiosUtil;
//import com.blt.other.common.util.MoneyUtil;
//import com.blt.other.common.util.MyMapperUtil;
//import com.blt.other.module.cost.service.CostService;
//import com.blt.other.module.cost.vo.CostListPrintVo;
//import com.blt.other.module.database.model.UserDomain;
//import io.swagger.annotations.Api;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.web.bind.annotation.PostMapping;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RestController;
//
//import javax.servlet.http.HttpServletRequest;
//import javax.servlet.http.HttpServletResponse;
//import java.util.*;
//
//
//@Deprecated
//@Api(tags = "打印费用单")
//@RestController
//@RequestMapping("/cost/list/print")
//public class CostListPrintController {
//
//
//
//}
package com.blt.other.module.cost.controller;
import io.swagger.annotations.Api;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
@Deprecated
@Api(tags = "费用搜索接口")
@RestController
@RequestMapping("cost/list")
public class CostListSearchController {
}
//package com.blt.other.module.cost.controller;
//
//import io.swagger.annotations.Api;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RestController;
//
//
//@Deprecated
//@Api(tags = "费用搜索接口")
//@RestController
//@RequestMapping("cost/list")
//public class CostListSearchController {
//
//
//}
......@@ -50,15 +50,15 @@ public interface CostTypeKindDao {
*/
CostTypeKindDomain selectByKindNo(String costTypeKindNo);
/**
* 根据费用小类名称和公司名称获取种类信息
*
* @param kindName
* @param companyName
* @return
*/
@Deprecated
CostTypeKindDomain selectByKindNameAndCompanyName(String kindName, String companyName);
// /**
// * 根据费用小类名称和公司名称获取种类信息
// *
// * @param kindName
// * @param companyName
// * @return
// */
// @Deprecated
// CostTypeKindDomain selectByKindNameAndCompanyName(String kindName, String companyName);
/**
* 根据费用小类名称和公司no获取种类信息
......
......@@ -84,9 +84,9 @@ public class CostDomain implements Serializable {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date createTime;
@ApiModelProperty("关联子单")
@Deprecated
private String sonCostNo;
// @ApiModelProperty("关联子单")
// @Deprecated
// private String sonCostNo;
@ApiModelProperty("关联父单")
private String supCostNo;
......
......@@ -38,10 +38,8 @@ public class CostTypeKindServiceImpl implements CostTypeKindService {
private StatusMapper statusMapper;
@Autowired
private CostTypeDao costTypeDao;
@Autowired
private CostCompanyDao costCompanyDao;
@Autowired
private UserDao userDao;
......@@ -51,7 +49,6 @@ public class CostTypeKindServiceImpl implements CostTypeKindService {
@Override
public List<CostTypeKindDto> getAllKind() {
List<CostTypeKindDomain> costTypeKindDomains = costTypeKindDao.selectAll();
// logger.warn("获取费用类型列表:"+costTypeKindDomains);
return getDtoList(costTypeKindDomains);
}
......@@ -367,8 +364,7 @@ public class CostTypeKindServiceImpl implements CostTypeKindService {
}
private String getCostTypeStatus(String statusname, Integer statuskey) {
String statusValue = statusMapper.getStatusValue(statusname, statuskey);
return statusValue;
return statusMapper.getStatusValue(statusname, statuskey);
}
@Override
......
......@@ -66,9 +66,10 @@ public class CostPlanDomain implements Serializable {
@ApiModelProperty("创建时间")
private Date createTime;
@ApiModelProperty("关联子单")
@Deprecated
private String sonCostNo;
// @ApiModelProperty("关联子单")
// @Deprecated
// private String sonCostNo;
@ApiModelProperty("关联父单")
private String supCostNo;
......@@ -138,9 +139,6 @@ public class CostPlanDomain implements Serializable {
/*借还单参数 end*/
@TableField(value = "`attach`", typeHandler = JacksonTypeHandler.class)
@ApiModelProperty("附加字段")
private List<CostAttach> attach;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment