generated from OBJNULL/Dockerized-Rust
Updated the App to work with the calculate func
This commit is contained in:
parent
d4b7b500c8
commit
10f6e9e17e
1 changed files with 11 additions and 3 deletions
|
@ -6,9 +6,10 @@ export component Prorater inherits Window {
|
||||||
height: 720px;
|
height: 720px;
|
||||||
|
|
||||||
in property <[string]> membership_names: ["Select One..."];
|
in property <[string]> membership_names: ["Select One..."];
|
||||||
|
out property <string> last_billing: "NULL";
|
||||||
out property <string> current_membership;
|
out property <string> current_membership;
|
||||||
out property <string> new_membership;
|
out property <string> new_membership;
|
||||||
callback on_calculate();
|
callback on_calculate() -> string;
|
||||||
|
|
||||||
VerticalBox {
|
VerticalBox {
|
||||||
Image {
|
Image {
|
||||||
|
@ -72,9 +73,15 @@ export component Prorater inherits Window {
|
||||||
Button {
|
Button {
|
||||||
text: "Calculate";
|
text: "Calculate";
|
||||||
clicked => {
|
clicked => {
|
||||||
on_calculate();
|
result_text.text = on_calculate();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
result_text := Text {
|
||||||
|
text: "";
|
||||||
|
font-size: 1.25rem;
|
||||||
|
horizontal-alignment: center;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
date_picker := DatePickerPopup {
|
date_picker := DatePickerPopup {
|
||||||
|
@ -84,7 +91,8 @@ export component Prorater inherits Window {
|
||||||
|
|
||||||
accepted(date) => {
|
accepted(date) => {
|
||||||
date_picker.close();
|
date_picker.close();
|
||||||
last-billing-date.text = date.month + "/" + date.day + "/" + date.year;
|
root.last_billing = date.month + "/" + date.day + "/" + date.year;
|
||||||
|
last_billing_date.text = root.last_billing;
|
||||||
}
|
}
|
||||||
|
|
||||||
canceled => {
|
canceled => {
|
||||||
|
|
Loading…
Reference in a new issue