Returns the most recent search result that matches the query.
(self, date_field)
| 528 | return self[0] |
| 529 | |
| 530 | def latest(self, date_field): |
| 531 | """Returns the most recent search result that matches the query.""" |
| 532 | clone = self._clone() |
| 533 | clone.query.clear_order_by() |
| 534 | clone.query.add_order_by("-%s" % date_field) |
| 535 | return clone.best_match() |
| 536 | |
| 537 | def more_like_this(self, model_instance): |
| 538 | """Finds similar results to the object passed in.""" |