/*
*  Copyright 2019-2020 Zheng Jie
*
*  Licensed under the Apache License, Version 2.0 (the "License");
*  you may not use this file except in compliance with the License.
*  You may obtain a copy of the License at
*
*  http://www.apache.org/licenses/LICENSE-2.0
*
*  Unless required by applicable law or agreed to in writing, software
*  distributed under the License is distributed on an "AS IS" BASIS,
*  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*  See the License for the specific language governing permissions and
*  limitations under the License.
*/
package com.usky.meeting.repository;

/**
* @website https://el-admin.vip
* @author shiguangji
* @date 2021-03-17
**/
//public interface DmMeetingApproveRepository extends JpaRepository<DmMeetingApprove, String>, JpaSpecificationExecutor<DmMeetingApprove> {
//    @Query(value = "SELECT a.* FROM dm_meeting_approve a WHERE a.approve_result = 0 " +
//            "and if(:meetingId != '',a.meeting_id = :meetingId,1=1)",nativeQuery = true)
//    List<DmMeetingApprove> findApprovingByMeetingId(@Param("meetingId") String meetingId);
//
//    @Modifying
//    @Query(value = "update dm_meeting_approve set approve_result = ?1, " +
//            "approve_suggest = ?2, approve_user_id = ?3, approve_date=now() where id = ?4",nativeQuery = true)
//    void updateApproveInfo(Long result,String suggest,Long userId,String id);
//
//    @Modifying
//    @Query(value = "delete from dm_meeting_approve where meeting_id = ?1",nativeQuery = true)
//    void delByMeetingId(Long meetingId);
//
//    @Query(value = "SELECT a.* FROM dm_user a inner join dm_meeting_approve_user b on a.id = b.dm_user_id WHERE b.meeting_id = :roomId ",nativeQuery = true)
//    Map findApproverByRoomId(@Param("roomId") String roomId);
//
//
//    @Modifying
//    @Query(value = "update dm_meeting set approve_status = :approveStatus , approve_suggest = :approveSuggest where task_id= :taskId",nativeQuery = true)
//    void updateAppriveStatusByTaskId(@Param("taskId") String taskId,@Param("approveStatus") Long approveStatus,@Param("approveSuggest") String approveSuggest);
//
//    //findApproverByRoomId
//}