Added schedule load to daily veiw with additional CSS fixes. BOD-319
This commit is contained in:
@@ -1,25 +1,11 @@
|
||||
import { SyncOutlined } from "@ant-design/icons";
|
||||
import { Button } from "antd";
|
||||
import React from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { connect } from "react-redux";
|
||||
import { setModalContext } from "../../redux/modals/modals.actions";
|
||||
import ScheduleCalendarWrapperComponent from "../schedule-calendar-wrapper/scheduler-calendar-wrapper.component";
|
||||
import ScheduleModal from "../schedule-job-modal/schedule-job-modal.container";
|
||||
import ScheduleProductionList from "../schedule-production-list/schedule-production-list.component";
|
||||
|
||||
const mapDispatchToProps = (dispatch) => ({
|
||||
setScheduleContext: (context) =>
|
||||
dispatch(setModalContext({ context: context, modal: "schedule" })),
|
||||
});
|
||||
|
||||
export function ScheduleCalendarComponent({
|
||||
data,
|
||||
refetch,
|
||||
setScheduleContext,
|
||||
}) {
|
||||
const { t } = useTranslation();
|
||||
|
||||
export default function ScheduleCalendarComponent({ data, refetch }) {
|
||||
return (
|
||||
<div>
|
||||
<div className="imex-flex-row">
|
||||
@@ -32,19 +18,6 @@ export function ScheduleCalendarComponent({
|
||||
<SyncOutlined />
|
||||
</Button>
|
||||
|
||||
<Button
|
||||
className="imex-flex-row__margin"
|
||||
onClick={() => {
|
||||
setScheduleContext({
|
||||
actions: { refetch: refetch },
|
||||
context: {
|
||||
jobId: null,
|
||||
},
|
||||
});
|
||||
}}
|
||||
>
|
||||
{t("appointments.actions.new")}
|
||||
</Button>
|
||||
<ScheduleProductionList />
|
||||
</div>
|
||||
|
||||
@@ -54,4 +27,3 @@ export function ScheduleCalendarComponent({
|
||||
</div>
|
||||
);
|
||||
}
|
||||
export default connect(null, mapDispatchToProps)(ScheduleCalendarComponent);
|
||||
|
||||
Reference in New Issue
Block a user