作者 shenhailong

添加 远程调用 预配添加接口

@@ -499,7 +499,6 @@ @@ -499,7 +499,6 @@
499 <artifactId>axis</artifactId> 499 <artifactId>axis</artifactId>
500 <version>1.4</version> 500 <version>1.4</version>
501 </dependency> 501 </dependency>
502 -  
503 </dependencies> 502 </dependencies>
504 503
505 <!-- 配置文件 --> 504 <!-- 配置文件 -->
@@ -1253,12 +1253,26 @@ public class ManifestController extends BasicController { @@ -1253,12 +1253,26 @@ public class ManifestController extends BasicController {
1253 * @param manifest 1253 * @param manifest
1254 * @return 1254 * @return
1255 */ 1255 */
1256 - @RequestMapping(value = "/savesendMainfest", method = { RequestMethod.POST }) 1256 + @RequestMapping(value = "/savesenManifest", method = { RequestMethod.POST })
1257 @ResponseBody 1257 @ResponseBody
1258 - public ResponseModel savesendMainfest(ManifestEntity manifest, HttpServletRequest request, HttpServletResponse response) { 1258 + public ResponseModel savesenManifest(ManifestEntity manifest, HttpServletRequest request, HttpServletResponse response) {
1259 1259
1260 ResponseModel model = new ResponseModel(); 1260 ResponseModel model = new ResponseModel();
1261 - if ("dcdf38d9a5d6411985e49155481882f5".equals(manifest.getPassword())){ 1261 + if ("dcdf38d9a5d6411985e49155481882f5".equals(manifest.getDe_size())){
  1262 +
  1263 + if(manifest.getWaybillnomaster().contains("-")){
  1264 +
  1265 + }else {
  1266 + StringBuilder stringBuilder = new StringBuilder(manifest.getWaybillnomaster());
  1267 +
  1268 + StringBuilder waybill = stringBuilder.insert(3, "-");
  1269 +
  1270 + manifest.setWaybillnomaster(waybill.toString());
  1271 +
  1272 + }
  1273 +
  1274 + manifest.setDe_size("");
  1275 +
1262 String flightno = manifest.getFlightno(); 1276 String flightno = manifest.getFlightno();
1263 String carrier = ""; 1277 String carrier = "";
1264 if (StringUtils.isNotBlank(flightno) && flightno.length() > 2) { 1278 if (StringUtils.isNotBlank(flightno) && flightno.length() > 2) {
@@ -1270,12 +1284,13 @@ public class ManifestController extends BasicController { @@ -1270,12 +1284,13 @@ public class ManifestController extends BasicController {
1270 1284
1271 1285
1272 try { 1286 try {
1273 - manifest.setUSER_ID(Tools.getUserId());  
1274 - if (manifestService.isExistsByWaybill(manifest)) { 1287 +// manifest.setUSER_ID(Tools.getUserId());
  1288 + ManifestEntity wbm = manifestService.findWbm(manifest.getWaybillnomaster());
  1289 + if (wbm != null) {
1275 model.setStatus(201); 1290 model.setStatus(201);
1276 model.setMsg("该订单号已存在!"); 1291 model.setMsg("该订单号已存在!");
1277 } else { 1292 } else {
1278 - WaybillReceiptType type = WaybillReceiptType.APPLY; 1293 + WaybillReceiptType type = WaybillReceiptType.TEMP_SAVE;
1279 1294
1280 String stowagedate = request.getParameter("stowagedate"); 1295 String stowagedate = request.getParameter("stowagedate");
1281 manifest.setStowagedate(ManifestEntity.getStowagedate(stowagedate)); 1296 manifest.setStowagedate(ManifestEntity.getStowagedate(stowagedate));
@@ -1286,11 +1301,6 @@ public class ManifestController extends BasicController { @@ -1286,11 +1301,6 @@ public class ManifestController extends BasicController {
1286 manifest.setSave_time(System.currentTimeMillis()); 1301 manifest.setSave_time(System.currentTimeMillis());
1287 1302
1288 manifestService.save(manifest); 1303 manifestService.save(manifest);
1289 - receiptService.saveFromManifest(manifest, type);  
1290 -  
1291 - manifest.setAgentcompany(getAgent().getNameCn());  
1292 - manifest.setAgentman(getAgent().getThreeCode());  
1293 - manifest.setAgentcompanycode(getAgent().getThreeCode());  
1294 1304
1295 model.setData(manifest); 1305 model.setData(manifest);
1296 model.setStatus(200); 1306 model.setStatus(200);
@@ -289,16 +289,16 @@ public class ManifestEntity extends BasicEntity implements Serializable { @@ -289,16 +289,16 @@ public class ManifestEntity extends BasicEntity implements Serializable {
289 private Long save_time; 289 private Long save_time;
290 private Long USER_ID; // 报文所属的用户id 290 private Long USER_ID; // 报文所属的用户id
291 291
292 - // 验证密码 调用使用  
293 - private String password;  
294 -  
295 - public String getPassword() {  
296 - return password;  
297 - }  
298 -  
299 - public void setPassword(String password) {  
300 - this.password = password;  
301 - } 292 +// // 验证密码 调用使用
  293 +// private String password;
  294 +//
  295 +// public String getPassword() {
  296 +// return password;
  297 +// }
  298 +//
  299 +// public void setPassword(String password) {
  300 +// this.password = password;
  301 +// }
302 302
303 public String getUnlodingcode() { 303 public String getUnlodingcode() {
304 return StringUtils.isBlank(unlodingcode) ? getDestinationstation() : unlodingcode; 304 return StringUtils.isBlank(unlodingcode) ? getDestinationstation() : unlodingcode;
@@ -29,7 +29,7 @@ public class MyShiroController implements Filter { @@ -29,7 +29,7 @@ public class MyShiroController implements Filter {
29 } 29 }
30 30
31 private String publicAction[] = { "/login", "/doLogin", "/manifest/app/send", 31 private String publicAction[] = { "/login", "/doLogin", "/manifest/app/send",
32 - "/receipt/a0608c4054662dd902e1314f7e450e3eaa81c114" }; 32 + "/receipt/a0608c4054662dd902e1314f7e450e3eaa81c114", "/manifest/savesenManifest" };
33 private String crossDomain[] = { "/cross/", "tracking/detail" }; 33 private String crossDomain[] = { "/cross/", "tracking/detail" };
34 34
35 // manifest/cross/grid.json 35 // manifest/cross/grid.json