This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import { | |
DrawerNavigator, | |
StackNavigator, | |
TabNavigator | |
} from 'react-navigation'; | |
import { Dimensions } from 'react-native'; | |
import { Provider } from 'react-redux'; | |
import getSlideFromRightTransition | |
from 'react-navigation-slide-from-right-transition'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const sendAttachment = function* sendAttachment(action) { | |
const sendAttachmentUrl = `http://${BASE_URL}.bamms.co/api/*****/*****/*****/*****`; | |
const attachment = require('../images/abc.jpg'); | |
const data = new FormData(); | |
data.append('inquiry_id', '265'); | |
data.append('created_at', '2017-10-05 13:01:22'); | |
data.append('note', 'halo'); | |
data.append('attachment', { | |
uri: attachment.toString(), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apply plugin: 'com.android.application' | |
android { | |
compileSdkVersion 25 | |
buildToolsVersion '25.0.2' | |
defaultConfig { | |
applicationId "bamms.bamms" | |
minSdkVersion 19 | |
targetSdkVersion 25 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | |
package="com.bamms" | |
android:versionCode="1" | |
android:versionName="1.0"> | |
<uses-permission android:name="android.permission.INTERNET" /> | |
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/> | |
<uses-sdk | |
android:minSdkVersion="16" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.bamms; | |
import android.os.Bundle; | |
import com.facebook.react.ReactActivity; | |
import com.cboy.rn.splashscreen.SplashScreen; | |
public class MainActivity extends ReactActivity { | |
@Override | |
protected void onCreate(Bundle savedInstanceState) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import PropTypes from 'prop-types'; | |
import { View, Image, Text, Dimensions } from 'react-native'; | |
import { DrawerItems } from 'react-navigation'; | |
const SCREEN_HEIGHT = Dimensions.get('window').height; | |
const BammsLogo = require('../../images/logo_login.png'); | |
const DrawerComponent = (props) => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "bamms_tcr", | |
"version": "0.1.0", | |
"private": true, | |
"devDependencies": { | |
"enzyme": "^2.8.0", | |
"eslint-plugin-react": "^7.1.0", | |
"jest-expo": "~18.0.0", | |
"jest-serializer-enzyme": "^1.0.0", | |
"react-native-scripts": "0.0.50", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component, PropTypes } from 'react'; | |
import { View, Image, TextInput, Text, Dimensions, Alert } from 'react-native'; | |
import { Font } from 'expo'; | |
import { connect } from 'react-redux'; | |
import { LoginButton } from '../SubComponents/LoginComponent/LoginButton'; | |
import { loginUser } from '../../actions' | |
class Login extends Component { | |
static propTypes = { | |
loginUser: PropTypes.func, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const admin = require('firebase-admin'); | |
module.exports = (req, res) => { | |
if (!req.body.phone || !req.body.code) { | |
res.status(422).send({ error: 'must supply phone and code' }); | |
} | |
const phone = String(req.body.phone).replace(/[^\d]/g, ''); | |
const code = parseInt(req.body.code, 10); |