diff --git a/html/template/sync/component/sidebar.html b/html/template/sync/component/sidebar.html index dc02eeca..05c9c6a1 100644 --- a/html/template/sync/component/sidebar.html +++ b/html/template/sync/component/sidebar.html @@ -32,6 +32,17 @@ Admin +
  • + + + Download + +
  • Settings
  • +
  • + + + Upload + +
  • + .report-card { + transition: all 0.3s; + border-radius: 10px; + } + .report-card:hover { + transform: translateY(-5px); + box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1); + } + .card-header { + border-radius: 10px 10px 0 0 !important; + } + .report-item { + padding: 12px; + border-left: 4px solid transparent; + transition: all 0.2s; + } + .report-item:hover { + background-color: rgba(0, 0, 0, 0.05); + border-left: 4px solid #0d6efd; + } + body { + background-color: #f8f9fa; + } + +{{ end }} +{{ define "content" }} +
    +
    + +
    +
    +
    +

    + Technician Supervision +

    +
    +
    + + +
    + +
    +
    Coverage Maps
    +

    Area coverage by region

    +
    + +
    + +
    + +
    +
    Performance
    +

    + Staff evaluations and metrics +

    +
    + +
    +
    +
    +
    + + +
    +
    +
    +

    + Inventory Management +

    +
    +
    +
    + +
    +
    Recent Orders
    +

    + Purchase orders and deliveries +

    +
    + +
    + +
    + +
    +
    Current Stock
    +

    Inventory levels and status

    +
    + +
    + +
    + +
    +
    Usage Rates
    +

    Consumption analytics

    +
    + +
    +
    +
    +
    + + +
    +
    +
    +

    + Lab Reports +

    +
    +
    +
    + +
    +
    Trap Counts
    +

    Regional trap data analysis

    +
    + +
    + +
    + +
    +
    Rate Changes
    +

    Population fluctuation data

    +
    + +
    + +
    + +
    +
    Disease Propagation
    +

    Health risk assessment data

    +
    + +
    +
    +
    +
    +
    +
    +{{ end }} diff --git a/html/template/sync/upload-list.html b/html/template/sync/upload-list.html new file mode 100644 index 00000000..016ec4f9 --- /dev/null +++ b/html/template/sync/upload-list.html @@ -0,0 +1,172 @@ +{{ template "sync/layout/authenticated.html" . }} + +{{ define "title" }}Downloads{{ end }} +{{ define "extraheader" }} + +{{ end }} + +{{ define "content" }} +
    +
    +
    +
    + + Select a data type below to import information into the system. + Supported file formats include CSV, Excel, and PDF documents. +
    +
    +
    + +
    + +
    +
    +
    + +
    Green Pool Management
    +

    + Upload spreadsheets with addresses and contact information of + unmaintained pools that may breed mosquitoes. +

    +

    Supported formats: .xlsx, .csv, .xls

    +
    + + +
    + +
    + +
    +
    + + +
    +
    +
    + +
    Employee Information
    +

    + Import employee data including names, contact information, and + responsibilities for system user creation. +

    +

    Supported formats: .xlsx, .csv

    +
    + + +
    + +
    + +
    +
    + + +
    +
    +
    + +
    Field Notebooks
    +

    + Upload scanned technician field notebooks to digitize information + about breeding sources they've identified. +

    +

    Supported formats: .pdf, .jpg, .png

    +
    + + +
    + +
    + +
    +
    +
    + + +
    +
    +

    Recent Import History

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Date/TimeImport TypeFilenameStatusRecordsActions
    03/15/2023 09:32 AMField Notebooksmarch-field-notes.pdfComplete42 entries + +
    03/01/2023 02:15 PMEmployee Informationstaff-2023-update.xlsxComplete18 employees + +
    02/15/2023 10:45 AMGreen Pool Managementfeb-pools.csvComplete157 properties + +
    +
    +
    +
    +{{ end }} diff --git a/sync/download.go b/sync/download.go new file mode 100644 index 00000000..a4f05d80 --- /dev/null +++ b/sync/download.go @@ -0,0 +1,14 @@ +package sync + +import ( + "context" + + "github.com/Gleipnir-Technology/nidus-sync/db/models" +) + +type contentDownloadPlaceholder struct{} + +func getDownloadList(ctx context.Context, user *models.User) (string, interface{}, *errorWithStatus) { + content := contentSettingPlaceholder{} + return "sync/download-list.html", content, nil +} diff --git a/sync/routes.go b/sync/routes.go index e94d1b31..88eba540 100644 --- a/sync/routes.go +++ b/sync/routes.go @@ -47,6 +47,7 @@ func Router() chi.Router { r.Route("/api", api.AddRoutes) r.Method("GET", "/admin", authenticatedHandler(getAdminDash)) r.Method("GET", "/cell/{cell}", auth.NewEnsureAuth(getCellDetails)) + r.Method("GET", "/download", authenticatedHandler(getDownloadList)) r.Method("GET", "/layout-test", auth.NewEnsureAuth(getLayoutTest)) r.Method("GET", "/message", authenticatedHandler(getMessageList)) r.Method("GET", "/notification", auth.NewEnsureAuth(getNotificationList)) @@ -67,6 +68,7 @@ func Router() chi.Router { r.Method("GET", "/stadia", auth.NewEnsureAuth(getStadia)) r.Method("GET", "/trap/{globalid}", auth.NewEnsureAuth(getTrap)) r.Method("GET", "/text/{destination}", auth.NewEnsureAuth(getTextMessages)) + r.Method("GET", "/upload", authenticatedHandler(getUploadList)) html.AddStaticRoute(r, "/static") return r diff --git a/sync/upload.go b/sync/upload.go new file mode 100644 index 00000000..23c072ab --- /dev/null +++ b/sync/upload.go @@ -0,0 +1,14 @@ +package sync + +import ( + "context" + + "github.com/Gleipnir-Technology/nidus-sync/db/models" +) + +type contentUploadPlaceholder struct{} + +func getUploadList(ctx context.Context, user *models.User) (string, interface{}, *errorWithStatus) { + content := contentUploadPlaceholder{} + return "sync/upload-list.html", content, nil +}