|
|
@@ -54,6 +54,23 @@ public class CollectionServiceImpl implements CollectionService {
|
|
|
return "success";
|
|
|
}
|
|
|
|
|
|
+ @Override
|
|
|
+ public String deleteByCmpIds(List<Long> ids) {
|
|
|
+ Iterator<Long> it = ids.iterator();
|
|
|
+ int count = 0;
|
|
|
+ while (it.hasNext()) {
|
|
|
+ Long id = (Long) it.next();
|
|
|
+ List<Collection> c = collectionDao.findStoreByUseruuAndEnuuAndKindAndComponentid(SystemSession.getUser().getUserUU(),
|
|
|
+ SystemSession.getUser().getEnterprise().getUu(),2,id);
|
|
|
+ if (c.size()>0){
|
|
|
+ collectionDao.delete(c.get(0).getId());
|
|
|
+ count++;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ System.out.println("删除的条数" + count);
|
|
|
+ return "success";
|
|
|
+ }
|
|
|
+
|
|
|
@Override
|
|
|
public String clear(int kind) {
|
|
|
int count = collectionDao.deleteByuseruuAndKindAndEnuu(SystemSession.getUser().getUserUU(), kind,
|