Browse Source

Withdraw money screen added

master
Preyea Regmi 6 years ago
parent
commit
dababf75fd
  1. BIN
      .idea/caches/build_file_checksums.ser
  2. 2
      .idea/misc.xml
  3. 2
      .idea/modules.xml
  4. 48
      app/src/main/AndroidManifest.xml
  5. 5
      app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestModalFragment.java
  6. 45
      app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/gateway/WithdrawV2Gateway.java
  7. 15
      app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/presenter/WithdrawV2InteractorInterface.java
  8. 23
      app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/presenter/WithdrawV2Presenter.java
  9. 17
      app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/presenter/WithdrawV2PresenterInterface.java
  10. 16
      app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/view/WithdrawV2Activity.java
  11. 187
      app/src/main/res/layout/activity_withdraw_v2.xml

BIN
.idea/caches/build_file_checksums.ser

2
.idea/misc.xml

@ -25,7 +25,7 @@
</value> </value>
</option> </option>
</component> </component>
<component name="ProjectRootManager">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/build/classes" /> <output url="file://$PROJECT_DIR$/build/classes" />
</component> </component>
<component name="ProjectType"> <component name="ProjectType">

2
.idea/modules.xml

@ -2,6 +2,8 @@
<project version="4"> <project version="4">
<component name="ProjectModuleManager"> <component name="ProjectModuleManager">
<modules> <modules>
<module fileurl="file://$PROJECT_DIR$/SpinnerDatePickerLib-release/SpinnerDatePickerLib-release.iml" filepath="$PROJECT_DIR$/SpinnerDatePickerLib-release/SpinnerDatePickerLib-release.iml" />
<module fileurl="file://$PROJECT_DIR$/app/app.iml" filepath="$PROJECT_DIR$/app/app.iml" />
<module fileurl="file://$PROJECT_DIR$/gme-android.iml" filepath="$PROJECT_DIR$/gme-android.iml" /> <module fileurl="file://$PROJECT_DIR$/gme-android.iml" filepath="$PROJECT_DIR$/gme-android.iml" />
</modules> </modules>
</component> </component>

48
app/src/main/AndroidManifest.xml

