IO-884 Add special coverage policy indicators.

This commit is contained in:
Patrick Fic
2021-04-12 15:22:01 -07:00
parent fbb170491b
commit c216295e66
8 changed files with 86 additions and 11 deletions

View File

@@ -1,6 +1,20 @@
import { DeleteFilled, FilterFilled, SyncOutlined } from "@ant-design/icons";
import {
DeleteFilled,
FilterFilled,
SyncOutlined,
WarningFilled,
} from "@ant-design/icons";
import { useMutation } from "@apollo/client";
import { Button, Dropdown, Input, Menu, PageHeader, Space, Table } from "antd";
import {
Button,
Dropdown,
Input,
Menu,
PageHeader,
Space,
Table,
Tag,
} from "antd";
import React, { useState } from "react";
import { useTranslation } from "react-i18next";
import { connect } from "react-redux";
@@ -318,6 +332,15 @@ export function JobLinesComponent({
<Button onClick={() => refetch()}>
<SyncOutlined />
</Button>
{job.special_coverage_policy && (
<Tag color="tomato">
<Space>
<WarningFilled />
<span>{t("jobs.labels.specialcoveragepolicy")}</span>
</Space>
</Tag>
)}
<Button
disabled={
(job && !job.converted) ||
@@ -329,6 +352,7 @@ export function JobLinesComponent({
actions: { refetch: refetch },
context: {
jobId: job.id,
job: job,
linesToOrder: selectedLines,
},
});
@@ -354,7 +378,6 @@ export function JobLinesComponent({
<Dropdown overlay={markMenu} trigger={["click"]}>
<Button>{t("jobs.actions.mark")}</Button>
</Dropdown>
<Button
disabled={jobRO}
onClick={() => {
@@ -366,7 +389,6 @@ export function JobLinesComponent({
>
{t("joblines.actions.new")}
</Button>
<Input.Search
placeholder={t("general.labels.search")}
onChange={(e) => {