added empty data check
This commit is contained in:
+2
@@ -149,6 +149,7 @@ public class JournalEntryRunningBalanceUpdateServiceImpl implements JournalEntry
|
|||||||
|
|
||||||
List<JournalEntryData> entryDatas = jdbcTemplate.query(entryMapper.organizationRunningBalanceSchema(), entryMapper,
|
List<JournalEntryData> entryDatas = jdbcTemplate.query(entryMapper.organizationRunningBalanceSchema(), entryMapper,
|
||||||
new Object[] { entityDate });
|
new Object[] { entityDate });
|
||||||
|
if(entryDatas.size()>0){
|
||||||
String[] updateSql = new String[entryDatas.size()];
|
String[] updateSql = new String[entryDatas.size()];
|
||||||
int i = 0;
|
int i = 0;
|
||||||
for (JournalEntryData entryData : entryDatas) {
|
for (JournalEntryData entryData : entryDatas) {
|
||||||
@@ -166,6 +167,7 @@ public class JournalEntryRunningBalanceUpdateServiceImpl implements JournalEntry
|
|||||||
updateSql[i++] = sql;
|
updateSql[i++] = sql;
|
||||||
}
|
}
|
||||||
this.jdbcTemplate.batchUpdate(updateSql);
|
this.jdbcTemplate.batchUpdate(updateSql);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user