diff --git a/.gitignore b/.gitignore
index 3c117df..fd45b12 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,65 +1,11 @@
-# Built application files
-*.apk
-*.ap_
-
-# Files for the ART/Dalvik VM
-*.dex
-
-# Java class files
-*.class
-
-# Generated files
-bin/
-gen/
-out/
-
-# Gradle files
-.gradle/
-build/
-
-# Local configuration file (sdk path, etc)
-local.properties
-
-# Proguard folder generated by Eclipse
-proguard/
-
-# Log Files
-*.log
-
-# Android Studio Navigation editor temp files
-.navigation/
-
-# Android Studio captures folder
-captures/
-
-# IntelliJ
*.iml
-.idea/workspace.xml
-.idea/tasks.xml
-.idea/gradle.xml
-.idea/assetWizardSettings.xml
-.idea/dictionaries
-.idea/libraries
-.idea/caches
-
-# Keystore files
-# Uncomment the following line if you do not want to check your keystore files in.
-#*.jks
-
-# External native build folder generated in Android Studio 2.2 and later
+.gradle
+/local.properties
+/.idea/caches/build_file_checksums.ser
+/.idea/libraries
+/.idea/modules.xml
+/.idea/workspace.xml
+.DS_Store
+/build
+/captures
.externalNativeBuild
-
-# Google Services (e.g. APIs or Firebase)
-google-services.json
-
-# Freeline
-freeline.py
-freeline/
-freeline_project_description.json
-
-# fastlane
-fastlane/report.xml
-fastlane/Preview.html
-fastlane/screenshots
-fastlane/test_output
-fastlane/readme.md
\ No newline at end of file
diff --git a/.idea/caches/build_file_checksums.ser b/.idea/caches/build_file_checksums.ser
index 49aff22..b99dd67 100644
Binary files a/.idea/caches/build_file_checksums.ser and b/.idea/caches/build_file_checksums.ser differ
diff --git a/.idea/vcs.xml b/.idea/vcs.xml
deleted file mode 100644
index 35eb1dd..0000000
--- a/.idea/vcs.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
-
-
-
-
\ No newline at end of file
diff --git a/LICENSE b/LICENSE
deleted file mode 100644
index 261eeb9..0000000
--- a/LICENSE
+++ /dev/null
@@ -1,201 +0,0 @@
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/Music/desktop.ini b/Music/desktop.ini
deleted file mode 100644
index c3dea78..0000000
Binary files a/Music/desktop.ini and /dev/null differ
diff --git a/UI/Event.png b/UI/Event.png
deleted file mode 100755
index 4fabf68..0000000
Binary files a/UI/Event.png and /dev/null differ
diff --git a/UI/Home.png b/UI/Home.png
deleted file mode 100755
index 54e1b05..0000000
Binary files a/UI/Home.png and /dev/null differ
diff --git a/UI/Index.png b/UI/Index.png
deleted file mode 100755
index a3cc191..0000000
Binary files a/UI/Index.png and /dev/null differ
diff --git a/app/build.gradle b/app/build.gradle
index 5dfdf64..6aecc0f 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -1,11 +1,11 @@
apply plugin: 'com.android.application'
android {
- compileSdkVersion 26
+ compileSdkVersion 28
defaultConfig {
- applicationId "com.example.admin.navbottom"
- minSdkVersion 19
- targetSdkVersion 26
+ applicationId "com.madprateek.jecrcpay"
+ minSdkVersion 21
+ targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
@@ -20,19 +20,11 @@ android {
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
- implementation 'com.android.support:appcompat-v7:26.1.0'
- implementation 'com.android.support:design:26.1.0'
- implementation 'com.android.support.constraint:constraint-layout:1.1.1'
- implementation 'com.android.support:support-vector-drawable:26.1.0'
- implementation 'com.google.firebase:firebase-core:16.0.0'
+ implementation 'com.android.support:appcompat-v7:28.0.0'
+ implementation 'com.android.support.constraint:constraint-layout:1.1.3'
+ implementation 'com.android.support:recyclerview-v7:28.0.0'
+ implementation 'com.android.support:cardview-v7:28.0.0'
testImplementation 'junit:junit:4.12'
- implementation 'com.squareup.retrofit2:retrofit:2.2.0'
- implementation 'com.squareup.retrofit2:converter-gson:2.2.0'
- implementation files('libs/PGSDK_V2.1.jar')
- implementation 'de.hdodenhof:circleimageview:1.2.1'
- implementation 'com.google.firebase:firebase-auth:16.0.2'
- implementation 'com.google.firebase:firebase-messaging:17.0.0'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
}
-apply plugin: 'com.google.gms.google-services'
diff --git a/app/google-services.json b/app/google-services.json
deleted file mode 100644
index e70f8ac..0000000
--- a/app/google-services.json
+++ /dev/null
@@ -1,46 +0,0 @@
-{
- "project_info": {
- "project_number": "266053633306",
- "firebase_url": "https://bloodyef-5d90d.firebaseio.com",
- "project_id": "bloodyef-5d90d",
- "storage_bucket": "bloodyef-5d90d.appspot.com"
- },
- "client": [
- {
- "client_info": {
- "mobilesdk_app_id": "1:266053633306:android:16be06cc99bd4a91",
- "android_client_info": {
- "package_name": "com.example.admin.navbottom"
- }
- },
- "oauth_client": [
- {
- "client_id": "266053633306-fsslq7h5e4roig8v0444jgs0smlk5oig.apps.googleusercontent.com",
- "client_type": 3
- },
- {
- "client_id": "266053633306-fsslq7h5e4roig8v0444jgs0smlk5oig.apps.googleusercontent.com",
- "client_type": 3
- }
- ],
- "api_key": [
- {
- "current_key": "AIzaSyAMGKmVcnuGiiyVqNYM9je7yCcpIXXDfuE"
- }
- ],
- "services": {
- "analytics_service": {
- "status": 1
- },
- "appinvite_service": {
- "status": 1,
- "other_platform_oauth_client": []
- },
- "ads_service": {
- "status": 2
- }
- }
- }
- ],
- "configuration_version": "1"
-}
\ No newline at end of file
diff --git a/app/libs/PGSDK_V2.1.jar b/app/libs/PGSDK_V2.1.jar
deleted file mode 100644
index 4572a9c..0000000
Binary files a/app/libs/PGSDK_V2.1.jar and /dev/null differ
diff --git a/app/src/androidTest/java/com/example/admin/navbottom/ExampleInstrumentedTest.java b/app/src/androidTest/java/com/madprateek/jecrcpay/ExampleInstrumentedTest.java
similarity index 83%
rename from app/src/androidTest/java/com/example/admin/navbottom/ExampleInstrumentedTest.java
rename to app/src/androidTest/java/com/madprateek/jecrcpay/ExampleInstrumentedTest.java
index 7324d86..8dc2218 100644
--- a/app/src/androidTest/java/com/example/admin/navbottom/ExampleInstrumentedTest.java
+++ b/app/src/androidTest/java/com/madprateek/jecrcpay/ExampleInstrumentedTest.java
@@ -1,4 +1,4 @@
-package com.example.admin.navbottom;
+package com.madprateek.jecrcpay;
import android.content.Context;
import android.support.test.InstrumentationRegistry;
@@ -21,6 +21,6 @@ public void useAppContext() {
// Context of the app under test.
Context appContext = InstrumentationRegistry.getTargetContext();
- assertEquals("com.example.admin.navbottom", appContext.getPackageName());
+ assertEquals("com.madprateek.jecrcpay", appContext.getPackageName());
}
}
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 17c6840..4e3b24b 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -1,58 +1,22 @@
-
-
-
-
-
-
-
-
+ package="com.madprateek.jecrcpay">
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
\ No newline at end of file
diff --git a/app/src/main/ic_launcher-web.png b/app/src/main/ic_launcher-web.png
deleted file mode 100644
index d90a5f5..0000000
Binary files a/app/src/main/ic_launcher-web.png and /dev/null differ
diff --git a/app/src/main/java/com/example/admin/navbottom/Activities/Events.java b/app/src/main/java/com/example/admin/navbottom/Activities/Events.java
deleted file mode 100644
index 83be94c..0000000
--- a/app/src/main/java/com/example/admin/navbottom/Activities/Events.java
+++ /dev/null
@@ -1,27 +0,0 @@
-package com.example.admin.navbottom.Activities;
-
-import android.content.Intent;
-import android.support.v7.app.AppCompatActivity;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.ImageView;
-
-import com.example.admin.navbottom.R;
-
-public class Events extends AppCompatActivity {
-ImageView i;
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_events);
- i=findViewById(R.id.events);
- i.setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View view) {
- Intent i=new Intent(getApplicationContext(),MUNActivity.class);
- startActivity(i);
- }
- });
-
- }
-}
diff --git a/app/src/main/java/com/example/admin/navbottom/Activities/LoginActivity.java b/app/src/main/java/com/example/admin/navbottom/Activities/LoginActivity.java
deleted file mode 100644
index 6d382d7..0000000
--- a/app/src/main/java/com/example/admin/navbottom/Activities/LoginActivity.java
+++ /dev/null
@@ -1,110 +0,0 @@
-package com.example.admin.navbottom.Activities;
-
-import android.app.ProgressDialog;
-import android.content.Intent;
-import android.support.annotation.NonNull;
-import android.support.v7.app.AppCompatActivity;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.Button;
-import android.widget.EditText;
-import android.widget.TextView;
-import android.widget.Toast;
-
-import com.example.admin.navbottom.R;
-import com.google.android.gms.tasks.OnCompleteListener;
-import com.google.android.gms.tasks.Task;
-import com.google.firebase.auth.AuthResult;
-import com.google.firebase.auth.FirebaseAuth;
-
-public class LoginActivity extends AppCompatActivity {
- private FirebaseAuth mfirebaseAuth;
- private int counter =5;
- private EditText mUsername,mPassword;
- private TextView SIGNUP;
- private Button login;
- private ProgressDialog progressDialog;
- private TextView mAttemptText;
- String namegive;
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_login);
-
- mUsername=(EditText)findViewById(R.id.username);
- mPassword=(EditText)findViewById(R.id.password);
- login=(Button)findViewById(R.id.loginn);
- mfirebaseAuth= FirebaseAuth.getInstance();
- SIGNUP=(TextView)findViewById(R.id.button2);
- mAttemptText=(TextView)findViewById(R.id.textView);
- progressDialog=new ProgressDialog(this);
- android.support.v7.app.ActionBar actionBar = getSupportActionBar();
- actionBar.setDisplayShowHomeEnabled(true);
- actionBar.setIcon(R.mipmap.white);
-
- //to check current user
- if(mfirebaseAuth.getCurrentUser()!=null)
- {
- finish();
- startActivity(new Intent(getApplicationContext(),MainActivity.class));
-
- }
-
- SIGNUP.setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View view) {
- Intent i=new Intent(getApplicationContext(),RegisterActivity.class);
- startActivity(i);
- finish();
- }
- });
-
- login.setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View view) {
- try{
-
- validate();
- }catch (Exception e){
- Toast.makeText(LoginActivity.this, ""+e, Toast.LENGTH_SHORT).show();
- }
- }
- });
-
-
- }
- private void validate()
- { String User=mUsername.getText().toString().trim();
- String Pass=mPassword.getText().toString().trim();
-
-
-
- progressDialog.setMessage("Loading...");
- progressDialog.show();
-
- mfirebaseAuth.signInWithEmailAndPassword(User,Pass).addOnCompleteListener(new OnCompleteListener() { //ADDCLICK ON LISTENER IS USED TO CHECK THAT THE TASK IS SUCCESSFUL OR NOT
- @Override
- public void onComplete(@NonNull Task task) {
- if(task.isSuccessful())
- { progressDialog.dismiss();
- Toast.makeText(getApplicationContext(), "LoginActivity success!", Toast.LENGTH_SHORT).show();
- Intent i=new Intent(getApplicationContext(), MainActivity.class);
- startActivity(i);
- finish();
-
- }
- else
- {progressDialog.dismiss();
- Toast.makeText(getApplicationContext(), "LoginActivity Failed!", Toast.LENGTH_SHORT).show();
- counter--;
- mAttemptText.setText("No. of Attempts Remaining "+ String.valueOf(counter));
- if(counter==0)
- login.setEnabled(false);
-
- }
- }
- });
- }
-
-}
-
diff --git a/app/src/main/java/com/example/admin/navbottom/Activities/MUNActivity.java b/app/src/main/java/com/example/admin/navbottom/Activities/MUNActivity.java
deleted file mode 100644
index 0a0d545..0000000
--- a/app/src/main/java/com/example/admin/navbottom/Activities/MUNActivity.java
+++ /dev/null
@@ -1,171 +0,0 @@
-package com.example.admin.navbottom.Activities;
-
-import android.support.v7.app.AppCompatActivity;
-import android.os.Bundle;
-import android.view.View;
-import android.widget.Button;
-import android.widget.TextView;
-import android.widget.Toast;
-
-import com.example.admin.navbottom.Api;
-import com.example.admin.navbottom.ModelClasses.Constants;
-import com.example.admin.navbottom.PaytmClasses.Checksum;
-import com.example.admin.navbottom.PaytmClasses.Paytm;
-import com.example.admin.navbottom.R;
-import com.paytm.pgsdk.PaytmOrder;
-import com.paytm.pgsdk.PaytmPGService;
-import com.paytm.pgsdk.PaytmPaymentTransactionCallback;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import retrofit2.Call;
-import retrofit2.Callback;
-import retrofit2.Response;
-import retrofit2.Retrofit;
-import retrofit2.converter.gson.GsonConverterFactory;
-
-public class MUNActivity extends AppCompatActivity implements PaytmPaymentTransactionCallback {
- TextView textViewPrice;
- Button b;
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_mun);
- textViewPrice = findViewById(R.id.textViewPrice);
-
-
- //attaching a click listener to the button buy
- findViewById(R.id.apply_del).setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View view) {
-
- //calling the method generateCheckSum() which will generate the paytm checksum for payment
- generateCheckSum();
- }
- });
-
- }
- private void generateCheckSum() {
-
- //getting the tax amount first.
- String txnAmount = textViewPrice.getText().toString().trim();
-
- //creating a retrofit object.
- Retrofit retrofit = new Retrofit.Builder()
- .baseUrl(Api.BASE_URL)
- .addConverterFactory(GsonConverterFactory.create())
- .build();
-
- //creating the retrofit api service
- Api apiService = retrofit.create(Api.class);
-
- //creating paytm object
- //containing all the values required
- final Paytm paytm = new Paytm(
- Constants.M_ID,
- Constants.CHANNEL_ID,
- txnAmount,
- Constants.WEBSITE,
- Constants.CALLBACK_URL,
- Constants.INDUSTRY_TYPE_ID
- );
-
- //creating a call object from the apiService
- Call call = apiService.getChecksum(
- paytm.getmId(),
- paytm.getOrderId(),
- paytm.getCustId(),
- paytm.getChannelId(),
- paytm.getTxnAmount(),
- paytm.getWebsite(),
- paytm.getCallBackUrl(),
- paytm.getIndustryTypeId()
- );
-
- //making the call to generate checksum
- call.enqueue(new Callback() {
- @Override
- public void onResponse(Call call, Response response) {
-
- //once we get the checksum we will initiailize the payment.
- //the method is taking the checksum we got and the paytm object as the parameter
- initializePaytmPayment(response.body().getChecksumHash(), paytm);
- }
-
- @Override
- public void onFailure(Call call, Throwable t) {
-
- }
- });
- }
-
- private void initializePaytmPayment(String checksumHash, Paytm paytm) {
-
- //getting paytm service
- PaytmPGService Service = PaytmPGService.getStagingService();
-
- //use this when using for production
- //PaytmPGService Service = PaytmPGService.getProductionService();
-
- //creating a hashmap and adding all the values required
- Map paramMap = new HashMap<>();
- paramMap.put("MID", Constants.M_ID);
- paramMap.put("ORDER_ID", paytm.getOrderId());
- paramMap.put("CUST_ID", paytm.getCustId());
- paramMap.put("CHANNEL_ID", paytm.getChannelId());
- paramMap.put("TXN_AMOUNT", paytm.getTxnAmount());
- paramMap.put("WEBSITE", paytm.getWebsite());
- paramMap.put("CALLBACK_URL", paytm.getCallBackUrl());
- paramMap.put("CHECKSUMHASH", checksumHash);
- paramMap.put("INDUSTRY_TYPE_ID", paytm.getIndustryTypeId());
-
-
- //creating a paytm order object using the hashmap
- PaytmOrder order = new PaytmOrder(paramMap);
-
- //intializing the paytm service
- Service.initialize(order, null);
-
- //finally starting the payment transaction
- Service.startPaymentTransaction(this, true, true, this);
-
- }
-
- //all these overriden method is to detect the payment result accordingly
- @Override
- public void onTransactionResponse(Bundle bundle) {
-
- Toast.makeText(this, bundle.toString(), Toast.LENGTH_LONG).show();
- }
-
- @Override
- public void networkNotAvailable() {
- Toast.makeText(this, "Network error", Toast.LENGTH_LONG).show();
- }
-
- @Override
- public void clientAuthenticationFailed(String s) {
- Toast.makeText(this, s, Toast.LENGTH_LONG).show();
- }
-
- @Override
- public void someUIErrorOccurred(String s) {
- Toast.makeText(this, s, Toast.LENGTH_LONG).show();
- }
-
- @Override
- public void onErrorLoadingWebPage(int i, String s, String s1) {
- Toast.makeText(this, s, Toast.LENGTH_LONG).show();
- }
-
- @Override
- public void onBackPressedCancelTransaction() {
- Toast.makeText(this, "Transaction cancelled!", Toast.LENGTH_LONG).show();
- }
-
- @Override
- public void onTransactionCancel(String s, Bundle bundle) {
- Toast.makeText(this, s + bundle.toString(), Toast.LENGTH_LONG).show();
- }
-}
diff --git a/app/src/main/java/com/example/admin/navbottom/Activities/MainActivity.java b/app/src/main/java/com/example/admin/navbottom/Activities/MainActivity.java
deleted file mode 100644
index da35273..0000000
--- a/app/src/main/java/com/example/admin/navbottom/Activities/MainActivity.java
+++ /dev/null
@@ -1,164 +0,0 @@
-package com.example.admin.navbottom.Activities;
-import android.content.Intent;
-import android.support.design.widget.FloatingActionButton;
-import android.support.design.widget.NavigationView;
-import android.support.v4.view.GravityCompat;
-import android.support.v4.widget.DrawerLayout;
-import android.os.Bundle;
-import android.support.annotation.NonNull;
-import android.support.design.widget.BottomNavigationView;
-import android.support.v7.app.ActionBarDrawerToggle;
-import android.support.v7.app.AppCompatActivity;
-import android.support.v7.widget.Toolbar;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.widget.TextView;
-import android.widget.Toast;
-
-import com.example.admin.navbottom.R;
-import com.google.firebase.auth.FirebaseAuth;
-import com.google.firebase.auth.FirebaseUser;
-
-public class MainActivity extends AppCompatActivity
- implements NavigationView.OnNavigationItemSelectedListener {
- private FirebaseAuth firebaseAuth1;
-
- String message;
-
- private BottomNavigationView.OnNavigationItemSelectedListener mOnNavigationItemSelectedListener
- = new BottomNavigationView.OnNavigationItemSelectedListener() {
-
-
- @Override
- public boolean onNavigationItemSelected(@NonNull MenuItem item) {
- switch (item.getItemId()) {
- case R.id.navigation_home:
- // mTextMessage.setText(R.string.title_home);
- return true;
- case R.id.navigation_dashboard:
- // mTextMessage.setText(R.string.title_dashboard);
- return true;
- case R.id.navigation_notifications:
- // mTextMessage.setText(R.string.title_notifications);
- return true;
- }
- return false;
- }
- };
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_main);
-
-
-
- firebaseAuth1 = FirebaseAuth.getInstance();
-
- if (firebaseAuth1.getCurrentUser() == null) {
- finish();
- startActivity(new Intent(getApplicationContext(), LoginActivity.class));
- }
- FirebaseUser firebaseUser = firebaseAuth1.getCurrentUser();
- if(firebaseUser!=null)
- {
- NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
- View headerView = navigationView.getHeaderView(0);
- TextView navUsername = (TextView) headerView.findViewById(R.id.user124);
- navUsername.setText(firebaseUser.getDisplayName());
- TextView navemail = (TextView) headerView.findViewById(R.id.email);
- navemail.setText(firebaseUser.getEmail());
-
- }
-
-
-
- FloatingActionButton signout11 = (FloatingActionButton) findViewById(R.id.fab);
-
- signout11.setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View view) {
- firebaseAuth1.signOut();
- Toast.makeText(MainActivity.this, "Successfuly Logged Out!", Toast.LENGTH_SHORT).show();
- finish();
- startActivity(new Intent(getApplicationContext(), LoginActivity.class));
- }
- });
-
-
-
- BottomNavigationView navigation = (BottomNavigationView) findViewById(R.id.navigation);
- navigation.setOnNavigationItemSelectedListener(mOnNavigationItemSelectedListener);
-
-
- Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
- setSupportActionBar(toolbar);
-
-
-
- DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
- ActionBarDrawerToggle toggle = new ActionBarDrawerToggle(
- this, drawer, toolbar, R.string.navigation_drawer_open, R.string.navigation_drawer_close);
- drawer.addDrawerListener(toggle);
- toggle.syncState();
-
- NavigationView navigationView = (NavigationView) findViewById(R.id.nav_view);
- navigationView.setNavigationItemSelectedListener(this);
- }
-
- @Override
- public void onBackPressed() {
- DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
- if (drawer.isDrawerOpen(GravityCompat.START)) {
- drawer.closeDrawer(GravityCompat.START);
- } else {
- super.onBackPressed();
- }
- }
-
- @Override
- public boolean onCreateOptionsMenu(Menu menu) {
- // Inflate the menu; this adds items to the action bar if it is present.
- getMenuInflater().inflate(R.menu.main, menu);
- return true;
- }
-
- @Override
- public boolean onOptionsItemSelected(MenuItem item) {
- // Handle action bar item clicks here. The action bar will
- // automatically handle clicks on the Home/Up button, so long
- // as you specify a parent activity in AndroidManifest.xml.
- int id = item.getItemId();
-
- //noinspection SimplifiableIfStatement
- if (id == R.id.action_settings) {
- return true;
- }
-
- return super.onOptionsItemSelected(item);
- }
-
- @SuppressWarnings("StatementWithEmptyBody")
- @Override
- public boolean onNavigationItemSelected(MenuItem item) {
- // Handle navigation view item clicks here.
- int id = item.getItemId();
-
- if (id == R.id.nav_camera) {
- // Handle the camera action
- } else if (id == R.id.nav_gallery) {
-
- } else if (id == R.id.nav_slideshow) {
-
- } else if (id == R.id.nav_manage) {
-Intent i=new Intent(getApplicationContext(),Events.class);
-startActivity(i);
- } else if (id == R.id.nav_share) {
-
- }
-
- DrawerLayout drawer = (DrawerLayout) findViewById(R.id.drawer_layout);
- drawer.closeDrawer(GravityCompat.START);
- return true;
- }
-}
diff --git a/app/src/main/java/com/example/admin/navbottom/Activities/RegisterActivity.java b/app/src/main/java/com/example/admin/navbottom/Activities/RegisterActivity.java
deleted file mode 100644
index 7b52f2c..0000000
--- a/app/src/main/java/com/example/admin/navbottom/Activities/RegisterActivity.java
+++ /dev/null
@@ -1,119 +0,0 @@
-package com.example.admin.navbottom.Activities;
-
-import android.app.ProgressDialog;
-import android.content.Intent;
-import android.support.annotation.NonNull;
-import android.support.v7.app.AppCompatActivity;
-import android.os.Bundle;
-import android.util.Log;
-import android.view.View;
-import android.widget.Button;
-import android.widget.EditText;
-import android.widget.Toast;
-
-import com.example.admin.navbottom.R;
-import com.google.android.gms.tasks.OnCompleteListener;
-import com.google.android.gms.tasks.Task;
-import com.google.firebase.auth.AuthResult;
-import com.google.firebase.auth.FirebaseAuth;
-import com.google.firebase.auth.FirebaseUser;
-import com.google.firebase.auth.UserProfileChangeRequest;
-
-public class RegisterActivity extends AppCompatActivity {
- EditText e1,e2,e3,e4,e5;
- Button b;
- private ProgressDialog progressDialog;
- private FirebaseAuth firebaseAuth;
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_signup);
- e1=(EditText)findViewById(R.id.name);
- e2=(EditText)findViewById(R.id.user);
-
- e4=(EditText)findViewById(R.id.pass);
- // e5=(EditText)findViewById(R.id.editText10);
- progressDialog=new ProgressDialog(this);
- b=(Button)findViewById(R.id.button3);
- firebaseAuth= FirebaseAuth.getInstance();
- b.setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View view) {
- if(validate())
- {
-
- //upload the data in the database
-
- String usernamewe=e2.getText().toString().trim();
- String password=e4.getText().toString().trim(); //trim is used to remove any white spaces
- progressDialog.setMessage("Loading...");
- progressDialog.show();
-
- firebaseAuth.createUserWithEmailAndPassword(usernamewe,password).addOnCompleteListener(new OnCompleteListener() {
- @Override
- public void onComplete(@NonNull Task task) {
- if(task.isSuccessful()) {
- userprofile();
- progressDialog.dismiss();
- Toast.makeText(getApplicationContext(), "Account Created Successfully!", Toast.LENGTH_SHORT).show();
- progressDialog.setMessage("Loading...");
- progressDialog.show();
- firebaseAuth.signOut();
- finish();
- progressDialog.setMessage("Loading...");
- progressDialog.show();
- Toast.makeText(RegisterActivity.this, "Please LoginActivity to continue!", Toast.LENGTH_SHORT).show();
- Intent i=new Intent(getApplicationContext(),LoginActivity.class);
- startActivity(i);
-
-
-
-
-
- }
- else
- Toast.makeText(getApplicationContext(), " Failed!", Toast.LENGTH_SHORT).show();
- progressDialog.dismiss();
- }
- });
-
-
-
-
- }
- }
- });
- }
-
-
- private Boolean validate() {
- Boolean result = false;
- String name = e1.getText().toString();
- String email = e2.getText().toString();
- // String phone = e3.getText().toString();
-
- if (name.isEmpty() || email.isEmpty()) {
- Toast.makeText(this, "Please Enter Details!", Toast.LENGTH_SHORT).show();
-
- } else
- result = true;
- return result;
- }
- private void userprofile() {
- FirebaseUser user = FirebaseAuth.getInstance().getCurrentUser();
- if (user != null) {
- UserProfileChangeRequest userProfileChangeRequest = new UserProfileChangeRequest.Builder()
- .setDisplayName(e1.getText().toString())
- .build();
- // Toast.makeText(signup.this, "name updated", Toast.LENGTH_SHORT).show();
- user.updateProfile(userProfileChangeRequest).addOnCompleteListener(new OnCompleteListener() {
- @Override
- public void onComplete(@NonNull Task task) {
- if (task.isSuccessful()) {
- Log.d("Testing", "user profile updated");
- }
- }
- });
- }
- }
-}
diff --git a/app/src/main/java/com/example/admin/navbottom/Api.java b/app/src/main/java/com/example/admin/navbottom/Api.java
deleted file mode 100644
index 3d3aa71..0000000
--- a/app/src/main/java/com/example/admin/navbottom/Api.java
+++ /dev/null
@@ -1,33 +0,0 @@
-package com.example.admin.navbottom;
-
-import com.example.admin.navbottom.PaytmClasses.Checksum;
-
-import retrofit2.Call;
-import retrofit2.http.Field;
-import retrofit2.http.FormUrlEncoded;
-import retrofit2.http.POST;
-
-/**
- * Created by Belal on 1/10/2018.
- */
-
-public interface Api {
-
- //this is the URL of the paytm folder that we added in the server
- //make sure you are using your ip else it will not work
- String BASE_URL = "http:///YOUR IP/paytm/"; //HERE YOUR IP ADDRESS KEEP IN MIND THAT YOUR LOCAL SERVER and device should be in the same network
-
- @FormUrlEncoded
- @POST("generateChecksum.php")
- Call getChecksum(
- @Field("MID") String mId,
- @Field("ORDER_ID") String orderId,
- @Field("CUST_ID") String custId,
- @Field("CHANNEL_ID") String channelId,
- @Field("TXN_AMOUNT") String txnAmount,
- @Field("WEBSITE") String website,
- @Field("CALLBACK_URL") String callbackUrl,
- @Field("INDUSTRY_TYPE_ID") String industryTypeId
- );
-
-}
diff --git a/app/src/main/java/com/example/admin/navbottom/ModelClasses/Constants.java b/app/src/main/java/com/example/admin/navbottom/ModelClasses/Constants.java
deleted file mode 100644
index 6dfe576..0000000
--- a/app/src/main/java/com/example/admin/navbottom/ModelClasses/Constants.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package com.example.admin.navbottom.ModelClasses;
-
-public class Constants {
- public static final String M_ID = "DIY12386817555501617"; //Paytm Merchand Id we got it in paytm credentials
- public static final String CHANNEL_ID = "WAP"; //Paytm Channel Id, got it in paytm credentials
- public static final String INDUSTRY_TYPE_ID = "Retail"; //Paytm industry type got it in paytm credential
-
-
- public static final String WEBSITE = "DIYtestingwap";//THIS IS STAGING
- public static final String CALLBACK_URL = "https://pguat.paytm.com/paytmchecksum/paytmCallback.jsp";
-
-}
-
-
-
diff --git a/app/src/main/java/com/example/admin/navbottom/PaytmClasses/Checksum.java b/app/src/main/java/com/example/admin/navbottom/PaytmClasses/Checksum.java
deleted file mode 100644
index cd360ff..0000000
--- a/app/src/main/java/com/example/admin/navbottom/PaytmClasses/Checksum.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package com.example.admin.navbottom.PaytmClasses;
-
-import com.google.gson.annotations.SerializedName;
-
-/**
- * Created by Belal on 1/10/2018.
- */
-
-public class Checksum {
-
- @SerializedName("CHECKSUMHASH")
- private String checksumHash;
-
- @SerializedName("ORDER_ID")
- private String orderId;
-
- @SerializedName("payt_STATUS")
- private String paytStatus;
-
- public Checksum(String checksumHash, String orderId, String paytStatus) {
- this.checksumHash = checksumHash;
- this.orderId = orderId;
- this.paytStatus = paytStatus;
- }
-
- public String getChecksumHash(){
- return checksumHash;
- }
-
- public String getOrderId() {
- return orderId;
- }
-
- public String getPaytStatus() {
- return paytStatus;
- }
-}
\ No newline at end of file
diff --git a/app/src/main/java/com/example/admin/navbottom/PaytmClasses/Paytm.java b/app/src/main/java/com/example/admin/navbottom/PaytmClasses/Paytm.java
deleted file mode 100644
index 37a3c2b..0000000
--- a/app/src/main/java/com/example/admin/navbottom/PaytmClasses/Paytm.java
+++ /dev/null
@@ -1,94 +0,0 @@
-package com.example.admin.navbottom.PaytmClasses;
-
-import android.util.Log;
-
-import com.google.gson.annotations.SerializedName;
-
-import java.util.UUID;
-
-/**
- * Created by Belal on 1/10/2018.
- */
-
-public class Paytm {
-
- @SerializedName("MID")
- String mId;
-
- @SerializedName("ORDER_ID")
- String orderId;
-
- @SerializedName("CUST_ID")
- String custId;
-
- @SerializedName("CHANNEL_ID")
- String channelId;
-
- @SerializedName("TXN_AMOUNT")
- String txnAmount;
-
- @SerializedName("WEBSITE")
- String website;
-
- @SerializedName("CALLBACK_URL")
- String callBackUrl;
-
- @SerializedName("INDUSTRY_TYPE_ID")
- String industryTypeId;
-
- public Paytm(String mId, String channelId, String txnAmount, String website, String callBackUrl, String industryTypeId) {
- this.mId = mId;
- this.orderId = generateString();
- this.custId = generateString();
- this.channelId = channelId;
- this.txnAmount = txnAmount;
- this.website = website;
- this.callBackUrl = callBackUrl;
- this.industryTypeId = industryTypeId;
-
- Log.d("orderId", orderId);
- Log.d("customerId", custId);
- }
-
- public String getmId() {
- return mId;
- }
-
- public String getOrderId() {
- return orderId;
- }
-
- public String getCustId() {
- return custId;
- }
-
- public String getChannelId() {
- return channelId;
- }
-
- public String getTxnAmount() {
- return txnAmount;
- }
-
- public String getWebsite() {
- return website;
- }
-
- public String getCallBackUrl() {
- return callBackUrl;
- }
-
- public String getIndustryTypeId() {
- return industryTypeId;
- }
-
- /*
- * The following method we are using to generate a random string everytime
- * As we need a unique customer id and order id everytime
- * For real scenario you can implement it with your own application logic
- * */
- private String generateString() {
- String uuid = UUID.randomUUID().toString();
- return uuid.replaceAll("-", "");
- }
-}
diff --git a/app/src/main/java/com/example/admin/navbottom/ServiceClasses/MyFirebaseInstanceIDService.java b/app/src/main/java/com/example/admin/navbottom/ServiceClasses/MyFirebaseInstanceIDService.java
deleted file mode 100644
index 58c28be..0000000
--- a/app/src/main/java/com/example/admin/navbottom/ServiceClasses/MyFirebaseInstanceIDService.java
+++ /dev/null
@@ -1,20 +0,0 @@
-package com.example.admin.navbottom.ServiceClasses;
-
-import android.util.Log;
-
-import com.google.firebase.iid.FirebaseInstanceId;
-import com.google.firebase.iid.FirebaseInstanceIdService;
-
-public class MyFirebaseInstanceIDService
- extends FirebaseInstanceIdService
-
- {
- private static final String TAG = "MyFirebaseInsIDService";
-
- @Override
- public void onTokenRefresh () {
- //getupdatetoken
- String refreshedToken = FirebaseInstanceId.getInstance().getToken();
- Log.d(TAG, "New Token" + refreshedToken);
- }
- }
\ No newline at end of file
diff --git a/app/src/main/java/com/example/admin/navbottom/ServiceClasses/MyFirebaseMessagingService.java b/app/src/main/java/com/example/admin/navbottom/ServiceClasses/MyFirebaseMessagingService.java
deleted file mode 100644
index fd3c54e..0000000
--- a/app/src/main/java/com/example/admin/navbottom/ServiceClasses/MyFirebaseMessagingService.java
+++ /dev/null
@@ -1,123 +0,0 @@
-package com.example.admin.navbottom.ServiceClasses;
-
-import android.app.NotificationManager;
-import android.app.PendingIntent;
-import android.content.Context;
-import android.content.Intent;
-import android.graphics.Bitmap;
-import android.graphics.BitmapFactory;
-import android.media.RingtoneManager;
-import android.net.Uri;
-import android.support.v4.app.NotificationCompat;
-import android.util.Log;
-
-import com.example.admin.navbottom.Activities.MainActivity;
-import com.example.admin.navbottom.R;
-import com.google.firebase.messaging.FirebaseMessagingService;
-import com.google.firebase.messaging.RemoteMessage;
-
-import java.io.InputStream;
-import java.net.HttpURLConnection;
-import java.net.URL;
-
-public class MyFirebaseMessagingService extends FirebaseMessagingService {
-
- private static final String TAG = "FirebaseMessageService";
- Bitmap bitmap;
-
- /**
- * Called when message is received.
- *
- * @param remoteMessage Object representing the message received from Firebase Cloud Messaging.
- */
- @Override
- public void onMessageReceived(RemoteMessage remoteMessage) {
- // There are two types of messages data messages and notification messages. Data messages are handled
- // here in onMessageReceived whether the app is in the foreground or background. Data messages are the type
- // traditionally used with GCM. Notification messages are only received here in onMessageReceived when the app
- // is in the foreground. When the app is in the background an automatically generated notification is displayed.
- // When the user taps on the notification they are returned to the app. Messages containing both notification
- // and data payloads are treated as notification messages. The Firebase console always sends notification
- // messages. For more see: https://firebase.google.com/docs/cloud-messaging/concept-options
- //
- Log.d(TAG, "From: " + remoteMessage.getFrom());
-
- // Check if message contains a data payload.
- if (remoteMessage.getData().size() > 0) {
- Log.d(TAG, "Message data payload: " + remoteMessage.getData());
- }
-
- // Check if message contains a notification payload.
- if (remoteMessage.getNotification() != null) {
- Log.d(TAG, "Message Notification Body: " + remoteMessage.getNotification().getBody());
- }
-
- //The message which i send will have keys named [message, image, AnotherActivity] and corresponding values.
- //You can change as per the requirement.
-
- //message will contain the Push Message
- String message = remoteMessage.getData().get("message");
- //imageUri will contain URL of the image to be displayed with Notification
- String imageUri = remoteMessage.getData().get("image");
- //If the key AnotherActivity has value as True then when the user taps on notification, in the app AnotherActivity will be opened.
- //If the key AnotherActivity has value as False then when the user taps on notification, in the app MainActivity will be opened.
- String TrueOrFlase = remoteMessage.getData().get("MainActivity");
-
- //To get a Bitmap image from the URL received
- bitmap = getBitmapfromUrl(imageUri);
-
- sendNotification(message, bitmap, TrueOrFlase);
-
- }
-
-
- /**
- * Create and show a simple notification containing the received FCM message.
- */
-
- private void sendNotification(String messageBody, Bitmap image, String TrueOrFalse) {
- Intent intent = new Intent(this, MainActivity.class);
- intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
- intent.putExtra("MainActivity", TrueOrFalse);
- PendingIntent pendingIntent = PendingIntent.getActivity(this, 0 /* Request code */, intent,
- PendingIntent.FLAG_ONE_SHOT);
-
- Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);
- NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this)
- .setLargeIcon(image)/*Notification icon image*/
- .setSmallIcon(R.drawable.jecrc)
- .setContentTitle(messageBody)
- .setStyle(new NotificationCompat.BigPictureStyle()
- .bigPicture(image))/*Notification with Image*/
- .setAutoCancel(true)
- .setSound(defaultSoundUri)
- .setContentIntent(pendingIntent);
-
- NotificationManager notificationManager =
- (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);
-
- notificationManager.notify(0 /* ID of notification */, notificationBuilder.build());
- }
-
- /*
- *To get a Bitmap image from the URL received
- * */
- public Bitmap getBitmapfromUrl(String imageUrl) {
- try {
- URL url = new URL(imageUrl);
- HttpURLConnection connection = (HttpURLConnection) url.openConnection();
- connection.setDoInput(true);
- connection.connect();
- InputStream input = connection.getInputStream();
- Bitmap bitmap = BitmapFactory.decodeStream(input);
- return bitmap;
-
- } catch (Exception e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- return null;
-
- }
- }
-}
-
diff --git a/app/src/main/java/com/example/admin/navbottom/splash.java b/app/src/main/java/com/example/admin/navbottom/splash.java
deleted file mode 100644
index e5052d6..0000000
--- a/app/src/main/java/com/example/admin/navbottom/splash.java
+++ /dev/null
@@ -1,51 +0,0 @@
-package com.example.admin.navbottom;
-
-
-import android.content.Intent;
-import android.support.v7.app.AppCompatActivity;
-import android.os.Bundle;
-import android.widget.ProgressBar;
-
-import com.example.admin.navbottom.Activities.LoginActivity;
-
-public class splash extends AppCompatActivity {
-ProgressBar p;
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_splash);
-
- android.support.v7.app.ActionBar actionBar = getSupportActionBar();
- actionBar.setDisplayShowHomeEnabled(true);
- actionBar.setIcon(R.mipmap.white);
- p=(ProgressBar)findViewById(R.id.progressBar);
- p.setMax(100);
- p.setProgress(0);
- Thread t=new Thread()
- {
- @Override
- public void run() {
- super.run();
- try{
- for(int i=0;i<100;i++)
-
- {
-
- p.setProgress(i);
- sleep(20);
- }
- }catch(Exception e)
- {
- e.printStackTrace();
- }
- finally {
- Intent i;
- i=new Intent(getApplicationContext(),LoginActivity.class);
- startActivity(i);
- finish();
- }
- }
- };t.start();
-
- }
-}
diff --git a/app/src/main/java/com/madprateek/jecrcpay/ActivityClasses/HomeActivity.java b/app/src/main/java/com/madprateek/jecrcpay/ActivityClasses/HomeActivity.java
new file mode 100644
index 0000000..e9a632c
--- /dev/null
+++ b/app/src/main/java/com/madprateek/jecrcpay/ActivityClasses/HomeActivity.java
@@ -0,0 +1,26 @@
+package com.madprateek.jecrcpay.ActivityClasses;
+
+import android.os.Bundle;
+import android.support.v7.app.AppCompatActivity;
+import android.support.v7.widget.Toolbar;
+
+import com.madprateek.jecrcpay.HelperClasses.SessionManager;
+import com.madprateek.jecrcpay.R;
+
+
+public class HomeActivity extends AppCompatActivity {
+
+ SessionManager session;
+ private Toolbar mToolbar;
+ @Override
+ protected void onCreate(Bundle savedInstanceState) {
+ super.onCreate(savedInstanceState);
+ setContentView(R.layout.activity_home);
+ mToolbar = (Toolbar) findViewById(R.id.homeToolBar);
+ setSupportActionBar(mToolbar);
+ getSupportActionBar().setTitle("JECRC Pay");
+
+ session = new SessionManager(HomeActivity.this);
+ session.checkLogin();
+ }
+}
diff --git a/app/src/main/java/com/madprateek/jecrcpay/ActivityClasses/MainActivity.java b/app/src/main/java/com/madprateek/jecrcpay/ActivityClasses/MainActivity.java
new file mode 100644
index 0000000..684ccd7
--- /dev/null
+++ b/app/src/main/java/com/madprateek/jecrcpay/ActivityClasses/MainActivity.java
@@ -0,0 +1,44 @@
+package com.madprateek.jecrcpay.ActivityClasses;
+
+import android.content.Intent;
+import android.os.Bundle;
+import android.support.v7.app.AppCompatActivity;
+import android.view.View;
+import android.widget.Button;
+import android.widget.EditText;
+
+import com.madprateek.jecrcpay.HelperClasses.SessionManager;
+import com.madprateek.jecrcpay.R;
+
+public class MainActivity extends AppCompatActivity {
+
+ private EditText mNameText, mMobileText;
+ private Button mSubmitBtn;
+ private SessionManager session;
+ @Override
+ protected void onCreate(Bundle savedInstanceState) {
+ super.onCreate(savedInstanceState);
+ setContentView(R.layout.activity_main);
+
+ mNameText = (EditText) findViewById(R.id.nameText);
+ mMobileText = (EditText) findViewById(R.id.mobileNoText);
+ mSubmitBtn = (Button) findViewById(R.id.submitBtn);
+ session = new SessionManager(getApplicationContext());
+
+ mSubmitBtn.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ String name = mNameText.getText().toString();
+ String number = mMobileText.getText().toString();
+ loginUser(name, number);
+ }
+ });
+ }
+
+ private void loginUser(String name, String number) {
+ session.createLoginSession(name,number);
+ Intent intent = new Intent(MainActivity.this,HomeActivity.class);
+ startActivity(intent);
+ finish();
+ }
+}
diff --git a/app/src/main/java/com/madprateek/jecrcpay/HelperClasses/SessionManager.java b/app/src/main/java/com/madprateek/jecrcpay/HelperClasses/SessionManager.java
new file mode 100644
index 0000000..b19d3c3
--- /dev/null
+++ b/app/src/main/java/com/madprateek/jecrcpay/HelperClasses/SessionManager.java
@@ -0,0 +1,78 @@
+package com.madprateek.jecrcpay.HelperClasses;
+
+import android.app.Activity;
+import android.content.Context;
+import android.content.Intent;
+import android.content.SharedPreferences;
+
+import com.madprateek.jecrcpay.ActivityClasses.MainActivity;
+
+public class SessionManager {
+
+ SharedPreferences sharedPref;
+ SharedPreferences.Editor editor;
+ Context context;
+ int PRIVATE_MODE = 0;
+
+ private static final String PREF_NAME = "jecrcPayPref";
+ private static final String IS_LOGIN = "IsLoggedIn";
+ public static final String KEY_NAME = "name";
+ public static final String KEY_NO = "mobileNo";
+
+ public SessionManager(Context context){
+ this.context = context;
+ sharedPref = context.getSharedPreferences(PREF_NAME, PRIVATE_MODE);
+ editor = sharedPref.edit();
+ }
+
+ public void createLoginSession(String username, String mobileNo){
+ // Storing login value as TRUE
+ editor.putBoolean(IS_LOGIN, true);
+
+ // Storing name in pref
+ editor.putString(KEY_NAME, username);
+ editor.putString(KEY_NO, mobileNo);
+
+ // commit changes
+ editor.commit();
+ }
+
+ public void checkLogin(){
+ // Check login status
+ if(!this.isLoggedIn()){
+ // user is not logged in redirect him to Login Activity
+ Intent i = new Intent(context, MainActivity.class);
+ // Closing all the Activities
+ i.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
+
+ // Add new Flag to start new Activity
+ i.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
+
+ // Staring Login Activity
+ context.startActivity(i);
+ ((Activity) context).finish();
+ }
+
+ }
+
+ public void logoutUser(){
+ // Clearing all data from Shared Preferences
+ editor.clear();
+ editor.commit();
+
+ // After logout redirect user to Loing Activity
+ Intent i = new Intent(context, MainActivity.class);
+ // Closing all the Activities
+ i.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
+
+ // Add new Flag to start new Activity
+ i.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
+
+ // Staring Login Activity
+ context.startActivity(i);
+ }
+
+ public boolean isLoggedIn(){
+ return sharedPref.getBoolean(IS_LOGIN, false);
+ }
+}
diff --git a/app/src/main/res/drawable-v21/ic_menu_camera.xml b/app/src/main/res/drawable-v21/ic_menu_camera.xml
deleted file mode 100644
index 0d9ea10..0000000
--- a/app/src/main/res/drawable-v21/ic_menu_camera.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-
-
-
-
diff --git a/app/src/main/res/drawable-v21/ic_menu_gallery.xml b/app/src/main/res/drawable-v21/ic_menu_gallery.xml
deleted file mode 100644
index f6872c4..0000000
--- a/app/src/main/res/drawable-v21/ic_menu_gallery.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/app/src/main/res/drawable-v21/ic_menu_manage.xml b/app/src/main/res/drawable-v21/ic_menu_manage.xml
deleted file mode 100644
index c1be60b..0000000
--- a/app/src/main/res/drawable-v21/ic_menu_manage.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/drawable-v21/ic_menu_send.xml b/app/src/main/res/drawable-v21/ic_menu_send.xml
deleted file mode 100644
index 00c668c..0000000
--- a/app/src/main/res/drawable-v21/ic_menu_send.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/app/src/main/res/drawable-v21/ic_menu_share.xml b/app/src/main/res/drawable-v21/ic_menu_share.xml
deleted file mode 100644
index a28fb9e..0000000
--- a/app/src/main/res/drawable-v21/ic_menu_share.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/app/src/main/res/drawable-v21/ic_menu_slideshow.xml b/app/src/main/res/drawable-v21/ic_menu_slideshow.xml
deleted file mode 100644
index 209aa64..0000000
--- a/app/src/main/res/drawable-v21/ic_menu_slideshow.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/app/src/main/res/drawable-v24/ic_launcher_foreground.xml b/app/src/main/res/drawable-v24/ic_launcher_foreground.xml
index c7bd21d..1f6bb29 100644
--- a/app/src/main/res/drawable-v24/ic_launcher_foreground.xml
+++ b/app/src/main/res/drawable-v24/ic_launcher_foreground.xml
@@ -2,13 +2,13 @@
xmlns:aapt="http://schemas.android.com/aapt"
android:width="108dp"
android:height="108dp"
- android:viewportHeight="108"
- android:viewportWidth="108">
+ android:viewportWidth="108"
+ android:viewportHeight="108">
+ android:strokeWidth="1"
+ android:strokeColor="#00000000">
+ android:strokeWidth="1"
+ android:strokeColor="#00000000" />
diff --git a/app/src/main/res/drawable/accept.png b/app/src/main/res/drawable/accept.png
deleted file mode 100644
index d6cdeff..0000000
Binary files a/app/src/main/res/drawable/accept.png and /dev/null differ
diff --git a/app/src/main/res/drawable/ambassaodr.png b/app/src/main/res/drawable/ambassaodr.png
deleted file mode 100644
index db31edf..0000000
Binary files a/app/src/main/res/drawable/ambassaodr.png and /dev/null differ
diff --git a/app/src/main/res/drawable/blood.png b/app/src/main/res/drawable/blood.png
deleted file mode 100644
index 7d60662..0000000
Binary files a/app/src/main/res/drawable/blood.png and /dev/null differ
diff --git a/app/src/main/res/drawable/button_corner.xml b/app/src/main/res/drawable/button_corner.xml
new file mode 100644
index 0000000..b83f2e8
--- /dev/null
+++ b/app/src/main/res/drawable/button_corner.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/src/main/res/drawable/delegate.png b/app/src/main/res/drawable/delegate.png
deleted file mode 100644
index 0d48b2b..0000000
Binary files a/app/src/main/res/drawable/delegate.png and /dev/null differ
diff --git a/app/src/main/res/drawable/hos.png b/app/src/main/res/drawable/hos.png
deleted file mode 100644
index 8c70ffb..0000000
Binary files a/app/src/main/res/drawable/hos.png and /dev/null differ
diff --git a/app/src/main/res/drawable/ic_dashboard_black_24dp.xml b/app/src/main/res/drawable/ic_dashboard_black_24dp.xml
deleted file mode 100644
index ae6a446..0000000
--- a/app/src/main/res/drawable/ic_dashboard_black_24dp.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/app/src/main/res/drawable/ic_home_black_24dp.xml b/app/src/main/res/drawable/ic_home_black_24dp.xml
deleted file mode 100644
index 0c36320..0000000
--- a/app/src/main/res/drawable/ic_home_black_24dp.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/app/src/main/res/drawable/ic_launcher_background.xml b/app/src/main/res/drawable/ic_launcher_background.xml
index d5fccc5..0d025f9 100644
--- a/app/src/main/res/drawable/ic_launcher_background.xml
+++ b/app/src/main/res/drawable/ic_launcher_background.xml
@@ -2,169 +2,169 @@
+ android:viewportWidth="108"
+ android:viewportHeight="108">
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
+ android:strokeWidth="0.8"
+ android:strokeColor="#33FFFFFF" />
diff --git a/app/src/main/res/drawable/ic_launcher_foreground.xml b/app/src/main/res/drawable/ic_launcher_foreground.xml
deleted file mode 100644
index c7bd21d..0000000
--- a/app/src/main/res/drawable/ic_launcher_foreground.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/src/main/res/drawable/ic_notifications_black_24dp.xml b/app/src/main/res/drawable/ic_notifications_black_24dp.xml
deleted file mode 100644
index 0262382..0000000
--- a/app/src/main/res/drawable/ic_notifications_black_24dp.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
diff --git a/app/src/main/res/drawable/ic_profile.png b/app/src/main/res/drawable/ic_profile.png
deleted file mode 100644
index 5bce389..0000000
Binary files a/app/src/main/res/drawable/ic_profile.png and /dev/null differ
diff --git a/app/src/main/res/drawable/icon.png b/app/src/main/res/drawable/icon.png
deleted file mode 100644
index 9ce24ab..0000000
Binary files a/app/src/main/res/drawable/icon.png and /dev/null differ
diff --git a/app/src/main/res/drawable/ithack.png b/app/src/main/res/drawable/ithack.png
deleted file mode 100644
index 81a92f7..0000000
Binary files a/app/src/main/res/drawable/ithack.png and /dev/null differ
diff --git a/app/src/main/res/drawable/jc.jpg b/app/src/main/res/drawable/jc.jpg
deleted file mode 100644
index 822f3d3..0000000
Binary files a/app/src/main/res/drawable/jc.jpg and /dev/null differ
diff --git a/app/src/main/res/drawable/jcc.jpg b/app/src/main/res/drawable/jcc.jpg
deleted file mode 100644
index c04c7f7..0000000
Binary files a/app/src/main/res/drawable/jcc.jpg and /dev/null differ
diff --git a/app/src/main/res/drawable/jcf.png b/app/src/main/res/drawable/jcf.png
deleted file mode 100644
index 44d667b..0000000
Binary files a/app/src/main/res/drawable/jcf.png and /dev/null differ
diff --git a/app/src/main/res/drawable/jecrc.png b/app/src/main/res/drawable/jecrc.png
deleted file mode 100644
index 6dcd929..0000000
Binary files a/app/src/main/res/drawable/jecrc.png and /dev/null differ
diff --git a/app/src/main/res/drawable/jecrcmun.jpg b/app/src/main/res/drawable/jecrcmun.jpg
deleted file mode 100644
index 52ed3cf..0000000
Binary files a/app/src/main/res/drawable/jecrcmun.jpg and /dev/null differ
diff --git a/app/src/main/res/drawable/profile.png b/app/src/main/res/drawable/profile.png
deleted file mode 100644
index 957bca1..0000000
Binary files a/app/src/main/res/drawable/profile.png and /dev/null differ
diff --git a/app/src/main/res/drawable/raised.png b/app/src/main/res/drawable/raised.png
deleted file mode 100644
index 60836de..0000000
Binary files a/app/src/main/res/drawable/raised.png and /dev/null differ
diff --git a/app/src/main/res/drawable/sev.png b/app/src/main/res/drawable/sev.png
deleted file mode 100644
index d993aa8..0000000
Binary files a/app/src/main/res/drawable/sev.png and /dev/null differ
diff --git a/app/src/main/res/drawable/side_nav_bar.xml b/app/src/main/res/drawable/side_nav_bar.xml
deleted file mode 100644
index 6d81870..0000000
--- a/app/src/main/res/drawable/side_nav_bar.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/drawable/theme.jpg b/app/src/main/res/drawable/theme.jpg
deleted file mode 100644
index db1b332..0000000
Binary files a/app/src/main/res/drawable/theme.jpg and /dev/null differ
diff --git a/app/src/main/res/drawable/user.png b/app/src/main/res/drawable/user.png
deleted file mode 100644
index 7de4dcc..0000000
Binary files a/app/src/main/res/drawable/user.png and /dev/null differ
diff --git a/app/src/main/res/drawable/white.png b/app/src/main/res/drawable/white.png
deleted file mode 100644
index 9b66df2..0000000
Binary files a/app/src/main/res/drawable/white.png and /dev/null differ
diff --git a/app/src/main/res/drawable/yef.png b/app/src/main/res/drawable/yef.png
deleted file mode 100644
index 162fe8d..0000000
Binary files a/app/src/main/res/drawable/yef.png and /dev/null differ
diff --git a/app/src/main/res/layout/activity_events.xml b/app/src/main/res/layout/activity_events.xml
deleted file mode 100644
index 5ecfa44..0000000
--- a/app/src/main/res/layout/activity_events.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/activity_home.xml b/app/src/main/res/layout/activity_home.xml
new file mode 100644
index 0000000..2370d74
--- /dev/null
+++ b/app/src/main/res/layout/activity_home.xml
@@ -0,0 +1,104 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/src/main/res/layout/activity_login.xml b/app/src/main/res/layout/activity_login.xml
deleted file mode 100644
index 1066767..0000000
--- a/app/src/main/res/layout/activity_login.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml
index 9d91f00..d91faf9 100644
--- a/app/src/main/res/layout/activity_main.xml
+++ b/app/src/main/res/layout/activity_main.xml
@@ -1,53 +1,86 @@
-
-
-
-
-
+ android:background="#FFFFFF"
+ tools:context=".ActivityClasses.MainActivity">
+
-
-
+
+
-
+
-
+ android:layout_below="@+id/nameText"
+ android:hint="Mobile Number"
+ android:padding="10dp"
+ android:background="@drawable/button_corner"
+ android:layout_marginLeft="30dp"
+ android:layout_marginRight="30dp"
+ android:textSize="30dp"
+ android:elevation="4dp"/>
-
+
+
\ No newline at end of file
diff --git a/app/src/main/res/layout/activity_mun.xml b/app/src/main/res/layout/activity_mun.xml
deleted file mode 100644
index 254db0d..0000000
--- a/app/src/main/res/layout/activity_mun.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/activity_signup.xml b/app/src/main/res/layout/activity_signup.xml
deleted file mode 100644
index 9caa746..0000000
--- a/app/src/main/res/layout/activity_signup.xml
+++ /dev/null
@@ -1,64 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/activity_splash.xml b/app/src/main/res/layout/activity_splash.xml
deleted file mode 100644
index 3e793bf..0000000
--- a/app/src/main/res/layout/activity_splash.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/app_bar.xml b/app/src/main/res/layout/app_bar.xml
new file mode 100644
index 0000000..8bf2960
--- /dev/null
+++ b/app/src/main/res/layout/app_bar.xml
@@ -0,0 +1,10 @@
+
+
+
+
\ No newline at end of file
diff --git a/app/src/main/res/layout/app_bar_main.xml b/app/src/main/res/layout/app_bar_main.xml
deleted file mode 100644
index 9504077..0000000
--- a/app/src/main/res/layout/app_bar_main.xml
+++ /dev/null
@@ -1,53 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- />
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/content_main.xml b/app/src/main/res/layout/content_main.xml
deleted file mode 100644
index b97d76e..0000000
--- a/app/src/main/res/layout/content_main.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/nav_header_main.xml b/app/src/main/res/layout/nav_header_main.xml
deleted file mode 100644
index 20614b2..0000000
--- a/app/src/main/res/layout/nav_header_main.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/src/main/res/menu/activity_main_drawer.xml b/app/src/main/res/menu/activity_main_drawer.xml
deleted file mode 100644
index 1871c89..0000000
--- a/app/src/main/res/menu/activity_main_drawer.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-
-
diff --git a/app/src/main/res/menu/main.xml b/app/src/main/res/menu/main.xml
deleted file mode 100644
index a2411e3..0000000
--- a/app/src/main/res/menu/main.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
-
diff --git a/app/src/main/res/menu/navigation.xml b/app/src/main/res/menu/navigation.xml
deleted file mode 100644
index f4de4f8..0000000
--- a/app/src/main/res/menu/navigation.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
-
-
-
-
-
-
-
diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
index 036d09b..eca70cf 100644
--- a/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
+++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml
@@ -1,5 +1,5 @@
-
-
+
+
\ No newline at end of file
diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
index 036d09b..eca70cf 100644
--- a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
+++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml
@@ -1,5 +1,5 @@
-
-
+
+
\ No newline at end of file
diff --git a/app/src/main/res/mipmap-anydpi-v26/white.png b/app/src/main/res/mipmap-anydpi-v26/white.png
deleted file mode 100644
index 9b66df2..0000000
Binary files a/app/src/main/res/mipmap-anydpi-v26/white.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-anydpi-v26/yef.png b/app/src/main/res/mipmap-anydpi-v26/yef.png
deleted file mode 100644
index 142b046..0000000
Binary files a/app/src/main/res/mipmap-anydpi-v26/yef.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher.png b/app/src/main/res/mipmap-hdpi/ic_launcher.png
index 327b15f..898f3ed 100644
Binary files a/app/src/main/res/mipmap-hdpi/ic_launcher.png and b/app/src/main/res/mipmap-hdpi/ic_launcher.png differ
diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png b/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
deleted file mode 100644
index c66028f..0000000
Binary files a/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
index 327b15f..dffca36 100644
Binary files a/app/src/main/res/mipmap-hdpi/ic_launcher_round.png and b/app/src/main/res/mipmap-hdpi/ic_launcher_round.png differ
diff --git a/app/src/main/res/mipmap-hdpi/white.png b/app/src/main/res/mipmap-hdpi/white.png
deleted file mode 100644
index 9b66df2..0000000
Binary files a/app/src/main/res/mipmap-hdpi/white.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-hdpi/yef.png b/app/src/main/res/mipmap-hdpi/yef.png
deleted file mode 100644
index 142b046..0000000
Binary files a/app/src/main/res/mipmap-hdpi/yef.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher.png b/app/src/main/res/mipmap-mdpi/ic_launcher.png
index f6d4c75..64ba76f 100644
Binary files a/app/src/main/res/mipmap-mdpi/ic_launcher.png and b/app/src/main/res/mipmap-mdpi/ic_launcher.png differ
diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png b/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
deleted file mode 100644
index 2f47fb4..0000000
Binary files a/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
index f6d4c75..dae5e08 100644
Binary files a/app/src/main/res/mipmap-mdpi/ic_launcher_round.png and b/app/src/main/res/mipmap-mdpi/ic_launcher_round.png differ
diff --git a/app/src/main/res/mipmap-mdpi/white.png b/app/src/main/res/mipmap-mdpi/white.png
deleted file mode 100644
index 9b66df2..0000000
Binary files a/app/src/main/res/mipmap-mdpi/white.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-mdpi/yef.png b/app/src/main/res/mipmap-mdpi/yef.png
deleted file mode 100644
index 142b046..0000000
Binary files a/app/src/main/res/mipmap-mdpi/yef.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/app/src/main/res/mipmap-xhdpi/ic_launcher.png
index f30a790..e5ed465 100644
Binary files a/app/src/main/res/mipmap-xhdpi/ic_launcher.png and b/app/src/main/res/mipmap-xhdpi/ic_launcher.png differ
diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png
deleted file mode 100644
index 15e8afa..0000000
Binary files a/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
index f30a790..14ed0af 100644
Binary files a/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png and b/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png differ
diff --git a/app/src/main/res/mipmap-xhdpi/white.png b/app/src/main/res/mipmap-xhdpi/white.png
deleted file mode 100644
index 9b66df2..0000000
Binary files a/app/src/main/res/mipmap-xhdpi/white.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xhdpi/yef.png b/app/src/main/res/mipmap-xhdpi/yef.png
deleted file mode 100644
index 142b046..0000000
Binary files a/app/src/main/res/mipmap-xhdpi/yef.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
index b0f422d..b0907ca 100644
Binary files a/app/src/main/res/mipmap-xxhdpi/ic_launcher.png and b/app/src/main/res/mipmap-xxhdpi/ic_launcher.png differ
diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png
deleted file mode 100644
index c41b81d..0000000
Binary files a/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
index b0f422d..d8ae031 100644
Binary files a/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png differ
diff --git a/app/src/main/res/mipmap-xxhdpi/white.png b/app/src/main/res/mipmap-xxhdpi/white.png
deleted file mode 100644
index 9b66df2..0000000
Binary files a/app/src/main/res/mipmap-xxhdpi/white.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xxhdpi/yef.png b/app/src/main/res/mipmap-xxhdpi/yef.png
deleted file mode 100644
index 142b046..0000000
Binary files a/app/src/main/res/mipmap-xxhdpi/yef.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
index f6aa0d4..2c18de9 100644
Binary files a/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png differ
diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png
deleted file mode 100644
index cd5ec25..0000000
Binary files a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
index f6aa0d4..beed3cd 100644
Binary files a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png differ
diff --git a/app/src/main/res/mipmap-xxxhdpi/white.png b/app/src/main/res/mipmap-xxxhdpi/white.png
deleted file mode 100644
index 9b66df2..0000000
Binary files a/app/src/main/res/mipmap-xxxhdpi/white.png and /dev/null differ
diff --git a/app/src/main/res/mipmap-xxxhdpi/yef.png b/app/src/main/res/mipmap-xxxhdpi/yef.png
deleted file mode 100644
index 142b046..0000000
Binary files a/app/src/main/res/mipmap-xxxhdpi/yef.png and /dev/null differ
diff --git a/app/src/main/res/values-v21/styles.xml b/app/src/main/res/values-v21/styles.xml
deleted file mode 100644
index fd7a058..0000000
--- a/app/src/main/res/values-v21/styles.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml
index c294f2e..69b2233 100644
--- a/app/src/main/res/values/colors.xml
+++ b/app/src/main/res/values/colors.xml
@@ -1,6 +1,6 @@
- #3F51B5
- #000000
- #FF4081
+ #008577
+ #00574B
+ #D81B60
diff --git a/app/src/main/res/values/dimens.xml b/app/src/main/res/values/dimens.xml
deleted file mode 100644
index 4ab4520..0000000
--- a/app/src/main/res/values/dimens.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
- 16dp
- 16dp
- 8dp
- 176dp
- 16dp
-
\ No newline at end of file
diff --git a/app/src/main/res/values/drawables.xml b/app/src/main/res/values/drawables.xml
deleted file mode 100644
index 52c6a6c..0000000
--- a/app/src/main/res/values/drawables.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
- - @android:drawable/ic_menu_camera
- - @android:drawable/ic_menu_gallery
- - @android:drawable/ic_menu_slideshow
- - @android:drawable/ic_menu_manage
- - @android:drawable/ic_menu_share
- - @android:drawable/ic_menu_send
-
diff --git a/app/src/main/res/values/ic_launcher_background.xml b/app/src/main/res/values/ic_launcher_background.xml
deleted file mode 100644
index c5d5899..0000000
--- a/app/src/main/res/values/ic_launcher_background.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
- #FFFFFF
-
\ No newline at end of file
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 10eeaab..b3158d3 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -1,12 +1,6 @@
- FINALYEFBLOODDONATION
- Open navigation drawer
- Close navigation drawer
- Android Studio
- android.studio@android.com
- Navigation header
- Settings
- Home
- Dashboard
- Notifications
+ JECRC Pay
+ Payment Solution for JECRC
+ We want to know some of your basic details to Get Started !
+ Search for Events/Clubs
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index 15fc6ca..0eb88fe 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -1,20 +1,11 @@
-
-
-
-
-
-
-
diff --git a/app/src/main/test/java/com/example/admin/navbottom/ExampleUnitTest.java b/app/src/test/java/com/madprateek/jecrcpay/ExampleUnitTest.java
similarity index 90%
rename from app/src/main/test/java/com/example/admin/navbottom/ExampleUnitTest.java
rename to app/src/test/java/com/madprateek/jecrcpay/ExampleUnitTest.java
index 49debe2..bf3cdda 100644
--- a/app/src/main/test/java/com/example/admin/navbottom/ExampleUnitTest.java
+++ b/app/src/test/java/com/madprateek/jecrcpay/ExampleUnitTest.java
@@ -1,4 +1,4 @@
-package com.example.admin.navbottom;
+package com.madprateek.jecrcpay;
import org.junit.Test;
diff --git a/build.gradle b/build.gradle
index b2589f6..8d3ef8e 100644
--- a/build.gradle
+++ b/build.gradle
@@ -7,8 +7,8 @@ buildscript {
jcenter()
}
dependencies {
- classpath 'com.android.tools.build:gradle:3.2.0'
- classpath 'com.google.gms:google-services:4.0.0'
+ classpath 'com.android.tools.build:gradle:3.2.1'
+
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
diff --git a/config_paytm.php b/config_paytm.php
deleted file mode 100644
index 34b7652..0000000
--- a/config_paytm.php
+++ /dev/null
@@ -1,4 +0,0 @@
-
diff --git a/encdec_paytm.php b/encdec_paytm.php
deleted file mode 100644
index cd969f0..0000000
--- a/encdec_paytm.php
+++ /dev/null
@@ -1,155 +0,0 @@
- $value) {
- if ($flag) {
- $paramStr .= checkString_e($value);
- $flag = 0;
- } else {
- $paramStr .= "|" . checkString_e($value);
- }
- }
- return $paramStr;
-}
-
-function redirect2PG($paramList, $key) {
- $hashString = getchecksumFromArray($paramList);
- $checksum = encrypt_e_openssl($hashString, $key);
-}
-
-function removeCheckSumParam($arrayList) {
- if (isset($arrayList["CHECKSUMHASH"])) {
- unset($arrayList["CHECKSUMHASH"]);
- }
- return $arrayList;
-}
-
-function getTxnStatus($requestParamList) {
- return callAPI(PAYTM_STATUS_QUERY_URL, $requestParamList);
-}
-
-function initiateTxnRefund($requestParamList) {
- $CHECKSUM = getChecksumFromArray($requestParamList,PAYTM_MERCHANT_KEY,0);
- $requestParamList["CHECKSUM"] = $CHECKSUM;
- return callAPI(PAYTM_REFUND_URL, $requestParamList);
-}
-
-function callAPI($apiURL, $requestParamList) {
- $jsonResponse = "";
- $responseParamList = array();
- $JsonData =json_encode($requestParamList);
- $postData = 'JsonData='.urlencode($JsonData);
- $ch = curl_init($apiURL);
- curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");
- curl_setopt($ch, CURLOPT_POSTFIELDS, $postData);
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 0);
- curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, 0);
- curl_setopt($ch, CURLOPT_HTTPHEADER, array(
- 'Content-Type: application/json',
- 'Content-Length: ' . strlen($postData))
- );
- $jsonResponse = curl_exec($ch);
- $responseParamList = json_decode($jsonResponse,true);
- return $responseParamList;
-}
diff --git a/generateChecksum.php b/generateChecksum.php
deleted file mode 100644
index c05e4df..0000000
--- a/generateChecksum.php
+++ /dev/null
@@ -1,44 +0,0 @@
-$value)
-{
- $pos = strpos($value, $findme);
- $pospipe = strpos($value, $findmepipe);
- if ($pos === false || $pospipe === false)
- {
- $paramList[$key] = $value;
- }
-}
-
-
-
-//Here checksum string will return by getChecksumFromArray() function.
-$checkSum = getChecksumFromArray($paramList,PAYTM_MERCHANT_KEY);
-//print_r($_POST);
- echo json_encode(array("CHECKSUMHASH" => $checkSum,"ORDER_ID" =>$_POST["ORDER_ID"], "payt_STATUS" => "1"));
- //Sample response return to SDK
-
-// {"CHECKSUMHASH":"GhAJV057opOCD3KJuVWesQ9pUxMtyUGLPAiIRtkEQXBeSws2hYvxaj7jRn33rTYGRLx2TosFkgReyCslu4OUj\/A85AvNC6E4wUP+CZnrBGM=","ORDER_ID":"asgasfgasfsdfhl7","payt_STATUS":"1"}
-
-?>
diff --git a/gradle.properties b/gradle.properties
index 743d692..82618ce 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -11,3 +11,5 @@ org.gradle.jvmargs=-Xmx1536m
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
+
+
diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar
index 7a3265e..f6b961f 100644
Binary files a/gradle/wrapper/gradle-wrapper.jar and b/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index e59736e..9a4163a 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,6 +1,5 @@
-#Fri Sep 28 21:42:01 IST 2018
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
+distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip
diff --git a/readthis.md b/readthis.md
deleted file mode 100644
index 9c5fb91..0000000
--- a/readthis.md
+++ /dev/null
@@ -1,3 +0,0 @@
-# JECRC-Pay
-JECRC Payment App
-This App includes jecrc events notifications and the payments portal.
diff --git a/verifyChecksum.php b/verifyChecksum.php
deleted file mode 100644
index 9e3bc01..0000000
--- a/verifyChecksum.php
+++ /dev/null
@@ -1,52 +0,0 @@
-
-
-
-
-
- Paytm
-
-
-
- Redirect back to the app
-
-
-
-