mirror of
https://github.com/commercialhaskell/stackage-server.git
synced 2026-01-23 01:11:56 +01:00
Remove dropdowns on diff page
This commit is contained in:
parent
c308e89a16
commit
6eb463f20c
@ -12,7 +12,6 @@ module Handler.StackageHome
|
|||||||
, getSnapshotPackagesR
|
, getSnapshotPackagesR
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import Data.Ord
|
|
||||||
import Data.These
|
import Data.These
|
||||||
import RIO.Time (FormatTime)
|
import RIO.Time (FormatTime)
|
||||||
import Import
|
import Import
|
||||||
@ -55,9 +54,6 @@ getStackageDiffR name1 name2 = track "Handler.StackageHome.getStackageDiffR" $ d
|
|||||||
cacheSeconds $ 60 * 60 * 48
|
cacheSeconds $ 60 * 60 * 48
|
||||||
Entity sid1 _ <- lookupSnapshot name1 >>= maybe notFound return
|
Entity sid1 _ <- lookupSnapshot name1 >>= maybe notFound return
|
||||||
Entity sid2 _ <- lookupSnapshot name2 >>= maybe notFound return
|
Entity sid2 _ <- lookupSnapshot name2 >>= maybe notFound return
|
||||||
let fixit = sortOn Down . map (snapshotName . entityVal)
|
|
||||||
ltsSnaps <- fixit <$> getSnapshots (Just LtsBranch) 20 0
|
|
||||||
nightlySnaps <- fixit <$> getSnapshots (Just NightlyBranch) 20 0
|
|
||||||
snapDiff <- getSnapshotDiff sid1 sid2
|
snapDiff <- getSnapshotDiff sid1 sid2
|
||||||
selectRep $ do
|
selectRep $ do
|
||||||
provideRep $ defaultLayout $ do
|
provideRep $ defaultLayout $ do
|
||||||
|
|||||||
@ -4,34 +4,9 @@
|
|||||||
<div .packages>
|
<div .packages>
|
||||||
<table .table>
|
<table .table>
|
||||||
<thead>
|
<thead>
|
||||||
<th>
|
<tr>
|
||||||
<select .form-control onchange="document.location = this.value">
|
<th>#{name1}
|
||||||
<optgroup label="LTS">
|
<th>#{name2}
|
||||||
$forall name1' <- ltsSnaps
|
|
||||||
$if name1' == name1
|
|
||||||
<option selected value=@{StackageDiffR name1' name2}>#{toPathPiece name1'}
|
|
||||||
$else
|
|
||||||
<option value=@{StackageDiffR name1' name2}>#{toPathPiece name1'}
|
|
||||||
<optgroup label="Nightly">
|
|
||||||
$forall name1' <- nightlySnaps
|
|
||||||
$if name1' == name1
|
|
||||||
<option selected value=@{StackageDiffR name1' name2}>#{toPathPiece name1'}
|
|
||||||
$else
|
|
||||||
<option value=@{StackageDiffR name1' name2}>#{toPathPiece name1'}
|
|
||||||
<th>
|
|
||||||
<select .form-control onchange="document.location = this.value">
|
|
||||||
<optgroup label="LTS">
|
|
||||||
$forall name2' <- ltsSnaps
|
|
||||||
$if name2' == name2
|
|
||||||
<option selected value=@{StackageDiffR name1 name2'}>#{toPathPiece name2'}
|
|
||||||
$else
|
|
||||||
<option value=@{StackageDiffR name1 name2'}>#{toPathPiece name2'}
|
|
||||||
<optgroup label="Nightly">
|
|
||||||
$forall name2' <- nightlySnaps
|
|
||||||
$if name2' == name2
|
|
||||||
<option selected value=@{StackageDiffR name1 name2'}>#{toPathPiece name2'}
|
|
||||||
$else
|
|
||||||
<option value=@{StackageDiffR name1 name2'}>#{toPathPiece name2'}
|
|
||||||
<tbody>
|
<tbody>
|
||||||
$forall (pkgname, VersionChange verChange, versionDiff) <- toVersionedDiffList snapDiff
|
$forall (pkgname, VersionChange verChange, versionDiff) <- toVersionedDiffList snapDiff
|
||||||
<tr>
|
<tr>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user