Replace getOrCreateCycleDay

This commit is contained in:
Julia Friesel
2018-11-16 14:24:16 +01:00
parent ecca6cfda9
commit bb0a535d65
18 changed files with 255 additions and 309 deletions
+2 -3
View File
@@ -1,7 +1,7 @@
import React, { Component } from 'react'
import { CalendarList } from 'react-native-calendars'
import {LocalDate} from 'js-joda'
import { getOrCreateCycleDay, getBleedingDaysSortedByDate } from '../db'
import { getBleedingDaysSortedByDate } from '../db'
import cycleModule from '../lib/cycle'
import {shadesOfRed} from '../styles/index'
import styles from '../styles/index'
@@ -36,9 +36,8 @@ export default class CalendarView extends Component {
}
passDateToDayView = (result) => {
const cycleDay = getOrCreateCycleDay(result.dateString)
const navigate = this.props.navigate
navigate('CycleDay', { cycleDay })
navigate('CycleDay', { date: result.dateString })
}
render() {
return (