updates on the fix

This commit is contained in:
2026-08-12 12:55:18 +05:30
parent bf28249528
commit fabb74c326
15 changed files with 1478 additions and 528 deletions

View File

@@ -673,7 +673,7 @@ export default function OrdersDetails() {
<Grid item xs={12} sm={6} md={3}>
<Autocomplete
options={locationlist || []}
getOptionLabel={(option) => (option ? `${option.locationname} (${option.suburb})` : '')}
getOptionLabel={(option) => (option?.locationname ? `${option.locationname}${option.suburb ? ` (${option.suburb})` : ''}` : '')}
value={locationValue}
PaperComponent={SoftPaper}
onOpen={(event) => {
@@ -725,7 +725,10 @@ export default function OrdersDetails() {
<Autocomplete
options={ridersList || []}
value={riderValue}
getOptionLabel={(option) => `${option.firstname} ${option.lastname}`}
getOptionLabel={(option) => {
const name = option?.displayname || option?.authname || '';
return option?.contactno ? `${name} (${option.contactno})` : name;
}}
PaperComponent={SoftPaper}
onOpen={() => {
if (!appId) {