2025-01-19 12:21:00 +08:00
|
|
|
class HomeController < ApplicationController
|
|
|
|
def index
|
2025-02-14 09:55:04 +08:00
|
|
|
@popular_arts = WeatherArt.includes(:city, :image_attachment).by_popularity(3)
|
2025-02-15 17:47:44 +08:00
|
|
|
# @random_arts = WeatherArt.includes(:city, :image_attachment).random(3)
|
2025-02-14 09:55:04 +08:00
|
|
|
@latest_arts = WeatherArt.includes(:city, :image_attachment).latest(6)
|
|
|
|
@featured_arts = WeatherArt.includes(:city, :image_attachment).order(created_at: :desc).limit(5)
|
2025-01-23 19:02:52 +08:00
|
|
|
set_meta_tags(
|
|
|
|
title: "AI-Generated Weather Art",
|
|
|
|
description: "Experience weather through artistic AI visualization. Daily updated weather art for cities worldwide.",
|
|
|
|
keywords: "AI weather art, weather visualization, city weather, artificial intelligence"
|
|
|
|
)
|
2025-01-19 12:21:00 +08:00
|
|
|
end
|
|
|
|
end
|