update: login function and purchased item store

This commit is contained in:
Rifqy Zacky Ariadhy
2019-01-06 15:18:00 +07:00
parent 02c17264b7
commit d7b2b8fdd1
12 changed files with 122 additions and 195 deletions

View File

@@ -24,7 +24,13 @@ export default class ModalVouchersComponent extends React.Component {
componentDidMount() {}
render() {
const {data, isVisible = false, onOk = () => {}, onCancel = () => {}, title='Modal'} = this.props;
const {data = {}, isVisible = false, onOk = () => {}, onCancel = () => {}, title='Modal'} = this.props;
let image = ''
if(data.images.logo.includes('http')){
image = data.images.logo;
}else{
image = this.http.appendImagePath(data.images.logo);
}
return (
<Modal
@@ -52,7 +58,7 @@ export default class ModalVouchersComponent extends React.Component {
// background: data.background_color || '#aaa',
flex: 0.3
}}>
<img className={'imageModal'} src={this.http.appendImagePath(data.images.logo)} />
<img className={'imageModal'} src={image} />
<p className={'titleModal'}>{data.name} }</p>
</div>
<div style={{