Fixed proxiwash screen not firing componentDidMount
這個提交存在於:
父節點
2b21b00ec8
當前提交
cf8014da3f
共有 2 個檔案被更改,包括 3 行新增 和 2 行删除
|
@ -51,7 +51,7 @@ export default class FetchedDataSectionList extends React.Component<Props, State
|
|||
}
|
||||
|
||||
/**
|
||||
* Refresh the FetchedData on first screen load
|
||||
* Register react navigation events on first screen load
|
||||
*/
|
||||
componentDidMount() {
|
||||
this.willFocusSubscription = this.props.navigation.addListener(
|
||||
|
|
|
@ -42,7 +42,7 @@ export default class ProxiwashScreen extends FetchedDataSectionList {
|
|||
* Creates machine state parameters using current theme and translations
|
||||
*/
|
||||
constructor() {
|
||||
super(DATA_URL, 1000 * 60); // Refresh every minute
|
||||
super(DATA_URL, 1000 * 10); // Refresh every minute
|
||||
let colors = ThemeManager.getCurrentThemeVariables();
|
||||
stateColors[MACHINE_STATES.TERMINE] = colors.proxiwashFinishedColor;
|
||||
stateColors[MACHINE_STATES.DISPONIBLE] = colors.proxiwashReadyColor;
|
||||
|
@ -78,6 +78,7 @@ export default class ProxiwashScreen extends FetchedDataSectionList {
|
|||
}
|
||||
|
||||
componentDidMount() {
|
||||
super.componentDidMount();
|
||||
if (Platform.OS === 'android') {
|
||||
Expo.Notifications.createChannelAndroidAsync('reminders', {
|
||||
name: 'Reminders',
|
||||
|
|
載入中…
新增問題並參考