@ -18,10 +18,10 @@
android:icon="@mipmap/ic_launcher" android:icon="@mipmap/ic_launcher"
android:label="@string/app_name" android:label="@string/app_name"
android:largeHeap="true" android:largeHeap="true"
tools:replace="android:allowBackup"
android:roundIcon="@mipmap/ic_launcher" android:roundIcon="@mipmap/ic_launcher"
android:supportsRtl="true" android:supportsRtl="true"
android:theme="@style/AppTheme">
android:theme="@style/AppTheme"
tools:replace="android:allowBackup">
<provider <provider
android:name="android.support.v4.content.FileProvider" android:name="android.support.v4.content.FileProvider"
android:authorities="com.gmeremit.online.gmeremittance_native.fileprovider" android:authorities="com.gmeremit.online.gmeremittance_native.fileprovider"
@ -52,19 +52,21 @@
</intent-filter> </intent-filter>
</activity> </activity>
<!--<meta-data-->
<!--android:name="com.facebook.sdk.ApplicationId"-->
<!--android:value="@string/facebook_app_id" />-->
<!-- <meta-data -->
<!-- android:name="com.facebook.sdk.ApplicationId" -->
<!-- android:value="@string/facebook_app_id" /> -->
<!--<activity-->
<!--android:name="com.facebook.FacebookActivity"-->
<!--android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"-->
<!--android:label="@string/app_name" />-->
<!--<provider-->
<!--android:name="com.facebook.FacebookContentProvider"-->
<!--android:authorities="com.facebook.app.FacebookContentProvider331163960743784"-->
<!--android:exported="true" />-->
<!-- <activity -->
<!-- android:name="com.facebook.FacebookActivity" -->
<!-- android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation" -->
<!-- android:label="@string/app_name" /> -->
<!-- <provider -->
<!-- android:name="com.facebook.FacebookContentProvider" -->
<!-- android:authorities="com.facebook.app.FacebookContentProvider331163960743784" -->
<!-- android:exported="true" /> -->
<activity <activity
android:name=".sign_in.view.LoginView" android:name=".sign_in.view.LoginView"
@ -362,10 +364,10 @@
android:screenOrientation="portrait" android:screenOrientation="portrait"
android:theme="@style/AppTheme.NoActionBar" android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="stateHidden" /> android:windowSoftInputMode="stateHidden" />
<!--<activity-->
<!--android:name="com.yalantis.ucrop.UCropActivity"-->
<!--android:screenOrientation="portrait"-->
<!--android:theme="@style/Theme.AppCompat.Light.NoActionBar" />-->
<!-- <activity -->
<!-- android:name="com.yalantis.ucrop.UCropActivity" -->
<!-- android:screenOrientation="portrait" -->
<!-- android:theme="@style/Theme.AppCompat.Light.NoActionBar" /> -->
<activity <activity
android:name=".user_profile.view.ProfileActivity" android:name=".user_profile.view.ProfileActivity"
android:screenOrientation="portrait" android:screenOrientation="portrait"
@ -551,13 +553,15 @@
android:screenOrientation="portrait" android:screenOrientation="portrait"
android:theme="@style/AppTheme.NoActionBar" android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="stateAlwaysHidden" /> android:windowSoftInputMode="stateAlwaysHidden" />
<activity android:name=".changepasswordV2.view.ChangePasswordV2Activity"
<activity
android:name=".changepasswordV2.view.ChangePasswordV2Activity"
android:screenOrientation="portrait" android:screenOrientation="portrait"
android:theme="@style/AppTheme.NoActionBar" android:theme="@style/AppTheme.NoActionBar"
android:windowSoftInputMode="stateAlwaysHidden"></activity>
<activity android:name="com.theartofdev.edmodo.cropper.CropImageActivity"
android:theme="@style/Base.Theme.AppCompat"/>
android:windowSoftInputMode="stateAlwaysHidden" />
<activity
android:name="com.theartofdev.edmodo.cropper.CropImageActivity"
android:theme="@style/Base.Theme.AppCompat" />
<activity android:name=".withdrawV2.view.WithdrawV2Activity"></activity>
</application> </application>
</manifest> </manifest>

5
app/src/main/java/com/gmeremit/online/gmeremittance_native/kycV2/view/pennytest/PennyTestModalFragment.java

@ -33,11 +33,6 @@ public class PennyTestModalFragment extends DialogFragment {
} }
@Override
public int getTheme() {
return R.style.DialogAnimation;
}
} }

45
app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/gateway/WithdrawV2Gateway.java

@ -0,0 +1,45 @@
package com.gmeremit.online.gmeremittance_native.withdrawV2.gateway;
import com.gmeremit.online.gmeremittance_native.base.PrivilegedGateway;
import com.gmeremit.online.gmeremittance_native.utils.https.HttpClientV2;
import com.gmeremit.online.gmeremittance_native.walletstatementV2.model.WalletStatementV2APIResponse;
import com.gmeremit.online.gmeremittance_native.walletstatementV2.presenter.WalletStatementV2InteractorInterface;
import com.gmeremit.online.gmeremittance_native.withdrawV2.presenter.WithdrawV2InteractorInterface;
import com.google.gson.JsonObject;
import io.reactivex.Observable;
public class WithdrawV2Gateway extends PrivilegedGateway implements WithdrawV2InteractorInterface.WithdrawV2GatewayInterface {
private final WithdrawV2InteractorInterface interactor;
private String mockedString="{\n" +
" \"ErrorCode\": \"0\",\n" +
" \"Msg\": \"1 wallet txn\",\n" +
" \"Id\": null,\n" +
" \"Extra\": \"\",\n" +
" \"Extra2\": \"\",\n" +
" \"Data\": [\n" +
" {\n" +
" \"TransactionDate\": \"1900.01.01\",\n" +
" \"Particular\": \"Balance Brought Forward\",\n" +
" \"WalletIn\": \"₩0\",\n" +
" \"WalletOut\": \"₩100,000,000\",\n" +
" \"ClosingAmount\": \"-₩85,000\"\n" +
" },\n" +
" {\n" +
" \"TransactionDate\": \"1900.01.01\",\n" +
" \"Particular\": \"Balance Brought Backward\",\n" +
" \"WalletIn\": \"₩200,000,000\",\n" +
" \"WalletOut\": \"₩0\",\n" +
" \"ClosingAmount\": \"-₩100,000\"\n" +
" }\n" +
" ]\n" +
"}";
public WithdrawV2Gateway(WithdrawV2InteractorInterface interactor) {
this.interactor=interactor;
}
}

