diff --git a/app/panels/mech_rec_cost_jobs_manage/hooks.js b/app/panels/mech_rec_cost_jobs_manage/hooks.js index 5f49f01..de4f8dc 100644 --- a/app/panels/mech_rec_cost_jobs_manage/hooks.js +++ b/app/panels/mech_rec_cost_jobs_manage/hooks.js @@ -1,3 +1,8 @@ +/* + Парус 8 - Панели мониторинга - ПУП - Выдача сменного задания + Кастомные хуки +*/ + //--------------------- //Подключение библиотек //--------------------- diff --git a/app/panels/mech_rec_cost_prod_plans/datagrids/fcdeliverylistsp.js b/app/panels/mech_rec_cost_prod_plans/datagrids/fcdeliverylistsp.js index 75f5021..d02c517 100644 --- a/app/panels/mech_rec_cost_prod_plans/datagrids/fcdeliverylistsp.js +++ b/app/panels/mech_rec_cost_prod_plans/datagrids/fcdeliverylistsp.js @@ -20,7 +20,8 @@ import { useCostDeliveryLists } from "./backend_dg"; //Собственные х //Стили const STYLES = { - CONTAINER: { margin: "5px 0px", textAlign: "center" } + CONTAINER: { margin: "5px 0px", textAlign: "center" }, + DATA_GRID_CELL_COVERED: { backgroundColor: "lightblue" } }; //------------------------------------ @@ -32,7 +33,7 @@ const dataCellRender = ({ row, columnDef }) => { //Если "Количество план" равно или меньше "Остаток" if (row["NQUANT_PLAN"] <= row["NREST"]) { return { - cellStyle: { backgroundColor: "lightblue" }, + cellStyle: { ...STYLES.DATA_GRID_CELL_COVERED }, data: row[columnDef] }; } else { diff --git a/app/panels/mech_rec_cost_prod_plans/datagrids/goodparties.js b/app/panels/mech_rec_cost_prod_plans/datagrids/goodparties.js index be18627..e208026 100644 --- a/app/panels/mech_rec_cost_prod_plans/datagrids/goodparties.js +++ b/app/panels/mech_rec_cost_prod_plans/datagrids/goodparties.js @@ -20,7 +20,8 @@ import { useGoodsParties } from "./backend_dg"; //Собственные хук //Стили const STYLES = { - CONTAINER: { margin: "5px 0px", textAlign: "center" } + CONTAINER: { margin: "5px 0px", textAlign: "center" }, + DATA_GRID_CELL_COVERED: { backgroundColor: "lightblue" } }; //------------------------------------ @@ -32,7 +33,7 @@ const dataCellRender = ({ row, columnDef, quantPlanSum }) => { //Если остаток больше суммы "Выдать по норме" - закрашиваем голубым if (row["NRESTFACT"] >= quantPlanSum) { return { - cellStyle: { backgroundColor: "lightblue" }, + cellStyle: { ...STYLES.DATA_GRID_CELL_COVERED }, data: row[columnDef] }; } else { diff --git a/app/panels/mech_rec_dept_cost_jobs/components/filter.js b/app/panels/mech_rec_dept_cost_jobs/components/filter.js index 4ae8604..0c1b1f0 100644 --- a/app/panels/mech_rec_dept_cost_jobs/components/filter.js +++ b/app/panels/mech_rec_dept_cost_jobs/components/filter.js @@ -36,7 +36,8 @@ const currentYear = currentDate.getUTCFullYear(); //Стили const STYLES = { - FILTER_BLOCK: { maxWidth: "200px" } + FILTER_CONTAINER: { display: "flex", flexDirection: "row", justifyContent: "flex-start", alignItems: "flex-end" }, + FILTER_BLOCK: { maxWidth: "200px", display: "flex" } }; //------------------------------------ @@ -71,7 +72,7 @@ DepartmentsDataGrid.propTypes = { //Компонент фильтра const FilterComponent = ({ filter, setFilter, handleMonthChange, handleSelectDeparture }) => { return ( - + Цех @@ -95,7 +96,7 @@ const FilterComponent = ({ filter, setFilter, handleMonthChange, handleSelectDep label="Цех" /> - + handleMonthChange(-1)}> navigate_before diff --git a/app/panels/mech_rec_dept_cost_jobs/components/ins_department_dg.js b/app/panels/mech_rec_dept_cost_jobs/components/ins_department_dg.js index 61a5791..a305bef 100644 --- a/app/panels/mech_rec_dept_cost_jobs/components/ins_department_dg.js +++ b/app/panels/mech_rec_dept_cost_jobs/components/ins_department_dg.js @@ -20,7 +20,8 @@ import { useInsDepartment } from "../hooks"; //Состояние таблицы //Стили const STYLES = { - CONTAINER: { margin: "5px 0px", textAlign: "center" } + CONTAINER: { margin: "5px 0px", textAlign: "center" }, + DATA_GRID_CELL_DEFAULT: { cursor: "pointer", backgroundColor: "#ADD8E6" } }; //------------------------------------ @@ -30,7 +31,7 @@ const STYLES = { //Генерация ссылок на строках const dataCellRender = ({ row, columnDef, handleSelectDeparture }) => { return { - cellStyle: { cursor: "pointer", backgroundColor: "#ADD8E6" }, + cellStyle: { ...STYLES.DATA_GRID_CELL_DEFAULT }, cellProps: { onClick: () => { handleSelectDeparture({ NRN: row["NRN"], SCODE: row["SCODE"].toString(), SNAME: row["SNAME"] });