Update time ticket areas added to use translations
This commit is contained in:
@@ -10,12 +10,6 @@ import { QUERY_EMPLOYEE_BY_ID } from "../../graphql/employees.queries";
|
||||
import { useEffect } from "react";
|
||||
import { t } from "i18next";
|
||||
|
||||
const data = [
|
||||
{ label: "Item 1", value: "1" },
|
||||
{ label: "Item 2", value: "3" },
|
||||
{ label: "Item 3", value: "3" },
|
||||
];
|
||||
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
bodyshop: selectBodyshop
|
||||
// timeTicketJobId: selectCurrentTimeTicketJobId,
|
||||
@@ -62,8 +56,8 @@ export function CostCenterSelect(props) {
|
||||
maxHeight={300}
|
||||
labelField="label"
|
||||
valueField="value"
|
||||
placeholder={!isFocus ? "Select Cost Center" : "..."}
|
||||
searchPlaceholder="Search..."
|
||||
placeholder={!isFocus ? t("selectcostcenter.labels.placeholder") : t("selectcostcenter.labels.selectedplaceholder")}
|
||||
searchPlaceholder={t("selectcostcenter.labels.searchplaceholder")}
|
||||
onFocus={() => setIsFocus(true)}
|
||||
onBlur={() => setIsFocus(false)}
|
||||
data={costCenters}
|
||||
|
||||
@@ -96,7 +96,7 @@ export function JobIdSearchSelect(
|
||||
useEffect(() => {
|
||||
// console.log("useEfectDependentOn: [theOptions]");
|
||||
var count = Object.keys(theOptions).length;
|
||||
console.log("useEfectDependentOn: [theOptions] count:", count);
|
||||
// console.log("useEfectDependentOn: [theOptions] count:", count);
|
||||
let selectDataArray = [];
|
||||
for (let i = 0; i < count; i++) {
|
||||
selectDataArray.push({
|
||||
@@ -131,8 +131,8 @@ export function JobIdSearchSelect(
|
||||
maxHeight={300}
|
||||
labelField="label"
|
||||
valueField="value"
|
||||
placeholder={!isFocus ? "RO #" : "..."}
|
||||
searchPlaceholder="Search..."
|
||||
placeholder={!isFocus ? t("selectjobid.labels.placeholder") : t("selectjobid.labels.selectedplaceholder")}
|
||||
searchPlaceholder={t("selectjobid.labels.searchplaceholder")}
|
||||
onFocus={() => setIsFocus(true)}
|
||||
onBlur={() => setIsFocus(false)}
|
||||
data={selectorData}
|
||||
|
||||
Reference in New Issue
Block a user