This commit is contained in:
Андрей Дувакин 2024-10-07 23:57:27 +05:00
parent e4ce32df2a
commit bd5ad2b7df
3 changed files with 12 additions and 5 deletions

View File

@ -99,7 +99,7 @@ const DeliveryOrdersList = ({
<div className="card-body">
<p>Этап {index + 1}</p>
<p>
Расчетная длительность этапа:{" "}
Расчетная длительность этапа:
{formatTimeInHours(order.estimated_route_time_in_minutes)}
</p>
{calculatingRoutes.includes(order.id) && (

View File

@ -19,7 +19,7 @@ const Header = () => {
<div className="container d-flex justify-content-between align-items-center">
<Link className="navbar-brand" to="/">
<img
src="delivery-icon.png"
src={`${process.env.PUBLIC_URL}/delivery-icon.png`}
alt="Логотип"
style={{ width: "60px", height: "60px", marginRight: "8px" }}
/>

View File

@ -4,9 +4,7 @@ import {
getDeliveryOrderDetails,
updateDeliveryOrderRoute,
} from "../api.jsx";
import { useParams } from "react-router-dom";
import { getCoordinates } from "../geocoder.jsx";
import { useNavigate } from "react-router-dom";
import { useParams, useNavigate } from "react-router-dom";
import {
MapContainer,
TileLayer,
@ -16,6 +14,7 @@ import {
} from "react-leaflet";
import { DivIcon } from "leaflet";
import polyline from "@mapbox/polyline";
import { getCoordinates } from "../geocoder.jsx";
import "./DeliveryOrderDetails.css";
const DELIVERY_CITY = {
@ -110,6 +109,10 @@ const DeliveryOrderDetails = () => {
}
};
const handleBack = () => {
navigate("/");
};
return (
<div className="delivery-order-details">
{loading ? (
@ -118,6 +121,10 @@ const DeliveryOrderDetails = () => {
</div>
) : (
<div className="content-container">
<button onClick={handleBack} className="btn btn-secondary mb-4">
Назад
</button>
<h2 style={{ textAlign: "center" }}>Общая информация</h2>
<table className="table table-bordered mb-5">
<thead>