more shit

This commit is contained in:
root 2026-01-10 16:29:27 +00:00
parent e5878ea429
commit 554e0bd9c8
5 changed files with 14 additions and 25 deletions

View file

@ -7,7 +7,7 @@ class PostsController < ApplicationController
before_action :set_post, only: [:show, :edit, :update, :destroy] before_action :set_post, only: [:show, :edit, :update, :destroy]
def index def index
@posts = @blog.posts @posts = Post.order(created_at: :desc)
end end
def show def show

View file

@ -31,7 +31,7 @@
<body> <body>
<main><br> <main><br>
<div class="headerall"><h3 class="float"><img src="/kissingcomputer.png" width="80px" alt="An emoji of a computer with kiss marks."> K I S S I N G C O M P U T E R</h3><div class="header"> <a href="/">Home</a> | <a href="/members/1">About Me</a> | <a href="/blogmap">Pages</a> | <a href="/sitemaps">Sitemap</a> | <a href="https://lesbian.alien.dentist/@feed.atom"><img src="https://file.garden/aJzQmzrHVB4BLKwu/46.png" alt="pink rss feed logo"></a></div></div> <div class="headerall"><h3 class="float"><img src="/kissingcomputer.png" width="80px" alt="An emoji of a computer with kiss marks."> K I S S I N G C O M P U T E R</h3><div class="header"> <a href="/">Home</a> | <a href="/members/1">About Me</a> | <a href="/blogmap">Pages</a> | <a href="https://lesbian.alien.dentist/@feed.atom"><img src="https://file.garden/aJzQmzrHVB4BLKwu/46.png" alt="pink rss feed logo"></a></div></div>
<br><br> <br><br>
<section class="article"> <section class="article">
<section class="auth"> <section class="auth">

View file

@ -58,12 +58,12 @@
</section> </section>
<section class="about"> <section class="about">
<label for="member_blog">Choose a blog:</label> <label for="member_blog">Choose a category:</label>
<select id="member_blog" onchange="if(this.value){ <select id="member_blog" onchange="if(this.value){
window.location.href = '<%= member_blog_path(@member, 'BLOG_ID') %>'.replace('BLOG_ID', this.value); window.location.href = '<%= member_blog_path(@member, 'BLOG_ID') %>'.replace('BLOG_ID', this.value);
} }
"> ">
<option value="">My blogs</option> <option value="">My stuff</option>
<% @member.blogs.each do |blog| %> <% @member.blogs.each do |blog| %>
<option value="<%= blog.id %>"><%= blog.title %></option> <option value="<%= blog.id %>"><%= blog.title %></option>
<% end %> <% end %>

View file

@ -18,7 +18,8 @@
<%= link_to 'Edit', edit_member_blog_post_path(@member, @blog, post) %> <%= link_to 'Edit', edit_member_blog_post_path(@member, @blog, post) %>
<%= link_to 'Destroy', member_blog_post_path(@member, @blog, post), data: { <%= link_to 'Destroy', member_blog_post_path(@member, @blog, post), data: {
turbo_method: :delete turbo_method: :delete,
turbo_confirm: "Are you sureee?"
} %> } %>
<% end %> <% end %>
</section> </section>

View file

@ -6,34 +6,22 @@
</p> </p>
<p> <p>
<strong>Content:</strong> <strong></strong>
<%= @post.text %> <%= @post.text %>
</p> </p>
<p> <p>
<% if @post.music.present? %>
<strong>Currently Listening To...:</strong> <strong>Currently Listening To...:</strong>
<%= @post.music %> <%= @post.music %>
<% end %>
</p> </p>
<% if @post.mood.present? %>
<p> <p>
<strong>Current Mood:</strong> <strong>Current Mood:</strong>
<%= @post.mood %> <%= @post.mood %></p>
<hr>
<section class="comment">
<h2>Comments</h2>
<%= render @post.comments %>
add a comment...
<%= form_with(
model: [@post.blog.member, @post.blog, @post, Comment.new],
local: true
) do |form| %>
<%= form.label :commenter %><br>
<%= form.text_field :commenter %>
<br>
<%= form.label :body %><br>
<%= form.rich_text_area :body %>
<%= form.submit %>
<% end %> <% end %>
</section></section> <hr>
</section>