Skip to content

Commit

Permalink
Bump versions and fix google filtering
Browse files Browse the repository at this point in the history
  • Loading branch information
angusmcleod committed Sep 14, 2024
1 parent e0a1095 commit eecc982
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
12 changes: 12 additions & 0 deletions app/models/discourse_events/source.rb
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,18 @@ def to_time
end
end

def match_name
@match_name ||=
begin
filter =
filters.find_by(
query_column: DiscourseEvents::Filter.query_columns[:name],
query_operator: DiscourseEvents::Filter.query_operators[:like],
)
filter ? filter.query_value : nil
end
end

private

def valid_source_options?
Expand Down
1 change: 1 addition & 0 deletions lib/discourse_events/import_manager.rb
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ def self.import(source)
opts = source.source_options_with_fixed
opts[:from_time] = source.from_time if source.from_time.present?
opts[:to_time] = source.to_time if source.to_time.present?
opts[:match_name] = source.match_name if source.match_name.present?

manager.import(opts)
end
Expand Down
6 changes: 3 additions & 3 deletions plugin.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true
# name: discourse-events
# about: Allows you to manage events in Discourse
# version: 0.8.5
# version: 0.8.6
# authors: Angus McLeod
# contact_emails: [email protected]
# url: https://github.com/paviliondev/discourse-events
Expand Down Expand Up @@ -29,8 +29,8 @@
gem "omnievent-eventbrite", "0.1.0.pre2", require_name: "omnievent/eventbrite"
gem "omnievent-eventzilla", "0.1.0.pre2", require_name: "omnievent/eventzilla"
gem "omnievent-meetup", "0.1.0.pre1", require_name: "omnievent/meetup"
gem "omnievent-outlook", "0.1.0.pre6", require_name: "omnievent/outlook"
gem "omnievent-google", "0.1.0.pre3", require_name: "omnievent/google"
gem "omnievent-outlook", "0.1.0.pre7", require_name: "omnievent/outlook"
gem "omnievent-google", "0.1.0.pre4", require_name: "omnievent/google"

Discourse.top_menu_items.push(:agenda)
Discourse.anonymous_top_menu_items.push(:agenda)
Expand Down

0 comments on commit eecc982

Please sign in to comment.