package garbagetown.domain.repository;

import garbagetown.domain.model.Tourinfo;
import org.springframework.data.jpa.repository.JpaRepository;

/**
 * Created by garbagetown on 10/15/15.
 */
public interface TourinfoRepository extends JpaRepository<Tourinfo, String>, TourinfoRepositoryCustom {
}

@@ -141,158 +141,539 @@
 ry;%0A
-%0A/**%0A * Created by garbagetown on 10/15/15.%0A */%0Apublic interface TourinfoRepository extends JpaRepository%3CTourinfo, String%3E, TourinfoRepositoryCustom %7B
+import org.springframework.data.jpa.repository.Lock;%0Aimport org.springframework.data.jpa.repository.Query;%0Aimport org.springframework.data.repository.query.Param;%0A%0Aimport javax.persistence.LockModeType;%0A%0A/**%0A * Created by garbagetown on 10/15/15.%0A */%0Apublic interface TourinfoRepository extends JpaRepository%3CTourinfo, String%3E, TourinfoRepositoryCustom %7B%0A%0A    @Query(%22SELECT t FROM Tourinfo t WHERE t.tourCode = :tourCode%22)%0A    @Lock(LockModeType.PESSIMISTIC_WRITE)%0A    Tourinfo findOneForUpdate(@Param(%22tourCode%22) String tourCode);
 %0A%7D%0A

add findOneForUpdate