@djb25/digit-ui-module-vendor 1.0.18 → 1.0.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
- import React, { useEffect, useMemo, useCallback, useState, Fragment } from 'react';
1
+ import React, { useEffect, useMemo, useCallback, useState } from 'react';
2
2
  import { useTranslation } from 'react-i18next';
3
3
  import { useParams, useLocation, Switch, Link, useHistory, useRouteMatch, Route, Redirect } from 'react-router-dom';
4
- import { Header, SearchForm, SearchField, Dropdown as Dropdown$2, MobileNumber, CardLabelError, DatePicker as DatePicker$3, SubmitBar, Card, Table, Loader, Toast, AppContainer, ModuleHeader, ArrowLeft, PrivateRoute, LayoutWrapper, HomeIcon, PropertyHouse, EmployeeModuleCard, VerticalTimeline, FormComposer, FormStep, CardLabel, Tooltip, TextInput, LabelFieldPair, UploadFile, CardSubHeader, CardText, RadioOrSelect, ShippingTruck, CheckBox, RadioButtons, CloseSvg, Localities, RemoveableTag, ActionBar, ApplyFilterBar, AddIcon, Menu, Label, LinkLabel, ToggleSwitch, CardSectionHeader, Row, EditIcon, DeleteIcon, Modal, InfoIcon, CardHeader, StatusTable, LinkButton, Banner } from '@djb25/digit-ui-react-components';
4
+ import { Header, SearchForm, SearchField, Dropdown as Dropdown$2, MobileNumber, CardLabelError, DatePicker as DatePicker$3, SubmitBar, Card, Table, Loader, Toast, AppContainer, ModuleHeader, ArrowLeft, PrivateRoute, LayoutWrapper, HomeIcon, PropertyHouse, EmployeeModuleCard, VerticalTimeline, FormComposer, FormStep, LabelFieldPair, CardLabel, Tooltip, TextInput, UploadFile, CardSubHeader, CardText, RadioOrSelect, ShippingTruck, CheckBox, RadioButtons, CloseSvg, Localities, RemoveableTag, ActionBar, ApplyFilterBar, AddIcon, Menu, LinkLabel, ToggleSwitch, CardSectionHeader, Row, EditIcon, DeleteIcon, Modal, InfoIcon, CardHeader, StatusTable, LinkButton, Banner } from '@djb25/digit-ui-react-components';
5
5
  import { useForm, Controller } from 'react-hook-form';
6
6
  import { useQueryClient } from 'react-query';
7
7
 
@@ -1095,8 +1095,9 @@ const VendorDetails = ({
1095
1095
  }, /*#__PURE__*/React.createElement(FormStep, {
1096
1096
  config: config,
1097
1097
  onSelect: goNext,
1098
- t: t
1099
- }, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, {
1098
+ t: t,
1099
+ className: "formcomposer-grid-container-form"
1100
+ }, /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
1100
1101
  className: "card-label-smaller"
1101
1102
  }, /*#__PURE__*/React.createElement(Tooltip, {
1102
1103
  label: `${t("IFSC_CODE")}`,
@@ -1121,7 +1122,7 @@ const VendorDetails = ({
1121
1122
  pattern: "^[A-Z]{4}0[A-Z0-9]{6}$",
1122
1123
  type: "text",
1123
1124
  title: t("INVALID_IFSC_CODE_ERROR_MESSAGE")
1124
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("VENDOR_BANK_NAME")}`, " ", /*#__PURE__*/React.createElement("span", {
1125
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("VENDOR_BANK_NAME")}`, " ", /*#__PURE__*/React.createElement("span", {
1125
1126
  className: "check-page-link-button"
1126
1127
  }, "*")), /*#__PURE__*/React.createElement(TextInput, {
1127
1128
  t: t,
@@ -1136,7 +1137,7 @@ const VendorDetails = ({
1136
1137
  value: Bank,
1137
1138
  onChange: setvendorbank,
1138
1139
  disabled: true
1139
- })), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("VENDOR_BANK_BRANCH_NAME")}`, " ", /*#__PURE__*/React.createElement("span", {
1140
+ })), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("VENDOR_BANK_BRANCH_NAME")}`, " ", /*#__PURE__*/React.createElement("span", {
1140
1141
  className: "check-page-link-button"
1141
1142
  }, "*")), /*#__PURE__*/React.createElement(TextInput, {
1142
1143
  t: t,
@@ -1151,7 +1152,7 @@ const VendorDetails = ({
1151
1152
  placeholder: "Bank Branch Name Auto Select",
1152
1153
  onChange: setBankbranch,
1153
1154
  disabled: false
1154
- })), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("VENDOR_MICR_NO")}`, " ", /*#__PURE__*/React.createElement("span", {
1155
+ })), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("VENDOR_MICR_NO")}`, " ", /*#__PURE__*/React.createElement("span", {
1155
1156
  className: "check-page-link-button"
1156
1157
  }, "*")), /*#__PURE__*/React.createElement(TextInput, {
1157
1158
  t: t,
@@ -1166,7 +1167,7 @@ const VendorDetails = ({
1166
1167
  placeholder: "MICR No",
1167
1168
  onChange: setmicrNo,
1168
1169
  disabled: false
1169
- })), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("ACCOUNT_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1170
+ })), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("ACCOUNT_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1170
1171
  t: t,
1171
1172
  type: "text",
1172
1173
  isMandatory: false,
@@ -1183,14 +1184,14 @@ const VendorDetails = ({
1183
1184
  pattern: "[0-9]{9,18}",
1184
1185
  type: "text",
1185
1186
  title: t("INVALID_ACCOUNT_NO_ERROR_MESSAGE")
1186
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("PHONE_NO")}`), /*#__PURE__*/React.createElement(MobileNumber, {
1187
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("PHONE_NO")}`), /*#__PURE__*/React.createElement(MobileNumber, {
1187
1188
  value: PhoneNo,
1188
1189
  name: "PhoneNo",
1189
1190
  onChange: setPhoneNo,
1190
1191
  style: {
1191
1192
  width: "100%"
1192
1193
  }
1193
- })), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("CONTACT_PERSON")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1194
+ })), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("CONTACT_PERSON")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1194
1195
  t: t,
