yaws
This commit is contained in:
parent
4ccc742772
commit
2fb417f853
|
@ -7,6 +7,8 @@ pub struct Message {
|
|||
pub x: f32,
|
||||
pub y: f32,
|
||||
pub z: f32,
|
||||
#[serde(default)]
|
||||
pub yaw: f32,
|
||||
|
||||
pub pack_id: Uuid,
|
||||
pub template_1: usize,
|
||||
|
@ -24,6 +26,7 @@ pub struct RetrievedMessage {
|
|||
pub x: f64,
|
||||
pub y: f64,
|
||||
pub z: f64,
|
||||
pub yaw: f64,
|
||||
pub message: String,
|
||||
pub positive_votes: i32,
|
||||
pub negative_votes: i32,
|
||||
|
@ -37,6 +40,7 @@ pub struct RetrievedMessageTerritory {
|
|||
pub x: f64,
|
||||
pub y: f64,
|
||||
pub z: f64,
|
||||
pub yaw: f64,
|
||||
pub message: String,
|
||||
pub positive_votes: i32,
|
||||
pub negative_votes: i32,
|
||||
|
|
|
@ -29,6 +29,7 @@ async fn logic(state: Arc<State>, id: i64, location: u32) -> Result<impl Reply,
|
|||
m.x,
|
||||
m.y,
|
||||
m.z,
|
||||
m.yaw,
|
||||
m.message,
|
||||
coalesce(sum(v.vote between 0 and 1), 0) as positive_votes,
|
||||
coalesce(sum(v.vote between -1 and 0), 0) as negative_votes,
|
||||
|
|
|
@ -30,6 +30,7 @@ async fn logic(state: Arc<State>, id: i64, message_id: Uuid) -> Result<impl Repl
|
|||
m.x,
|
||||
m.y,
|
||||
m.z,
|
||||
m.yaw,
|
||||
m.message,
|
||||
coalesce(sum(v.vote between 0 and 1), 0) as positive_votes,
|
||||
coalesce(sum(v.vote between -1 and 0), 0) as negative_votes,
|
||||
|
|
|
@ -27,6 +27,7 @@ async fn logic(state: Arc<State>, id: i64) -> Result<impl Reply, Rejection> {
|
|||
m.x,
|
||||
m.y,
|
||||
m.z,
|
||||
m.yaw,
|
||||
m.message,
|
||||
coalesce(sum(v.vote between 0 and 1), 0) as positive_votes,
|
||||
coalesce(sum(v.vote between -1 and 0), 0) as negative_votes,
|
||||
|
|
Loading…
Reference in New Issue