|
@@ -1,6 +1,6 @@
|
|
|
package com.uas.erp.schedular.publicproduct.task;
|
|
|
|
|
|
-import com.uas.erp.schedular.publicproduct.domain.ProductSaler;
|
|
|
+import com.uas.erp.schedular.publicproduct.domain.ProductReplace;
|
|
|
import com.uas.erp.schedular.task.support.Method;
|
|
|
import com.uas.erp.schedular.task.support.Role;
|
|
|
import com.uas.erp.schedular.task.support.TaskMapping;
|
|
@@ -27,11 +27,11 @@ public class ProdUserTask extends AbstractTask {
|
|
|
*/
|
|
|
@TaskMapping(title = "同步ERP的个人物料信息到公共服务", fixedDelay = 60000, method = Method.UPLOAD)
|
|
|
public void uploadProductSaler() {
|
|
|
- List<ProductSaler> prods = jdbcTemplate.queryForBeanList("select ps_id,ps_prcode ps_code,nvl(em_uu,0) em_uu,nvl((select en_uu from enterprise ),0) en_uu from productSaler, employee, product where em_code = ps_emcode and nvl(em_uu, 0)<>0 and pr_code = ps_prcode and nvl(pr_sendstatus, ' ') = '已上传' and nvl(pr_status, ' ') = '已审核' and nvl(ps_emstatus,' ') = '是' and nvl(ps_uploadstatus, ' ') <> '已上传' and rownum <= 200",
|
|
|
- ProductSaler.class);
|
|
|
+ List<ProductReplace> prods = jdbcTemplate.queryForBeanList("select ps_id,ps_prcode ps_code,nvl(em_uu,0) em_uu,nvl((select en_uu from enterprise ),0) en_uu from productSaler, employee, product where em_code = ps_emcode and nvl(em_uu, 0)<>0 and pr_code = ps_prcode and nvl(pr_sendstatus, ' ') = '已上传' and nvl(pr_status, ' ') = '已审核' and nvl(ps_emstatus,' ') = '是' and nvl(ps_uploadstatus, ' ') <> '已上传' and rownum <= 200",
|
|
|
+ ProductReplace.class);
|
|
|
if (!CollectionUtils.isEmpty(prods)) {
|
|
|
ContextHolder.increaseDataSize(prods.size());
|
|
|
- new StatusBasedHandler<ProductSaler>("productsaler", "ps_id", "ps_uploadstatus", "/product/produser", prods).run();
|
|
|
+ postForList("/erp/productReplace/update", ProductReplace.class, dataWrap(prods));
|
|
|
}
|
|
|
}
|
|
|
/**
|
|
@@ -40,7 +40,7 @@ public class ProdUserTask extends AbstractTask {
|
|
|
* @author wuyx
|
|
|
* @date 2018-01-30 08:16
|
|
|
*/
|
|
|
- @TaskMapping(title = "同步取消公共服务ERP的个人物料信息", fixedDelay = 60000, method = Method.UPLOAD)
|
|
|
+ /* @TaskMapping(title = "同步取消公共服务ERP的个人物料信息", fixedDelay = 60000, method = Method.UPLOAD)
|
|
|
public void uploadProductSalerQuit() {
|
|
|
List<ProductSaler> prods = jdbcTemplate.queryForBeanList("select ps_id,ps_prcode ps_code,nvl(em_uu,0) em_uu,nvl((select en_uu from enterprise ),0) en_uu from productSaler, employee, product where em_code = ps_emcode and nvl(em_uu, 0)<>0 and pr_code = ps_prcode and nvl(pr_sendstatus, ' ') = '已上传' and nvl(pr_status, ' ') = '已审核' and nvl(ps_emstatus,' ') = '否' and nvl(ps_uploadstatus, ' ') <> '已上传' and rownum <= 200",
|
|
|
ProductSaler.class);
|
|
@@ -48,6 +48,6 @@ public class ProdUserTask extends AbstractTask {
|
|
|
ContextHolder.increaseDataSize(prods.size());
|
|
|
new StatusBasedHandler<ProductSaler>("productsaler", "ps_id", "ps_uploadstatus", "/product/produser/quit", prods).run();
|
|
|
}
|
|
|
- }
|
|
|
+ }*/
|
|
|
|
|
|
}
|