add: developer panel

This commit is contained in:
trisua 2025-06-14 20:26:54 -04:00
parent ebded00fd3
commit 39574df691
44 changed files with 982 additions and 84 deletions

View file

@ -33,7 +33,7 @@ impl Community {
pub fn new(title: String, owner: usize) -> Self {
Self {
id: Snowflake::new().to_string().parse::<usize>().unwrap(),
created: unix_epoch_timestamp() as usize,
created: unix_epoch_timestamp(),
title: title.clone(),
context: CommunityContext {
display_name: title,
@ -157,7 +157,7 @@ impl CommunityMembership {
pub fn new(owner: usize, community: usize, role: CommunityPermission) -> Self {
Self {
id: Snowflake::new().to_string().parse::<usize>().unwrap(),
created: unix_epoch_timestamp() as usize,
created: unix_epoch_timestamp(),
owner,
community,
role,
@ -273,7 +273,7 @@ impl Post {
) -> Self {
Self {
id: Snowflake::new().to_string().parse::<usize>().unwrap(),
created: unix_epoch_timestamp() as usize,
created: unix_epoch_timestamp(),
content,
owner,
community,
@ -353,7 +353,7 @@ impl Question {
) -> Self {
Self {
id: Snowflake::new().to_string().parse::<usize>().unwrap(),
created: unix_epoch_timestamp() as usize,
created: unix_epoch_timestamp(),
owner,
receiver,
content,
@ -387,7 +387,7 @@ impl PostDraft {
pub fn new(content: String, owner: usize) -> Self {
Self {
id: Snowflake::new().to_string().parse::<usize>().unwrap(),
created: unix_epoch_timestamp() as usize,
created: unix_epoch_timestamp(),
content,
owner,
}
@ -426,7 +426,7 @@ impl Poll {
Self {
id: Snowflake::new().to_string().parse::<usize>().unwrap(),
owner,
created: unix_epoch_timestamp() as usize,
created: unix_epoch_timestamp(),
expires,
// options
option_a,
@ -491,7 +491,7 @@ impl PollVote {
Self {
id: Snowflake::new().to_string().parse::<usize>().unwrap(),
owner,
created: unix_epoch_timestamp() as usize,
created: unix_epoch_timestamp(),
poll_id,
vote,
}