class Supply::Listing
Attributes
full_description[RW]
language[R]
short_description[RW]
title[RW]
video[RW]
Public Class Methods
new(google_api, language, source_listing = nil)
click to toggle source
Initializes the listing to use the given api client, language, and fills it with the current listing if available
# File supply/lib/supply/listing.rb, line 11 def initialize(google_api, language, source_listing = nil) @google_api = google_api @language = language if source_listing # this might be nil, e.g. when creating a new locale self.title = source_listing.title self.short_description = source_listing.short_description self.full_description = source_listing.full_description self.video = source_listing.video end end
Public Instance Methods
save()
click to toggle source
Updates the listing in the current edit
# File supply/lib/supply/listing.rb, line 24 def save @google_api.update_listing_for_language(language: language, title: title, short_description: short_description, full_description: full_description, video: video) end