def ld_entity(self): site = self.get_site() return extend( super().ld_entity(), { '@type': 'Event', "name": self.title, "startDate": (datetime.combine(self.date_from, self.time_from)).strftime('%d-%m-%YT%H:%M'), "endDate": (datetime.combine(self.date_from, self.time_from) + timedelta(hours=6)).strftime('%d-%m-%YT%H:%M'), "url": site.root_url + self.url, "eventStatus": "EventScheduled", "image": image_ld(self.image, base_url=site.root_url), "location": { "@type": "Place", "name": self.location_name, "address": self.location }, "offers": { "@type": "Offer", "url": "https://www.willysbrewing.com/cervezas/riot-apa", "category": "primary", "availability": "InStock", "price": "3.50", "priceCurrency": "EUR" } })
def ld_entity(self): site = self.get_site() return extend( super(PersonPage, self).ld_entity(), { '@type': 'Person', 'birthDate': self.date_of_birth.isoformat(), 'image': image_ld(self.photo, base_url=site.root_url), 'organisation': TestOrganisation.for_site(site), })
def ld_entity(self): return extend( super(TestOrganisation, self).ld_entity(), { '@type': 'Organisation', 'name': self.name, 'email': self.email, 'telephone': self.phone_number, 'sameAs': [ self.twitter_url, self.facebook_url, ], })
def ld_entity(self): site = self.get_site() return extend( super().ld_entity(), { '@type': 'Product', "name": self.name, "image": image_ld(self.image, base_url=site.root_url), "brand": { "@type": "Thing", "name": "Willy's" } })
def ld_entity(self): return extend( super().ld_entity(), { '@type': 'Organization', 'name': self.name, 'email': self.email, 'sameAs': [ self.facebook_url, self.instagram_url, self.facebook_url, ], })
def ld_entity(self): """ Generates structured data to be displayed as rich snippets on google search """ return extend( super().ld_entity(), { "@context": "http://schema.org/", "@type": "TaxiService", "provider": { "@type": "Organization", "name": "Meru", "url": "https://www.meru.in/" }, "aggregateRating": { "ratingValue": self.aggregate_rating(), "reviewCount": self.total_reviews() } })
def ld_entity(self): return extend( super().ld_entity(), { "@type": "Brewery", "acceptsReservations": self.acceptsReservations, "currenciesAccepted": self.currenciesAccepted, "name": self.name, "legalName": self.legal_name, "vatID": self.vat_id, "url": self.url, "image": self.url, "logo": self.logo, "priceRange": self.priceRange, "servesCuisine": "no", "description": self.description, "foundingDate": self.foundingDate, "openingHours": self.openingHours, "address": self.address.get_ldjson(), "contactPoint": self.contactPoint.get_ldjson(), "telephone": self.contactPoint.telephone.as_e164, "sameAs": self.same_as.get_ldjson() })
def ld_entity(self): return extend(super().ld_entity(), self.schema.as_python_dict)