diff options
author | Baitinq <manuelpalenzuelamerino@gmail.com> | 2022-10-28 20:39:38 +0200 |
---|---|---|
committer | Baitinq <manuelpalenzuelamerino@gmail.com> | 2022-10-28 20:39:38 +0200 |
commit | 600a44f9aec5cf39ef50173ec226be7faee5211e (patch) | |
tree | 19bd92969d21c6e1b1762b9572abe6c31cec63e4 | |
parent | Frontend: Show result website's title and description (diff) | |
download | OSSE-600a44f9aec5cf39ef50173ec226be7faee5211e.tar.gz OSSE-600a44f9aec5cf39ef50173ec226be7faee5211e.tar.bz2 OSSE-600a44f9aec5cf39ef50173ec226be7faee5211e.zip |
Frontend: Show results in reverse order with priority
-rw-r--r-- | frontend/src/main.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/frontend/src/main.rs b/frontend/src/main.rs index 46b9232..38879f9 100644 --- a/frontend/src/main.rs +++ b/frontend/src/main.rs @@ -35,7 +35,7 @@ impl PartialOrd for CrawledResource { impl Ord for CrawledResource { fn cmp(&self, other: &Self) -> Ordering { - self.priority.cmp(&other.priority) + self.priority.cmp(&other.priority).reverse() } } @@ -74,7 +74,7 @@ fn osse() -> Html { html! { <div key={r.url.to_owned()}> //Show page title and description - <a href={r.url.to_owned()}>{r.url.to_owned()}{"--"}{r.title.to_owned()}{"----"}{r.description.to_owned()}</a> + <a href={r.url.to_owned()}>{r.url.to_owned()}{"--"}{r.title.to_owned()}{"----"}{r.description.to_owned()}{format!("PRIO: {}", r.priority)}</a> </div> } }) |