15
app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/presenter/WithdrawV2InteractorInterface.java

@ -0,0 +1,15 @@
package com.gmeremit.online.gmeremittance_native.withdrawV2.presenter;
import com.gmeremit.online.gmeremittance_native.base.BaseInteractorInterface;
import com.gmeremit.online.gmeremittance_native.base.PrivilegedGatewayInterface;
import com.gmeremit.online.gmeremittance_native.walletstatementV2.model.WalletStatementV2APIResponse;
import io.reactivex.Observable;
public interface WithdrawV2InteractorInterface extends BaseInteractorInterface {
interface WithdrawV2GatewayInterface extends PrivilegedGatewayInterface
{
}
}

23
app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/presenter/WithdrawV2Presenter.java

@ -0,0 +1,23 @@
package com.gmeremit.online.gmeremittance_native.withdrawV2.presenter;
import com.gmeremit.online.gmeremittance_native.base.BasePresenter;
import com.gmeremit.online.gmeremittance_native.withdrawV2.gateway.WithdrawV2Gateway;
import io.reactivex.disposables.CompositeDisposable;
public class WithdrawV2Presenter extends BasePresenter implements WithdrawV2PresenterInterface,WithdrawV2InteractorInterface {
private final WithdrawV2ContractInterface view;
private final WithdrawV2GatewayInterface gateway;
private final CompositeDisposable compositeDisposables;
public WithdrawV2Presenter(WithdrawV2ContractInterface view) {
this.view=view;
this.gateway=new WithdrawV2Gateway(this);
compositeDisposables=new CompositeDisposable();
}
}

17
app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/presenter/WithdrawV2PresenterInterface.java

@ -0,0 +1,17 @@
package com.gmeremit.online.gmeremittance_native.withdrawV2.presenter;
import com.gmeremit.online.gmeremittance_native.base.BaseContractInterface;
import com.gmeremit.online.gmeremittance_native.base.BasePresenterInterface;
import com.gmeremit.online.gmeremittance_native.walletstatementV2.model.WalletStatementV2ItemModel;
import java.util.List;
public interface WithdrawV2PresenterInterface extends BasePresenterInterface {
interface WithdrawV2ContractInterface extends BaseContractInterface {
}
}

16
app/src/main/java/com/gmeremit/online/gmeremittance_native/withdrawV2/view/WithdrawV2Activity.java

@ -0,0 +1,16 @@
package com.gmeremit.online.gmeremittance_native.withdrawV2.view;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import com.gmeremit.online.gmeremittance_native.R;
import com.gmeremit.online.gmeremittance_native.base.BaseActivity;
public class WithdrawV2Activity extends BaseActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_withdraw_v2);
}
}

187
app/src/main/res/layout/activity_withdraw_v2.xml

