color theme
commit
4f392f5c6a
|
@ -126,15 +126,15 @@ export function MyEmailFormInput({
|
|||
|
||||
export function MyCalendarMaxFutureBookingDaysFormInput({
|
||||
formItemName = "calendarMaxFutureBookingDays",
|
||||
maxLength,
|
||||
}) {
|
||||
const { t } = useTranslation();
|
||||
const appContext = useAppContext();
|
||||
|
||||
return (
|
||||
<MyFormInput
|
||||
formItemName={formItemName}
|
||||
minLength={Constants.GLOBALS.MIN_CALENDAR_FUTURE_BOOKING_DAYS}
|
||||
maxLength={appContext.paymentPlanSettings.maxEmployees}
|
||||
maxLength={maxLength}
|
||||
label={t("common.calendarMaxFutureBookingDays")}
|
||||
ruleMessageValueRequired={t(
|
||||
"common.inputRules.calendarMaxFutureBookingDaysRequired"
|
||||
|
@ -150,6 +150,7 @@ export function MyCalendarMaxFutureBookingDaysFormInput({
|
|||
|
||||
export function MyCalendarMinEarliestBookingTimeFormInput({
|
||||
formItem = "calendarMinEarliestBookingTime",
|
||||
maxLength,
|
||||
}) {
|
||||
const { t } = useTranslation();
|
||||
|
||||
|
@ -157,7 +158,7 @@ export function MyCalendarMinEarliestBookingTimeFormInput({
|
|||
<MyFormInput
|
||||
formItemName={formItem}
|
||||
minLength={Constants.GLOBALS.MIN_CALENDAR_EARLIEST_BOOKING_TIME}
|
||||
maxLength={Constants.GLOBALS.MAX_CALENDAR_EARLIEST_BOOKING_TIME}
|
||||
maxLength={maxLength}
|
||||
label={t("common.calendarMinEarliestBookingTime")}
|
||||
ruleMessageValueRequired={t(
|
||||
"common.inputRules.calendarMinEarliestBookingTimeRequired"
|
||||
|
|
|
@ -106,7 +106,6 @@ export function SideMenuContent({
|
|||
};
|
||||
|
||||
const showPaymentPlanInfoBanner =
|
||||
sideBarContext.permissions.includes("paymentPlan") &&
|
||||
sideBarContext.paymentPlanStatus === "trialing" &&
|
||||
sideBarContext.paymentPlanTrialEnd !== null &&
|
||||
sideBarContext.paymentPlanCanceledAt !== null;
|
||||
|
@ -129,7 +128,10 @@ export function SideMenuContent({
|
|||
);
|
||||
}
|
||||
|
||||
if (!showPaymentPlanInfoBanner) {
|
||||
if (
|
||||
sideBarContext.permissions.includes("paymentPlan") &&
|
||||
!showPaymentPlanInfoBanner
|
||||
) {
|
||||
items.push({
|
||||
label: t("sideMenu.paymentPlan"),
|
||||
icon: <WalletOutlined />,
|
||||
|
@ -240,7 +242,8 @@ export function SideMenuContent({
|
|||
<div>
|
||||
<Divider style={{ margin: 0 }} />
|
||||
|
||||
{showPaymentPlanInfoBanner && (
|
||||
{sideBarContext.permissions.includes("paymentPlan") &&
|
||||
showPaymentPlanInfoBanner && (
|
||||
<Card
|
||||
style={{ backgroundColor: AppStyle.colors.primary, margin: 8 }}
|
||||
styles={{ body: { padding: 10 } }}
|
||||
|
|
|
@ -17,7 +17,6 @@ import {
|
|||
myFetch,
|
||||
EncodeStringToBase64,
|
||||
showInputsInvalidNotification,
|
||||
Constants,
|
||||
showUnkownErrorNotification,
|
||||
} from "../../../utils";
|
||||
import { useTranslation } from "react-i18next";
|
||||
|
@ -383,13 +382,6 @@ function ModalAddEditEmployee({
|
|||
body.username = formUsername;
|
||||
}
|
||||
|
||||
console.log(
|
||||
"email",
|
||||
formEmail,
|
||||
modalOptions.selectedEmployee.email,
|
||||
formEmail !== modalOptions.selectedEmployee.email
|
||||
);
|
||||
|
||||
if (formEmail !== modalOptions.selectedEmployee.email) {
|
||||
validateFields.push("email");
|
||||
body.email = formEmail;
|
||||
|
@ -471,9 +463,13 @@ function ModalAddEditEmployee({
|
|||
</>
|
||||
)}
|
||||
|
||||
<MyCalendarMaxFutureBookingDaysFormInput />
|
||||
<MyCalendarMaxFutureBookingDaysFormInput
|
||||
maxLength={storeSettings.calendar_max_future_booking_days}
|
||||
/>
|
||||
|
||||
<MyCalendarMinEarliestBookingTimeFormInput />
|
||||
<MyCalendarMinEarliestBookingTimeFormInput
|
||||
maxLength={storeSettings.calendar_min_earliest_booking_time}
|
||||
/>
|
||||
</Form>
|
||||
</MyModal>
|
||||
</>
|
||||
|
|
Loading…
Reference in New Issue