Skip to content
Snippets Groups Projects
Commit c09c9240 authored by stroredi's avatar stroredi
Browse files

modified patientenSuche layout

parent 321f975f
Branches
No related tags found
1 merge request!2Development
...@@ -30,12 +30,12 @@ public class PatientenSuche extends AppCompatActivity { ...@@ -30,12 +30,12 @@ public class PatientenSuche extends AppCompatActivity {
setContentView(R.layout.activity_patienten_suche); setContentView(R.layout.activity_patienten_suche);
pname=findViewById(R.id.pname); pname=findViewById(R.id.pname);
vname=findViewById(R.id.Vnumber); // vname=findViewById(R.id.Vnumber);
rname=findViewById(R.id.editTextTextPersonName5); // rname=findViewById(R.id.editTextTextPersonName5);
vbutton=findViewById(R.id.vbutton); vbutton=findViewById(R.id.vbutton);
sbutton=findViewById(R.id.sbutton); sbutton=findViewById(R.id.sbutton);
swPatient=findViewById(R.id.switch2); // swPatient=findViewById(R.id.switch2);
listings=findViewById(R.id.plist); listings=findViewById(R.id.plist);
...@@ -52,7 +52,8 @@ public class PatientenSuche extends AppCompatActivity { ...@@ -52,7 +52,8 @@ public class PatientenSuche extends AppCompatActivity {
akte =new Akte(pname.getText().toString()); akte =new Akte(pname.getText().toString());
databaseHelper= new DatabaseHelper(PatientenSuche.this); databaseHelper= new DatabaseHelper(PatientenSuche.this);
// databaseHelper.search(akte); // databaseHelper.search(akte);
Toast.makeText(PatientenSuche.this,"successfully searching patient", Toast.LENGTH_SHORT).show(); // commmented the next line toast message out because it keep printing ebven when it can not find a patient from the database
// Toast.makeText(PatientenSuche.this,"successfully searching patient", Toast.LENGTH_SHORT).show();
patientArrayAdapter= new ArrayAdapter<Akte>(PatientenSuche.this, android.R.layout.simple_list_item_1,databaseHelper.search(akte)); patientArrayAdapter= new ArrayAdapter<Akte>(PatientenSuche.this, android.R.layout.simple_list_item_1,databaseHelper.search(akte));
listings.setAdapter(patientArrayAdapter); listings.setAdapter(patientArrayAdapter);
......
...@@ -20,64 +20,25 @@ ...@@ -20,64 +20,25 @@
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />
<EditText
android:id="@+id/Vnumber"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
android:ems="10"
android:hint="VersicherungsNummer"
android:inputType="textPersonName"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.497"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/pname" />
<EditText
android:id="@+id/editTextTextPersonName5"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginEnd="8dp"
android:ems="10"
android:hint="ZimmerNummer"
android:inputType="textPersonName"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Vnumber" />
<Switch
android:id="@+id/switch2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:text="Switch"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/editTextTextPersonName5" />
<Button <Button
android:id="@+id/vbutton" android:id="@+id/vbutton"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="8dp" android:layout_marginTop="64dp"
android:text="ViewAll" android:text="ViewAll"
app:layout_constraintEnd_toStartOf="@+id/sbutton" app:layout_constraintEnd_toStartOf="@+id/sbutton"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/switch2" /> app:layout_constraintTop_toBottomOf="@+id/pname" />
<Button <Button
android:id="@+id/sbutton" android:id="@+id/sbutton"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="8dp" android:layout_marginTop="64dp"
android:text="Search" android:text="Search"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/vbutton" app:layout_constraintStart_toEndOf="@id/vbutton"
app:layout_constraintTop_toBottomOf="@+id/switch2" /> app:layout_constraintTop_toBottomOf="@+id/pname" />
<ListView <ListView
android:id="@+id/plist" android:id="@+id/plist"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment