Compare commits
2 Commits
10f975d98f
...
1736e787a6
| Author | SHA1 | Date | |
|---|---|---|---|
| 1736e787a6 | |||
|
|
54b3bfdc42 |
@ -194,7 +194,7 @@ const SettingPanel = ({
|
|||||||
</IconButton>
|
</IconButton>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
{/* проверяем на 4 форму */}
|
{/* проверяем на 4 форму */}
|
||||||
{formType === FORM_TYPE_OPTIONS[3] && (
|
{formType === FORM_TYPE_OPTIONS[2] && (
|
||||||
<>
|
<>
|
||||||
<Tooltip title='Добавить программу'>
|
<Tooltip title='Добавить программу'>
|
||||||
<IconButton onClick={onAddProgram} variant='outlined' sx={controlSx}>
|
<IconButton onClick={onAddProgram} variant='outlined' sx={controlSx}>
|
||||||
|
|||||||
@ -13,7 +13,7 @@ import Modal from './Modal/Modal';
|
|||||||
import { CheckBoxCheckSvg, CheckBoxUncheckSvg, DateIcon, UserIcon } from './icons/icons';
|
import { CheckBoxCheckSvg, CheckBoxUncheckSvg, DateIcon, UserIcon } from './icons/icons';
|
||||||
|
|
||||||
const TaskCard = styled.div`
|
const TaskCard = styled.div`
|
||||||
width: 26.8rem;
|
width: ${({ $fluidWidth }) => ($fluidWidth ? 'calc((100% - 2.25rem) / 4)' : '26.8rem')};
|
||||||
min-height: 10rem;
|
min-height: 10rem;
|
||||||
display: flex;
|
display: flex;
|
||||||
padding: 1rem;
|
padding: 1rem;
|
||||||
@ -32,6 +32,18 @@ const TaskCard = styled.div`
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
|
@media (max-width: 1200px) {
|
||||||
|
width: ${({ $fluidWidth }) => ($fluidWidth ? 'calc((100% - 1.5rem) / 3)' : '26.8rem')};
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 900px) {
|
||||||
|
width: ${({ $fluidWidth }) => ($fluidWidth ? 'calc((100% - 0.75rem) / 2)' : '26.8rem')};
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 600px) {
|
||||||
|
width: ${({ $fluidWidth }) => ($fluidWidth ? '100%' : '26.8rem')};
|
||||||
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
transform: translateY(-5px);
|
transform: translateY(-5px);
|
||||||
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
|
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
|
||||||
@ -73,6 +85,7 @@ const TaskTitle = styled.div`
|
|||||||
export const TaskCardComponent = ({
|
export const TaskCardComponent = ({
|
||||||
taskForm,
|
taskForm,
|
||||||
isForm = false,
|
isForm = false,
|
||||||
|
fluidWidth = false,
|
||||||
exportMode = false,
|
exportMode = false,
|
||||||
isLoadingFile = false,
|
isLoadingFile = false,
|
||||||
onAddForExport,
|
onAddForExport,
|
||||||
@ -158,6 +171,7 @@ export const TaskCardComponent = ({
|
|||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<TaskCard
|
<TaskCard
|
||||||
|
$fluidWidth={fluidWidth}
|
||||||
onClick={(event) => {
|
onClick={(event) => {
|
||||||
if (exportMode) {
|
if (exportMode) {
|
||||||
handleCheckboxClick(event);
|
handleCheckboxClick(event);
|
||||||
|
|||||||
@ -178,6 +178,13 @@ const SspDataTable = ({
|
|||||||
enableRowActions={true}
|
enableRowActions={true}
|
||||||
renderRowActions={renderRowActions}
|
renderRowActions={renderRowActions}
|
||||||
positionActionsColumn='last'
|
positionActionsColumn='last'
|
||||||
|
tableOptions={{
|
||||||
|
displayColumnDefOptions: {
|
||||||
|
'mrt-row-actions': {
|
||||||
|
header: 'Действия',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}}
|
||||||
initialState={initialState}
|
initialState={initialState}
|
||||||
enableSorting={false}
|
enableSorting={false}
|
||||||
enableColumnFilters={false}
|
enableColumnFilters={false}
|
||||||
|
|||||||
@ -223,11 +223,12 @@ export default function TasksPage() {
|
|||||||
totalCount={totalCount}
|
totalCount={totalCount}
|
||||||
page={page}
|
page={page}
|
||||||
limit={limit}
|
limit={limit}
|
||||||
|
maxHeight='none'
|
||||||
onPageChange={handlePageChange}
|
onPageChange={handlePageChange}
|
||||||
onLimitChange={handleLimitChange}
|
onLimitChange={handleLimitChange}
|
||||||
entityName='задач'
|
entityName='задач'
|
||||||
emptyMessage='Задачи не найдены'
|
emptyMessage='Задачи не найдены'
|
||||||
renderItem={(task, exportProps) => <TaskCardComponent key={task.id} taskForm={task} {...exportProps} />}
|
renderItem={(task, exportProps) => <TaskCardComponent key={task.id} taskForm={task} fluidWidth {...exportProps} />}
|
||||||
getItemId={(task) => task.id}
|
getItemId={(task) => task.id}
|
||||||
getItemTitle={(task) =>
|
getItemTitle={(task) =>
|
||||||
task.title ||
|
task.title ||
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user