Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update UI for AddCommand #29

Merged
merged 12 commits into from
Mar 20, 2024
4 changes: 1 addition & 3 deletions src/main/java/seedu/address/ui/PersonCard.java
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
@FXML
private FlowPane tags;


/**
* Creates a {@code PersonCode} with the given {@code Person} and index to display.
*/
Expand All @@ -57,13 +58,10 @@
this.person = person;
id.setText(displayedIndex + ". ");
name.setText(person.getName().fullName);
phone.setText(person.getPhone().value);
address.setText(person.getAddress().value);
email.setText(person.getEmail().value);
dob.setText(person.getDob().value);
ic.setText(person.getIc().value);
admissionDate.setText(person.getAdmissionDate().value);
ward.setText(person.getWard().value);

Check warning on line 64 in src/main/java/seedu/address/ui/PersonCard.java

View check run for this annotation

Codecov / codecov/patch

src/main/java/seedu/address/ui/PersonCard.java#L61-L64

Added lines #L61 - L64 were not covered by tests
person.getTags().stream()
.sorted(Comparator.comparing(tag -> tag.tagName))
.forEach(tag -> tags.getChildren().add(new Label(tag.tagName)));
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/view/MainWindow.fxml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<?import javafx.scene.layout.VBox?>

<fx:root type="javafx.stage.Stage" xmlns="http://javafx.com/javafx/17" xmlns:fx="http://javafx.com/fxml/1"
title="Address App" minWidth="450" minHeight="600" onCloseRequest="#handleExit">
title="Nursing Address Book" minWidth="450" minHeight="600" onCloseRequest="#handleExit">
<icons>
<Image url="@/images/address_book_32.png" />
</icons>
Expand Down
7 changes: 2 additions & 5 deletions src/main/resources/view/PersonListCard.fxml
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,10 @@
<Label fx:id="name" text="\$first" styleClass="cell_big_label" />
</HBox>
<FlowPane fx:id="tags" />
<Label fx:id="phone" styleClass="cell_small_label" text="\$phone" />
<Label fx:id="address" styleClass="cell_small_label" text="\$address" />
<Label fx:id="email" styleClass="cell_small_label" text="\$email" />
<Label fx:id="dob" styleClass="cell_small_label" text="\$dob" />
<Label fx:id="ic" styleClass="cell_small_label" text="\$ic" />
<Label fx:id="admissionDate" styleClass="cell_small_label" text="\$admissionDate" />
<Label fx:id="dob" styleClass="cell_small_label" text="\$dob" />
<Label fx:id="ward" styleClass="cell_small_label" text="\$ward" />
<Label fx:id="admissionDate" styleClass="cell_small_label" text="\$admissionDate" />
</VBox>
</GridPane>
</HBox>
Loading