1195
1196
  type: "text",
1196
1197
  isMandatory: false,
@@ -1207,7 +1208,7 @@ const VendorDetails = ({
1207
1208
  pattern: "^[a-zA-Z0-9/-]{1,20}$",
1208
1209
  type: "text",
1209
1210
  title: t("INVALID_ACCOUNT_NO_ERROR_MESSAGE")
1210
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("PAN_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1211
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("PAN_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1211
1212
  t: t,
1212
1213
  type: "text",
1213
1214
  isMandatory: false,
@@ -1224,7 +1225,7 @@ const VendorDetails = ({
1224
1225
  pattern: "[A-Z]{5}[0-9]{4}[A-Z]{1}",
1225
1226
  type: "text",
1226
1227
  title: t("INVALID_PAN_NO_ERROR_MESSAGE")
1227
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("GST_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1228
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("GST_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1228
1229
  t: t,
1229
1230
  type: "text",
1230
1231
  isMandatory: false,
@@ -1241,7 +1242,7 @@ const VendorDetails = ({
1241
1242
  pattern: "^[0-9]{2}[A-Z]{5}[0-9]{4}[A-Z]{1}[A-Z0-9]{1}[Z]{1}[A-Z0-9]{1}$",
1242
1243
  type: "text",
1243
1244
  title: t("INVALID_GST_NO_ERROR_MESSAGE")
1244
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("GST_REGISTERED_STATE/UT")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1245
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("GST_REGISTERED_STATE/UT")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1245
1246
  t: t,
1246
1247
  type: "text",
1247
1248
  isMandatory: false,
@@ -1258,7 +1259,7 @@ const VendorDetails = ({
1258
1259
  pattern: "^[a-zA-Z0-9/-]{1,20}$",
1259
1260
  type: "text",
1260
1261
  title: t("PT_NAME_ERROR_MESSAGE")
1261
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("REGISTRATION_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1262
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("REGISTRATION_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1262
1263
  t: t,
1263
1264
  type: "text",
1264
1265
  isMandatory: false,
@@ -1275,7 +1276,7 @@ const VendorDetails = ({
1275
1276
  pattern: "^[a-zA-Z0-9/-]{1,20}$",
1276
1277
  type: "text",
1277
1278
  title: t("INVALID_REGISTRATION_NO_ERROR_MESSAGE")
1278
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("EPF_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1279
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("EPF_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1279
1280
  t: t,
1280
1281
  type: "text",
1281
1282
  isMandatory: false,
@@ -1292,7 +1293,7 @@ const VendorDetails = ({
1292
1293
  pattern: "^[a-zA-Z0-9/-]{1,15}$",
1293
1294
  type: "text",
1294
1295
  title: t("INVALID_EPF_NO_ERROR_MESSAGE")
1295
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("ESI_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1296
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, `${t("ESI_NO")}`), /*#__PURE__*/React.createElement(TextInput, Object.assign({
1296
1297
  t: t,
1297
1298
  type: "text",
1298
1299
  isMandatory: false,
@@ -1309,7 +1310,7 @@ const VendorDetails = ({
1309
1310
  pattern: "^[a-zA-Z0-9/-]{1,20}$",
1310
1311
  type: "text",
1311
1312
  title: t("INVALID_ESI_NO_ERROR_MESSAGE")
1312
- }))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, t("VENDOR_TYPE"), /*#__PURE__*/React.createElement("div", {
1313
+ }))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement("div", null, t("VENDOR_TYPE"), /*#__PURE__*/React.createElement("div", {
1313
1314
  className: "tooltip",
1314
1315
  style: {
1315
1316
  width: "12px",
@@ -1349,7 +1350,7 @@ const VendorDetails = ({
1349
1350
  placeholder: "Select",
1350
1351
  t: t
1351
1352
  })
1352
- })), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, t("VENOR_CATEGORY"), /*#__PURE__*/React.createElement("div", {
1353
+ })), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement("div", null, t("VENOR_CATEGORY"), /*#__PURE__*/React.createElement("div", {
1353
1354
  className: "tooltip",
1354
1355
  style: {
1355
1356
  width: "12px",
@@ -1389,11 +1390,7 @@ const VendorDetails = ({
1389
1390
  placeholder: "Select",
1390
1391
  t: t
1391
1392
  })
1392
- })), /*#__PURE__*/React.createElement("div", {
1393
- style: {
1394
- paddingBottom: "10px"
1395
- }
1396
- }, /*#__PURE__*/React.createElement("div", null, t("STATUS"), /*#__PURE__*/React.createElement("div", {
1393
+ })), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement("div", null, t("STATUS"), /*#__PURE__*/React.createElement("div", {
1397
1394
  className: "tooltip",
1398
1395
  style: {
1399
1396
  width: "12px",
@@ -8131,27 +8128,27 @@ const SearchApplication = ({
8131
8128
  }))), /*#__PURE__*/React.createElement("form", {
8132
8129
  onSubmit: handleSubmit(onSubmitInput)
8133
8130
  }, /*#__PURE__*/React.createElement("div", {
8134
- className: FSTP ? "complaint-input-container for-pt for-search" : "complaint-input-container",
8131
+ className: FSTP ? "for-pt for-search flex-box" : "flex-box",
8135
8132
  style: {
8136
- display: "grid",
8137
- width: "100%",
8138
- gridTemplateColumns: "33.33% 66.66% 0%",
8139
8133
  gap: "16px"
8140
8134
  }
8141
8135
  }, searchFields === null || searchFields === void 0 ? void 0 : searchFields.map((input, index) => /*#__PURE__*/React.createElement("span", {
8142
8136
  key: index,
8143
- className: index === 0 ? "complaint-input" : "mobile-input"
8144
- }, /*#__PURE__*/React.createElement(Label, null, input.label), getFields(input), " ")), /*#__PURE__*/React.createElement("div", {
8145
- className: "finance-mainlayout-col1"
8146
- }, /*#__PURE__*/React.createElement(Label, null, "\xA0"), type === "desktop" && !mobileView && /*#__PURE__*/React.createElement(SubmitBar, {
8137
+ className: index === 0 ? "finance-mainlayout-col2 complaint-input" : "finance-mainlayout-col2 mobile-input"
8138
+ }, getFields(input))), /*#__PURE__*/React.createElement("div", {
8139
+ style: {
8140
+ display: "flex",
8141
+ justifyContent: "end",
8142
+ gap: "16px",
8143
+ alignItems: "center"
8144
+ }
8145
+ }, type === "desktop" && !mobileView && /*#__PURE__*/React.createElement("span", {
8146
+ className: "clear-search generic-button"
8147
+ }, clearAll()), type === "desktop" && !mobileView && /*#__PURE__*/React.createElement(SubmitBar, {
8147
8148
  className: "submit-bar-search",
8148
8149
  label: t("ES_COMMON_SEARCH"),
8149
8150
  submit: true
8150
- })), /*#__PURE__*/React.createElement("div", {
8151
- className: "finance-mainlayout-col1"
8152
- }, /*#__PURE__*/React.createElement(Label, null, "\xA0"), type === "desktop" && !mobileView && /*#__PURE__*/React.createElement("span", {
8153
- className: "clear-search generic-button"
8154
- }, clearAll()))), error ? /*#__PURE__*/React.createElement(CardLabelError, {
8151
+ }))), error ? /*#__PURE__*/React.createElement(CardLabelError, {
8155
8152
  className: "search-error-label"
8156
8153
  }, t("ES_SEARCH_APPLICATION_ERROR")) : null))));
8157
8154
  };
@@ -9323,7 +9320,7 @@ const SelectServiceType = ({
9323
9320
  return /*#__PURE__*/React.createElement(Loader, null);
9324
9321
  }
9325
9322
  if (userType === "employee") {
9326
- return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(CardLabel, null, t(config.label)), /*#__PURE__*/React.createElement(Dropdown$2, {
9323
+ return /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, null, t(config.label)), /*#__PURE__*/React.createElement(Dropdown$2, {
9327
9324
  className: "payment-form-text-input-correction",
9328
9325
  isMandatory: config.isMandatory,
9329
9326
  selected: serviceTypes,
@@ -9973,21 +9970,11 @@ const EditVendorDetails = props => {
9973
9970
  className: "additional-value"
9974
9971
  }, safeVal));
9975
9972
  })), /*#__PURE__*/React.createElement("div", {
9976
- style: {
9977
- marginTop: "16px",
9978
- color: "#a82227",
9979
- cursor: "pointer",
9980
- textDecoration: "underline"
9981
- },
9973
+ className: "add-details-link hover-button",
9982
9974
  onClick: () => history.push(`/digit-ui/employee/vendor/registry/additionaldetails/info?vendorId=${dsoId}`)
9983
9975
  }, t("Edit Details"))) : /*#__PURE__*/React.createElement("div", {
9984
- style: {
9985
- marginLeft: "16px",
9986
- color: "#a82227",
9987
- cursor: "pointer",
9988
- textDecoration: "underline"
9989
- },
9990
- onClick: () => history.push(`/digit-ui/employee/vendor/registry/additionaldetails/vendor-details?vendorId=${dsoId}`)
9976
+ onClick: () => history.push(`/digit-ui/employee/vendor/registry/additionaldetails/vendor-details?vendorId=${dsoId}`),
9977
+ className: "add-details-link hover-button"
9991
9978
  }, t("Add Additional Details")));
9992
9979
  }
9993
9980
  return /*#__PURE__*/React.createElement(Row, {
@@ -10041,11 +10028,7 @@ const EditVendorDetails = props => {
10041
10028
  });
10042
10029
  }));
10043
10030
  }), detail.type && /*#__PURE__*/React.createElement("div", {
10044
- style: {
10045
- color: "#a82227",
10046
- cursor: "pointer",
10047
- marginLeft: "16px"
10048
- },
10031
+ className: "add-details-link hover-button",
10049
10032
  onClick: () => onActionSelect(detail.type === "ES_FSM_REGISTRY_DETAILS_TYPE_DRIVER" ? "ADD_DRIVER" : "ADD_VEHICLE")
10050
10033
  }, t(`${detail.type}_ADD`))));
10051
10034
  })), showModal && /*#__PURE__*/React.createElement(Modal, {
@@ -10839,11 +10822,13 @@ const CheckPage = ({
10839
10822
  height: "auto"
10840
10823
  },
10841
10824
  checked: agree
10842
- })), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement(SubmitBar, {
10825
+ })), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("div", {
10826
+ className: "formcomposer-section-button"
10827
+ }, /*#__PURE__*/React.createElement(SubmitBar, {
10843
10828
  label: t("COMMON_BUTTON_SUBMIT"),
10844
10829
  onSubmit: onSubmit,
10845
10830
  disabled: !agree
10846
- }))));
10831
+ })))));
10847
10832
  };
