Skip to content

naravid19/mytree-journal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

219 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Contributors Forks Stargazers Issues MIT License

Logo

🌳 MyTree Journal

Simple, extensible tree record-keeping for researchers and hobbyists.
πŸ“š Explore the docs Β»

View Demo Β· Report Bug Β· Request Feature


πŸ“– Table of Contents


About The Project

Product Screenshot

MyTree Journal is a full-stack tree record-keeping system designed for simplicity and extensibility. Perfect for researchers, hobbyists, or small-to-medium scale cultivation projects.

Why MyTree Journal?

  • 🎯 Purpose-built for tree and plant tracking
  • πŸ“± Mobile-first responsive design
  • πŸŒ™ Dark mode support out of the box
  • πŸ“Έ Media management with automatic thumbnails
  • πŸ”— QR codes for easy sharing and tracking

(back to top)


Features

Core Functionality

Feature Description
🌱 Strain Management Organize plants by genetic strains
πŸ“¦ Batch Tracking Group plants by cultivation batches
🌳 Tree Records Comprehensive individual plant records
πŸ“Έ Media Attachments Images and documents per tree
πŸ“Š QR Codes Generate shareable QR codes

User Experience

Feature Description
🎨 Modern UI Organic Biophilic + Claymorphism design
🧱 Bento Grid Responsive dashboard with hero cards
🌐 Multi-lang Thai (TH) & English (EN) support
πŸ“± Responsive Works on desktop, tablet, and mobile
πŸŒ™ Dark Mode System-aware theme switching
⚑ Fast useMemo, useCallback optimizations
β™Ώ Accessible ARIA labels and keyboard navigation

Data Management

Feature Description
🧬 Genetics Track lineage, parents, and strains
πŸ“… Timeline Detailed lifecycle tracking
🌸 Pollination Breeding and seed harvest records
πŸ“‚ Smart Folders Auto-organize images by tree name
πŸ–ΌοΈ Thumbnails Automatic thumbnail generation
πŸ“€ Drag & Drop Upload files with drag-and-drop

(back to top)


Tech Stack

Backend

Django DRF

Frontend

Next.js React Tailwind CSS Flowbite

Infrastructure

Nginx

(back to top)


Project Structure

mytree-journal/
β”œβ”€β”€ πŸ“ mytree_journal/        # Django project configuration
β”‚   └── settings.py           # Database, CORS, timezone config
β”‚
β”œβ”€β”€ πŸ“ trees/                 # Django app (models, views, API)
β”‚   β”œβ”€β”€ models.py             # Strain, Batch, Tree, Image models
β”‚   β”œβ”€β”€ serializers.py        # DRF serializers
β”‚   β”œβ”€β”€ views.py              # API ViewSets
β”‚   └── migrations/           # Database migrations
β”‚
β”œβ”€β”€ πŸ“ mytree-frontend/       # Next.js frontend
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ page.tsx          # Dashboard
β”‚   β”‚   β”œβ”€β”€ types.ts          # TypeScript type definitions
β”‚   β”‚   β”œβ”€β”€ utils.ts          # Shared utility functions
β”‚   β”‚   β”œβ”€β”€ constants.ts      # App-wide constants
β”‚   β”‚   β”œβ”€β”€ strains/          # Strain management
β”‚   β”‚   β”œβ”€β”€ batches/          # Batch management
β”‚   β”‚   └── tree/[id]/        # Tree detail page
β”‚   β”œβ”€β”€ components/           # Reusable UI components
β”‚   β”‚   β”œβ”€β”€ TreeCard.tsx      # Tree card with clay styling
β”‚   β”‚   β”œβ”€β”€ DashboardStats.tsx # Bento grid stats
β”‚   β”‚   β”œβ”€β”€ InfoCard.tsx      # Reusable info card
β”‚   β”‚   └── Navbar.tsx        # Responsive navigation
β”‚   β”œβ”€β”€ constants/            # Shared constants
β”‚   β”‚   └── treeStatus.ts     # Tree status constants
β”‚   β”œβ”€β”€ services/             # API service layer
β”‚   β”‚   └── treeService.ts    # Tree API client
β”‚   β”œβ”€β”€ contexts/             # React contexts
β”‚   β”‚   └── LanguageContext.tsx # i18n context
β”‚   └── hooks/                # Custom React hooks
β”‚
β”œβ”€β”€ πŸ“ media/                 # Uploaded files
β”‚   β”œβ”€β”€ tree_images/          # Tree photos & thumbnails
β”‚   └── tree_documents/       # Attached documents
β”‚
β”œβ”€β”€ πŸ“ nginx/                 # Deployment config
β”œβ”€β”€ πŸ“„ requirements.txt       # Python dependencies
β”œβ”€β”€ πŸ“„ package.json           # Node.js dependencies
β”œβ”€β”€ πŸ“„ CHANGELOG.md           # Version history
└── πŸ“„ README.md              # This file

