# Job Profitability record

## Job Profitability records

A Job Profitability record is the surface for comparing one sales job's actual
revenue, direct cost, gross profit, and gross margin. Use the summary first, then
inspect **Purchasing Cost** for purchase-order items and Additional Cost for cost
transactions grouped by cost type.

| If you need to… | Go to |
|---|---|
| Check the job's sales price, direct cost, gross profit, or gross margin | [Read the financial summary](#read-the-financial-summary) |
| Review purchase-order items | [Inspect order and direct-cost detail](#inspect-order-and-direct-cost-detail) |
| Review additional cost transactions | [Inspect order and direct-cost detail](#inspect-order-and-direct-cost-detail) |
| Understand why a measure or detail row is shown differently | [Handle conditional detail](#handle-conditional-detail) |
| Find the list that leads to a record | [Find and open a Job Profitability record](#find-and-open-a-job-profitability-record) |
| Enter a direct-cost transaction | Cost transactions |
| Choose among Job Profitability list tabs | Job Profitability |
| Read the wider sales-job context | [Sales job record](https://pams-doc-test-fresh.atloria.app/p/pams-doc-test-fresh-N9B4TwWn3Q/user/sales-job-record) |

![Running Jobs list with the profitability columns and list controls](https://atloriaassets.blob.core.windows.net/assets/a438221c-c1af-407c-b9e6-a56c986db846/c8298ff2bab32fba1e46134e12c5c2ad.png)

## Before you start

The Job Profitability surface appears only when the subscription, page state, sales
job, selected work area, and access conditions allow it. Its record form requires
**Client** and **Job Title**.

Before opening the surface, have the following in place:

| Check | What must be true | Why it matters |
|---|---|---|
| Subscription | Your subscription grants Job Profitability access | Job Profitability does not appear when the subscription excludes it. |
| Page state | The page loads as a record page, not a not-found page | A not-found page does not render the record surface. |
| Sales job | A sales job with an identifier is available | The embedded record area requires the job identifier. |
| Work area | The sales job is on the Job Costing work area | The embedded record is shown for the active Job Costing tab. |
| Access | Your access allows Job Profitability work | The embedded area checks the Job Profitability permission before appearing. |
| Record information | The sales job has **Client** and **Job Title** values | Both fields are required by the record form. |

The routed record requires signed-in access, and leaving the form is guarded when the
page has changes that need protection.

## Find and open a Job Profitability record

Use a Job Profitability list to choose a profitability view, or use the direct-cost
transaction list when your next task is a cost transaction. The **Running Jobs** list
is the running-job view for this work.

**Prerequisites**

- You have the access, subscription, and saved sales-job conditions in [Before you start](#before-you-start).
- You know which saved sales job you need to review.

**Steps**

1. Choose the list that matches your next task.

   | If you need to… | Choose |
   |---|---|
   | Compare profitability for a job | Job Profitability |
   | Work with a direct-cost transaction | Cost transactions |

2. Open the **Running Jobs** list.

3. Use the visible list controls as needed: **Refresh**, **Table Layout**, or **Settings**.

4. Identify the job from the visible columns, including **Job No.**, Gross Margin (€),
   Gross Margin (ج.م.‏), Total Direct Cost (€), Purchase Cost (€), Purchase Cost (ج.م.‏),
   Other Direct Cost (€), Sales price (€), and Client.

5. Open the row using its available open control.

**Result:** The **Running Jobs** list is on screen with its listed columns and controls.

## Read the financial summary

The financial summary shows four profitability measures for the currency selected on
the record. Select **Reference Currency** or **Local currency** to compare the same
measures in either currency view.

| Currency view | Measures |
|---|---|
| **Reference Currency** | **Sales Price**, **Actual Direct Cost**, **Gross profit**, **Gross margin** |
| **Local currency** | **Sales Price**, **Actual Direct Cost**, **Gross profit**, **Gross margin** |

The metric controls are disabled and read-only. Read the values shown for the selected
currency rather than entering replacement figures. **Actual Revenue** is not shown in
the record summary.

After opening the record, use the selected currency view to read its measures.

## Inspect order and direct-cost detail

The detail area separates committed purchasing from other direct costs. The
**Purchasing Cost** group contains purchase-order items. The Additional Cost group
contains cost transactions grouped by cost type.

**Prerequisites**

- You have opened the Job Profitability surface for a sales job.
- You can identify the purchase order or cost transaction you need to inspect.

**Steps**

1. In the **Purchasing Cost** group, select **POs** to expand the purchase items.

2. Select the purchase-order number to open the procurement edit page in a new window.

3. In the Additional Cost group, select the cost group row to show its transaction
   detail when the group has more than one item.

4. Select the transaction number to open the cost-transaction edit page in a new window.

5. If editing is allowed, select **Direct Cost** to start the additional-cost action.

**Result:** You can distinguish purchase-order items from additional-cost transactions,
and the selected purchase order or transaction opens in its owning page.

## Handle conditional detail

The record can show different currency measures and detail rows because each area is
conditional. Check the applicable condition before interpreting a missing measure or row.

| Area | It appears when… |
|---|---|
| Reference-currency measures | The selected currency matches the branch's currency. |
| Local-currency measures | The selected currency matches the local currency. |
| Purchase-order detail | The purchase-item group is expanded. |
| Additional-cost detail | The cost has more than one item and its detail is not collapsed. |
| **Direct Cost** | Editing is allowed. |

Select **POs** to expand or collapse purchase items. Additional-cost visibility is
controlled by the cost group's collapsed state when it contains more than one item.

## When validation or access goes wrong

Use the message text to identify whether the form needs a value, rejects characters, or
does not allow the requested operation. Then apply the matching fix in the table.

| What you see | What to do |
|---|---|
| `Validation errors:` | Review the fields highlighted by the validation summary. |
| `This Field Is Required` | Enter the required value before continuing. |
| `Input contains forbidden characters(< , >). Please remove them and try again.` | Remove the forbidden characters and enter the value again. |
| `You don’t have permission` | Continue only with an account that has the required access. |

### Direct-cost messages

The **Direct Cost** hand-off can raise the following validation messages. The complete
entry procedure belongs to Cost transactions; use these messages to recognise the
problem before continuing there.

| Message | Check |
|---|---|
| `Please select at least one order.` | Select an order. |
| `Please select at least one item/product.` | Select an item or product. |
| `Please enter the percentage value or delete unused items.` | Enter the percentage or remove unused items. |
| `Please adjust cost allocation.` | Adjust the allocation. |
| `Please enter valid amount.` | Enter a valid amount. |
| `Please choose cost type.` | Choose a cost type. |
| `Please choose provider.` | Choose a provider. |
| `Please enter Transaction Title.` | Enter the transaction title. |
| `Please choose payment due date.` | Choose the payment due date. |
| `Just '-' '_' and '.' are the only characters that are accepted.` | Use only the accepted characters in that field. |
| `Your request was completed successfully` | The direct-cost request completed successfully. |
| `An error occurred while processing your request` | The direct-cost request encountered an error. |

## Continue with the detailed work

Use the owning pages for work that goes beyond reading this record. **Cost
transactions** owns direct-cost transaction entry and allocation records. **Job
Profitability** owns the profitability list tabs and list selection. Use [Sales job
record](https://pams-doc-test-fresh.atloria.app/p/pams-doc-test-fresh-N9B4TwWn3Q/user/sales-job-record) when you need the broader sales-job context; it is an
optional related-work hand-off from this page.
