@Query("select s.id,s.name,s.classes,s.startTime,s.endTime,s.subjects,s.progress,s.settings from Art as s where s.period.id = @periodId and s.code = @code " +
@Query("select s.id,s.name,s.classes,s.startTime,s.endTime,s.subjects,s.progress,s.settings from Art as s where s.progress = 'finish' and s.period.id = @periodId and s.code = @code " +
"and (IS_NULL(@startTime) or s.startTime >= @startTime) "+
"and (IS_NULL(@startTime) or s.startTime >= @startTime) "+
"and (IS_NULL(@endTime) or s.startTime < @endTime) ")
"and (IS_NULL(@endTime) or s.startTime < @endTime) ")