commodity & amount style parser cleanups, part 2
This commit is contained in:
		
							parent
							
								
									9b4b85b4bf
								
							
						
					
					
						commit
						330dfe6891
					
				| @ -133,7 +133,7 @@ nulljournal = Journal { jmodifiertxns = [] | ||||
|                       } | ||||
| 
 | ||||
| nullctx :: JournalContext | ||||
| nullctx = Ctx { ctxYear = Nothing, ctxCommodityAndStyle = Nothing, ctxAccount = [], ctxAliases = [] } | ||||
| nullctx = Ctx { ctxYear = Nothing, ctxDefaultCommodityAndStyle = Nothing, ctxAccount = [], ctxAliases = [] } | ||||
| 
 | ||||
| journalFilePath :: Journal -> FilePath | ||||
| journalFilePath = fst . mainfile | ||||
|  | ||||
| @ -266,7 +266,7 @@ amountAndCommentWizard EntryState{..} = do | ||||
|    line $ green $ printf "Amount  %d%s: " pnum (showDefault def) | ||||
|     where   | ||||
|       parseAmountAndComment = either (const Nothing) Just . parseWithCtx nodefcommodityctx amountandcommentp | ||||
|       nodefcommodityctx = (jContext esJournal){ctxCommodityAndStyle=Nothing} | ||||
|       nodefcommodityctx = (jContext esJournal){ctxDefaultCommodityAndStyle=Nothing} | ||||
|       amountandcommentp = do | ||||
|         a <- amountp | ||||
|         many spacenonewline | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user