Explorar el Código

Movie category selection to top for transaction editing.

Lee Morgan hace 10 meses
padre
commit
3c9b9c0f75
Se han modificado 1 ficheros con 23 adiciones y 20 borrados
  1. 23 20
      src/views/js/pages/EditTransaction.js

+ 23 - 20
src/views/js/pages/EditTransaction.js

@@ -52,6 +52,29 @@ export default class EditTransaction extends Page{
             .append(new Elem("h1")
                 .text("Edit Transaction")
             )
+            .append(new Elem("label")
+                .text("Category")
+                .append(new Elem("select")
+                    .addClass("category")
+                    .toVar((a)=>{select = a})
+                    .append(new Elem("option")
+                        .text("Discretionary")
+                        .value("discretionary")
+                    )
+                    .append(new Elem("optgroup")
+                        .label("Allowances")
+                        .toVar((e)=>{allowancesOpt = e})
+                    )
+                    .append(new Elem("optgroup")
+                        .label("Bills")
+                        .toVar((e)=>{billsOpt = e})
+                    )
+                    .append(new Elem("optgroup")
+                        .label("Income")
+                        .toVar((e)=>{incomeOpt = e})
+                    )
+                )
+            )
             .append(new Elem("label")
                 .text("Amount")
                 .append(new Elem("input")
@@ -63,26 +86,6 @@ export default class EditTransaction extends Page{
                     .focus()
                 )
             )
-            .append(new Elem("select")
-                .addClass("category")
-                .toVar((a)=>{select = a})
-                .append(new Elem("option")
-                    .text("Discretionary")
-                    .value("discretionary")
-                )
-                .append(new Elem("optgroup")
-                    .label("Allowances")
-                    .toVar((e)=>{allowancesOpt = e})
-                )
-                .append(new Elem("optgroup")
-                    .label("Bills")
-                    .toVar((e)=>{billsOpt = e})
-                )
-                .append(new Elem("optgroup")
-                    .label("Income")
-                    .toVar((e)=>{incomeOpt = e})
-                )
-            )
             .append(new Elem("label")
                 .text("Tags")
                 .append(new Elem("input")