Commit 57378297 by 王炜晨

merge

parents 6b129698 00b0f2d2
......@@ -80,7 +80,7 @@ public class SandMiningAreaServiceImpl implements SandMiningAreaService {
warnSetting.setBillId(kobject.getUuid("id"));
warnSetting.setTarget(SandMiningAreaConstant.SAND_MINING_AREA_WARN_TARGET);
warnSetting.setTargetType(WarnTargetTypeEnum.NUMBER_TYPE.name());
warnSetting.setOpen(false);
warnSetting.setOpen(true);
warnSetting.setMemo(getAreaWarningInfo(kobject));
warnSetting.setWarnCalculator(SandMiningAreaConstant.warnCalculator);
warningSettingService.insertWarnSetting(warnSetting);
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractAdd</name>
<title>新</title>
<title>新</title>
<tags></tags>
<description></description>
</header>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractApproveList</name>
<title>列表</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractCardLook</name>
<title>卡片查看</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractChange</name>
<title>变更</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractComplete</name>
<title>完成</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractEdit</name>
<title>编辑</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='1ef4ce72-d73d-442d-9428-5fe3be0bb8c1' category='合同/合同登记(区域公司)' seq='5'></privilege>
<privilege type='TOKEN' target-type='' id='1ef4ce72-d73d-442d-9428-5fe3be0bb8c1' category='合同/合同登记(区域公司)' seq='4'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractExecuteAnalyseList</name>
<title>列表</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractExport</name>
<title>导出</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='ef6a6291-c631-4c4b-90ce-32ebea1d984d' category='合同/合同登记(区域公司)' seq='4'></privilege>
<privilege type='TOKEN' target-type='' id='ef6a6291-c631-4c4b-90ce-32ebea1d984d' category='合同/合同登记(区域公司)' seq='5'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractList</name>
<title>列表</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractRemove</name>
<title>删除</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractSubmit</name>
<title>提交</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractWarningExeList</name>
<title>列表</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractWarningSettingList</name>
<title>列表</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractWarningSettingMemberSet</name>
<title>人员设置</title>
<tags></tags>
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.sales.auth</package>
<package>com.xyst.dinas.contract.auth</package>
<name>ContractWarningSettingWarningSet</name>
<title>预警设置</title>
<tags></tags>
......
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>af449c11-de31-4e42-8ef6-be62f359aa01</id>
<name>com.xyst.dinas.contract.auth.ContractAdd</name>
<title>新建</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>3</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>527c15dd-7fe3-4162-bb27-c40f8ec50478</id>
<name>com.xyst.dinas.contract.auth.ContractApproveList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同审核(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>501467ff-5202-4b02-9fa7-f3316c60b0b5</id>
<name>com.xyst.dinas.contract.auth.ContractCardLook</name>
<title>卡片查看</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>2</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>47207868-c0b4-455a-b8fc-e18b0c19cd16</id>
<name>com.xyst.dinas.contract.auth.ContractChange</name>
<title>变更</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>6</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>01bbc7a0-e37a-4316-830e-b043e5e231ca</id>
<name>com.xyst.dinas.contract.auth.ContractComplete</name>
<title>完成</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>7</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>1ef4ce72-d73d-442d-9428-5fe3be0bb8c1</id>
<name>com.xyst.dinas.contract.auth.ContractEdit</name>
<title>编辑</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>4</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>c2ae8f54-b0fb-4397-b050-5d327867f1b8</id>
<name>com.xyst.dinas.contract.auth.ContractExecuteAnalyseList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同执行分析</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>ef6a6291-c631-4c4b-90ce-32ebea1d984d</id>
<name>com.xyst.dinas.contract.auth.ContractExport</name>
<title>导出</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>5</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>e9e9390f-87d0-41ef-a3a5-a20af58fb1ff</id>
<name>com.xyst.dinas.contract.auth.ContractList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>ef0dd8eb-f063-4390-aab6-dbb8f70f89e0</id>
<name>com.xyst.dinas.contract.auth.ContractRemove</name>
<title>删除</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>8</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>f6ca0ba5-985a-4fb6-90e5-fcb616dfdffe</id>
<name>com.xyst.dinas.contract.auth.ContractSubmit</name>
<title>提交</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同登记(区域公司)</m:category>
<m:seq>9</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>f6911413-296e-43c5-92d4-2a27e8d8901f</id>
<name>com.xyst.dinas.contract.auth.ContractWarningExeList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同执行预警</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>e58e42d9-a2c9-4126-ab8b-93de7d4c47e9</id>
<name>com.xyst.dinas.contract.auth.ContractWarningSettingList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同预警设置(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>e15a4b0f-43c1-436e-9a47-05ed4b216701</id>
<name>com.xyst.dinas.contract.auth.ContractWarningSettingMemberSet</name>
<title>人员设置</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同预警设置(区域公司)</m:category>
<m:seq>2</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>165f487e-75b5-493b-8cc6-0c233f85ec85</id>
<name>com.xyst.dinas.contract.auth.ContractWarningSettingWarningSet</name>
<title>预警设置</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>合同/合同预警设置(区域公司)</m:category>
<m:seq>3</m:seq>
</m:privilege>
</content>
</metadata>
......@@ -8,15 +8,18 @@ import com.xyst.dinas.finance.dao.StatementAccountDao;
import com.xyst.dinas.finance.internal.dao.BankRechargeDetailDaoImpl;
import com.xyst.dinas.finance.internal.dao.ExpenseAdjustDaoImpl;
import com.xyst.dinas.finance.internal.dao.StatementAccountDaoImpl;
import com.xyst.dinas.finance.internal.service.ArtificialRechargeServiceImpl;
import com.xyst.dinas.finance.internal.service.BankRechargeDetailServiceImpl;
import com.xyst.dinas.finance.internal.service.ExpenseAdjustServiceImpl;
import com.xyst.dinas.finance.internal.service.FinanceRefundServiceImpl;
import com.xyst.dinas.finance.internal.service.StatementAccountServiceImpl;
import com.xyst.dinas.finance.processor.FinanceRefundProcessor;
import com.xyst.dinas.finance.service.ArtificialRechargeService;
import com.xyst.dinas.finance.service.BankRechargeDetailService;
import com.xyst.dinas.finance.service.ExpenseAdjustService;
import com.xyst.dinas.finance.service.FinanceRefundService;
import com.xyst.dinas.finance.service.StatementAccountService;
import com.xyst.dinas.finance.web.ArtificialRechargeController;
import com.xyst.dinas.finance.web.BankRechargeDetailController;
import com.xyst.dinas.finance.web.ExpenseAdjustController;
import com.xyst.dinas.finance.web.RefundController;
......@@ -90,5 +93,14 @@ public class FinanceConfiguration {
return new StatementAccountDaoImpl();
}
@Bean
public ArtificialRechargeController artificialRechargeController() {
return new ArtificialRechargeController();
}
@Bean
public ArtificialRechargeService artificialRechargeService() {
return new ArtificialRechargeServiceImpl();
}
}
package com.xyst.dinas.finance.internal.service;
import java.math.BigDecimal;
import java.util.UUID;
import org.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import com.beecode.bcp.type.KObject;
import com.beecode.inz.basis.team.pojo.ResponseObj;
import com.jiuqi.np.syntax.parser.ANTLRParser.ifthen_eval_return;
import com.xyst.dinas.contract.internal.dao.ContractDao;
import com.xyst.dinas.finance.enumeration.FundTypeEnum;
import com.xyst.dinas.finance.service.ArtificialRechargeService;
public class ArtificialRechargeServiceImpl implements ArtificialRechargeService {
@Autowired
private ContractDao contractDao;
@Override
@Transactional
public Object adjustContractBalance(JSONObject jsonObject) {
try{
UUID contractId = UUID.fromString(jsonObject.getString("contractId"));
KObject contract = contractDao.load(contractId);
if (FundTypeEnum.ADVANCE.name().equals(jsonObject.getString("fundType"))) {
contract.set("advanceBalance", contract.getBigDecimal("advanceBalance") == null ? new BigDecimal("0").add(jsonObject.getBigDecimal("rechargeAmount")) : contract.getBigDecimal("advanceBalance").add(jsonObject.getBigDecimal("rechargeAmount")));
} else if(FundTypeEnum.DEPOSIT.name().equals(jsonObject.getString("fundType"))){
contract.set("depositBalance", contract.getBigDecimal("depositBalance") == null ? new BigDecimal("0").add(jsonObject.getBigDecimal("rechargeAmount")) : contract.getBigDecimal("depositBalance").add(jsonObject.getBigDecimal("rechargeAmount")));
}
contractDao.update(contract);
return ResponseObj.success();
} catch(Exception e){
return ResponseObj.error();
}
}
}
......@@ -79,19 +79,28 @@ public class BankRechargeDetailServiceImpl implements BankRechargeDetailService
artificialRecharge.set("regionalCompany", jsonObject.isNull("regionalCompany") ? null : dinasOrganizationDao.load(UUID.fromString(jsonObject.getJSONObject("regionalCompany").getString("id"))));
artificialRecharge.set("purchaseSandUnit", jsonObject.isNull("purchaseSandUnit") ? null : purchaseSandCompanyDao.load(UUID.fromString(jsonObject.getJSONObject("purchaseSandUnit").getString("id"))));
artificialRecharge.set("contract", jsonObject.isNull("contract") ? null : contractDao.load(UUID.fromString(jsonObject.getJSONObject("contract").getString("id"))));
//获取关联合同
UUID contractId = UUID.fromString(jsonObject.getJSONObject("contract").getString("id"));
KObject contract = contractDao.load(contractId);
if (!jsonObject.isNull("advanceAmount")) {
//生成预付款调整
//生成预付款入账
artificialRecharge.set("id", UUID.randomUUID());
artificialRecharge.set("fundType", "ADVANCE");
artificialRecharge.set("rechargeAmount", jsonObject.getBigDecimal("advanceAmount"));
contract.set("advanceBalance", contract.getBigDecimal("advanceBalance") == null ? new BigDecimal("0").add(jsonObject.getBigDecimal("advanceAmount")) : contract.getBigDecimal("advanceBalance").add(jsonObject.getBigDecimal("advanceAmount")));
contractDao.update(contract);
artificialRecharge.set("contract", contract);
bankRechargeDetailDao.save(artificialRecharge);
}
if (!jsonObject.isNull("depositAmount")) {
//生成保证金调整
//生成保证金入账
KObject artificialRechargeTwo = artificialRechargeClass.newInstance(artificialRecharge);
artificialRechargeTwo.set("id", UUID.randomUUID());
artificialRechargeTwo.set("fundType", "DEPOSIT");
artificialRechargeTwo.set("rechargeAmount", jsonObject.getBigDecimal("depositAmount"));
contract.set("depositBalance", contract.getBigDecimal("depositBalance") == null ? new BigDecimal("0").add(jsonObject.getBigDecimal("depositAmount")) : contract.getBigDecimal("depositBalance").add(jsonObject.getBigDecimal("depositAmount")));
contractDao.update(contract);
artificialRecharge.set("contract", contract);
bankRechargeDetailDao.save(artificialRechargeTwo);
}
return ResponseObj.success();
......
......@@ -166,7 +166,7 @@ public class StatementAccountServiceImpl implements StatementAccountService{
cell.setCellStyle(textStyle);
Cell cell1 = row.createCell(1);
cell1.setCellValue(statementAccount.getDealDate());
cell1.setCellValue(statementAccount.getDealDate().substring(0, statementAccount.getDealDate().indexOf(".")));
cell1.setCellStyle(textStyle);
Cell cell2 = row.createCell(2);
......
package com.xyst.dinas.finance.service;
import org.json.JSONObject;
public interface ArtificialRechargeService {
Object adjustContractBalance(JSONObject jsonObject);
}
package com.xyst.dinas.finance.web;
import org.json.JSONArray;
import org.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;
import com.xyst.dinas.finance.service.ArtificialRechargeService;
import com.xyst.dinas.finance.service.BankRechargeDetailService;
import com.xyst.dinas.finance.service.ExpenseAdjustService;
/**
* 人工充值
*
* @author yangqingsong
* @date 2021年4月29日
*/
@RestController
public class ArtificialRechargeController {
@Autowired
private ArtificialRechargeService artificialRechargeService;
@ResponseBody
@RequestMapping(value = "/finance/artificialRecharge/adjustContractBalance", method = RequestMethod.POST, consumes = "application/json")
public Object adjustContractBalance(@RequestBody String body) {
JSONObject jsonObject = new JSONObject(body);
return artificialRechargeService.adjustContractBalance(jsonObject);
}
}
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>ArtificialRechargeCard</name>
<title>卡片查看</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='0ba03c35-0f62-40ac-bc96-94e80dffe2d3' category='资金/人工账户充值(区域公司)' seq='2'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>ArtificialRechargeCreate</name>
<title>新建</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='a742f2aa-db1a-4075-9890-79b50b8cccd2' category='资金/人工账户充值(区域公司)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>ArtificialRechargeList</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='45f107ed-dc73-40a2-af55-86f2d3a06928' category='资金/人工账户充值' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>BankRechargeDetailCreate</name>
<title>新建</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='f2d1a332-5aec-491e-acbc-b2f3e1c8909c' category='资金/银行充值明细(区域公司)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>BankRechargeDetailList</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='ae29a89f-29ec-442f-b60c-0c3ed0332609' category='资金/银行充值明细' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>ExpenseAdjustCard</name>
<title>卡片查看</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='c7901c69-fe3b-4f4f-9f8f-edee831af56f' category='资金/费用调整(区域公司)' seq='2'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>ExpenseAdjustCreate</name>
<title>新建</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='71f136e6-86c2-4633-8c64-3243f706b3f0' category='资金/费用调整(区域公司)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>ExpenseAdjustList</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='fdecb055-3121-458a-a4f1-6e63971957fe' category='资金/费用调整(区域公司)' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>FinanceRefundAccept</name>
<title>受理</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='6c88e9a2-2e07-40cd-8c78-a0fac1f3426a' category='资金/退费管理(区域公司)' seq='2'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>FinanceRefundCard</name>
<title>卡片查看</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='71e8e3ed-b0d0-47f4-b451-752416a5fa7d' category='资金/退费管理(区域公司)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>FinanceRefundList</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='054dae92-83fe-4bc4-b280-49983845914f' category='资金/退费管理' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.finance.auth</package>
<name>FinanceRefundReturnPremium</name>
<title>退费</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='e3b6a228-18d4-4da2-8954-8587d5ce09d4' category='资金/退费管理(区域公司)' seq='3'></privilege>
</content>
</model>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>0ba03c35-0f62-40ac-bc96-94e80dffe2d3</id>
<name>com.xyst.dinas.finance.auth.ArtificialRechargeCard</name>
<title>卡片查看</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/人工账户充值(区域公司)</m:category>
<m:seq>2</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>a742f2aa-db1a-4075-9890-79b50b8cccd2</id>
<name>com.xyst.dinas.finance.auth.ArtificialRechargeCreate</name>
<title>新建</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/人工账户充值(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>45f107ed-dc73-40a2-af55-86f2d3a06928</id>
<name>com.xyst.dinas.finance.auth.ArtificialRechargeList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/人工账户充值</m:category>
<m:seq>0</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>f2d1a332-5aec-491e-acbc-b2f3e1c8909c</id>
<name>com.xyst.dinas.finance.auth.BankRechargeDetailCreate</name>
<title>新建</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/银行充值明细(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>ae29a89f-29ec-442f-b60c-0c3ed0332609</id>
<name>com.xyst.dinas.finance.auth.BankRechargeDetailList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/银行充值明细</m:category>
<m:seq>0</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>c7901c69-fe3b-4f4f-9f8f-edee831af56f</id>
<name>com.xyst.dinas.finance.auth.ExpenseAdjustCard</name>
<title>卡片查看</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/费用调整(区域公司)</m:category>
<m:seq>2</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>71f136e6-86c2-4633-8c64-3243f706b3f0</id>
<name>com.xyst.dinas.finance.auth.ExpenseAdjustCreate</name>
<title>新建</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/费用调整(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>fdecb055-3121-458a-a4f1-6e63971957fe</id>
<name>com.xyst.dinas.finance.auth.ExpenseAdjustList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/费用调整(区域公司)</m:category>
<m:seq>0</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>6c88e9a2-2e07-40cd-8c78-a0fac1f3426a</id>
<name>com.xyst.dinas.finance.auth.FinanceRefundAccept</name>
<title>受理</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/退费管理(区域公司)</m:category>
<m:seq>2</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>71e8e3ed-b0d0-47f4-b451-752416a5fa7d</id>
<name>com.xyst.dinas.finance.auth.FinanceRefundCard</name>
<title>卡片查看</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/退费管理(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>054dae92-83fe-4bc4-b280-49983845914f</id>
<name>com.xyst.dinas.finance.auth.FinanceRefundList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/退费管理</m:category>
<m:seq>0</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>e3b6a228-18d4-4da2-8954-8587d5ce09d4</id>
<name>com.xyst.dinas.finance.auth.FinanceRefundReturnPremium</name>
<title>退费</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>资金/退费管理(区域公司)</m:category>
<m:seq>3</m:seq>
</m:privilege>
</content>
</metadata>
package com.xyst.dinas.price.constant;
/**
* @author scol
*/
public interface PriceAdjustmentConstant {
/**
......
......@@ -106,7 +106,7 @@ public class PriceAdjustmentDaoImpl extends AbstractBaseDao implements PriceAdju
DetachedCriteria detachedCriteria = DetachedCriteria.forEntityName(bean.getName());
detachedCriteria.add(Restrictions.eq(BaseConstants.DEL, false));
detachedCriteria.add(Restrictions.in("station.id", id));
detachedCriteria.add(Restrictions.in("applyStatus", BizProcessState.IN_PROCESS.getValue(), BizProcessState.DONE_WITH_REJECT.getValue()));
detachedCriteria.add(Restrictions.in("applyStatus", BizProcessState.IN_PROCESS.getValue()));
detachedCriteria.addOrder(Order.desc("adjustmentDate"));
List<KObject> byCriteria = (List<KObject>) template.findByCriteria(detachedCriteria, 0, 1);
return byCriteria;
......@@ -355,7 +355,7 @@ public class PriceAdjustmentDaoImpl extends AbstractBaseDao implements PriceAdju
private List<PriceAdjustmentEchartReturnEntity> getPriceAdjustmentEchartReturnEntities(List<HashMap<String, Object>> byCriteria, Date adjustmentStartDate, Date adjustmentEndDate) {
PriceAdjustmentEchartReturnEntity priceAdjustmentEchartReturnEntity;
List<PriceAdjustmentEchartReturnEntity> priceAdjustmentEchartReturnEntities = new ArrayList<>();
HashMap<String, PriceAdjustmentEchartReturnEntity> priceAdjustmentEchartReturnHashMap = new HashMap<>();
HashMap<String, PriceAdjustmentEchartReturnEntity> priceAdjustmentEchartReturnHashMap = new HashMap<>(12);
StationDetailEntity stationDetailEntity;
HashMap<String, StationDetailEntity> stationDetail = new HashMap<>();
......@@ -455,13 +455,13 @@ public class PriceAdjustmentDaoImpl extends AbstractBaseDao implements PriceAdju
@Override
public UUID create(KObject kObject) {
KObject staff = AminoContextHolder.getContext().getStaff();
if (null == kObject.getUuid("id")) {
kObject.set("id", UUID.randomUUID());
if (null == kObject.getUuid(BaseConstants.ID)) {
kObject.set(BaseConstants.ID, UUID.randomUUID());
}
kObject.set("regionalCompany", dinasTypeDao.getCurrentLoginRegionalCompany());
kObject.set(BaseConstants.CREATOR, staff);
kObject.set(BaseConstants.CREATE_TIME, new Date());
kObject.set("del", false);
kObject.set(BaseConstants.DEL, false);
return ((UUID) template.save(kObject));
}
......
......@@ -3,6 +3,7 @@ package com.xyst.dinas.price.internal.service;
import com.beecode.bap.attachment.common.Page;
import com.beecode.bap.workflow.core.BizProcessState;
import com.beecode.bcp.type.KObject;
import com.beecode.inz.common.BaseConstants;
import com.xyst.dinas.price.dao.PriceAdjustmentDao;
import com.xyst.dinas.price.entity.PriceAdjustmentEchartReturnEntity;
import com.xyst.dinas.price.entity.PriceAdjustmentEchartSearchEntity;
......@@ -134,15 +135,16 @@ public class PriceAdjustmentServiceImpl implements PriceAdjustmentService {
@Override
public void update(KObject kobject) {
priceAdjustmentDao.modify(kobject);
//审批通过后获取 同一天生效时间 && 创建时间小于该条记录 && 已审批 的记录,将其改为驳回
//审批通过后获取 同一天生效时间 && 创建时间小于该条记录 && 已审批 的记录,将其改为失效
List<KObject> kObjects = priceAdjustmentDao.getSameAdjustmentDateAndLtCreateDate(kobject);
if (null == kObjects) {
return;
}
for (KObject kObject : kObjects) {
// kObject.set("applyStatus", BizProcessState.DONE_WITH_REJECT.getValue());
if(kObject.getString(BaseConstants.ID).equals(kObject.getString(BaseConstants.ID))){
continue;
}
kObject.set("adjustmentStatus", PriceAdjustmentAdjustmentStatusEnum.ABOLITION.getValue());
// kObject.set("failureReason", "本条数据所属生效日已有新记录审批通过,本条系统自动废弃");
priceAdjustmentDao.modify(kObject);
}
......
......@@ -174,7 +174,7 @@ public class PriceAdjustmentController {
}
KObject priceAdjustment = priceAdjustmentService.validateByStationId(id);
if(null!=priceAdjustment){
return ResponseObj.error("有正在审批或者未通过的数据,不可新建", priceAdjustment);
return ResponseObj.error("有正在审批的数据,不可新建", priceAdjustment);
}
return ResponseObj.success("可以新增");
......@@ -218,7 +218,7 @@ public class PriceAdjustmentController {
@GetMapping("getSameMessage")
public ResponseObj getSameAdjustmentDateAndLtCreateDateInfo(@DateTimeFormat(pattern = "yyyy-MM-dd")@RequestParam("adjustmentDate") Date adjustmentDate, @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") @RequestParam("createTime") Date createTime, @DateTimeFormat(pattern = "yyyy-MM-dd")@RequestParam("stationId") UUID stationId){
List<KObject> sameAdjustmentDateAndLtCreateDateInfo = priceAdjustmentService.getSameAdjustmentDateAndLtCreateDateInfo(adjustmentDate, createTime, stationId);
if(CollectionUtils.isEmpty(sameAdjustmentDateAndLtCreateDateInfo)){
if(!CollectionUtils.isEmpty(sameAdjustmentDateAndLtCreateDateInfo)){
String formart1DateString = DateTimeUtils.getFormart1DateString(adjustmentDate);
String message = "检查到该场站生效日期为["+formart1DateString+"]下有"+sameAdjustmentDateAndLtCreateDateInfo.size()+"条早先创建并审批通过的记录,当该记录提交审批通过后,会将其它记录置为失效";
return ResponseObj.error(message, sameAdjustmentDateAndLtCreateDateInfo);
......@@ -234,8 +234,8 @@ public class PriceAdjustmentController {
@GetMapping("getSameMessageById")
public ResponseObj getSameById(@RequestParam("id") UUID id){
KObject byId = priceAdjustmentService.getById(id);
List<KObject> sameAdjustmentDateAndLtCreateDateInfo = priceAdjustmentService.getSameAdjustmentDateAndLtCreateDateInfo(byId.getDate("adjustmentDate"),byId.getDate("createTime") , byId.get("station").getUuid("Id"));
if(CollectionUtils.isEmpty(sameAdjustmentDateAndLtCreateDateInfo)){
List<KObject> sameAdjustmentDateAndLtCreateDateInfo = priceAdjustmentService.getSameAdjustmentDateAndLtCreateDateInfo(byId.getDate("adjustmentDate"),byId.getDate("createTime") , byId.get("station").getUuid("id"));
if(!CollectionUtils.isEmpty(sameAdjustmentDateAndLtCreateDateInfo)){
String formart1DateString = DateTimeUtils.getFormart1DateString(byId.getDate("adjustmentDate"));
String message = "检查到该场站生效日期为["+formart1DateString+"]下有"+sameAdjustmentDateAndLtCreateDateInfo.size()+"条早先创建并审批通过的记录,当该记录提交审批通过后,会将其它记录置为失效";
return ResponseObj.error(message, sameAdjustmentDateAndLtCreateDateInfo);
......@@ -243,6 +243,4 @@ public class PriceAdjustmentController {
return ResponseObj.success();
}
}
\ No newline at end of file
......@@ -33,6 +33,6 @@ public interface ProductionPlanReportDao extends BaseDao {
void deleteByStationAndDate(UUID stationId, Date convertStringToDate1);
List<KObject> getNoWareHousing(List<UUID> productionLineIds);
List<KObject> getNoWareHousing(UUID productionPlanId);
}
......@@ -57,7 +57,7 @@ public class ProductionPlanReportDaoImpl extends AbstractBaseDao implements Prod
detachedCriteria.add(Restrictions.ge("productionPlanDate", startDate));
}
if (null != endDate) {
detachedCriteria.add(Restrictions.le("productionPlanDate", startDate));
detachedCriteria.add(Restrictions.le("productionPlanDate", endDate));
}
dinasTypeDao.addRegionalCompanyFilter(detachedCriteria);
......@@ -235,19 +235,33 @@ public class ProductionPlanReportDaoImpl extends AbstractBaseDao implements Prod
}
@Override
public List<KObject> getNoWareHousing(List<UUID> productionLineIds) {
public List<KObject> getNoWareHousing(UUID productionPlanId) {
DetachedCriteria detachedCriteria = DetachedCriteria.forEntityName(ENTITY);
detachedCriteria.add(Restrictions.eq(BaseConstants.DEL, false));
if (CollectionUtils.isEmpty(productionLineIds)) {
if (null==productionPlanId) {
detachedCriteria.add(Restrictions.le("productionPlanDate", new Date()));
} else {
detachedCriteria.add(Restrictions.in("id", productionLineIds));
//根据单条生产计划id查询该场站今天所有的生产计划
List<UUID> ids= getAllByOne(productionPlanId);
assert ids != null;
detachedCriteria.add(Restrictions.in("id", ids));
}
detachedCriteria.add(Restrictions.eq("warehousingStatus", false));
return (List<KObject>) template.findByCriteria(detachedCriteria);
}
private List<UUID> getAllByOne(UUID productionPlanId) {
KObject load = load(productionPlanId);
DetachedCriteria detachedCriteria = DetachedCriteria.forEntityName(ENTITY);
detachedCriteria.add(Restrictions.eq(BaseConstants.DEL, false));
detachedCriteria.add(Restrictions.eq("productionPlanDate", load.getDate("productionPlanDate")));
detachedCriteria.add(Restrictions.eq("station.id", load.get("station").getUuid("id")));
detachedCriteria.setProjection(Projections.projectionList().add(Projections.distinct(Projections.property("id"))));
return (List<UUID>)template.findByCriteria(detachedCriteria);
}
/**
* 抽象方法,需要实现类提供HibernateTemplate
*
......
......@@ -29,8 +29,8 @@ public class DischargingServiceImpl implements DischargingService {
@Autowired
private DischargingDao dischargingDao;
@Autowired
private WarningService warningService;
@Autowired
private WarningService warningService;
@Autowired
private StationDao stationDao;
@Autowired
......@@ -59,9 +59,9 @@ public class DischargingServiceImpl implements DischargingService {
}
@Override
public List<HashMap<String,Object>> groupInfoByYear(List<UUID> regionalCompanyIds, Integer year, Boolean isGroupByMonth, Boolean isGroupByRegionalCompany, Boolean isGroupBySandMiningArea) {
public List<HashMap<String, Object>> groupInfoByYear(List<UUID> regionalCompanyIds, Integer year, Boolean isGroupByMonth, Boolean isGroupByRegionalCompany, Boolean isGroupBySandMiningArea) {
return dischargingDao.groupInfo(regionalCompanyIds,year,isGroupByMonth,isGroupByRegionalCompany,isGroupBySandMiningArea);
return dischargingDao.groupInfo(regionalCompanyIds, year, isGroupByMonth, isGroupByRegionalCompany, isGroupBySandMiningArea);
}
@Override
......@@ -97,7 +97,7 @@ public class DischargingServiceImpl implements DischargingService {
//生成预警消息的逻辑 如果是小于当前年份的记录,不生成预警
//如果已有parentId 也不触发预警
Boolean ltYear = DateTimeUtils.isLtNowYear(dischargingTime);
if (!ltYear && kObject.getUuid("parentId")!=null) {
if (!ltYear && kObject.getUuid("parentId") != null) {
setWarningRecord(sandMiningAreaId, dischargingTime, sandMiningArea);
}
return uuid;
......@@ -107,14 +107,14 @@ public class DischargingServiceImpl implements DischargingService {
//查询某个采区下某的开采量
Double allDischargingWeightByYearAndSandAreaId = dischargingDao.getAllDischargingWeightByYearAndSandAreaId(dischargingTime, billId);
SandAreaDinasCountWarningCalculate sandAreaDinasCountWarningCalculate = new SandAreaDinasCountWarningCalculate(allDischargingWeightByYearAndSandAreaId, sandMiningArea.getString("sandMiningAreaName"));
BaseBusinessWarn businessWarn = warningService.createWarn(SandMiningAreaConstant.SAND_MINING_AREA_BILL_TYPE, billId, SandMiningAreaConstant.SAND_MINING_AREA_WARN_TARGET);
businessWarn.setWarningCalculate(sandAreaDinasCountWarningCalculate);
businessWarn.warn();
}
@Override
public Double getAllDischargingWeightByNowAndSandAreaId(UUID billId){
public Double getAllDischargingWeightByNowAndSandAreaId(UUID billId) {
return dischargingDao.getAllDischargingWeightByYearAndSandAreaId(new Date(), billId);
}
......@@ -188,14 +188,14 @@ public class DischargingServiceImpl implements DischargingService {
KObject oldSandMiningArea = id.get("sandMiningArea");
UUID oldSandMiningAreaId = oldSandMiningArea.getUuid("id");
if(null!=kObject.getUuid("parentId")){
if (null == kObject.getUuid("parentId")) {
//如果采区和年都没有变化,则不判断旧的数据是否结束
if(oldSandMiningAreaId!=sandMiningAreaId&&!DateTimeUtils.isSameYear(oldDischargingTime,dischargingTime)){
if (oldSandMiningAreaId != sandMiningAreaId && !DateTimeUtils.isSameYear(oldDischargingTime, dischargingTime)) {
setWarningRecord(oldSandMiningAreaId, oldDischargingTime, oldSandMiningArea);
}
if(!DateTimeUtils.isLtNowYear(dischargingTime)){
if (!DateTimeUtils.isLtNowYear(dischargingTime)) {
setWarningRecord(sandMiningAreaId, dischargingTime, sandMiningArea);
}
}
}
dischargingDao.modify(kObject);
}
......
......@@ -168,7 +168,7 @@ public class ProductionPlanReportServiceImpl implements ProductionPlanReportServ
}
@Override
public void warehousing(List<UUID> productionLineIds) {
public void warehousing(UUID productionLineIds) {
//查询本天之前所有未入库的数据
List<KObject> a = productionPlanReportDao.getNoWareHousing(productionLineIds);
......
......@@ -38,6 +38,6 @@ public interface ProductionPlanReportService {
void deleteByStationAndDate(UUID stationId, Date convertStringToDate1);
void warehousing(List<UUID> productionLineIds);
void warehousing(UUID productionLineIds);
}
......@@ -59,9 +59,9 @@ public class ProductionPlanReportController {
@RequestMapping(value = "warehousing", method = RequestMethod.GET)
public ResponseObj warehousing(
@RequestParam(name = "productionLineIds", required = false) List<UUID> productionLineIds
@RequestParam(name = "productionPlanId", required = false) UUID productionPlanId
) {
productionPlanReportService.warehousing(productionLineIds);
productionPlanReportService.warehousing(productionPlanId);
return ResponseObj.success("入库成功");
}
......
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledCard</name>
<title>卡片查看</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='285b4a7d-a887-45f1-81fd-7b6d3595579d' category='项目/项目备案(区域公司)' seq='3'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledCardGroupCompany</name>
<title>卡片查看</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='0ada5952-4eb2-4e24-be76-be63c77afee0' category='项目/项目清单(集团)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledCreate</name>
<title>新建</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='b0030e40-a73f-4b56-966e-d9975a882b7f' category='项目/项目备案(区域公司)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledDiscard</name>
<title>删除</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='9cf0044e-d723-42ec-92e1-a4f289102ec9' category='项目/项目备案(区域公司)' seq='4'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledEdit</name>
<title>编辑</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='be2cb17f-aac0-4424-9dff-8a6cfdbba670' category='项目/项目备案(区域公司)' seq='2'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledExport</name>
<title>导出</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='90169ba4-65a0-4720-8034-dc0206ee82e1' category='项目/项目备案(区域公司)' seq='5'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledExportGroupCompany</name>
<title>导出</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='d3fac741-040c-4e52-9194-879bccb2ace2' category='项目/项目清单(集团)' seq='2'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledList</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='38d2a15a-e8bf-4a0c-b27d-812f13915962' category='项目/项目备案(区域公司)' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>ProjectFiledListGroupCompany</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='ba078e68-b467-4ce6-a45f-c9d8f7db0089' category='项目/项目清单(集团)' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyCard</name>
<title>卡片查看</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='f06da281-d6dc-4475-9168-b5a1ed374ecc' category='项目/购砂单位备案(区域公司)' seq='3'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyCardGroupCompany</name>
<title>卡片查看</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='28768a8d-df79-4b38-bb37-956cba7724ac' category='项目/购砂单位清单(集团)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyCreate</name>
<title>新建</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='1572cd56-456c-4b9e-b487-15a6b42df517' category='项目/购砂单位备案(区域公司)' seq='1'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyDiscard</name>
<title>删除</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='b26cd05a-cb87-4e0e-ac2d-2211cec7b2ae' category='项目/购砂单位备案(区域公司)' seq='4'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyEdit</name>
<title>编辑</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='ff38f29e-1742-4443-956d-f2b126ab9b26' category='项目/购砂单位备案(区域公司)' seq='2'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyExport</name>
<title>导出</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='7cbbce5b-5ac1-40c5-92b1-3a6e740648f4' category='项目/购砂单位备案(区域公司)' seq='5'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyExportGroupCompany</name>
<title>导出</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='0ed28840-4411-47ef-a2cf-fa6755de0428' category='项目/购砂单位清单(集团)' seq='2'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyList</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='1d093c8b-84f6-4383-bf7a-fcda912559c7' category='项目/购砂单位备案(区域公司)' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<model>
<header>
<type>bcp.authz.Privilege</type>
<package>com.xyst.dinas.project.auth</package>
<name>PurchaseSandCompanyListGroupCompany</name>
<title>列表</title>
<tags></tags>
<description></description>
</header>
<content>
<privilege type='TOKEN' target-type='' id='d093b261-bb6c-4713-b5ed-439bf54648ad' category='项目/购砂单位清单(集团)' seq='0'></privilege>
</content>
</model>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>285b4a7d-a887-45f1-81fd-7b6d3595579d</id>
<name>com.xyst.dinas.project.auth.ProjectFiledCard</name>
<title>卡片查看</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目备案(区域公司)</m:category>
<m:seq>3</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>0ada5952-4eb2-4e24-be76-be63c77afee0</id>
<name>com.xyst.dinas.project.auth.ProjectFiledCardGroupCompany</name>
<title>卡片查看</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目清单(集团)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>b0030e40-a73f-4b56-966e-d9975a882b7f</id>
<name>com.xyst.dinas.project.auth.ProjectFiledCreate</name>
<title>新建</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目备案(区域公司)</m:category>
<m:seq>1</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>9cf0044e-d723-42ec-92e1-a4f289102ec9</id>
<name>com.xyst.dinas.project.auth.ProjectFiledDiscard</name>
<title>删除</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目备案(区域公司)</m:category>
<m:seq>4</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>be2cb17f-aac0-4424-9dff-8a6cfdbba670</id>
<name>com.xyst.dinas.project.auth.ProjectFiledEdit</name>
<title>编辑</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目备案(区域公司)</m:category>
<m:seq>2</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>90169ba4-65a0-4720-8034-dc0206ee82e1</id>
<name>com.xyst.dinas.project.auth.ProjectFiledExport</name>
<title>导出</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目备案(区域公司)</m:category>
<m:seq>5</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>d3fac741-040c-4e52-9194-879bccb2ace2</id>
<name>com.xyst.dinas.project.auth.ProjectFiledExportGroupCompany</name>
<title>导出</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目清单(集团)</m:category>
<m:seq>2</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>38d2a15a-e8bf-4a0c-b27d-812f13915962</id>
<name>com.xyst.dinas.project.auth.ProjectFiledList</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目备案(区域公司)</m:category>
<m:seq>0</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>ba078e68-b467-4ce6-a45f-c9d8f7db0089</id>
<name>com.xyst.dinas.project.auth.ProjectFiledListGroupCompany</name>
<title>列表</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/项目清单(集团)</m:category>
<m:seq>0</m:seq>
</m:privilege>
</content>
</metadata>
<?xml version="1.0" encoding="UTF-8"?>
<metadata xmlns="http://www.beecode.cn/schema/amino-metadata" xmlns:m="http://www.beecode.cn/schema/bcp-privilege">
<specification>1.0</specification>
<id>f06da281-d6dc-4475-9168-b5a1ed374ecc</id>
<name>com.xyst.dinas.project.auth.PurchaseSandCompanyCard</name>
<title>卡片查看</title>
<define>bcp.authz.privilege</define>
<define-version>1.0.0</define-version>
<content>
<m:privilege>
<m:type>TOKEN</m:type>
<m:category>项目/购砂单位备案(区域公司)</m:category>
<m:seq>3</m:seq>
</m:privilege>
</content>
</metadata>
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