|
@@ -6,10 +6,12 @@ import com.github.pagehelper.PageHelper;
|
6
|
6
|
import com.github.pagehelper.PageInfo;
|
7
|
7
|
import com.th.demo.mapping.finance.ModPriceLogMapper;
|
8
|
8
|
import com.th.demo.mapping.finance.VerifyAccountMapper;
|
|
9
|
+import com.th.demo.mapping.ware.DistributionMapper;
|
9
|
10
|
import com.th.demo.mapping.ware.OutRecordMapper;
|
10
|
11
|
import com.th.demo.model.finance.ModPriceLog;
|
11
|
12
|
import com.th.demo.model.finance.VerifyAccount;
|
12
|
13
|
import com.th.demo.model.system.Type;
|
|
14
|
+import com.th.demo.model.ware.Distribution;
|
13
|
15
|
import com.th.demo.model.ware.OutRecord;
|
14
|
16
|
import com.th.demo.model.ware.Store;
|
15
|
17
|
import com.th.demo.model.ware.TotalRecord;
|
|
@@ -30,6 +32,8 @@ public class OutRecordServiceImpl implements OutRecordService {
|
30
|
32
|
public OutRecordMapper outRecordMapper;
|
31
|
33
|
@Autowired
|
32
|
34
|
public VerifyAccountMapper verifyAccountMapper;
|
|
35
|
+ @Autowired
|
|
36
|
+ public DistributionMapper distributionMapper;
|
33
|
37
|
|
34
|
38
|
@Autowired
|
35
|
39
|
public ModPriceLogMapper modPriceLogMapper;
|
|
@@ -140,6 +144,19 @@ public class OutRecordServiceImpl implements OutRecordService {
|
140
|
144
|
}
|
141
|
145
|
return Tools.moreThanZeroResultJSON(num);
|
142
|
146
|
}
|
|
147
|
+
|
|
148
|
+ @Override
|
|
149
|
+ public String saveCar(String json,String truckNo,String driverName,String driverPhone,String userId,String belongId) {
|
|
150
|
+ List<OutRecord> list = JSON.parseObject(json, new TypeReference<List<OutRecord>>() {
|
|
151
|
+ });
|
|
152
|
+ Distribution distribution = distributionMapper.selectByPrimaryKey(list.get(0).getDistributionId());
|
|
153
|
+ distribution.setTruckNo(truckNo);
|
|
154
|
+ distribution.setDriverName(driverName);
|
|
155
|
+ distribution.setDriverPhone(driverPhone);
|
|
156
|
+ num = distributionMapper.updateByPrimaryKey(distribution);
|
|
157
|
+
|
|
158
|
+ return Tools.moreThanZeroResultJSON(num);
|
|
159
|
+ }
|
143
|
160
|
}
|
144
|
161
|
|
145
|
162
|
|