Compare commits
2
Commits
9413a78cc1
...
adadd55c77
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
adadd55c77 | ||
|
|
90df42246e |
No files matched your search
@@ -1,7 +1,6 @@
|
|||||||
package com.binary.weight.service;
|
package com.binary.weight.service;
|
||||||
|
|
||||||
import com.binary.weight.entity.Order;
|
import com.binary.weight.entity.Order;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.beans.factory.annotation.Qualifier;
|
import org.springframework.beans.factory.annotation.Qualifier;
|
||||||
import org.springframework.dao.EmptyResultDataAccessException;
|
import org.springframework.dao.EmptyResultDataAccessException;
|
||||||
import org.springframework.jdbc.core.BeanPropertyRowMapper;
|
import org.springframework.jdbc.core.BeanPropertyRowMapper;
|
||||||
|
|||||||
@@ -32,7 +32,6 @@ public class SyncService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void sync() {
|
public void sync() {
|
||||||
long start = System.currentTimeMillis();
|
|
||||||
String sql = "SELECT TOP 1000 * FROM tbl_weight_info WHERE id > ?";
|
String sql = "SELECT TOP 1000 * FROM tbl_weight_info WHERE id > ?";
|
||||||
|
|
||||||
String id = jdbcTemplate.queryForObject("select max(id) from tbl_weight_info", String.class);
|
String id = jdbcTemplate.queryForObject("select max(id) from tbl_weight_info", String.class);
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ public class WeightService {
|
|||||||
private JdbcTemplate jdbcTemplate;
|
private JdbcTemplate jdbcTemplate;
|
||||||
|
|
||||||
public byte[] getWeightData() {
|
public byte[] getWeightData() {
|
||||||
String sql = "SELECT net, carno, receiver, remark, goods, YEAR(gross_time) as `year`, MONTH(gross_time) as `month`, DAY(gross_time) as `day`, TIME(gross_time) as `time` FROM tbl_weight_info";
|
String sql = "SELECT net, carNo, receiver, remark, goods, YEAR(gross_time) as `year`, MONTH(gross_time) as `month`, DAY(gross_time) as `day`, TIME(gross_time) as `time`, orderNo, salesTy, shipNo, transportInfo, wharf, car_team as carTeam FROM tbl_weight_info";
|
||||||
|
|
||||||
if (cache == null) {
|
if (cache == null) {
|
||||||
ObjectMapper objectMapper = new ObjectMapper();
|
ObjectMapper objectMapper = new ObjectMapper();
|
||||||
|
|||||||
Reference in new issue
Block a user