10848
10833
 
10849
10834
  const GetActionMessage = props => {
@@ -11058,6 +11043,7 @@ const DriverDetails = props => {
11058
11043
  });
11059
11044
  queryClient.invalidateQueries("DSO_SEARCH");
11060
11045
  setTimeout(() => {
11046
+ closeToast();
11061
11047
  history.push(`/digit-ui/employee/fsm/registry`);
11062
11048
  }, 5000);
11063
11049
  }
@@ -11222,7 +11208,6 @@ const DriverDetails = props => {
11222
11208
  }));
11223
11209
  }
11224
11210
  };
11225
- const isMobile = window.Digit.Utils.browser.isMobile();
11226
11211
  if (isLoading) {
11227
11212
  return /*#__PURE__*/React.createElement(Loader, null);
11228
11213
  }
@@ -11230,7 +11215,8 @@ const DriverDetails = props => {
11230
11215
  className: "employee-form-content"
11231
11216
  }, /*#__PURE__*/React.createElement(Card, {
11232
11217
  style: {
11233
- position: "relative"
11218
+ position: "relative",
11219
+ backgroundColor: "#fff"
11234
11220
  }
11235
11221
  }, driverData === null || driverData === void 0 ? void 0 : (_driverData$5 = driverData[0]) === null || _driverData$5 === void 0 ? void 0 : (_driverData$5$employe = _driverData$5.employeeResponse) === null || _driverData$5$employe === void 0 ? void 0 : _driverData$5$employe.map((detail, index) => {
11236
11222
  var _detail$values;
@@ -11251,33 +11237,35 @@ const DriverDetails = props => {
11251
11237
  className: "value",
11252
11238
  style: {
11253
11239
  color: "#a82227",
11254
- display: "flex"
11240
+ display: "flex",
11241
+ gap: "20px",
11242
+ alignItems: "center"
11255
11243
  }
11256
11244
  }, t(value.value) || "N/A", value.value === "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("span", {
11245
+ className: "add-details-link hover-button hover-button-round",
11257
11246
  onClick: () => onActionSelect("ADD_VENDOR")
11258
11247
  }, /*#__PURE__*/React.createElement(AddIcon, {
11259
11248
  className: "",
11260
11249
  fill: "#a82227",
11261
11250
  styles: {
11262
11251
  cursor: "pointer",
11263
- marginLeft: "20px",
11264
11252
  height: "24px"
11265
11253
  }
11266
- })), value.value != "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("span", {
11254
+ })), value.value !== "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("div", {
11255
+ className: "add-details-link hover-button hover-button-round",
11267
11256
  onClick: () => onActionSelect("EDIT_VENDOR")
