Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
Research-Project
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jayakody J.A.D.K.A - IT19114040
Research-Project
Commits
7f04f41a
Commit
7f04f41a
authored
Apr 06, 2022
by
Anuththara18
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Consent Form Access from Navigation Activity
parent
30d18236
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
3 deletions
+23
-3
app/src/main/java/com/anuththara18/attentionassessment/consentform/ConsentFormActivity.java
.../attentionassessment/consentform/ConsentFormActivity.java
+11
-1
app/src/main/java/com/anuththara18/attentionassessment/details/ParentDetailsActivity.java
...18/attentionassessment/details/ParentDetailsActivity.java
+3
-0
app/src/main/java/com/anuththara18/attentionassessment/home/NavigationDrawerActivity.java
...18/attentionassessment/home/NavigationDrawerActivity.java
+9
-2
No files found.
app/src/main/java/com/anuththara18/attentionassessment/consentform/ConsentFormActivity.java
View file @
7f04f41a
...
@@ -13,6 +13,8 @@ import androidx.recyclerview.widget.LinearLayoutManager;
...
@@ -13,6 +13,8 @@ import androidx.recyclerview.widget.LinearLayoutManager;
import
androidx.recyclerview.widget.RecyclerView
;
import
androidx.recyclerview.widget.RecyclerView
;
import
com.anuththara18.attentionassessment.R
;
import
com.anuththara18.attentionassessment.R
;
import
com.anuththara18.attentionassessment.details.ParentDetailsActivity
;
import
com.anuththara18.attentionassessment.home.NavigationDrawerActivity
;
import
com.anuththara18.attentionassessment.language.LanguageSetter
;
import
com.anuththara18.attentionassessment.language.LanguageSetter
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
...
@@ -41,13 +43,21 @@ public class ConsentFormActivity extends AppCompatActivity {
...
@@ -41,13 +43,21 @@ public class ConsentFormActivity extends AppCompatActivity {
textView
=
findViewById
(
R
.
id
.
textView
);
textView
=
findViewById
(
R
.
id
.
textView
);
next
=
findViewById
(
R
.
id
.
next
);
next
=
findViewById
(
R
.
id
.
next
);
if
(
ParentDetailsActivity
.
nav
==
0
)
{
next
.
setVisibility
(
View
.
INVISIBLE
);
next
.
setEnabled
(
false
);
}
else
{
next
.
setVisibility
(
View
.
VISIBLE
);
next
.
setEnabled
(
true
);
}
textView
.
setText
(
LanguageSetter
.
getresources
().
getString
(
R
.
string
.
consentForm
));
textView
.
setText
(
LanguageSetter
.
getresources
().
getString
(
R
.
string
.
consentForm
));
next
.
setText
(
LanguageSetter
.
getresources
().
getString
(
R
.
string
.
proceed
));
next
.
setText
(
LanguageSetter
.
getresources
().
getString
(
R
.
string
.
proceed
));
initData
();
initData
();
initRecyclerView
();
initRecyclerView
();
TextView
next
=
findViewById
(
R
.
id
.
next
);
next
.
setOnClickListener
(
new
View
.
OnClickListener
()
{
next
.
setOnClickListener
(
new
View
.
OnClickListener
()
{
@Override
@Override
public
void
onClick
(
View
view
)
{
public
void
onClick
(
View
view
)
{
...
...
app/src/main/java/com/anuththara18/attentionassessment/details/ParentDetailsActivity.java
View file @
7f04f41a
...
@@ -30,6 +30,8 @@ public class ParentDetailsActivity extends AppCompatActivity {
...
@@ -30,6 +30,8 @@ public class ParentDetailsActivity extends AppCompatActivity {
EditText
childName
,
parentEmail
,
parentContact
,
diagnosis
;
EditText
childName
,
parentEmail
,
parentContact
,
diagnosis
;
public
static
String
child_name
,
parent_email
,
parent_contact
;
public
static
String
child_name
,
parent_email
,
parent_contact
;
public
static
int
nav
=
1
;
@Override
@Override
protected
void
onCreate
(
Bundle
savedInstanceState
)
{
protected
void
onCreate
(
Bundle
savedInstanceState
)
{
super
.
onCreate
(
savedInstanceState
);
super
.
onCreate
(
savedInstanceState
);
...
@@ -93,6 +95,7 @@ public class ParentDetailsActivity extends AppCompatActivity {
...
@@ -93,6 +95,7 @@ public class ParentDetailsActivity extends AppCompatActivity {
parentContact
.
setError
(
"Enter Valid Number\nEg: 0771234567"
);
parentContact
.
setError
(
"Enter Valid Number\nEg: 0771234567"
);
}
}
else
{
else
{
nav
=
1
;
if
(
LanguageActivity
.
text
.
equals
(
"English"
))
{
if
(
LanguageActivity
.
text
.
equals
(
"English"
))
{
startActivity
(
new
Intent
(
ParentDetailsActivity
.
this
,
ConsentFormActivity
.
class
));
startActivity
(
new
Intent
(
ParentDetailsActivity
.
this
,
ConsentFormActivity
.
class
));
}
else
{
}
else
{
...
...
app/src/main/java/com/anuththara18/attentionassessment/home/NavigationDrawerActivity.java
View file @
7f04f41a
...
@@ -19,7 +19,10 @@ import android.widget.Toast;
...
@@ -19,7 +19,10 @@ import android.widget.Toast;
import
com.anuththara18.attentionassessment.R
;
import
com.anuththara18.attentionassessment.R
;
import
com.anuththara18.attentionassessment.consentform.ConsentFormActivity
;
import
com.anuththara18.attentionassessment.consentform.ConsentFormActivity
;
import
com.anuththara18.attentionassessment.consentform.SinhalaConsentFormActivity
;
import
com.anuththara18.attentionassessment.details.ParentDetailsActivity
;
import
com.anuththara18.attentionassessment.emailfiles.EmailDataFilesActivity
;
import
com.anuththara18.attentionassessment.emailfiles.EmailDataFilesActivity
;
import
com.anuththara18.attentionassessment.language.LanguageActivity
;
import
com.google.android.material.navigation.NavigationView
;
import
com.google.android.material.navigation.NavigationView
;
import
static
android
.
Manifest
.
permission
.
MANAGE_EXTERNAL_STORAGE
;
import
static
android
.
Manifest
.
permission
.
MANAGE_EXTERNAL_STORAGE
;
...
@@ -109,8 +112,12 @@ public class NavigationDrawerActivity extends AppCompatActivity implements Navig
...
@@ -109,8 +112,12 @@ public class NavigationDrawerActivity extends AppCompatActivity implements Navig
//startActivity(intent6);
//startActivity(intent6);
break
;
break
;
case
R
.
id
.
consentForm
:
case
R
.
id
.
consentForm
:
Intent
intent7
=
new
Intent
(
getApplicationContext
(),
ConsentFormActivity
.
class
);
ParentDetailsActivity
.
nav
=
0
;
startActivity
(
intent7
);
if
(
LanguageActivity
.
text
.
equals
(
"English"
))
{
startActivity
(
new
Intent
(
getApplicationContext
(),
ConsentFormActivity
.
class
));
}
else
{
startActivity
(
new
Intent
(
getApplicationContext
(),
SinhalaConsentFormActivity
.
class
));
}
break
;
break
;
case
R
.
id
.
sendData
:
case
R
.
id
.
sendData
:
Intent
intent9
=
new
Intent
(
getApplicationContext
(),
EmailDataFilesActivity
.
class
);
Intent
intent9
=
new
Intent
(
getApplicationContext
(),
EmailDataFilesActivity
.
class
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment