Mercurial Hosting > chat
comparison src/get_chat.js.luan @ 33:e2b7f6393dab
add online
| author | Franklin Schmidt <fschmidt@gmail.com> |
|---|---|
| date | Sun, 10 Nov 2024 19:57:14 -0700 |
| parents | 809193524522 |
| children | 62d04ca486dd |
comparison
equal
deleted
inserted
replaced
| 32:0f40501b0b56 | 33:e2b7f6393dab |
|---|---|
| 11 local get_chat_by_id = Chat.get_by_id or error() | 11 local get_chat_by_id = Chat.get_by_id or error() |
| 12 local Post = require "site:/lib/Post.luan" | 12 local Post = require "site:/lib/Post.luan" |
| 13 local post_search = Post.search or error() | 13 local post_search = Post.search or error() |
| 14 local Shared = require "site:/lib/Shared.luan" | 14 local Shared = require "site:/lib/Shared.luan" |
| 15 local post_html = Shared.post_html or error() | 15 local post_html = Shared.post_html or error() |
| 16 local chat_other_users_html = Shared.chat_other_users_html or error() | |
| 16 local Logging = require "luan:logging/Logging.luan" | 17 local Logging = require "luan:logging/Logging.luan" |
| 17 local logger = Logging.logger "get_chat.js" | 18 local logger = Logging.logger "get_chat.js" |
| 18 | 19 |
| 19 | 20 |
| 20 local function html() | 21 local function html() |
| 24 local posts = post_search( "post_chat_id:"..chat.id, "id" ) | 25 local posts = post_search( "post_chat_id:"..chat.id, "id" ) |
| 25 %> | 26 %> |
| 26 <div top> | 27 <div top> |
| 27 <h3> | 28 <h3> |
| 28 <img back onclick="back()" src="/images/arrow_back.svg"> | 29 <img back onclick="back()" src="/images/arrow_back.svg"> |
| 29 <span><%= chat.other_users_email(user) %></span> | 30 <span><% chat_other_users_html(chat,user) %></span> |
| 30 </h3> | 31 </h3> |
| 31 <button onclick='deleteChat()'>delete</button> | 32 <button onclick='deleteChat()'>delete</button> |
| 32 </div> | 33 </div> |
| 33 <div main> | 34 <div main> |
| 34 <% | 35 <% |
