feature/IO-3624-Shop-Config-UX-Refresh - Add missing es/fr keys to translations

This commit is contained in:
Dave
2026-03-24 13:50:57 -04:00
parent fd712da4a3
commit dd306e1a7b
2 changed files with 21 additions and 9 deletions

View File

@@ -43,6 +43,9 @@ export function ShopEmployeesFormComponent({ bodyshop }) {
const { t } = useTranslation();
const [form] = useForm();
const employeeRates = Form.useWatch(["rates"], form) || [];
const employeeNumber = Form.useWatch("employee_number", form);
const firstName = Form.useWatch("first_name", form);
const lastName = Form.useWatch("last_name", form);
const employeeOptionsColProps = {
xs: 24,
sm: 12,
@@ -61,6 +64,10 @@ export function ShopEmployeesFormComponent({ bodyshop }) {
nextFetchPolicy: "network-only"
});
const notification = useNotification();
const employeeTitleName = [firstName, lastName].filter(Boolean).join(" ").trim();
const employeeCardTitle =
[employeeNumber, employeeTitleName].filter(Boolean).join(" - ") ||
(search.employeeId === "new" ? t("employees.actions.new") : t("bodyshop.labels.employees"));
const {
treatments: { Enhanced_Payroll }
@@ -179,6 +186,7 @@ export function ShopEmployeesFormComponent({ bodyshop }) {
return (
<Card
title={employeeCardTitle}
extra={
<Button type="primary" onClick={() => form.submit()}>
{t("general.actions.save")}
@@ -379,9 +387,7 @@ export function ShopEmployeesFormComponent({ bodyshop }) {
>
<Form.Item
label={t("employees.fields.cost_center")}
key={`${index}`}
name={[field.name, "cost_center"]}
valuePropName="value"
rules={[
{
required: true
@@ -406,7 +412,6 @@ export function ShopEmployeesFormComponent({ bodyshop }) {
</Form.Item>
<Form.Item
label={t("employees.fields.rate")}
key={`${index}`}
name={[field.name, "rate"]}
rules={[
{