Agriculture

Season accounting for farms: define fields and crops, open a season per planting, record its costs (seeds, irrigation, fertilizer, pesticides, labor, machinery…) which are capitalized automatically to the "crop work in progress" account, then record harvests that move the cost into the "harvest inventory" account — revealing the true cost per ton and the profitability of every season and field.

ℹ️ Logical flow: Define fields and crops once → open a season (crop + field + start date) → record its costs as they occur (each one posts its journal entry instantly) → at picking record harvests that transfer cost from WIP to harvest inventory → after the final pick close the season to lock in its result.

Before you start: module accounts

Purpose: the Agriculture module posts automatically, so — once only — two chart-of-accounts links must be configured in Settings › Accounts before saving the first cost or harvest:

Setting keyAccountUsed for
Agri.CropWipAccountCodeCrop work in progress (WIP)Debited by every season cost; credited by every harvest value.
Agri.HarvestInventoryAccountCodeHarvest inventoryDebited by the harvest value when a harvest is recorded.
Comm.CashAccountCodeDefault cash boxThe credit side of a season cost when no cash box is chosen on the form.
⚠️ Note: if these accounts are not configured the system refuses to save the cost/harvest with an explicit message such as "Configure Agri.CropWipAccountCode in الحسابات settings" — set them first, then retry.

Permissions: each screen has its own permissions granted from role management: AGRI.Fields.* and AGRI.Crops.* (view/create/edit/delete), AGRI.Seasons.* (view/create/edit — closing requires the edit permission), AGRI.Costs.* and AGRI.Harvests.* (view/create).

Fields

Route: Agriculture › Fields/agri/fields

Fields
Field list

Purpose: master data defined once: each field (or farm/plot) with its code, name, area in feddan and location. The field is one side of every season, and it lets you compare field productivity and cost across years.

When to use it: during initial setup, when renting/buying new land, or to deactivate a field taken out of service.

Create/edit screen fields

FieldRequiredDescription
CodeAutoSuggested automatically in sequence and read-only on the form; must be unique — duplicates are rejected with "Field code already exists".
Arabic nameYesThe field name shown in seasons and lists.
English nameNoOptional; if left empty the Arabic name is used.
Area (feddan)NoNumber with 2 decimals, cannot be negative. The list shows its total, giving overall farmed area.
LocationNoFree text: village/road/coordinates… to tell fields apart.
ActiveShown only when editing. An inactive field disappears from the field picker of new seasons without losing its history.
  1. From the list click "Create" — the form opens with the code pre-suggested.
  2. Enter the Arabic name (required), the area and the location.
  3. Save with "Save", or "Save & New" to enter several fields in a row; "Back" cancels.
  4. Next to the form is a record notes panel for permanent notes about the field (soil type, water source…).
⚠️ Deleting: a field linked to any season cannot be deleted — the system refuses with "Field has seasons". The right alternative: untick "Active" so it disappears from pickers while keeping its history.

FAQ

Q: I plant the same field in summer and winter — do I define it twice?
A: No. The field is defined once; open a new season on it for each planting — costs are separated by season, not by field.

Q: We measure in hectares, not feddan?
A: The area box is a plain number labeled "feddan"; in practice you can enter values in your own unit as long as you use one unit consistently across all fields so totals and comparisons stay meaningful.

Q: I split a large field into two plots — what should I do?
A: Define the two plots as new fields with their areas and deactivate the old field (untick "Active"); old seasons stay on the old field for history.

Crops

Route: Agriculture › Crops/agri/crops

Crops
Crop list

Purpose: master data: the list of what you grow (wheat, dates, tomatoes…) with a code and Arabic/English names. The crop is the second side of a season's definition, and profitability reports group by it.

Create/edit screen fields

FieldRequiredDescription
CodeAutoAuto-suggested and unique — duplicates are rejected with "Crop code already exists".
Arabic nameYesThe crop name shown in seasons and reports.
English nameNoOptional; the Arabic name is used if left empty.
ActiveWhen editing only. An inactive crop disappears from the new-season picker.
ℹ️ Production unit: the unit (ton/box…) is not set here; it is written on each harvest document (default "طن" — ton) — stick to one unit per crop so quantity totals stay valid.
⚠️ Deleting: a crop with recorded seasons cannot be deleted ("Crop has seasons") — deactivate it by unticking "Active" instead.

FAQ

Q: I grow two wheat varieties (local and imported) — one crop or two?
A: If you want to compare their cost and profitability, define them as two separate crops; if treated identically, one crop is enough.

Q: Is the crop linked to a stock item in the Inventory module?
A: There is no automatic link; the harvest posts its value to the harvest inventory account in the chart of accounts. When selling, you issue a sales invoice with whatever item you use, and the harvest inventory account is settled by accounting entry.

