From b1465275360c4be3347e4da19a2f82bdb36ddff7 Mon Sep 17 00:00:00 2001 From: bussm Date: Fri, 11 Apr 2025 15:21:05 -0400 Subject: [PATCH 01/22] Added HTML sub-tab to FD2 School Tab --- .../farmdata2_modules/fd2_school/fd2_school.module | 10 ++++++++++ farmdata2/farmdata2_modules/fd2_school/html/html.html | 1 + 2 files changed, 11 insertions(+) create mode 100644 farmdata2/farmdata2_modules/fd2_school/html/html.html diff --git a/farmdata2/farmdata2_modules/fd2_school/fd2_school.module b/farmdata2/farmdata2_modules/fd2_school/fd2_school.module index 167ca8ef2..a7ebed109 100644 --- a/farmdata2/farmdata2_modules/fd2_school/fd2_school.module +++ b/farmdata2/farmdata2_modules/fd2_school/fd2_school.module @@ -61,6 +61,16 @@ function fd2_school_menu() { ); // Add items blocks for new sub-tabs here. + + // Add a sub-tab named HTML with content in ./html/html.html. + $items['farm/fd2-school/html'] = array( + 'title' => 'HTML', + 'type' => MENU_LOCAL_TASK, + 'page callback' => 'fd2_school_view', + 'page arguments' => array('html'), + 'access arguments' => array('view fd2 school'), + 'weight' => 110, + ); return $items; }; diff --git a/farmdata2/farmdata2_modules/fd2_school/html/html.html b/farmdata2/farmdata2_modules/fd2_school/html/html.html new file mode 100644 index 000000000..84f9a2a3c --- /dev/null +++ b/farmdata2/farmdata2_modules/fd2_school/html/html.html @@ -0,0 +1 @@ +Matthew Buss \ No newline at end of file From 2535ec76a17344cda55753a739753f5b7a6f20b2 Mon Sep 17 00:00:00 2001 From: bussm Date: Sun, 13 Apr 2025 15:59:57 -0400 Subject: [PATCH 02/22] Added sample Harvest Report text to the HTML sub-tab of the FD2 School Tab --- .../fd2_school/html/html.html | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/html/html.html b/farmdata2/farmdata2_modules/fd2_school/html/html.html index 84f9a2a3c..03024465a 100644 --- a/farmdata2/farmdata2_modules/fd2_school/html/html.html +++ b/farmdata2/farmdata2_modules/fd2_school/html/html.html @@ -1 +1,17 @@ -Matthew Buss \ No newline at end of file +

Harvest Report

+

This page is a mockup of a simplified harvest report.

+ +
+ +

My Sample Harvest Report

+

Details: +

+

\ No newline at end of file From dcb890557305ec7bbeb143ac4c0098f3bd4a9fb8 Mon Sep 17 00:00:00 2001 From: bussm Date: Mon, 14 Apr 2025 00:12:53 -0400 Subject: [PATCH 03/22] Added nonfunctional Title input and Generate Report buttons to the FD2School tab's HTML sub-tab --- farmdata2/farmdata2_modules/fd2_school/html/html.html | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/html/html.html b/farmdata2/farmdata2_modules/fd2_school/html/html.html index 03024465a..4a888cdbb 100644 --- a/farmdata2/farmdata2_modules/fd2_school/html/html.html +++ b/farmdata2/farmdata2_modules/fd2_school/html/html.html @@ -14,4 +14,12 @@

