Commit 7cc35fec by manxiaoqiang

2

parent 2949c5ec
......@@ -3,7 +3,7 @@
<component name="ChangeListManager">
<list default="true" id="e2e217e2-2dd6-4c6f-ad19-b1cba46bc7ad" name="Default" comment="">
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/main/java/common/repository/IOAccount4WebRepository.java" afterPath="$PROJECT_DIR$/src/main/java/common/repository/IOAccount4WebRepository.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/main/java/common/service/impl/ContractServiceImpl.java" afterPath="$PROJECT_DIR$/src/main/java/common/service/impl/ContractServiceImpl.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/main/java/tkio/task/AccountCheck.java" afterPath="$PROJECT_DIR$/src/main/java/tkio/task/AccountCheck.java" />
</list>
<ignored path="$PROJECT_DIR$/target/" />
......@@ -33,11 +33,11 @@
<component name="ExecutionTargetManager" SELECTED_TARGET="default_target" />
<component name="FileEditorManager">
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="ContractServiceImpl.java" pinned="false" current-in-tab="false">
<file leaf-file-name="ContractServiceImpl.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/main/java/common/service/impl/ContractServiceImpl.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="368">
<caret line="226" column="13" lean-forward="false" selection-start-line="226" selection-start-column="13" selection-end-line="226" selection-end-column="13" />
<state relative-caret-position="920">
<caret line="367" column="13" lean-forward="false" selection-start-line="367" selection-start-column="13" selection-end-line="367" selection-end-column="13" />
<folding />
</state>
</provider>
......@@ -66,8 +66,8 @@
<file leaf-file-name="AccountCheck.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/main/java/tkio/task/AccountCheck.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="175">
<caret line="35" column="67" lean-forward="false" selection-start-line="35" selection-start-column="67" selection-end-line="35" selection-end-column="67" />
<state relative-caret-position="529">
<caret line="36" column="48" lean-forward="false" selection-start-line="36" selection-start-column="48" selection-end-line="36" selection-end-column="48" />
<folding />
</state>
</provider>
......@@ -83,7 +83,7 @@
</provider>
</entry>
</file>
<file leaf-file-name="IOAccount4WebRepository.java" pinned="false" current-in-tab="true">
<file leaf-file-name="IOAccount4WebRepository.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/main/java/common/repository/IOAccount4WebRepository.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="366">
......@@ -206,9 +206,9 @@
<option value="$PROJECT_DIR$/src/main/java/userio/service/IOAccountService.java" />
<option value="$PROJECT_DIR$/src/main/java/userio/repository/IOSalesManLeaderRepository.java" />
<option value="$PROJECT_DIR$/src/main/resources/spring/applicationContext-schedule.xml" />
<option value="$PROJECT_DIR$/src/main/java/common/service/impl/ContractServiceImpl.java" />
<option value="$PROJECT_DIR$/src/main/java/tkio/task/AccountCheck.java" />
<option value="$PROJECT_DIR$/src/main/java/common/repository/IOAccount4WebRepository.java" />
<option value="$PROJECT_DIR$/src/main/java/tkio/task/AccountCheck.java" />
<option value="$PROJECT_DIR$/src/main/java/common/service/impl/ContractServiceImpl.java" />
</list>
</option>
</component>
......@@ -1193,13 +1193,6 @@
<workItem from="1523843445576" duration="7238000" />
<workItem from="1523876594256" duration="75800000" />
</task>
<task id="LOCAL-00079" summary="app排序">
<created>1517477110327</created>
<option name="number" value="00079" />
<option name="presentableId" value="LOCAL-00079" />
<option name="project" value="LOCAL" />
<updated>1517477110327</updated>
</task>
<task id="LOCAL-00080" summary="app排序">
<created>1517477130551</created>
<option name="number" value="00080" />
......@@ -1536,11 +1529,18 @@
<option name="project" value="LOCAL" />
<updated>1524727895420</updated>
</task>
<option name="localTasksCounter" value="128" />
<task id="LOCAL-00128" summary="2&#10;">
<created>1524728497519</created>
<option name="number" value="00128" />
<option name="presentableId" value="LOCAL-00128" />
<option name="project" value="LOCAL" />
<updated>1524728497519</updated>
</task>
<option name="localTasksCounter" value="129" />
<servers />
</component>
<component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="502955000" />
<option name="totallyTimeSpent" value="503745000" />
</component>
<component name="ToolWindowManager">
<frame x="-8" y="-8" width="1382" height="744" extended-state="6" />
......@@ -2052,14 +2052,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/common/service/impl/ContractServiceImpl.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="368">
<caret line="226" column="13" lean-forward="false" selection-start-line="226" selection-start-column="13" selection-end-line="226" selection-end-column="13" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/tkio/repository/AccountRepository.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="115">
......@@ -2068,14 +2060,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/tkio/task/AccountCheck.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="175">
<caret line="35" column="67" lean-forward="false" selection-start-line="35" selection-start-column="67" selection-end-line="35" selection-end-column="67" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/userio/controller/IoAccountController.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="390">
......@@ -2134,6 +2118,22 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/tkio/task/AccountCheck.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="529">
<caret line="36" column="48" lean-forward="false" selection-start-line="36" selection-start-column="48" selection-end-line="36" selection-end-column="48" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/common/service/impl/ContractServiceImpl.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="920">
<caret line="367" column="13" lean-forward="false" selection-start-line="367" selection-start-column="13" selection-end-line="367" selection-end-column="13" />
<folding />
</state>
</provider>
</entry>
</component>
<component name="masterDetails">
<states>
......
......@@ -346,23 +346,25 @@ public class ContractServiceImpl implements ContractService{
}
if(contract.getPlatform().equals("tkio")){
IncrementFlow flow = incrementFlowRepository.findOne(resource.getContractCode());
if(null != flow){
flow.setEndDate(resource.getEndDate());
flow.setStartDate(resource.getStartDate());
if(contract.getExtraFlow() != resource.getExtraFlow() ){
flow.setFlow(resource.getExtraFlow());
incrementFlowRepository.save(flow);
if(resource.getPlatform().equals("tkio")) {
IncrementFlow flow = incrementFlowRepository.findOne(resource.getContractCode());
if (null != flow) {
flow.setEndDate(resource.getEndDate());
flow.setStartDate(resource.getStartDate());
if (contract.getExtraFlow() != resource.getExtraFlow()) {
flow.setFlow(resource.getExtraFlow());
incrementFlowRepository.save(flow);
}
} else if (resource.getExtraFlow().longValue() > 0) {
IncrementFlow flow1 = new IncrementFlow();
Account account = accountRepository.findByEmail(contract.getEmail());
flow1.setAccount(account.getId());
flow1.setFlow(resource.getExtraFlow());
flow1.setEndDate(resource.getEndDate());
flow1.setStartDate(resource.getStartDate());
flow1.setContractCode(resource.getContractCode());
incrementFlowRepository.save(flow1);
}
} else if(resource.getExtraFlow().longValue() > 0){
IncrementFlow flow1 = new IncrementFlow();
Account account = accountRepository.findByEmail(contract.getEmail());
flow1.setAccount(account.getId());
flow1.setFlow(resource.getExtraFlow());
flow1.setEndDate(resource.getEndDate());
flow1.setStartDate(resource.getStartDate());
flow1.setContractCode(resource.getContractCode());
incrementFlowRepository.save(flow1);
}
}
......
......@@ -34,7 +34,7 @@ public class AccountCheck {
for(Account a: accountList){
List<Contract> contractList = contractRepository.findByPlatformAndEmail("tkio", a.getEmail(), ContractTypeEnum.MAIN.getKey());
logger.error("startDate :" + (null == contractList));
if(null == contractList){
if(null == contractList || contractList.isEmpty()){
a.setStatus(0);
list.add(a);
}
......
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