casr-logbook 0.6.10 → 0.6.11
raw patch · 3 files changed
+27/−8 lines, 3 files
Files
- casr-logbook.cabal +1/−1
- src/Data/Aviation/Casr/Logbook/Reports/FlightTimeReport.hs +25/−5
- src/Data/Aviation/Casr/Logbook/Types/Command.hs +1/−2
casr-logbook.cabal view
@@ -1,5 +1,5 @@ name: casr-logbook-version: 0.6.10+version: 0.6.11 license: OtherLicense license-file: LICENSE author: Tony Morris <ʇǝu˙sıɹɹoɯʇ@ןןǝʞsɐɥ>
src/Data/Aviation/Casr/Logbook/Reports/FlightTimeReport.hs view
@@ -198,31 +198,51 @@ Just _ -> x Nothing ->- mempty+ case preview (command . _ApprovedSolo) fl of+ Just (_, _) ->+ x+ Nothing ->+ mempty instrRA x = case preview (command . _InCommandInstructing) fl of Just a -> if isRAInstruction (view instructionRating a) then x else mempty Nothing ->- mempty+ case preview (command . _ApprovedSolo) fl of+ Just (_, r) ->+ if isRAInstruction r then mempty else x+ Nothing ->+ mempty instrGA x = case preview (command . _InCommandInstructing) fl of Just a -> if isGAInstruction (view instructionRating a) then x else mempty Nothing ->- mempty+ case preview (command . _ApprovedSolo) fl of+ Just (_, r) ->+ if isGAInstruction r then mempty else x+ Nothing ->+ mempty instrRAJunior x = case preview (command . _InCommandInstructing) fl of Just a -> if isn't _RAInstructionRating (view instructionRating a) then mempty else x Nothing ->- mempty+ case preview (command . _ApprovedSolo) fl of+ Just (_, r) ->+ if isn't _RAInstructionRating r then mempty else x+ Nothing ->+ mempty instrRASenior x = case preview (command . _InCommandInstructing) fl of Just a -> if isn't _RASIInstructionRating (view instructionRating a) then mempty else x Nothing ->- mempty+ case preview (command . _ApprovedSolo) fl of+ Just (_, r) ->+ if isn't _RASIInstructionRating r then mempty else x+ Nothing ->+ mempty instrGA1 x = case preview (command . _InCommandInstructing) fl of Just a ->
src/Data/Aviation/Casr/Logbook/Types/Command.hs view
@@ -12,10 +12,9 @@ import Control.Applicative ( Alternative((<|>)) ) import Control.Lens- ( Prism', preview, makeClassyPrisms, isn't, prism', (#) )+ ( Prism', preview, makeClassyPrisms, prism', (#) ) import Data.Aviation.Casr.Logbook.Types.Aviator(Aviator) import Data.Aviation.Casr.Logbook.Types.Instruction ( Instruction, InstructionRating )-import Data.Bool ( Bool(..) ) import Data.Eq(Eq) import Data.Functor ( Functor((<$)), (<$>) ) import Data.Maybe(Maybe(Just, Nothing))