11268
11257
  }, /*#__PURE__*/React.createElement(EditIcon, {
11269
11258
  style: {
11270
- cursor: "pointer",
11271
- marginLeft: "20px"
11259
+ cursor: "pointer"
11272
11260
  }
11273
- })), value.value != "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("span", {
11261
+ })), value.value !== "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("div", {
11262
+ className: "add-details-link hover-button hover-button-round",
11274
11263
  onClick: () => onActionSelect("DELETE_VENDOR")
11275
11264
  }, /*#__PURE__*/React.createElement(DeleteIcon, {
11276
11265
  className: "delete",
11277
11266
  fill: "#a82227",
11278
11267
  style: {
11279
- cursor: "pointer",
11280
- marginLeft: "20px"
11268
+ cursor: "pointer"
11281
11269
  }
11282
11270
  }))))) : /*#__PURE__*/React.createElement(Row, {
11283
11271
  key: t(value.title),
@@ -11347,7 +11335,6 @@ const CloseBtn$2 = props => {
11347
11335
  const VehicleDetails = props => {
11348
11336
  var _vehicleData$6, _vehicleData$6$employ;
11349
11337
  const tenantId = Digit.ULBService.getCurrentTenantId();
11350
- const state = Digit.ULBService.getStateId();
11351
11338
  const {
11352
11339
  t
11353
11340
  } = useTranslation();
@@ -11358,7 +11345,6 @@ const VehicleDetails = props => {
11358
11345
  } = useParams();
11359
11346
  const [displayMenu, setDisplayMenu] = useState(false);
11360
11347
  const [selectedAction, setSelectedAction] = useState(null);
11361
- const [config, setCurrentConfig] = useState({});
11362
11348
  const [showModal, setShowModal] = useState(false);
11363
11349
  const [showToast, setShowToast] = useState(null);
11364
11350
  const [vendors, setVendors] = useState([]);
@@ -11588,6 +11574,7 @@ const VehicleDetails = props => {
11588
11574
  });
11589
11575
  queryClient.invalidateQueries("FSM_VEICLES_SEARCH");
11590
11576
  setTimeout(() => {
11577
+ closeToast();
11591
11578
  history.push(`/digit-ui/employee/fsm/registry`);
11592
11579
  }, 5000);
11593
11580
  }
@@ -11602,7 +11589,7 @@ const VehicleDetails = props => {
11602
11589
  });
11603
11590
  }
