Skip to content

Conversation

@dborowiecki
Copy link
Collaborator

Added build variants.

Changes:

  • API URL is determined in gradle
  • build,
  • RAR Archive password determined in gradle build,
  • Strings for BEPHA and CHF taken from separate soruces,
  • Local, Demo, MV builds use strings from main source.

}
productFlavors {
demoProd {
buildConfigField "String", "API_BASE_URL", '"http://demo.openimis.org/rest/"'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change applicationId as org.openimis.imisclaims.demoProd. Do this change for other flavors so we can install all versions on same phone.

Copy link
Contributor

@malinowskikam malinowskikam Feb 17, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added this. You can install all builds on a single device, but it's hard to determine which is which (nearly all the builds use the same name and icon).

Copy link
Member

@dragos-dobre dragos-dobre Feb 18, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please look on Policies mobile app gradle: https://github.com/openimis/policies_android_app_java/blob/master/app/build.gradle#L51

We are changing the app name based on the build variant. Can you please make this change also?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I updated the build variants app names to "Claims (VARIANT)"

}
productFlavors {
demoProd {
buildConfigField "String", "API_BASE_URL", '"http://demo.openimis.org/rest/"'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need API_BASE_URL in this library?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I deleted unused build config fields.

}

sourceSets {
chfDev.res.srcDir 'src/chf/res'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have escape procedures for ValidateCHF? Do we need to have specific java.srcDir here?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added source sets with Escape.java for every build variant.


//Post with Token
public HttpResponse postToRestApiToken(final JSONObject object, final String functionName) {
setProperUri(functionName);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You removed this function call. Is this to manage the 2 REST APIs? Should this be removed only after REST APIs integration?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I fixed the setProperUri function.

@dragos-dobre
Copy link
Member

@dborowiecki will you finish this issue or @malinowskikam will do?

@dborowiecki
Copy link
Collaborator Author

@malinowskikam Can you take a look at this? Tell me if anything about issue is unclear.

package org.openimis.imisclaims;

public class Escape {
public boolean CheckCHFID(String InsureeNumber) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added the CHFID validation from Policies app to chfDev build

@dragos-dobre
Copy link
Member

Please take the Policies mobile app as reference for this work: https://github.com/openimis/policies_android_app_java/blob/master/app/build.gradle

@malinowskikam
Copy link
Contributor

@dragos-dobre i fixed all the issues, can you re-review?

@dragos-dobre dragos-dobre merged commit d80a673 into develop Mar 9, 2021
@dragos-dobre dragos-dobre deleted the build_variants branch March 9, 2021 10:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants