|
|
@@ -1,11 +1,19 @@
|
|
|
package com.izouma.zhirongip.service;
|
|
|
|
|
|
import com.izouma.zhirongip.ApplicationTests;
|
|
|
+import com.izouma.zhirongip.domain.demand.CopyrightDemand;
|
|
|
+import com.izouma.zhirongip.domain.demand.LogoDemand;
|
|
|
+import com.izouma.zhirongip.domain.demand.PatentDemand;
|
|
|
+import com.izouma.zhirongip.domain.demand.TechProductDemand;
|
|
|
import com.izouma.zhirongip.domain.supply.Copyright;
|
|
|
import com.izouma.zhirongip.domain.supply.Logo;
|
|
|
import com.izouma.zhirongip.domain.supply.Patent;
|
|
|
import com.izouma.zhirongip.domain.supply.TechnologyProduct;
|
|
|
import com.izouma.zhirongip.dto.SearchDTO;
|
|
|
+import com.izouma.zhirongip.repo.demand.CopyrightDemandRepo;
|
|
|
+import com.izouma.zhirongip.repo.demand.LogoDemandRepo;
|
|
|
+import com.izouma.zhirongip.repo.demand.PatentDemandRepo;
|
|
|
+import com.izouma.zhirongip.repo.demand.TechProductDemandRepo;
|
|
|
import com.izouma.zhirongip.repo.supply.CopyrightRepo;
|
|
|
import com.izouma.zhirongip.repo.supply.LogoRepo;
|
|
|
import com.izouma.zhirongip.repo.supply.PatentRepo;
|
|
|
@@ -25,13 +33,13 @@ public class AllServiceTest extends ApplicationTests {
|
|
|
private ApplicationContext applicationContext;
|
|
|
|
|
|
@Autowired
|
|
|
- private PatentRepo patentRepo;
|
|
|
+ private PatentDemandRepo patentDemandRepo;
|
|
|
@Autowired
|
|
|
- private LogoRepo logoRepo;
|
|
|
+ private LogoDemandRepo logoDemandRepo;
|
|
|
@Autowired
|
|
|
- private CopyrightRepo copyrightRepo;
|
|
|
+ private CopyrightDemandRepo copyrightDemandRepo;
|
|
|
@Autowired
|
|
|
- private TechnologyProductRepo technologyProductRepo;
|
|
|
+ private TechProductDemandRepo techProductDemandRepo;
|
|
|
|
|
|
@Test
|
|
|
public void search() {
|
|
|
@@ -48,25 +56,32 @@ public class AllServiceTest extends ApplicationTests {
|
|
|
|
|
|
// @Test
|
|
|
// public void test2() {
|
|
|
-// List<Logo> logos= logoRepo.findAll();
|
|
|
-// logos.forEach(item ->{
|
|
|
-// if(item.getTradingMethod()!=null){
|
|
|
-// item.setTradingMethodId(item.getTradingMethod().getId());
|
|
|
-// logoRepo.save(item);
|
|
|
+// List<PatentDemand> patents= patentDemandRepo.findAll();
|
|
|
+// patents.forEach(item ->{
|
|
|
+// if(item.getMode()!=null){
|
|
|
+// item.setModeId(item.getMode().getId());
|
|
|
+// patentDemandRepo.save(item);
|
|
|
// }
|
|
|
// });
|
|
|
-// List<Copyright> copys= copyrightRepo.findAll();
|
|
|
+// List<LogoDemand> logos= logoDemandRepo.findAll();
|
|
|
+// logos.forEach(item ->{
|
|
|
+// if(item.getMode()!=null){
|
|
|
+// item.setModeId(item.getMode().getId());
|
|
|
+// logoDemandRepo.save(item);
|
|
|
+// }
|
|
|
+// });
|
|
|
+// List<CopyrightDemand> copys= copyrightDemandRepo.findAll();
|
|
|
// copys.forEach(item ->{
|
|
|
-// if(item.getTradingMethod()!=null){
|
|
|
-// item.setTradingMethodId(item.getTradingMethod().getId());
|
|
|
-// copyrightRepo.save(item);
|
|
|
+// if(item.getMode()!=null){
|
|
|
+// item.setModeId(item.getMode().getId());
|
|
|
+// copyrightDemandRepo.save(item);
|
|
|
// }
|
|
|
// });
|
|
|
-// List<TechnologyProduct> tecs= technologyProductRepo.findAll();
|
|
|
-// tecs.forEach(item ->{
|
|
|
-// if(item.getTradingMethod()!=null){
|
|
|
-// item.setTradingMethodId(item.getTradingMethod().getId());
|
|
|
-// technologyProductRepo.save(item);
|
|
|
+// List<TechProductDemand> techs= techProductDemandRepo.findAll();
|
|
|
+// techs.forEach(item ->{
|
|
|
+// if(item.getMode()!=null){
|
|
|
+// item.setModeId(item.getMode().getId());
|
|
|
+// techProductDemandRepo.save(item);
|
|
|
// }
|
|
|
// });
|
|
|
// }
|