My Sample Harvest Report

  • End:05/15/2018
  • Crop:Kale
  • -

    \ No newline at end of file +

    + +
    + + + + + From fa8c8a25a83a83a2ebc10f2b729a414644813ddb Mon Sep 17 00:00:00 2001 From: bussm Date: Tue, 15 Apr 2025 23:44:20 -0400 Subject: [PATCH 04/22] Added Crop input to the FD2School HTML sub-tab --- farmdata2/farmdata2_modules/fd2_school/html/html.html | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/html/html.html b/farmdata2/farmdata2_modules/fd2_school/html/html.html index 4a888cdbb..49fc1b3a1 100644 --- a/farmdata2/farmdata2_modules/fd2_school/html/html.html +++ b/farmdata2/farmdata2_modules/fd2_school/html/html.html @@ -12,7 +12,14 @@

    My Sample Harvest Report


  • Start:05/01/2018
  • End:05/15/2018
  • -
  • Crop:Kale
  • +
  • + + +
  • From 5169d11544fe9aee795e7f4731d5cb395f3e19ad Mon Sep 17 00:00:00 2001 From: bussm Date: Tue, 15 Apr 2025 23:48:47 -0400 Subject: [PATCH 05/22] Added Field input to the FD2School HTML sub-tab --- farmdata2/farmdata2_modules/fd2_school/html/html.html | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/farmdata2/farmdata2_modules/fd2_school/html/html.html b/farmdata2/farmdata2_modules/fd2_school/html/html.html index 49fc1b3a1..a5227b6a8 100644 --- a/farmdata2/farmdata2_modules/fd2_school/html/html.html +++ b/farmdata2/farmdata2_modules/fd2_school/html/html.html @@ -20,6 +20,14 @@

    My Sample Harvest Report

    +
  • + + +
  • From 0d4d800ee2fe52e9ce34ad35aba45223d9a9b6ff Mon Sep 17 00:00:00 2001 From: bussm Date: Tue, 15 Apr 2025 23:57:37 -0400 Subject: [PATCH 06/22] Added start and end date imputs to the FD2School HTML sub-tab --- .../fd2_school/html/html.html | 22 +++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/html/html.html b/farmdata2/farmdata2_modules/fd2_school/html/html.html index a5227b6a8..d86eb5082 100644 --- a/farmdata2/farmdata2_modules/fd2_school/html/html.html +++ b/farmdata2/farmdata2_modules/fd2_school/html/html.html @@ -10,8 +10,26 @@

    My Sample Harvest Report

  • User:manager1
  • Language:English

  • -
  • Start:05/01/2018
  • -
  • End:05/15/2018
  • +
  • + + +
  • +
  • + + +
  • +

    + + + + + + +

    + + + + + + + +

    + +

    My Sample Harvest Report

    @@ -10,49 +51,12 @@

    My Sample Harvest Report

  • User:manager1
  • Language:English

  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • +
  • Start:05/01/2018
  • +
  • End:05/15/2018
  • +
  • Crop:Kale

  • - - - From 5627308ff42a2f560a99db68fb8094441c4b3f14 Mon Sep 17 00:00:00 2001 From: bussm Date: Wed, 16 Apr 2025 00:17:15 -0400 Subject: [PATCH 08/22] Added sample harvest report data table to the bottom of the FD2School HTML sub-tab --- .../fd2_school/html/html.html | 26 ++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/html/html.html b/farmdata2/farmdata2_modules/fd2_school/html/html.html index aba433062..40881adf4 100644 --- a/farmdata2/farmdata2_modules/fd2_school/html/html.html +++ b/farmdata2/farmdata2_modules/fd2_school/html/html.html @@ -57,6 +57,26 @@

    My Sample Harvest Report

    -
    - - + + + + + + + + + + + + + + + + + + + + + + +
    DateAreaCropYieldUnits
    05/02/2011Chuau-1Kale10Bunches
    05/05/2011SQ7Kale7Bunches
    From 5b24f3780ed08058a9acff5b4950dfd163ec8a5d Mon Sep 17 00:00:00 2001 From: bussm Date: Wed, 16 Apr 2025 21:47:48 -0400 Subject: [PATCH 09/22] Added Vue1 sub-tab to the FD2School tab --- .../fd2_school/fd2_school.module | 10 +++ .../fd2_school/vue1/vue1.html | 82 +++++++++++++++++++ 2 files changed, 92 insertions(+) create mode 100644 farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html diff --git a/farmdata2/farmdata2_modules/fd2_school/fd2_school.module b/farmdata2/farmdata2_modules/fd2_school/fd2_school.module index a7ebed109..784dea6b7 100644 --- a/farmdata2/farmdata2_modules/fd2_school/fd2_school.module +++ b/farmdata2/farmdata2_modules/fd2_school/fd2_school.module @@ -72,6 +72,16 @@ function fd2_school_menu() { 'weight' => 110, ); + // Add a sub-tab named Vue1 with content in ./vue1/vue1.html. + $items['farm/fd2-school/vue1'] = array( + 'title' => 'Vue1', + 'type' => MENU_LOCAL_TASK, + 'page callback' => 'fd2_school_view', + 'page arguments' => array('vue1'), + 'access arguments' => array('view fd2 school'), + 'weight' => 110, + ); + return $items; }; diff --git a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html new file mode 100644 index 000000000..40881adf4 --- /dev/null +++ b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html @@ -0,0 +1,82 @@ +

    Harvest Report

    +

    This page is a mockup of a simplified harvest report.

    + + + +

    + + + + + + +

    + + + + + + + +

    + + +
    + +

    My Sample Harvest Report

    +

    Details: +

      +
    • Farm:Sample Farm
    • +
    • User:manager1
    • +
    • Language:English
    • +
      +
    • Start:05/01/2018
    • +
    • End:05/15/2018
    • +
    • Crop:Kale
    • +
    +

    + + + + + + + + + + + + + + + + + + + + + + + +
    DateAreaCropYieldUnits
    05/02/2011Chuau-1Kale10Bunches
    05/05/2011SQ7Kale7Bunches
    From 90b9d88f47f4ab60092a16a04d197e866a84bb09 Mon Sep 17 00:00:00 2001 From: bussm Date: Wed, 16 Apr 2025 23:28:49 -0400 Subject: [PATCH 10/22] Added basic Vue capabilities to the FD2School Vue1 sub-tab, including functionality for the Title input --- .../fd2_school/vue1/vue1.html | 158 ++++++++++-------- 1 file changed, 85 insertions(+), 73 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html index 40881adf4..4f78365a4 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html @@ -1,82 +1,94 @@ -

    Harvest Report

    -

    This page is a mockup of a simplified harvest report.

    +
    +

    Harvest Report

    +

    This page is a mockup of a simplified harvest report.

    - - -

    - - + - - + +

    + + -

    + + - - +

    - - + + -

    - + + -
    +

    + -

    My Sample Harvest Report

    -

    Details: -

      -
    • Farm:Sample Farm
    • -
    • User:manager1
    • -
    • Language:English
    • -
      -
    • Start:05/01/2018
    • -
    • End:05/15/2018
    • -
    • Crop:Kale
    • -
    -

    +
    - - - - - - - - - - - - - - - - - - - - - - -
    DateAreaCropYieldUnits
    05/02/2011Chuau-1Kale10Bunches
    05/05/2011SQ7Kale7Bunches
    +

    {{reportTitle}}

    +

    Details: +

      +
    • Farm:Sample Farm
    • +
    • User:manager1
    • +
    • Language:English
    • +
      +
    • Start:05/01/2018
    • +
    • End:05/15/2018
    • +
    • Crop:Kale
    • +
    +

    + + + + + + + + + + + + + + + + + + + + + + + +
    DateAreaCropYieldUnits
    05/02/2011Chuau-1Kale10Bunches
    05/05/2011SQ7Kale7Bunches
    +
    + + \ No newline at end of file From 37e074141a2d3609f5c7267f8967f96403d6c890 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 13:21:11 -0400 Subject: [PATCH 11/22] Updated the FD2-School Vue1 subtab so that the date and crop input elements affect the sample harvest report --- .../fd2_school/vue1/vue1.html | 20 ++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html index 4f78365a4..242d189a8 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html @@ -8,27 +8,25 @@

    Harvest Report

    value="My Sample Harvest Report" v-model="reportTitle"/>

    - -

    - @@ -53,9 +51,9 @@

    {{reportTitle}}

  • User:manager1
  • Language:English

  • -
  • Start:05/01/2018
  • -
  • End:05/15/2018
  • -
  • Crop:Kale
  • +
  • Start:{{startDate}}
  • +
  • End:{{endDate}}
  • +
  • Crop:{{crop}}
  • @@ -88,7 +86,11 @@

    {{reportTitle}}

    var vue = new Vue({ el: "#harvest-report", data: { - reportTitle: "My Sample Harvest Report" + reportTitle: "My Sample Harvest Report", + startDate: "2020-05-05", + endDate: "2020-05-15", + crop: "Kale" } + }) \ No newline at end of file From d09199cd6391d55d1be7814a1235104df8c500b1 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 14:09:11 -0400 Subject: [PATCH 12/22] Added a placeholder report title in the case that the harvest report title input is left empty on the FD2-School Vue1 sub-tab --- farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html index 242d189a8..926576662 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html @@ -44,7 +44,7 @@

    Harvest Report


    -

    {{reportTitle}}

    +

    {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

    Details:

    • Farm:Sample Farm
    • From 72d9bcffc41ee2c3beef1d3d66998027486d0f52 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 14:26:37 -0400 Subject: [PATCH 13/22] Changed the crop and area dropdown inputs so that options are generated from an array stored in the Vue instance of the FD2-School Vue1 sub-tab --- .../fd2_school/vue1/vue1.html | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html index 926576662..55210de7c 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html @@ -27,16 +27,12 @@

      Harvest Report



      @@ -89,7 +85,18 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      reportTitle: "My Sample Harvest Report", startDate: "2020-05-05", endDate: "2020-05-15", - crop: "Kale" + crop: "Kale", + crops: [ + "Broccoli", + "Kale", + "Peas", + ], + areas: [ + "All", + "Chuau-1", + "SQ7", + ], + } }) From 54caea8a348db8d9282ba93d9dbd6b96f56d0155 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 15:44:07 -0400 Subject: [PATCH 14/22] Changed the harvest report table is generated from an array of objects stored in the Vue instance of the FD2-School Vue1 sub-tab --- .../fd2_school/vue1/vue1.html | 24 ++++++++----------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html index 55210de7c..b0f8623f4 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html @@ -61,19 +61,12 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      Yield Units - - 05/02/2011 - Chuau-1 - Kale - 10 - Bunches - - - 05/05/2011 - SQ7 - Kale - 7 - Bunches + + {{report.date}} + {{report.area}} + {{report.crop}} + {{report.yield}} + {{report.units}} @@ -96,7 +89,10 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      "Chuau-1", "SQ7", ], - + reports: [ + {date: "2018-05-02", area: "Chuau-1", crop: "Kale", yield: 10, units: "Bunches"}, + {date: "2018-05-05", area: "SQ7", crop: "Kale", yield: 7, units: "Bunches"}, + ], } }) From 5e1447de1394734816be3f951e8aa971d8ae3915 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 15:57:26 -0400 Subject: [PATCH 15/22] Added Vue DevTools compatibility to the FD2-School Vue1 sub-tab --- farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html index b0f8623f4..c87523d64 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue1/vue1.html @@ -96,4 +96,6 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      } }) + + Vue.config.devtools = true; \ No newline at end of file From 2868864830c92711357003788b7e30b53c1dc5f7 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 22:29:54 -0400 Subject: [PATCH 16/22] Added Vue2 sub-tab to the FD2-School tab --- .../fd2_school/fd2_school.module | 10 ++ .../fd2_school/vue2/vue2.html | 101 ++++++++++++++++++ 2 files changed, 111 insertions(+) create mode 100644 farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html diff --git a/farmdata2/farmdata2_modules/fd2_school/fd2_school.module b/farmdata2/farmdata2_modules/fd2_school/fd2_school.module index 784dea6b7..7a8c837e5 100644 --- a/farmdata2/farmdata2_modules/fd2_school/fd2_school.module +++ b/farmdata2/farmdata2_modules/fd2_school/fd2_school.module @@ -82,6 +82,16 @@ function fd2_school_menu() { 'weight' => 110, ); + // Add a sub-tab named Vue2 with content in ./vue2/vue2.html. + $items['farm/fd2-school/vue2'] = array( + 'title' => 'Vue2', + 'type' => MENU_LOCAL_TASK, + 'page callback' => 'fd2_school_view', + 'page arguments' => array('vue2'), + 'access arguments' => array('view fd2 school'), + 'weight' => 110, + ); + return $items; }; diff --git a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html new file mode 100644 index 000000000..c87523d64 --- /dev/null +++ b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html @@ -0,0 +1,101 @@ +
      +

      Harvest Report

      +

      This page is a mockup of a simplified harvest report.

      + + + + +

      + + + + + + +

      + + + + + + + +

      + + +
      + +

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      +

      Details: +

        +
      • Farm:Sample Farm
      • +
      • User:manager1
      • +
      • Language:English
      • +
        +
      • Start:{{startDate}}
      • +
      • End:{{endDate}}
      • +
      • Crop:{{crop}}
      • +
      +

      + + + + + + + + + + + + + + + + +
      DateAreaCropYieldUnits
      {{report.date}}{{report.area}}{{report.crop}}{{report.yield}}{{report.units}}
      +
      + + \ No newline at end of file From 10f45484b6dc38503ee28582929008fda0fc9d71 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 23:08:30 -0400 Subject: [PATCH 17/22] Made the harvest report table in the FD2-School Vue2 sub-tab start empty and then fill out with rows once the Generate Report button is clicked --- farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html index c87523d64..2a9ecb45c 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html @@ -36,7 +36,8 @@

      Harvest Report



      - +
      @@ -90,8 +91,7 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      "SQ7", ], reports: [ - {date: "2018-05-02", area: "Chuau-1", crop: "Kale", yield: 10, units: "Bunches"}, - {date: "2018-05-05", area: "SQ7", crop: "Kale", yield: 7, units: "Bunches"}, + ], } From 532b5afaf036f4df2bf35170dd896a518132bbb0 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 23:26:37 -0400 Subject: [PATCH 18/22] Abstracted the update functionality of the harvest report table to a method --- farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html index 2a9ecb45c..82b689474 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html @@ -37,7 +37,7 @@

      Harvest Report



      + @click="saveReport"/>
      @@ -91,8 +91,13 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      "SQ7", ], reports: [ - + ], + }, + methods: { + saveReport: function() { + this.reports.push({date: "2018-05-02", area: "Chuau-1", crop: "Kale", yield: 10, units: "Bunches"}) + } } }) From fa0e43734c66cefd02f8375c90ccc8a45bafca06 Mon Sep 17 00:00:00 2001 From: bussm Date: Sat, 3 May 2025 23:33:15 -0400 Subject: [PATCH 19/22] Added row column to the harvest report table --- farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html index 82b689474..890774e1c 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html @@ -56,13 +56,15 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      + - + + From d3b23c5b678a77f3865238b91277c8ec434b821a Mon Sep 17 00:00:00 2001 From: bussm Date: Sun, 4 May 2025 00:19:15 -0400 Subject: [PATCH 20/22] Added column of Delete buttons to the harvest report table that remove the button's row from the table --- farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html index 890774e1c..fc875200e 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html @@ -36,8 +36,7 @@

      Harvest Report



      - +
      @@ -62,14 +61,16 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      + - + +
      Row Date Area Crop Yield Units
      {{index + 1}} {{report.date}} {{report.area}} {{report.crop}}Crop Yield UnitsDelete
      {{index + 1}}{{report.date}}{{report.date }} {{report.area}} {{report.crop}} {{report.yield}} {{report.units}}
      @@ -99,6 +100,9 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      methods: { saveReport: function() { this.reports.push({date: "2018-05-02", area: "Chuau-1", crop: "Kale", yield: 10, units: "Bunches"}) + }, + deleteReport: function(index) { + this.reports.splice(index, 1) } } From b62c4f13e89186ff91a614b7e2e9278d912fc409 Mon Sep 17 00:00:00 2001 From: bussm Date: Sun, 4 May 2025 00:33:11 -0400 Subject: [PATCH 21/22] Gave the harvest report table a default state that indicates there are no reports if there are not any --- farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html index fc875200e..f913c3435 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html @@ -54,7 +54,8 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      - + + @@ -63,6 +64,7 @@

      {{reportTitle=="" ? "Mock Harvest Report" : reportTitle}}

      + From b62827e5a5b6b9b7fb8635a3af47c82a59a135c9 Mon Sep 17 00:00:00 2001 From: bussm Date: Sun, 4 May 2025 00:42:31 -0400 Subject: [PATCH 22/22] Restricted the date input elements to prevent the start date coming after the end date or the end date coming before the start date on the FD2-School Vue2 sub-tab --- farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html index f913c3435..77b1c9f7f 100644 --- a/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html +++ b/farmdata2/farmdata2_modules/fd2_school/vue2/vue2.html @@ -13,14 +13,14 @@

      Harvest Report

      id="start" name="start" min="2014-01-01" - max="2022-01-01" /> + :max="endDate"/>

      There are no matching records!
      Row Date Area Units Delete
      {{index + 1}} {{report.date }}