(back to top)


Getting Started

Prerequisites

Requirement Version
Node.js v22.13.1+
npm v10.8.3+
Python 3.11+
PostgreSQL 14+ (recommended)
Nginx For production

Installation

  1. Clone the repository

    git clone https://github.com/naravid19/mytree-journal.git
    cd mytree-journal
  2. Set up the backend

    # Create virtual environment (recommended)
    python -m venv venv
    source venv/bin/activate  # Windows: venv\Scripts\activate
    
    # Install dependencies
    pip install -r requirements.txt
    
    # Run migrations
    python manage.py migrate
  3. Set up the frontend

    cd mytree-frontend
    npm install
    cd ..

Environment Variables

Create .env in the project root:

DJANGO_ALLOWED_HOSTS=localhost,127.0.0.1,api.example.com

Create mytree-frontend/.env.local:

NEXT_PUBLIC_FRONTEND_ORIGIN=https://www.example.com
NEXT_PUBLIC_API_BASE_URL=https://api.example.com
NEXT_PUBLIC_MEDIA_DOMAIN=api.example.com

Quick Start

Option 1: One-click (Windows)

# Double-click start_app.bat

Option 2: Manual

# Terminal 1: Backend
python manage.py runserver

# Terminal 2: Frontend
cd mytree-frontend
npm run dev

Then open http://localhost:3000 in your browser.

(back to top)


Usage

Route Description
/ Dashboard - View and manage all trees
/strains Manage plant strains
/batches Manage cultivation batches
/tree/[id] Public tree detail page
/api/ REST API documentation

Data Models

  • Strain: Name, description, genetics information
  • Batch: Code, description, start date
  • Tree: Comprehensive plant data with relationships

Media Support

  • Images: JPEG, PNG, WebP (auto-thumbnails)
  • Documents: PDF attachments
  • Storage: Organized in media/tree_images/ and media/tree_documents/

(back to top)


Deployment

See the Nginx configuration example for production deployment.

Key features:

  • Static & media file serving
  • API reverse proxy
  • Security headers
  • HTTPS support (add your SSL config)

(back to top)


Roadmap

  • 🎨 Design system (Claymorphism + Bento Grid)
  • πŸ”§ Clean code refactoring
  • ⚑ Performance optimizations (useMemo, useCallback)
  • πŸ” Authentication & user management
  • πŸ” Advanced search & filtering
  • πŸ“± Progressive Web App (PWA)
  • πŸ‘₯ Multi-user collaboration
  • πŸ“Š Analytics dashboard

See the open issues for a full list of proposed features.

(back to top)


Contributing

Contributions are what make the open-source community amazing! Any contributions are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)


License

Distributed under the MIT License. See LICENSE for more information.

(back to top)


Contact

Project Link: https://github.com/naravid19/mytree-journal

(back to top)


Acknowledgments

(back to top)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published