diff --git a/src/components/third-party/ReactTable.js b/src/components/third-party/ReactTable.js index 7a3a656..da2980d 100644 --- a/src/components/third-party/ReactTable.js +++ b/src/components/third-party/ReactTable.js @@ -496,7 +496,7 @@ SortingSelect.propTypes = { export const CSVExport = ({ data, filename, headers }) => { return ( - + diff --git a/src/pages/nearle/clients/customers.js b/src/pages/nearle/clients/customers.js index b14196c..1b628a4 100644 --- a/src/pages/nearle/clients/customers.js +++ b/src/pages/nearle/clients/customers.js @@ -525,7 +525,8 @@ const Customers = () => { try { // await axios.get(`${process.env.REACT_APP_URL}/tenants/gettenants/?partnerid=${tid}&status=active`) await axios - .get(`${process.env.REACT_APP_URL}/customers/getbytid/?tenantid=${tid}`) + // .get(`${process.env.REACT_APP_URL}/customers/gettenantcustomers/?tenantid=${tid}`) + .get(`${process.env.REACT_APP_URL}/customers/gettenantcustomers/?tenantid=${tid}&pageno=1&pagesize=20`) .then((res) => { if (res.data.message === 'Success') { diff --git a/src/pages/nearle/orders/createorder1.js b/src/pages/nearle/orders/createorder1.js index 6859b77..715927e 100644 --- a/src/pages/nearle/orders/createorder1.js +++ b/src/pages/nearle/orders/createorder1.js @@ -433,6 +433,11 @@ const Createorder1 = () => { const [appLocaLat, setAppLocaLat] = useState(); const [appLocaLng, setAppLocaLng] = useState(); const [appLocaRadius, setAppLocaRadius] = useState(); + const [isSms, setIsSms] = useState(0); + + useEffect(() => { + console.log(isSms); + }, [isSms]); const handleChipClick = (chipLabel) => { setSelectedCatChip(chipLabel); @@ -840,7 +845,7 @@ const Createorder1 = () => { processing: '', ready: '', remarks: '', - smsdelivery: 1, + smsdelivery: isSms, subcategoryid: +subCatId, taxamount: 0.0, tenantid: tenant.tenantid, @@ -978,7 +983,8 @@ const Createorder1 = () => { try { let url = searchCustList == '' - ? `${process.env.REACT_APP_URL}/customers/getbytid/?tenantid=${tid}&pageno=1&pagesize=1` + ? // ? `${process.env.REACT_APP_URL}/customers/getbytid/?tenantid=${tid}&pageno=1&pagesize=1` + `${process.env.REACT_APP_URL}/customers/gettenantcustomers/?tenantid=${tid}&pageno=1&pagesize=20` : `${process.env.REACT_APP_URL}/customers/search/?tenantid=${tid}&keyword=${searchCustList}`; await axios @@ -1517,7 +1523,6 @@ const Createorder1 = () => { label="Address" disabled={!isLocation} id="addressAuto1" - placeholder="Search" fullWidth value={inputValue2} onChange={(e) => setInputValue2(e.target.value)} @@ -1878,7 +1883,7 @@ const Createorder1 = () => { setInputValue3(e.target.value)} @@ -2194,6 +2199,15 @@ const Createorder1 = () => { )} + + SMS Delivery + { + setIsSms(e.target.checked ? 1 : 0); + }} + /> + Category ({ + tenantname: order.tenantname, + tenantcity: order.tenantcity, + tenantcontactno: order.tenantcontactno, + rider: order.rider, + orderid: order.orderid, + orderdate: order.orderdate, + deliverydate: order.deliverydate, + orderstatus: order.orderstatus, + deliverystatus: order.deliverystatus, + ordernotes: order.ordernotes, + kms: order.kms, + actualkms: order.actualkms, + assigntime: order.assigntime, + starttime: order.starttime, + arrivaltime: order.arrivaltime, + pickuptime: order.pickuptime, + deliverytime: order.deliverytime, + canceltime: order.canceltime, + deliverycharge: order.deliverycharge, + deliveryamt: order.deliveryamt, + pickupcustomer: order.pickupcustomer, + pickupcontactno: order.pickupcontactno, + pickupaddress: order.pickupaddress, + pickupsuburb: order.pickupsuburb, + pickupcity: order.pickupcity, + pickuplat: order.pickuplat, + pickuplong: order.pickuplong, + deliverycustomer: order.deliverycustomer, + deliverycontactno: order.deliverycontactno, + deliveryaddress: order.deliveryaddress, + deliverysuburb: order.deliverysuburb, + deliverylat: order.deliverylat, + deliverylong: order.deliverylong, + locationname: order.locationname, + locationsuburb: order.locationsuburb, + locationcity: order.locationcity, + locationcontactno: order.locationcontactno + })); + const handleSelectAllClick = (event) => { if (event.target.checked) { const newSelectedId = rows.map((n) => n.name); @@ -426,17 +467,16 @@ export default function ordersDetails() { - {' '} -
- + setOpen(true)} > -
+ + +
{/*