update Employee field to show first and last name
This commit is contained in:
@@ -11,6 +11,7 @@ import DateTimePickerModal from "react-native-modal-datetime-picker";
|
||||
import {
|
||||
selectCurrentEmployee,
|
||||
selectRates,
|
||||
selectEmployeeFullName
|
||||
} from "../../redux/employee/employee.selectors";
|
||||
import { selectBodyshop } from "../../redux/user/user.selectors";
|
||||
import { useCallback } from "react";
|
||||
@@ -29,6 +30,7 @@ const mapStateToProps = createStructuredSelector({
|
||||
currentEmployee: selectCurrentEmployee,
|
||||
currentRatesNCostCenters: selectRates,
|
||||
currentBodyshop: selectBodyshop,
|
||||
currentEmployeeFullName: selectEmployeeFullName
|
||||
});
|
||||
// const mapDispatchToProps = (dispatch) => ({});
|
||||
|
||||
@@ -36,6 +38,7 @@ export function TimeTicketCreate({
|
||||
currentEmployee,
|
||||
currentRatesNCostCenters,
|
||||
currentBodyshop,
|
||||
currentEmployeeFullName
|
||||
}) {
|
||||
const navigation = useNavigation();
|
||||
const { t } = useTranslation();
|
||||
@@ -183,7 +186,7 @@ export function TimeTicketCreate({
|
||||
initialValues={{
|
||||
jobid: { currentSJobId },
|
||||
ticketdate: date2.toLocaleDateString(),
|
||||
employee: currentEmployee.technician.first_name,
|
||||
employee: {currentEmployeeFullName},
|
||||
costcenter: { currentSCC },
|
||||
productivehours: "",
|
||||
actualhours: "",
|
||||
|
||||
Reference in New Issue
Block a user