Compare commits
3 Commits
b126f2c52d
...
7ac18ec61d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7ac18ec61d | ||
|
|
25ddf86ac4 | ||
|
|
70b3e6b260 |
@ -354,6 +354,9 @@ func leadDraft(it storage.ConfirmItem, cfg storage.BookingSettings) bitrix.LeadD
|
||||
"Приём: " + formatSlotTime(it.Start),
|
||||
"Филиал: " + html.EscapeString(branchOrDash(it.Branch)),
|
||||
}
|
||||
if it.Comment != "" {
|
||||
lines = append(lines, "Комментарий пациента: "+html.EscapeString(it.Comment))
|
||||
}
|
||||
if it.ServiceName != "" {
|
||||
lines = append(lines, "Услуга: "+html.EscapeString(it.ServiceName))
|
||||
}
|
||||
|
||||
@ -52,6 +52,7 @@ func (s *Storage) SetBookingSettings(ctx context.Context, b BookingSettings) err
|
||||
|
||||
// ConfirmItem — запись с сайта, ждущая решения оператора, со всем, что нужно для лида в Битриксе и CRM.
|
||||
type ConfirmItem struct {
|
||||
Comment string
|
||||
ID int64
|
||||
Start time.Time
|
||||
CreatedAt time.Time
|
||||
@ -73,7 +74,7 @@ const confirmItemSelect = `
|
||||
SELECT a.id, a.start_at, a.created_at, a.patient_name, a.patient_phone, a.doctor_onec_id,
|
||||
COALESCE(NULLIF(o.full_name, ''), a.doctor_onec_id), COALESCE(NULLIF(b.address, ''), b.name, ''),
|
||||
COALESCE(sv.name, ''), a.onec_appointment_id, a.bitrix_lead_id, a.error,
|
||||
a.crm_deal_id, a.crm_confirm_state, a.crm_error
|
||||
a.crm_deal_id, a.crm_confirm_state, a.crm_error, a.patient_comment
|
||||
FROM onec_appointments a
|
||||
LEFT JOIN onec_doctors o ON o.onec_id = a.doctor_onec_id
|
||||
LEFT JOIN onec_branches b ON b.onec_id = a.branch_onec_id
|
||||
@ -133,7 +134,7 @@ func (s *Storage) confirmItems(ctx context.Context, query string, limit int) ([]
|
||||
var c ConfirmItem
|
||||
if err := rows.Scan(&c.ID, &c.Start, &c.CreatedAt, &c.Patient, &c.Phone, &c.DoctorOnec, &c.DoctorName,
|
||||
&c.Branch, &c.ServiceName, &c.OnecID, &c.BitrixLeadID, &c.Error,
|
||||
&c.CrmDealID, &c.CrmConfirmState, &c.CrmError); err != nil {
|
||||
&c.CrmDealID, &c.CrmConfirmState, &c.CrmError, &c.Comment); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
out = append(out, c)
|
||||
|
||||
@ -10,27 +10,6 @@
|
||||
color: rgba(44, 73, 95, 0.35);
|
||||
}
|
||||
|
||||
.rating-badge {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 5.2px;
|
||||
height: 29px;
|
||||
padding: 5.9px 8.2px 5.9px 7.4px;
|
||||
background: var(--soft);
|
||||
border: 0.744px solid var(--chip-border);
|
||||
border-radius: 8.923px;
|
||||
font-weight: 700;
|
||||
font-size: 13.385px;
|
||||
color: var(--navy);
|
||||
}
|
||||
|
||||
.rating-badge img {
|
||||
width: 13.385px;
|
||||
height: 13.385px;
|
||||
padding: 0 0.33px 1.28px;
|
||||
}
|
||||
|
||||
/* ---------- плитка «Специалисты» на главной: 209 × 232 ---------- */
|
||||
.doctor-tile {
|
||||
width: 209px;
|
||||
@ -56,12 +35,6 @@
|
||||
object-position: center top;
|
||||
}
|
||||
|
||||
.doctor-tile__rating {
|
||||
position: absolute;
|
||||
top: 8px;
|
||||
right: 9px;
|
||||
}
|
||||
|
||||
.doctor-tile__info {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
@ -219,22 +192,6 @@
|
||||
height: 180px;
|
||||
border-radius: 0;
|
||||
}
|
||||
.doctor-tile__rating {
|
||||
top: 8px;
|
||||
right: 8px;
|
||||
height: auto;
|
||||
padding: 2px 8px;
|
||||
gap: 4px;
|
||||
border: 0;
|
||||
border-radius: var(--r-8);
|
||||
font-size: 10px;
|
||||
line-height: 15px;
|
||||
}
|
||||
.doctor-tile__rating img {
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
padding: 0;
|
||||
}
|
||||
.doctor-tile__info {
|
||||
gap: 0;
|
||||
margin-top: 0;
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
import { Link } from 'react-router-dom';
|
||||
import starIcon from '../assets/figma/icon-star.svg';
|
||||
import { experienceLabel, ratingLabel } from '../lib/format.js';
|
||||
import { experienceLabel } from '../lib/format.js';
|
||||
import { doctorPath } from '../lib/links.js';
|
||||
import { useLeadModal } from '../context/LeadModalContext.jsx';
|
||||
import './DoctorCard.css';
|
||||
@ -41,16 +40,6 @@ function DoctorPhoto({ doctor, className }) {
|
||||
);
|
||||
}
|
||||
|
||||
export function RatingBadge({ rating, className = '' }) {
|
||||
if (typeof rating !== 'number') return null;
|
||||
return (
|
||||
<span className={`rating-badge ${className}`} aria-label={`Рейтинг ${ratingLabel(rating)}`}>
|
||||
<img src={starIcon} alt="" width="13" height="13" />
|
||||
{ratingLabel(rating)}
|
||||
</span>
|
||||
);
|
||||
}
|
||||
|
||||
// Плитка для слайдера «Специалисты» на главной.
|
||||
export function DoctorTile({ doctor }) {
|
||||
const path = doctorPath(doctor);
|
||||
@ -58,7 +47,6 @@ export function DoctorTile({ doctor }) {
|
||||
<article className="doctor-tile">
|
||||
<Link to={path} className="doctor-tile__photo-link" tabIndex={-1} aria-hidden="true">
|
||||
<DoctorPhoto doctor={doctor} className="doctor-tile__photo" />
|
||||
<RatingBadge rating={doctor.rating} className="doctor-tile__rating" />
|
||||
</Link>
|
||||
<div className="doctor-tile__info">
|
||||
<Link to={path} className="doctor-tile__name">
|
||||
@ -90,7 +78,6 @@ export function DoctorRow({ doctor }) {
|
||||
{doctor.experience_years != null && (
|
||||
<span className="doctor-row__exp">{experienceLabel(doctor.experience_years)}</span>
|
||||
)}
|
||||
<RatingBadge rating={doctor.rating} />
|
||||
</div>
|
||||
<div className="doctor-row__actions">
|
||||
{doctor.absent ? (
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { useEffect, useState } from 'react';
|
||||
import { Link, useParams } from 'react-router-dom';
|
||||
import { BookButton, RatingBadge } from '../components/DoctorCard.jsx';
|
||||
import { BookButton } from '../components/DoctorCard.jsx';
|
||||
import { NextSlots } from '../components/NativeBooking.jsx';
|
||||
import ContactsSection from '../components/ContactsSection.jsx';
|
||||
import StubPage from './StubPage.jsx';
|
||||
@ -177,7 +177,6 @@ export default function DoctorPage() {
|
||||
{d.experience_years != null && (
|
||||
<span className="doctor-hero__exp">{experienceLabel(d.experience_years)}</span>
|
||||
)}
|
||||
<RatingBadge rating={d.rating} />
|
||||
</div>
|
||||
{d.branches?.length > 0 && (
|
||||
<p className="doctor-hero__branches">
|
||||
|
||||
Loading…
Reference in New Issue
Block a user