public ReturnStatus SetEmployeePermission(SetEmployeePermission req) { using (var connection = new SqlConnection(_connectionString.HotelManagement)) { var cmd = new SqlCommand(p_EmployeePermissions_Set, connection) { CommandType = CommandType.StoredProcedure }; cmd.Parameters.AddWithValue("@UserID", _requestInfo.UserId); cmd.Parameters.Add("@RetVal", SqlDbType.Int).Direction = ParameterDirection.Output; cmd.Parameters.Add("@RetMsg", SqlDbType.VarChar, 500).Direction = ParameterDirection.Output; cmd.Parameters.AddWithValue("@EmployeeId", req.EmployeeId); cmd.Parameters.AddWithValue("@PermissionId", req.PermissionId); cmd.Parameters.AddWithValue("@Disable", req.Disable); connection.Open(); cmd.ExecuteNonQuery(); return(new ReturnStatus(cmd.Parameters["@RetVal"].Value.ToSafeInt32(), cmd.Parameters["@RetMsg"].Value.ToSafeString())); } }
public ReturnStatus SetEmployeePermission(SetEmployeePermission req) { return(null); }