@@ -137,6 +137,10 @@ export default class HomePageController extends WorklenzControllerBase {
|
|||||||
WHERE category_id NOT IN (SELECT id
|
WHERE category_id NOT IN (SELECT id
|
||||||
FROM sys_task_status_categories
|
FROM sys_task_status_categories
|
||||||
WHERE is_done IS FALSE))
|
WHERE is_done IS FALSE))
|
||||||
|
AND NOT EXISTS(SELECT project_id
|
||||||
|
FROM archived_projects
|
||||||
|
WHERE project_id = p.id
|
||||||
|
AND user_id = $2)
|
||||||
${groupByClosure}
|
${groupByClosure}
|
||||||
ORDER BY t.end_date ASC`;
|
ORDER BY t.end_date ASC`;
|
||||||
|
|
||||||
@@ -158,9 +162,13 @@ export default class HomePageController extends WorklenzControllerBase {
|
|||||||
WHERE category_id NOT IN (SELECT id
|
WHERE category_id NOT IN (SELECT id
|
||||||
FROM sys_task_status_categories
|
FROM sys_task_status_categories
|
||||||
WHERE is_done IS FALSE))
|
WHERE is_done IS FALSE))
|
||||||
|
AND NOT EXISTS(SELECT project_id
|
||||||
|
FROM archived_projects
|
||||||
|
WHERE project_id = p.id
|
||||||
|
AND user_id = $3)
|
||||||
${groupByClosure}`;
|
${groupByClosure}`;
|
||||||
|
|
||||||
const result = await db.query(q, [teamId, userId]);
|
const result = await db.query(q, [teamId, userId, userId]);
|
||||||
const [row] = result.rows;
|
const [row] = result.rows;
|
||||||
return row;
|
return row;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -123,11 +123,11 @@ const TasksList: React.FC = React.memo(() => {
|
|||||||
<span>{t('tasks.name')}</span>
|
<span>{t('tasks.name')}</span>
|
||||||
</Flex>
|
</Flex>
|
||||||
),
|
),
|
||||||
width: '150px',
|
width: '40%',
|
||||||
render: (_, record) => (
|
render: (_, record) => (
|
||||||
<div style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center' }}>
|
<div style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center' }}>
|
||||||
<Tooltip title={record.name}>
|
<Tooltip title={record.name}>
|
||||||
<Typography.Text ellipsis={{ tooltip: true }} style={{ maxWidth: 150 }}>
|
<Typography.Text style={{ flex: 1, marginRight: 8 }}>
|
||||||
{record.name}
|
{record.name}
|
||||||
</Typography.Text>
|
</Typography.Text>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
@@ -155,15 +155,14 @@ const TasksList: React.FC = React.memo(() => {
|
|||||||
{
|
{
|
||||||
key: 'project',
|
key: 'project',
|
||||||
title: t('tasks.project'),
|
title: t('tasks.project'),
|
||||||
width: '120px',
|
width: '25%',
|
||||||
render: (_, record) => {
|
render: (_, record) => {
|
||||||
return (
|
return (
|
||||||
<Tooltip title={record.project_name}>
|
<Tooltip title={record.project_name}>
|
||||||
<Typography.Paragraph
|
<Typography.Paragraph
|
||||||
style={{ margin: 0, paddingInlineEnd: 6, maxWidth: 120 }}
|
style={{ margin: 0, paddingInlineEnd: 6 }}
|
||||||
ellipsis={{ tooltip: true }}
|
|
||||||
>
|
>
|
||||||
<Badge color={record.phase_color || 'blue'} style={{ marginInlineEnd: 4 }} />
|
<Badge color={record.project_color || 'blue'} style={{ marginInlineEnd: 4 }} />
|
||||||
{record.project_name}
|
{record.project_name}
|
||||||
</Typography.Paragraph>
|
</Typography.Paragraph>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
@@ -173,7 +172,7 @@ const TasksList: React.FC = React.memo(() => {
|
|||||||
{
|
{
|
||||||
key: 'status',
|
key: 'status',
|
||||||
title: t('tasks.status'),
|
title: t('tasks.status'),
|
||||||
width: '180px',
|
width: '20%',
|
||||||
render: (_, record) => (
|
render: (_, record) => (
|
||||||
<HomeTasksStatusDropdown task={record} teamId={record.team_id || ''} />
|
<HomeTasksStatusDropdown task={record} teamId={record.team_id || ''} />
|
||||||
),
|
),
|
||||||
@@ -181,7 +180,7 @@ const TasksList: React.FC = React.memo(() => {
|
|||||||
{
|
{
|
||||||
key: 'dueDate',
|
key: 'dueDate',
|
||||||
title: t('tasks.dueDate'),
|
title: t('tasks.dueDate'),
|
||||||
width: '180px',
|
width: '15%',
|
||||||
dataIndex: 'end_date',
|
dataIndex: 'end_date',
|
||||||
render: (_, record) => <HomeTasksDatePicker record={record} />,
|
render: (_, record) => <HomeTasksDatePicker record={record} />,
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user