Skip to content

Commit

Permalink
All bottomnavigation tabs, Notification with redesign Implemented
Browse files Browse the repository at this point in the history
QR code generator and reader implemented
  • Loading branch information
garvit984 committed Jun 11, 2020
1 parent 9ea018b commit 4929762
Show file tree
Hide file tree
Showing 110 changed files with 3,920 additions and 298 deletions.
32 changes: 18 additions & 14 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ android {
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 1
versionName "1.0"
multiDexEnabled true
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
}
Expand Down Expand Up @@ -130,14 +131,17 @@ dependencies {
implementation 'com.github.bumptech.glide:glide:4.8.0'
kapt 'com.github.bumptech.glide:compiler:4.8.0'

implementation 'me.dm7.barcodescanner:zxing:1.9.13'
implementation 'com.karumi:dexter:5.0.0'

//dbFlow for database
kapt "com.github.Raizlabs.DBFlow:dbflow-processor:$rootProject.dbFlowVersion"
implementation "com.github.Raizlabs.DBFlow:dbflow-core:$rootProject.dbFlowVersion"
implementation "com.github.Raizlabs.DBFlow:dbflow:$rootProject.dbFlowVersion"
implementation "com.github.Raizlabs.DBFlow:dbflow-kotlinextensions:$rootProject.dbFlowVersion"
implementation "com.github.Raizlabs.DBFlow:dbflow-rx2:$rootProject.dbFlowVersion"
implementation "com.github.Raizlabs.DBFlow:dbflow-rx2-kotlinextensions:$rootProject.dbFlowVersion"

implementation 'com.android.support:multidex:1.0.3'
//OpenSource Licences
implementation "com.google.android.gms:play-services-oss-licenses:17.0.0"

Expand Down Expand Up @@ -167,32 +171,32 @@ dependencies {
testImplementation 'org.robolectric:robolectric:3.3.1'
}

// Log out test results to console
tasks.matching { it instanceof Test }.all {
testLogging.events = ["failed", "passed", "skipped"]
}
// Log out test results to console
tasks.matching { it instanceof Test }.all {
testLogging.events = ["failed", "passed", "skipped"]
}

/*
/*
Resolves dependency versions across test and production APKs, specifically, transitive
dependencies. This is required since Espresso internally has a dependency on support-annotations.
*/
configurations.all {
resolutionStrategy {
force 'com.android.support:support-annotations:27.1.1'
force 'com.google.code.findbugs:jsr305:1.3.9'
}
configurations.all {
resolutionStrategy {
force 'com.android.support:support-annotations:27.1.1'
force 'com.google.code.findbugs:jsr305:1.3.9'
}
}


/*
/*
All direct/transitive dependencies shared between your test and production APKs need to be
excluded from the test APK! This is necessary because both APKs will contain the same classes. Not
excluding these dependencies from your test configuration will result in an dex pre-verifier error
at runtime. More info in this tools bug: (https://code.google.com/p/android/issues/detail?id=192497)
*/
configurations.compile.dependencies.each { compileDependency ->
configurations.compile.dependencies.each { compileDependency ->
println "Excluding compile dependency: ${compileDependency.getName()}"
configurations.androidTestCompile.dependencies.each { androidTestCompileDependency ->
configurations.androidTestCompile.exclude module: "${compileDependency.getName()}"
}
}
}
31 changes: 21 additions & 10 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,28 +1,33 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.mifos.mobile.cn">
package="org.mifos.mobile.cn">

<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-feature android:name="android.hardware.camera" />
<uses-feature android:name="android.hardware.camera.autofocus" />

<application
android:name=".MifosApplication"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:name=".MifosApplication"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity android:name=".ui.mifos.launcher.LauncherActivity"
android:theme="@style/AppTheme"
android:usesCleartextTraffic="true">
<activity
android:name=".ui.mifos.launcher.LauncherActivity"
android:theme="@style/LauncherTheme">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER"/>
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

<activity android:name=".ui.mifos.DashboardActivity" />
<activity android:name=".ui.mifos.login.LoginActivity"
android:screenOrientation="portrait"/>
Expand All @@ -38,7 +43,13 @@
<activity android:name=".ui.mifos.debtincomereport.DebtIncomeReportActivity"/>
<activity android:name=".ui.mifos.aboutus.AboutUsActivity"/>
<activity android:name=".ui.mifos.privacypolicy.PrivacyPolicyActivity"/>
<activity
<activity android:name=".ui.mifos.Main" />
<activity android:name=".ui.mifos.signup.SignupActivity" />
<activity android:name=".ui.mifos.Notification" />
<activity android:name=".ui.mifos.QRGenerator" />

<activity android:name=".ui.mifos.beneficiaries.BeneficiariesActivity" />
<activity
android:name="com.google.android.gms.oss.licenses.OssLicensesMenuActivity"
android:theme="@style/Theme.AppCompat.Light.DarkActionBar" />
</application>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
package org.mifos.mobile.cn.data.models.beneficiaries

data class Beneficiary(val name: String, val description: String, val price: String)
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ package org.mifos.mobile.cn.injection.component
import dagger.Subcomponent
import org.mifos.mobile.cn.injection.PerActivity
import org.mifos.mobile.cn.injection.module.ActivityModule
import org.mifos.mobile.cn.ui.mifos.Account
import org.mifos.mobile.cn.ui.mifos.DashboardActivity
import org.mifos.mobile.cn.ui.mifos.aboutus.AboutUsFragment
import org.mifos.mobile.cn.ui.mifos.accounts.AccountsFragment
Expand Down Expand Up @@ -39,6 +40,8 @@ interface ActivityComponent {

fun inject(passcodeActivity: PasscodeActivity)

fun inject(account :Account)

fun inject(launcherActivity: LauncherActivity)

fun inject(dashboardActivity: DashboardActivity)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
package org.mifos.mobile.cn.ui.adapter

import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.TextView
import androidx.recyclerview.widget.RecyclerView
import org.mifos.mobile.cn.R
import org.mifos.mobile.cn.data.models.beneficiaries.Beneficiary


class BeneficiariesAdapter(val beneficiariesList: ArrayList<Beneficiary>) : RecyclerView.Adapter<BeneficiariesAdapter.ViewHolder>() {

override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ViewHolder {
val v = LayoutInflater.from(parent.context).inflate(R.layout.item_beneficiaries, parent, false)
return ViewHolder(v)
}

override fun getItemCount(): Int {
return beneficiariesList.size
}

override fun onBindViewHolder(holder: ViewHolder, position: Int) {
val list: Beneficiary = beneficiariesList[position]
holder.textViewName?.text = list.name
holder.textViewDescription?.text = list.description
holder.textViewPrice?.text = list.price
}

class ViewHolder(itemView: View) : RecyclerView.ViewHolder(itemView) {
val textViewName = itemView.findViewById<TextView>(R.id.tv_name)
val textViewDescription = itemView.findViewById<TextView>(R.id.tv_beneficiaries_decription)
val textViewPrice = itemView.findViewById<TextView>(R.id.tv_price)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ open class MifosBaseFragment : Fragment() {
callback.showTabLayout(false)
}

override fun onAttach(context: Context?) {
override fun onAttach(context: Context?) {
super.onAttach(context)
val activity = context as? Activity
try {
Expand Down
Loading

0 comments on commit 4929762

Please sign in to comment.