Vera 2.1 stable build

parent c1601154
Showing with 79 additions and 121 deletions
......@@ -43,19 +43,6 @@
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustResize|stateHidden" />
<activity
android:name=".ui.OtpValidationActivity"
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustResize|stateHidden" />
<activity
android:name=".ui.LoginChooseActivity"
android:screenOrientation="portrait"
/> <activity
android:name=".ui.ADALActivity"
android:screenOrientation="portrait"
/>
<activity android:name=".ui.ResetPasswordActivity"
android:screenOrientation="portrait"
android:fitsSystemWindows="true"
......

127 KB | W: | H:

13.9 KB | W: | H:

app/src/main/ic_launcher-web.png
app/src/main/ic_launcher-web.png
app/src/main/ic_launcher-web.png
app/src/main/ic_launcher-web.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -40,10 +40,9 @@ import retrofit2.Retrofit;
public class IncidentApiManager {
public static void getIncident(Context context, GetIncidentApiListener listener) {
String sysId = PrefManager.getSharedPref(context, PrefManager.PREFERENCE_DYNAMIC_USER_SYS_ID);
CatalogueLog.d("IncidentApiManager: getIncident: ");
StringBuilder stringBuilder = new StringBuilder();
stringBuilder.append("caller_id="+sysId);
stringBuilder.append("caller_id=javascript:gs.getUserID()");
CatalogueLog.d("IncidentApiManager: getIncident: request parameter: "+stringBuilder.toString());
String accessToken = PrefManager.getSharedPref(context, PrefManager.PREFERENCE_ACCESS_TOKEN);
......@@ -52,7 +51,6 @@ public class IncidentApiManager {
listener.onFailApiCall();
return;
}
final Retrofit retrofit = RestClient.getInitializedRestAdapter(accessToken);
Call<ResponseBody> call = retrofit.create(IncidentApi.class).getIncident(stringBuilder.toString(), "");
try {
......
......@@ -207,11 +207,11 @@ public class ChatActivity extends AppCompatActivity implements OnDSListener, OnD
mLoggedInUserSysId = PrefManager.getSharedPref(this, PrefManager.PREFERENCE_USER_SYS_ID);
mLoggedInUsername = PrefManager.getSharedPref(this, PrefManager.PREFERENCE_USER_FIRST_NAME);
userSysId = PrefManager.getSharedPref(this, PrefManager.PREFERENCE_DYNAMIC_USER_SYS_ID);
userSysId = PrefManager.getSharedPref(this, PrefManager.PREFERENCE_USER_SYS_ID);
if(TextUtils.isEmpty(mLoggedInUserSysId) || TextUtils.isEmpty(mLoggedInUsername)) {
CatalogueLog.e("User Sys id or Name is Null");
Intent intent = new Intent(this, ADALActivity.class);
Intent intent = new Intent(this, LoginScreen.class);
intent.putExtra(Constants.DATA_KEY_LOGIN_REQUEST_CODE, Constants.LOGIN_SCREEN_REQUEST_CODE);
startActivity(intent);
finish();
......
......@@ -172,68 +172,25 @@ public class HomeScreen extends HandleNotificationActivity {
// alert.show();
// }
// if(BuildConfig.BUILD_TYPE_INT == 1 ||BuildConfig.BUILD_TYPE_INT == 3 ) {
// AlertDialog.Builder builder = new AlertDialog.Builder(this);
// StringBuilder stringBuilder = new StringBuilder();
// stringBuilder.append("ServiceNow Instance: ");
// stringBuilder.append(Constants.DOMAIN);
// stringBuilder.append("\n");
// stringBuilder.append("Socket URL: ");
// stringBuilder.append(Constants.CHAT_SERVER_URL);
// stringBuilder.append("\n");
// stringBuilder.append("Flavor: ");
// stringBuilder.append(BuildConfig.FLAVOR);
// stringBuilder.append("\n");
// stringBuilder.append("Build Type: ");
// stringBuilder.append(BuildConfig.BUILD_TYPE);
// stringBuilder.append("\n");
// stringBuilder.append("\n");
// stringBuilder.append("Version: "+BuildConfig.VERSION_NAME);
// builder.setMessage(stringBuilder.toString())
// .setTitle("App Info")
// .setCancelable(false)
// .setPositiveButton(R.string.ok_string, new DialogInterface.OnClickListener() {
// public void onClick(DialogInterface dialog, int id) {
// dialog.dismiss();
// }
// });
// AlertDialog alert = builder.create();
// alert.show();
// }
if(BuildConfig.BUILD_TYPE_INT == 1 ||BuildConfig.BUILD_TYPE_INT == 3 ) {
String userFullName = PrefManager.getSharedPref(HomeScreen.this, PrefManager.PREFERENCE_USER_FULL_NAME);
if(userFullName!= null){
AlertDialog.Builder builder = new AlertDialog.Builder(this);
StringBuilder stringBuilder = new StringBuilder();
stringBuilder.append("Username: ");
stringBuilder.append(userFullName);
stringBuilder.append("ServiceNow Instance: ");
stringBuilder.append(Constants.DOMAIN);
stringBuilder.append("\n");
stringBuilder.append("Socket URL: ");
stringBuilder.append(Constants.CHAT_SERVER_URL);
stringBuilder.append("\n");
stringBuilder.append("Version: "+BuildConfig.VERSION_NAME);
builder.setMessage(stringBuilder.toString())
.setTitle("User Details")
.setCancelable(false)
.setPositiveButton(R.string.ok_string, new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int id) {
dialog.dismiss();
}
});
AlertDialog alert = builder.create();
alert.show();
}else {
String mobileNumber = PrefManager.getSharedPref(HomeScreen.this, PrefManager.MOBILE_NUMBER);
AlertDialog.Builder builder = new AlertDialog.Builder(this);
StringBuilder stringBuilder = new StringBuilder();
stringBuilder.append("Username: ");
stringBuilder.append(mobileNumber);
stringBuilder.append("Flavor: ");
stringBuilder.append(BuildConfig.FLAVOR);
stringBuilder.append("\n");
stringBuilder.append("Build Type: ");
stringBuilder.append(BuildConfig.BUILD_TYPE);
stringBuilder.append("\n");
stringBuilder.append("\n");
stringBuilder.append("Version: "+BuildConfig.VERSION_NAME);
builder.setMessage(stringBuilder.toString())
.setTitle("User Details")
.setTitle("App Info")
.setCancelable(false)
.setPositiveButton(R.string.ok_string, new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int id) {
......@@ -244,7 +201,6 @@ public class HomeScreen extends HandleNotificationActivity {
alert.show();
}
}
}
......@@ -350,10 +306,8 @@ public class HomeScreen extends HandleNotificationActivity {
PrefManager.setSharedPref(HomeScreen.this, PrefManager.PREFERENCE_USER_FULL_NAME, "");
PrefManager.setSharedPref(HomeScreen.this, PrefManager.PREFERENCE_USER_EMAIL_ID, "");
PrefManager.setSharedPref(HomeScreen.this, PrefManager.SESSION_ID, "");
PrefManager.setSharedPref(HomeScreen.this, PrefManager.MOBILE_NUMBER, "");
PrefManager.setSharedPref(HomeScreen.this, PrefManager.PREFERENCE_DYNAMIC_USER_SYS_ID, "");
Intent loginIntent = new Intent(HomeScreen.this, ADALActivity.class);
Intent loginIntent = new Intent(HomeScreen.this, LoginScreen.class);
loginIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);
startActivity(loginIntent);
} else {
......
......@@ -42,7 +42,7 @@ import butterknife.ButterKnife;
import butterknife.OnClick;
/**
* Created by Kunj on 11/8/16.
* Created by Krishna on 16/10/19.
*/
public class LoginScreen extends Activity {
......@@ -78,7 +78,7 @@ public class LoginScreen extends Activity {
switch (keyCode) {
case KeyEvent.KEYCODE_DPAD_CENTER:
case KeyEvent.KEYCODE_ENTER:
callLoginAPI(false);
callLoginAPI();
return true;
default:
break;
......@@ -114,22 +114,6 @@ public class LoginScreen extends Activity {
Util.sendScreenName(tracker, getString(R.string.login_screen_string));
}
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
if(requestCode == Constants.LOGIN_SCREEN_OTP_REQUEST_CODE){
if(data!=null && data.getExtras()!=null){
String message = data.getExtras().getString(Constants.MESSAGE);
if(message.equalsIgnoreCase(Constants.RESPONSE_SUCCESS)){
callLoginAPI(false);
}else{
Toast.makeText(this,"Something went Wrong",Toast.LENGTH_LONG).show();
}
}
}
}
private void CheckLoginValues() {
String sysId = PrefManager.getSharedPref(LoginScreen.this, PrefManager.PREFERENCE_USER_SYS_ID);
if (!TextUtils.isEmpty(sysId)) {
......@@ -153,7 +137,7 @@ public class LoginScreen extends Activity {
}
}
private void callLoginAPI(boolean withOtp) {
private void callLoginAPI() {
String userNameString = mUserNameEditText.getText().toString().trim();
String passwordString = mPasswordEditText.getText().toString().trim();
......@@ -166,26 +150,19 @@ public class LoginScreen extends Activity {
if (!TextUtils.isEmpty(userNameString) && !TextUtils.isEmpty(passwordString)) {
KeyboardUtil.hideKeyboard(LoginScreen.this);
if (mApplication.isNetConnected()) {
if(withOtp){
launchOptValidationScreen();
}else{
new LoginDetailsSendToServer().execute(mUserNameEditText.getText().toString().trim(), mPasswordEditText.getText().toString().trim());
}
} else {
DialogUtils.showNoConnectionDialog(LoginScreen.this);
}
}
}
@OnClick(R.id.login_screen_login_text_view)
void onLoginClicked() {
callLoginAPI();
private void launchOptValidationScreen(){
Intent intent = new Intent(LoginScreen.this,OtpValidationActivity.class);
startActivityForResult(intent,Constants.LOGIN_SCREEN_OTP_REQUEST_CODE);
}
private class LoginDetailsSendToServer extends AsyncTask<String, Integer, Integer> {
private ProgressDialog progressDialog;
private static final int USER_DETAIL = 1;
......
......@@ -11,12 +11,10 @@ public class PrefManager {
public static final String PREFERENCE_USER_FIRST_NAME = "firstName";
public static final String PREFERENCE_USER_LAST_NAME = "lastName";
public static final String PREFERENCE_USER_SYS_ID = "sysId";
public static final String PREFERENCE_DYNAMIC_USER_SYS_ID = "dynamic_sysId";
public static final String PREFERENCE_USER_FULL_NAME = "full_name";
public static final String PREFERENCE_USER_ID = "user_id";
public static final String PREFERENCE_USER_EMAIL_ID = "user_email_id";
public static final String SESSION_ID = "session_id";
public static final String MOBILE_NUMBER = "mobile_number";
//Chat Server Url
public static final String PREFERENCE_CHAT_SERVER_URL = "chat_server_url";
......
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<!-- <solid android:color="@color/button_bg" />-->
<!-- <corners android:radius="10dip" />-->
<!-- <stroke-->
<!-- android:width="1dp"-->
<!-- android:color="@color/button_bg" />-->
<corners
android:radius="0dp"
/>
<gradient
android:angle="45"
android:centerX="35%"
android:startColor="#e5e5e5"
android:centerColor="#7f7f7f"
android:endColor="#b2b2b2"
android:type="linear"
/>
<padding
android:left="0dp"
android:top="0dp"
android:right="0dp"
android:bottom="0dp"
/>
<size
android:width="200dp"
android:height="400dp"
/>
</shape>
<vector android:height="24dp" android:tint="#FFFFFF"
android:viewportHeight="24.0" android:viewportWidth="24.0"
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:fillColor="#FF000000" android:pathData="M12,12c2.21,0 4,-1.79 4,-4s-1.79,-4 -4,-4 -4,1.79 -4,4 1.79,4 4,4zM12,14c-2.67,0 -8,1.34 -8,4v2h16v-2c0,-2.66 -5.33,-4 -8,-4z"/>
</vector>
......@@ -16,9 +16,9 @@
<gradient
android:angle="45"
android:centerX="35%"
android:centerColor="#6699c8"
android:startColor="#7faad1"
android:endColor="#1966ad"
android:startColor="#303030"
android:centerColor="#666666"
android:endColor="#303030"
android:type="linear"
/>
<padding
......
......@@ -39,7 +39,7 @@
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:layout_centerVertical="true"
android:text="FULTON COUNTY"
android:text="@string/app_name"
android:textColor="@color/screen_bg_color_white" />
<ImageView
......

6.88 KB | W: | H:

1.33 KB | W: | H:

app/src/main/res/mipmap-hdpi/ic_launcher.png
app/src/main/res/mipmap-hdpi/ic_launcher.png
app/src/main/res/mipmap-hdpi/ic_launcher.png
app/src/main/res/mipmap-hdpi/ic_launcher.png
  • 2-up
  • Swipe
  • Onion skin

10.5 KB | W: | H:

1.58 KB | W: | H:

app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
  • 2-up
  • Swipe
  • Onion skin

6.88 KB | W: | H:

3.09 KB | W: | H:

app/src/main/res/mipmap-hdpi/ic_launcher_round.png
app/src/main/res/mipmap-hdpi/ic_launcher_round.png
app/src/main/res/mipmap-hdpi/ic_launcher_round.png
app/src/main/res/mipmap-hdpi/ic_launcher_round.png
  • 2-up
  • Swipe
  • Onion skin

3.94 KB | W: | H:

941 Bytes | W: | H:

app/src/main/res/mipmap-mdpi/ic_launcher.png
app/src/main/res/mipmap-mdpi/ic_launcher.png
app/src/main/res/mipmap-mdpi/ic_launcher.png
app/src/main/res/mipmap-mdpi/ic_launcher.png
  • 2-up
  • Swipe
  • Onion skin

5.82 KB | W: | H:

1.01 KB | W: | H:

app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
  • 2-up
  • Swipe
  • Onion skin

3.94 KB | W: | H:

1.93 KB | W: | H:

app/src/main/res/mipmap-mdpi/ic_launcher_round.png
app/src/main/res/mipmap-mdpi/ic_launcher_round.png
app/src/main/res/mipmap-mdpi/ic_launcher_round.png
app/src/main/res/mipmap-mdpi/ic_launcher_round.png
  • 2-up
  • Swipe
  • Onion skin

10.5 KB | W: | H:

1.86 KB | W: | H:

app/src/main/res/mipmap-xhdpi/ic_launcher.png
app/src/main/res/mipmap-xhdpi/ic_launcher.png
app/src/main/res/mipmap-xhdpi/ic_launcher.png
app/src/main/res/mipmap-xhdpi/ic_launcher.png
  • 2-up
  • Swipe
  • Onion skin

16.2 KB | W: | H:

2.16 KB | W: | H:

app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png
  • 2-up
  • Swipe
  • Onion skin

10.5 KB | W: | H:

4.48 KB | W: | H:

app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
  • 2-up
  • Swipe
  • Onion skin

18.7 KB | W: | H:

2.86 KB | W: | H:

app/src/main/res/mipmap-xxhdpi/ic_launcher.png
app/src/main/res/mipmap-xxhdpi/ic_launcher.png
app/src/main/res/mipmap-xxhdpi/ic_launcher.png
app/src/main/res/mipmap-xxhdpi/ic_launcher.png
  • 2-up
  • Swipe
  • Onion skin

31.3 KB | W: | H:

3.49 KB | W: | H:

app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png
  • 2-up
  • Swipe
  • Onion skin

18.7 KB | W: | H:

7.14 KB | W: | H:

app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
  • 2-up
  • Swipe
  • Onion skin

28.7 KB | W: | H:

4.05 KB | W: | H:

app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
  • 2-up
  • Swipe
  • Onion skin

50.1 KB | W: | H:

5.19 KB | W: | H:

app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png
  • 2-up
  • Swipe
  • Onion skin

28.7 KB | W: | H:

10.3 KB | W: | H:

app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
  • 2-up
  • Swipe
  • Onion skin
<resources>
<string name="app_name">Fulton-County</string>
<string name="app_name">VERA-2.1</string>
<string name="set_string">Set</string>
<string name="submit_string">Submit</string>
......
......@@ -12,8 +12,8 @@ public class AppConfig {
public static final String LOGIN_CLIENT_ID_RELEASE = "d958eb06b0f3830093781f441d59febc";
public static final String LOGIN_CLIENT_SECRET_RELEASE = "krD*!O}1.8";
public static final String LOGIN_CLIENT_ID_DEBUG = "89cfc0656ce6b30012af8b50316c9376";
public static final String LOGIN_CLIENT_SECRET_DEBUG = ")R+)DZh|,T";
public static final String LOGIN_CLIENT_ID_DEBUG = "0ab7489795c40410d06a70ea1d212df1";
public static final String LOGIN_CLIENT_SECRET_DEBUG = "Cmei6uCRfM";
public static final String LOGIN_CLIENT_ID_STAGING = "091b5d1ea97cd700e4268b90dd5521ca";
public static final String LOGIN_CLIENT_SECRET_STAGING = "+tPJ@jS<;S";
......@@ -61,8 +61,8 @@ public class AppConfig {
/**
* We will hit the below url to get the chat server url.
* */
public static final String CHAT_SERVER_API_URL_RELEASE = "http://52.21.5.26:12814/service_discovery";
public static final String CHAT_SERVER_API_URL_RELEASE = "http://52.21.5.26:12811/service_discovery";
public static final String CHAT_SERVER_API_URL_DEBUG = "http://52.21.5.26:12811/service_discovery";
public static final String CHAT_SERVER_API_URL_STAGING = "http://52.21.5.26:12813/service_discovery";
public static final String CHAT_SERVER_API_URL_STAGING = "http://52.21.5.26:12811/service_discovery";
}
......@@ -2,6 +2,7 @@
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:focusableInTouchMode="true"
android:scrollbarStyle="insideOverlay">
......
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="@+id/splash_main_lyt"
......@@ -11,8 +11,10 @@
android:id="@+id/splash_image"
android:layout_gravity="center"
android:layout_width="200dp"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:layout_height="150dp"
/>
</LinearLayout>
\ No newline at end of file
</RelativeLayout>
\ No newline at end of file
<resources>
<string name="app_name">Fulton-County</string>
<string name="app_name">VERA-2.1</string>
<!--home Screen Option-->
<!--Start-->
......
No preview for this file type
[{"outputType":{"type":"APK"},"apkData":{"type":"MAIN","splits":[],"versionCode":1,"versionName":"0.0.6","enabled":true,"outputFile":"app-vportal-debug.apk","fullName":"vportalDebug","baseName":"vportal-debug"},"path":"app-vportal-debug.apk","properties":{}}]
\ No newline at end of file
[{"outputType":{"type":"APK"},"apkData":{"type":"MAIN","splits":[],"versionCode":1,"versionName":"0.2.6","enabled":true,"outputFile":"app-vportal-debug.apk","fullName":"vportalDebug","baseName":"vportal-debug"},"path":"app-vportal-debug.apk","properties":{}}]
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment