summaryrefslogtreecommitdiffstats
path: root/portal-BE/src/main/java/org/onap/portal/dao/ep/EpWidgetCatalogParameterDao.java
blob: 04c123249c770b4c7c355192b8d4ba71297d05e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package org.onap.portal.dao.ep;

import java.util.List;
import java.util.Optional;
import org.onap.portal.domain.db.ep.EpWidgetCatalogParameter;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Transactional;

@Repository
@Transactional
public interface EpWidgetCatalogParameterDao extends JpaRepository<EpWidgetCatalogParameter, Long> {

       @Query
       Optional<List<EpWidgetCatalogParameter>> retrieveByParamId(@Param("PARAMID") Long paramId);

       @Query
       void deleteWidgetCatalogParameter(@Param("PARAMID") Long paramId);

       @Query
       Optional<List<EpWidgetCatalogParameter>> getUserParamById(@Param("WIDGETID") Long widgetId,
               @Param("USERID") Long userId, @Param("PARAMID") Long paramId);
}