Q: I entered the Arabic name only — what shows in the English interface?
A: The system automatically uses the Arabic name as the English name until you edit it later.

Seasons

Route: Agriculture › Seasons/agri/seasons

Seasons
Season list
New season
New season

Purpose: the season is the cost container: crop + field + period (e.g. Wheat 2026 — North field). Every cost and every harvest is recorded against a specific season, and the list shows each season's live totals: costs, harvest quantity, harvest value and profit.

The two season statuses: Open accepts costs and harvests — Closed is finished and accepts no further documents.

"New season" screen fields

FieldRequiredDescription
CropYesPick from active crops only, with in-list search.
FieldYesPick from active fields only.
Start dateYesDefaults to today. Determines the fiscal year the season belongs to.
NotesNoFree text (seed variety, planting plan…).

On save the system assigns a sequential document number in the form SEAS-00001 and links the season to the default branch. "Save & New" keeps you on the screen to open another season.

List columns

ColumnMeaning
Season noThe sequential number SEAS-….
Crop / FieldThe two sides of the definition.
Start dateBeginning of the season.
CostsSum of all posted season costs — updates automatically with every cost.
Harvest qtySum of harvest document quantities.
Harvest valueSum of harvest document values.
ProfitComputed automatically = harvest value − costs.
StatusOpen (green) or Closed (grey).

Closing a season

  1. Make sure every cost and every harvest has been recorded — after closing, the season accepts no documents.
  2. On the season's row (Open seasons only) click the lock icon "Close season".
  3. It switches to "Closed" immediately, and its end date is fixed to today if not already set.
⚠️ Closing is immediate and final: the button executes at once with no confirmation dialog, and there is no "reopen" on the screen. Any cost or harvest against a closed season is rejected with "Season is closed". Be sure before clicking.

FAQ

Q: Profit shows zero or negative although the season is profitable — why?
A: The column compares the recorded harvest value with costs. If you value harvests at cost (the recommended practice) it will naturally be near zero, and the real profit appears when the produce is sold via sales invoices. A large negative usually means not all harvests are recorded yet.

Q: Can two seasons run on the same field at the same time?
A: Yes — the system does not prevent it (intercropping, for example). Just take care to pick the right season when recording costs.

Q: I closed a season by mistake before the last harvest — what now?
A: There is no reopen on the screen. Record the remaining effect with a manual journal entry from the Accounting module, or refer to your system administrator.

Season costs

Route: Agriculture › Season Costs/agri/costs

Season costs
Season cost list

Purpose: record every expense against its season the moment it happens. The document is created and posted instantly in the same save: the amount is capitalized to "crop work in progress" against the chosen cash box, and accumulates in the "Costs" column of the season list.

When to use it: buying seed, an irrigation bill, daily labor wages, tractor rental… everything spent on the season before harvest.

"New season cost" screen fields

FieldRequiredDescription
DateYesDefaults to today; determines the entry's fiscal year.
SeasonYesList of Open seasons only, shown as: season no − crop / field, with search.
Cost typeYesOne of seven types (table below); default "Irrigation".
AmountYesGreater than zero, 2 decimals — zero or negative blocks saving.
Cash boxNoA cash account from the defined payment accounts; the first is preselected, and if left empty the default cash box from settings is used.
DescriptionNoFree text shown in the list and in the journal entry narration.

Cost types

TypeExamples
SeedsCertified seed, seedlings.
IrrigationWater, pump electricity/diesel.
FertilizerChemical and organic fertilizers.
PesticidesInsecticides, fungicides, herbicides.
LaborDaily wages, weeding, picking.
MachineryTractor/combine rental, machine fuel.
OtherAnything not covered above.

Accounting effect (automatic on save)

AccountDebitCredit
Crop work in progressAmount
Chosen cash boxAmount

Document numbers follow ACST-00001. In the list, the book icon 📖 next to each cost shows its posted journal entry.

⚠️ No edit, no delete: the cost screen is create-and-view only — because the entry posts on save. Review the season, type and amount before saving; if you make a mistake, offset it with a reversing manual journal entry from the Accounting module.
💡 Fast entry: "Save & New" keeps the date, season and cash box and clears the amount and description — ideal for entering a batch of costs for the same season.

FAQ

Q: My season does not appear in the list?
A: The list shows Open seasons only — a closed season accepts no costs.

Q: I bought fertilizer on credit from a supplier, not cash?
A: This screen posts against a cash account (cash box). For credit purchases record the invoice in the Purchasing module against the supplier, then charge its value to the season according to your accounting policy (a manual entry to WIP).