@ -0,0 +1,187 @@
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_height="match_parent"
android:clickable="true"
android:scrollbars="none"
android:background="@color/background_gray"
tools:context="com.gmeremit.online.gmeremittance_native.exchange_rate.view.ExchangeMethodV2Activity"
android:layout_width="match_parent">
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="3dp"
android:layout_marginStart="3dp"
android:layout_marginEnd="3dp"
android:background="@drawable/ic_rounded_white"
tools:context=".withdrawV2.view.WithdrawV2Activity">
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeTextView
android:id="@+id/withdrawTitle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="16dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
android:gravity="center"
android:singleLine="false"
android:text="How much would you like to refund?"
android:textColor="@color/darkgray"
android:textSize="21sp"
app:layout_constraintBottom_toTopOf="@+id/withdrawAvailableTxt"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_chainStyle="packed" />
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeTextView
android:id="@+id/withdrawAvailableTxt"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:gravity="center"
android:singleLine="false"
android:text="Available Balance : 99,745,176(KRW)"
android:textColor="@color/darkgray"
android:textSize="17sp"
app:layout_constraintBottom_toTopOf="@+id/withdrawBankChargeTxt"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/withdrawTitle" />
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeTextView
android:id="@+id/withdrawBankChargeTxt"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="8dp"
android:gravity="center"
android:singleLine="false"
android:text="Pre Fund Bank Charge : 1,000(KRW)"
android:textColor="@color/darkgray"
android:textSize="18sp"
app:layout_constraintBottom_toTopOf="@+id/refundMoneyContainer"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/withdrawAvailableTxt" />
<LinearLayout
android:id="@+id/refundMoneyContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="8dp"
android:background="@drawable/curve_rectangle_grey_bg"
android:orientation="horizontal"
app:layout_constraintBottom_toTopOf="@+id/refundButton"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/withdrawBankChargeTxt">
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
android:paddingLeft="5dp"
android:paddingRight="5dp">
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeTextView
android:id="@+id/bank_label"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingStart="3dp"
android:paddingLeft="3dp"
android:paddingTop="3dp"
android:text="You Refund"
android:textColor="@color/darkgray"
android:textSize="16sp" />
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeEditText
android:id="@+id/sendAmountEdTxt"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:backgroundTint="@android:color/transparent"
android:digits="0,1,2,3,4,5,6,7,8,9"
android:gravity="center_vertical"
android:hint="100,000"
android:imeOptions="actionDone"
android:inputType="textMultiLine|number"
android:text="1000000000000000000000000000000000000000"
android:textColor="@color/colorPrimary"
android:textSize="30sp"
app:edfontName="@string/semibold" />
</LinearLayout>
<FrameLayout
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:background="@drawable/curve_rectangle_blue_bg"
android:paddingStart="5dp"
android:paddingEnd="5dp">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="50dp"
android:layout_height="45dp"
android:layout_gravity="center"
android:background="@drawable/flag_korean" />
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeTextView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:paddingStart="5dp"
android:paddingLeft="5dp"
android:paddingEnd="5dp"
android:paddingRight="5dp"
android:text="KRW"
android:textColor="@color/white"
android:textSize="15sp"
android:textStyle="bold" />
</LinearLayout>
</FrameLayout>
</LinearLayout>
<com.gmeremit.online.gmeremittance_native.customwidgets.GmeButton
android:id="@+id/refundButton"
android:layout_width="200dp"
android:layout_height="50dp"
android:layout_gravity="center"
android:layout_marginStart="8dp"
android:layout_marginTop="30dp"
android:layout_marginEnd="8dp"
android:layout_marginBottom="20dp"
android:background="@drawable/ic_rounded_background_coloured"
android:text="Calculate"
android:textAllCaps="false"
android:textColor="@color/white"
android:textSize="18sp"
app:layout_constraintBottom_toTopOf="@+id/withdrawTitle"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/refundMoneyContainer" />
</android.support.constraint.ConstraintLayout>
</ScrollView>
Loading…
Cancel
Save