11604
11591
  if (selectedAction === "ADD_VENDOR") {
11605
- return /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(CardText, null, t(`ES_FSM_REGISTRY_SELECT_VENODOR`)), /*#__PURE__*/React.createElement(Dropdown$2, {
11592
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(CardText, null, t(`ES_FSM_REGISTRY_SELECT_VENODOR`)), /*#__PURE__*/React.createElement(Dropdown$2, {
11606
11593
  t: t,
11607
11594
  option: vendors,
11608
11595
  value: selectedOption,
@@ -11612,7 +11599,7 @@ const VehicleDetails = props => {
11612
11599
  }));
11613
11600
  }
11614
11601
  if (selectedAction === "EDIT_VENDOR") {
11615
- return /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(CardText, null, t(`ES_FSM_REGISTRY_SELECT_VENODOR`)), /*#__PURE__*/React.createElement(Dropdown$2, {
11602
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(CardText, null, t(`ES_FSM_REGISTRY_SELECT_VENODOR`)), /*#__PURE__*/React.createElement(Dropdown$2, {
11616
11603
  t: t,
11617
11604
  option: vendors,
11618
11605
  value: selectedOption,
@@ -11654,40 +11641,38 @@ const VehicleDetails = props => {
11654
11641
  }
11655
11642
  }, t(detail.title)), /*#__PURE__*/React.createElement(StatusTable, null, detail === null || detail === void 0 ? void 0 : (_detail$values = detail.values) === null || _detail$values === void 0 ? void 0 : _detail$values.map((value, index) => {
11656
11643
  var _detail$values2, _detail$values3;
11657
- return (value === null || value === void 0 ? void 0 : value.type) === "custom" ? /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
11644
+ return (value === null || value === void 0 ? void 0 : value.type) === "custom" ? /*#__PURE__*/React.createElement(React.Fragment, {
11645
+ key: index
11646
+ }, /*#__PURE__*/React.createElement("div", {
11658
11647
  className: `${index === (detail === null || detail === void 0 ? void 0 : (_detail$values2 = detail.values) === null || _detail$values2 === void 0 ? void 0 : _detail$values2.length) - 1 ? "row last" : "row"} border-none`
11659
11648
  }, /*#__PURE__*/React.createElement("h2", null, t(value.title)), /*#__PURE__*/React.createElement("div", {
11660
- className: "value",
11649
+ className: "value add-details-link hover-button",
11661
11650
  style: {
11662
11651
  color: "#a82227",
11663
- display: "flex"
11652
+ display: "flex",
11653
+ alignItems: "center",
11654
+ gap: "8px"
11655
+ }
11656
+ }, value.value === "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("div", {
11657
+ onClick: () => onActionSelect("ADD_VENDOR"),
11658
+ style: {
11659
+ color: "#a82227",
11660
+ display: "flex",
11661
+ alignItems: "center",
11662
+ gap: "8px"
11664
11663
  }
11665
- }, t(value.value) || "N/A", value.value === "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("span", {
11666
- onClick: () => onActionSelect("ADD_VENDOR")
11667
11664
  }, /*#__PURE__*/React.createElement(AddIcon, {
11668
11665
  className: "",
11669
- fill: "#a82227",
11670
- styles: {
11671
- cursor: "pointer",
11672
- marginLeft: "20px",
11673
- height: "24px"
11674
- }
11675
- })), value.value != "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("span", {
11666
+ fill: "#a82227"
11667
+ }), " ", t(value.value) || "N/A"), value.value !== "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("div", {
11668
+ className: "add-details-link hover-button",
11676
11669
  onClick: () => onActionSelect("EDIT_VENDOR")
11677
- }, /*#__PURE__*/React.createElement(EditIcon, {
11678
- style: {
11679
- cursor: "pointer",
11680
- marginLeft: "20px"
11681
- }
11682
- })), value.value != "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("span", {
11670
+ }, /*#__PURE__*/React.createElement(EditIcon, null)), value.value !== "ES_FSM_REGISTRY_DETAILS_ADD_VENDOR" && /*#__PURE__*/React.createElement("div", {
11671
+ className: "add-details-link hover-button",
11683
11672
  onClick: () => onActionSelect("DELETE_VENDOR")
11684
11673
  }, /*#__PURE__*/React.createElement(DeleteIcon, {
11685
11674
  className: "delete",
11686
- fill: "#a82227",
11687
- style: {
11688
- cursor: "pointer",
11689
- marginLeft: "20px"
11690
- }
11675
+ fill: "#a82227"
11691
11676
  }))))) : /*#__PURE__*/React.createElement(Row, {
11692
11677
  key: t(value.title),
11693
11678
  label: t(value.title),