Q: One expense belongs to two seasons (tractor fuel serving two fields)?
A: Split it manually: two documents with appropriate amounts, each on its season — there is no automatic allocation.

Harvests

Route: Agriculture › Harvests/agri/harvests

Harvests
Harvest list

Purpose: record what was picked from the season: quantity, unit and value. The document posts instantly: the value moves from "crop work in progress" to "harvest inventory", and the quantity and value are added to the season totals. A season accepts multiple harvests (picking in batches).

"New harvest" screen fields

FieldRequiredDescription
DateYesPicking date; defaults to today.
SeasonYesOpen seasons only (season no − crop / field).
QuantityYesGreater than zero, up to 3 decimals.
UnitNoFree text, default "طن" (ton) — keep one consistent unit per crop.
ValueYesGreater than zero — you enter it: the cost of this batch that will move from WIP to harvest inventory (see the tip below).
NotesNoFree text (quality grade, receiving store…).

Accounting effect (automatic on save)

AccountDebitCredit
Harvest inventoryValue
Crop work in progressValue

Document numbers follow HARV-00001, and the book icon 📖 in the list shows the entry.

💡 How to set the value? Recommended practice: value harvests at cost — unit cost = accumulated season costs ÷ total expected quantity, then value = this batch's quantity × unit cost. That way WIP nets exactly to zero after the last harvest, and inventory carries the true cost (see the full example below).
⚠️ No edit, no delete: like costs, the harvest document posts on save and cannot be edited from the screen — verify quantity and value before saving, and correct mistakes with a reversing entry if needed.

FAQ

Q: Does the system compute the value automatically from season costs?
A: No — the value is manual so you stay in control (partial picking, damaged crop…). Use the formula in the tip above.

Q: I picked in three batches — one document or three?
A: Three documents with their actual dates; totals accumulate on the season automatically while keeping each batch's detail.

Q: Where do I enter the receiving warehouse and quality grade?
A: There are no dedicated fields for them; note them in "Notes". The stock effect here is an accounting one (the harvest inventory account), not an item movement in warehouses.

💡 Module reports: in the Report Center: detailed season cost, season comparison, field productivity and per-crop margins.

Full example: a wheat season from opening to profit

A farm opens season Wheat 2026 — North field (document SEAS-00007). Here is the whole cycle in numbers:

1) Recording costs (80,000)

DocumentTypeDescriptionAmount
ACST-00031SeedsCertified wheat seed12,000
ACST-00032FertilizerUrea + superphosphate20,000
ACST-00033IrrigationPump diesel for the season8,000
ACST-00034PesticidesRust control5,000
ACST-00035LaborWeeding and picking25,000
ACST-00036MachineryCombine rental10,000
Total season costs80,000

Each document posted instantly: Dr Crop work in progress / Cr Cash box. WIP now carries a debit balance of 80,000, and the "Costs" column in the season list shows 80,000.

2) Cost per ton and recording harvests

Expected yield is 50 tons → cost per ton = 80,000 ÷ 50 = 1,600. The season is picked in two batches:

DocumentQtyUnitEntered valueAutomatic posting
HARV-0001130ton30 × 1,600 = 48,000Dr Harvest inventory 48,000 / Cr WIP 48,000
HARV-0001220ton20 × 1,600 = 32,000Dr Harvest inventory 32,000 / Cr WIP 32,000
Total: 50 tons80,000WIP balance = zero ✓

The season list now reads: Costs 80,000 — Harvest qty 50 — Harvest value 80,000 — Profit 0 (harvests were valued at cost, so all costs moved into inventory with no book gain or loss).

3) Closing, then selling

  1. After the last batch click "Close season" — it turns "Closed" and the end date is fixed.
  2. Sell the 50 tons at 2,100 per ton via the Sales module = revenue 105,000.
  3. Cost of goods sold = 80,000 (from the harvest inventory account) → actual season profit = 25,000, a 23.8% margin.
ℹ️ Summary: WIP accumulates during cultivation and is cleared by harvests; harvest inventory carries the cost until sale; the real profit appears at sale = sales − actual cost per ton.

Frequently asked questions

How do agricultural seasons work?

Create a season for a crop and field; record its costs (seeds, fertilizer, irrigation, labor) and harvests to see profit per season.

How do I record a harvest?

Open the season and add a harvest with quantity and value; the season profit updates as harvests and costs accumulate.

Can I track cost per crop or field?

Yes. Seasons are linked to crops and fields, so you can compare profitability across different crops and plots.

Does agriculture post to accounting?

Yes, season costs and harvest revenue flow to the general ledger for accurate financial reporting.