Resolve employee search on kanban board.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { Select, Tag } from "antd";
|
||||
import { Select, Space, Tag } from "antd";
|
||||
import React, { forwardRef, useEffect, useState } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
const { Option } = Select;
|
||||
@@ -37,7 +37,7 @@ const EmployeeSearchSelect = (
|
||||
search={`${o.employee_number} ${o.first_name} ${o.last_name}`}
|
||||
discount={o.discount}
|
||||
>
|
||||
<div style={{ display: "flex" }}>
|
||||
<Space>
|
||||
{`${o.employee_number} ${o.first_name} ${o.last_name}`}
|
||||
<Tag color="blue">{o.cost_center}</Tag>
|
||||
|
||||
@@ -46,7 +46,7 @@ const EmployeeSearchSelect = (
|
||||
? t("timetickets.labels.flat_rate")
|
||||
: t("timetickets.labels.straight_time")}
|
||||
</Tag>
|
||||
</div>
|
||||
</Space>
|
||||
</Option>
|
||||
))
|
||||
: null}
|
||||
|
||||
@@ -21,7 +21,7 @@ export function ProductionBoardFilters({ bodyshop, filter, setFilter }) {
|
||||
const { t } = useTranslation();
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div style={{ display: "flex" }}>
|
||||
<Input.Search
|
||||
//value={filter.search}
|
||||
placeholder={t("general.labels.search")}
|
||||
@@ -32,6 +32,7 @@ export function ProductionBoardFilters({ bodyshop, filter, setFilter }) {
|
||||
<EmployeeSearchSelectComponent
|
||||
options={bodyshop.employees}
|
||||
value={filter.employeeId}
|
||||
placeholder={t("production.labels.employeesearch")}
|
||||
onChange={(emp) => setFilter({ ...filter, employeeId: emp })}
|
||||
allowClear
|
||||
/>
|
||||
|
||||
@@ -63,10 +63,10 @@ export const createBoardData = (AllStatuses, Jobs, filter) => {
|
||||
|
||||
if (!!employeeId) {
|
||||
include =
|
||||
include &&
|
||||
(j.employee_body === employeeId ||
|
||||
j.employee_prep === employeeId ||
|
||||
j.employee_refinish === employeeId);
|
||||
include ||
|
||||
j.employee_body === employeeId ||
|
||||
j.employee_prep === employeeId ||
|
||||
j.employee_refinish === employeeId;
|
||||
}
|
||||
|
||||
return include;
|
||||
|
||||
@@ -1380,6 +1380,7 @@
|
||||
"bodyhours": "B",
|
||||
"bodypriority": "B/P",
|
||||
"cycletime": "C/T",
|
||||
"employeesearch": "Employee Search",
|
||||
"jobdetail": "Job Details",
|
||||
"note": "Production Note",
|
||||
"paintpriority": "P/P",
|
||||
|
||||
@@ -1380,6 +1380,7 @@
|
||||
"bodyhours": "",
|
||||
"bodypriority": "",
|
||||
"cycletime": "",
|
||||
"employeesearch": "",
|
||||
"jobdetail": "",
|
||||
"note": "",
|
||||
"paintpriority": "",
|
||||
|
||||
@@ -1380,6 +1380,7 @@
|
||||
"bodyhours": "",
|
||||
"bodypriority": "",
|
||||
"cycletime": "",
|
||||
"employeesearch": "",
|
||||
"jobdetail": "",
|
||||
"note": "",
|
||||
"paintpriority": "",
|
||||
|
||||
Reference in New Issue
Block a user