Skip to content

Commit

Permalink
Splash screen, version config, and add phone number
Browse files Browse the repository at this point in the history
  • Loading branch information
kevindavee committed Aug 7, 2017
1 parent 8df95ca commit 7316462
Show file tree
Hide file tree
Showing 32 changed files with 84 additions and 15 deletions.
11 changes: 11 additions & 0 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,16 @@ android {
abiFilters "armeabi-v7a", "x86"
}
}
signingConfigs {
release {
if (project.hasProperty('MYAPP_RELEASE_STORE_FILE')) {
storeFile file(MYAPP_RELEASE_STORE_FILE)
storePassword MYAPP_RELEASE_STORE_PASSWORD
keyAlias MYAPP_RELEASE_KEY_ALIAS
keyPassword MYAPP_RELEASE_KEY_PASSWORD
}
}
}
splits {
abi {
reset()
Expand All @@ -115,6 +125,7 @@ android {
release {
minifyEnabled enableProguardInReleaseBuilds
proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
signingConfig signingConfigs.release
}
}
// applicationVariants are e.g. debug, release
Expand Down
Binary file modified android/app/src/main/res/drawable-land-hdpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-land-ldpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-land-mdpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-land-xhdpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-hdpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-ldpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-mdpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-xhdpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-xxhdpi/launch_screen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion android/app/src/main/res/drawable/launch_screen_bitmap.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" android:opacity="opaque">
<item android:drawable="@color/splashBackground"/>
<item android:drawable="@android:color/white"/>
<item>
<bitmap
android:src="@drawable/launch_screen"
Expand Down
Binary file added android/app/teckaline-release-key.jks
Binary file not shown.
4 changes: 4 additions & 0 deletions android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,7 @@
# org.gradle.parallel=true

android.useDeprecatedNdk=true
MYAPP_RELEASE_STORE_FILE=teckaline-release-key.jks
MYAPP_RELEASE_KEY_ALIAS=teckaline-key
MYAPP_RELEASE_STORE_PASSWORD=Oevkas44mz
MYAPP_RELEASE_KEY_PASSWORD=Oevkas44mz
2 changes: 2 additions & 0 deletions ios/TeckalineApp.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1113,6 +1113,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
CURRENT_PROJECT_VERSION = 1;
DEAD_CODE_STRIPPING = NO;
Expand All @@ -1136,6 +1137,7 @@
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
CURRENT_PROJECT_VERSION = 1;
INFOPLIST_FILE = TeckalineApp/Info.plist;
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 12 additions & 5 deletions src/actions/ProfileActions.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import firebase from 'firebase';
import { PROFILE_FULLNAME_CHANGE, PROFILE_COMPANY_CHANGE,
INITIAL_PROFILE, FETCH_PROFILE, PROFILE_SAVE_CHANGES,
PROFILE_CHANGES_SUCCESS, PROFILE_CHANGES_FAIL } from './types';
PROFILE_CHANGES_SUCCESS, PROFILE_CHANGES_FAIL, PROFILE_PHONE_NUMBER_CHANGE } from './types';

export const initialProfile = () => {
const { currentUser } = firebase.auth();
Expand All @@ -10,8 +10,8 @@ export const initialProfile = () => {
dispatch({ type: FETCH_PROFILE });
firebase.database().ref(`/profiles/${currentUser.uid}`)
.on('value', snapshot => {
const { fullName, company } = snapshot.val();
const payload = { email: currentUser.email, fullName, company };
const { fullName, company, phoneNumber } = snapshot.val();
const payload = { email: currentUser.email, fullName, company, phoneNumber };
dispatch({ type: INITIAL_PROFILE, payload });
});
};
Expand All @@ -31,14 +31,21 @@ export const profileCompanyChange = (text) => {
};
};

export const profileSaveChanges = ({ fullName, company }) => {
export const profilePhoneNumberChange = (number) => {
return {
type: PROFILE_PHONE_NUMBER_CHANGE,
payload: number
};
};

export const profileSaveChanges = ({ fullName, company, phoneNumber }) => {
const { currentUser } = firebase.auth();

return (dispatch) => {
dispatch({ type: PROFILE_SAVE_CHANGES });

firebase.database().ref(`/profiles/${currentUser.uid}`)
.update({ fullName, company })
.update({ fullName, company, phoneNumber })
.then(() => {
dispatch({ type: PROFILE_CHANGES_SUCCESS });
})
Expand Down
1 change: 1 addition & 0 deletions src/actions/types.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ export const INITIAL_REGISTER_SCREEN = 'initial_register_screen';

export const PROFILE_FULLNAME_CHANGE = 'profile_fullname_change';
export const PROFILE_COMPANY_CHANGE = 'profile_company_change';
export const PROFILE_PHONE_NUMBER_CHANGE = 'profile_phone_number_change';
export const PROFILE_SAVE_CHANGES = 'profile_save_changes';
export const PROFILE_CHANGES_SUCCESS = 'profile_change_success';
export const PROFILE_CHANGES_FAIL = 'profile_change_fail';
Expand Down
26 changes: 26 additions & 0 deletions src/component/main_app/FormReward.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,32 @@ class FormReward extends Component {
/>
</Item>
{this.renderButton()}
<Text style={{ textAlign: 'center', paddingTop: 15, paddingBottom: 15, fontWeight: 'bold' }}>Reward Program Teckaline Indonesia</Text>
<Text style={{ fontSize: 13, paddingBottom: 15 }}>
Reward Program Teckaline Indonesia adalah marketing program yang disediakan khusus bagi
para consultant yang menggunakan Teckaline dalam spesifikasi yang mereka buat, atau para person in contact
kontraktor/owner yang memilih Teckaline sebagai equivalent, sebagai apresiasi Teckaline Indonesia kepada user-nya.
</Text>
<Text style={{ fontSize: 13, paddingBottom: 15 }}>
{
'Cara mengikuti program ini adalah dengan mengisi nama project, yang memenuhi sudah syarat dan ketentuan yang berlaku. '
}
</Text>
<Text style={{ fontSize: 13, paddingBottom: 15 }}>
{`Syarat dan Ketentuan:\n
1. Program ini hanya berlaku untuk konsultan yang menggunakan Teckaline sebagai spesifikasi yang mereka buat\n
2. Program ini berlaku untuk Kontraktor / Owner yang memilih Teckaline sebagai equivalent\n
3. Reward program dapat di reimburse setelah menjadi SPK/Kontrak\n
4. Konsultan / Kontraktor / Owner harus mengisi dengan project yang real dan bukan fiktif, ataupun mencantumkan project yang tidak sesuai dengan syarat mengikuti program ini\n
5. Pengguna aplikasi yang melakukan spam pada form ini, akan langsung kami blacklist dan kami banned/non-aktif account nya\n
6. Program ini tidak berlaku untuk karyawan Teckaline Indonesia`
}
</Text>
<Text style={{ fontSize: 13, paddingBottom: 15 }}>
{
'Untuk informasi atau pun pertanyaan lebih lanjut, bisa hubungi ke whatsapp 0811990342'
}
</Text>
</Form>
</Content>
</Container>
Expand Down
27 changes: 21 additions & 6 deletions src/component/main_app/Profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import firebase from 'firebase';
import { CustomHeader, MyDrawer } from '../commons';
import { DRAWER_MENU } from '../commons/ButtonConst';
import { profileFullNameChange, profileCompanyChange, initialProfile,
profileSaveChanges } from '../../actions';
profileSaveChanges, profilePhoneNumberChange } from '../../actions';
import styles from '../styles';

const { UIManager } = NativeModules;
Expand All @@ -33,8 +33,12 @@ class Profile extends Component {
}

onChangeProfile() {
const { fullName, company } = this.props;
this.props.profileSaveChanges({ fullName, company });
const { fullName, company, phoneNumber } = this.props;
this.props.profileSaveChanges({ fullName, company, phoneNumber });
}

onPhoneNumberChange(number) {
this.props.profilePhoneNumberChange(number);
}

onLogOut() {
Expand Down Expand Up @@ -73,6 +77,16 @@ class Profile extends Component {
placeholder={this.props.email}
/>
</Item>
<Item>
<Label style={styles.inputLabelStyle}>No Telp.</Label>
<Input
placeholder="0812345678"
keyboardType="phone-pad"
style={{ flex: 2 }}
onChangeText={this.onPhoneNumberChange.bind(this)}
value={this.props.phoneNumber}
/>
</Item>
<Item>
<Label style={styles.inputLabelStyle}>Nama Lengkap</Label>
<Input
Expand Down Expand Up @@ -147,13 +161,14 @@ class Profile extends Component {
}

const mapStateToProps = ({ profile }) => {
const { fullName, company, loading, email, loadingSubmit } = profile;
const { fullName, company, loading, email, loadingSubmit, phoneNumber } = profile;

return { fullName, company, loading, email, loadingSubmit };
return { fullName, company, loading, email, loadingSubmit, phoneNumber };
};

export default connect(mapStateToProps,
{ profileCompanyChange,
profileFullNameChange,
initialProfile,
profileSaveChanges })(Profile);
profileSaveChanges,
profilePhoneNumberChange })(Profile);
Binary file modified src/content/images/splashscreen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 6 additions & 3 deletions src/reducers/ProfileReducer.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { ToastAndroid } from 'react-native';
import { PROFILE_FULLNAME_CHANGE, PROFILE_COMPANY_CHANGE,
INITIAL_PROFILE, FETCH_PROFILE, PROFILE_CHANGES_SUCCESS,
PROFILE_SAVE_CHANGES, PROFILE_CHANGES_FAIL } from '../actions/types';
PROFILE_SAVE_CHANGES, PROFILE_CHANGES_FAIL, PROFILE_PHONE_NUMBER_CHANGE } from '../actions/types';

const INITIAL_STATE = {
fullName: '',
company: '',
email: '',
phoneNumber: '',
loading: false,
loadingSubmit: false,
uid: ''
Expand All @@ -17,12 +18,14 @@ export default (state = INITIAL_STATE, action) => {
case FETCH_PROFILE:
return { ...state, loading: true };
case INITIAL_PROFILE:
const { fullName, company, email, uid } = action.payload;
return { ...state, loading: false, fullName, company, email, uid };
const { fullName, company, email, uid, phoneNumber } = action.payload;
return { ...state, loading: false, fullName, company, email, uid, phoneNumber };
case PROFILE_FULLNAME_CHANGE:
return { ...state, fullName: action.payload };
case PROFILE_COMPANY_CHANGE:
return { ...state, company: action.payload };
case PROFILE_PHONE_NUMBER_CHANGE:
return { ...state, phoneNumber: action.payload };
case PROFILE_SAVE_CHANGES:
return { ...state, loadingSubmit: true };
case PROFILE_CHANGES_SUCCESS:
Expand Down

0 comments on commit 7316462

Please sign in to comment.