Merge pull request #1329 from esteemapp/new/currency-endpoint

added new api enhanced settings screen
This commit is contained in:
Feruz M 2019-11-29 20:40:14 +02:00 committed by GitHub
commit b09fbd2a65
2 changed files with 229 additions and 246 deletions

View File

@ -4,10 +4,10 @@ import imageApi from '../../config/imageApi';
import serverList from '../../config/serverListApi';
import { jsonStringify } from '../../utils/jsonUtils';
import bugsnag from '../../config/bugsnag';
//market-data/currency-rate/USD/estm
export const getCurrencyRate = currency =>
api
.get(`/currencyRate/${currency.toUpperCase()}/steem`)
.get(`/market-data/currency-rate/${currency.toUpperCase()}/steem`)
.then(resp => resp.data)
.catch(err => {
console.log('err :', err);

View File

@ -1,5 +1,5 @@
/* eslint-disable react/jsx-wrap-multilines */
import React, { PureComponent, Fragment } from 'react';
import React, { Fragment } from 'react';
import { ScrollView, View, RefreshControl } from 'react-native';
import { injectIntl } from 'react-intl';
@ -17,22 +17,7 @@ import { BasicHeader, SettingsItem, CollapsibleCard } from '../../../components'
// Styles
import styles from './settingsStyles';
class SettingsScreen extends PureComponent {
/* Props
* ------------------------------------------------
* @prop { type } name - Description....
*/
constructor(props) {
super(props);
this.state = {};
}
// Component Life Cycles
// Component Functions
// TODO: REFACTOR ME !
render() {
const {
const SettingsScreen = ({
handleOnChange,
intl,
isDarkTheme,
@ -53,8 +38,7 @@ class SettingsScreen extends PureComponent {
voteNotification,
handleOnButtonPress,
isLoading,
} = this.props;
}) => {
return (
<Fragment>
<BasicHeader
@ -272,6 +256,5 @@ class SettingsScreen extends PureComponent {
</ScrollView>
</Fragment>
);
}
}
};
export default injectIntl(SettingsScreen);