|
|
@@ -1,5 +1,5 @@
|
|
|
import { ActionType, ProTable } from "@ant-design/pro-components";
|
|
|
-import { FormattedMessage, useIntl } from "react-intl";
|
|
|
+import { useIntl } from "react-intl";
|
|
|
import { Link } from "react-router-dom";
|
|
|
import { Alert, Badge, Button, message, Modal, Popover } from "antd";
|
|
|
import { Dropdown } from "antd";
|
|
|
@@ -20,29 +20,6 @@ import { TransferOutLinedIcon } from "../../assets/icon";
|
|
|
import { IProjectData, IProjectListResponse } from "../api/task";
|
|
|
import ProjectCreate from "./ProjectCreate";
|
|
|
|
|
|
-export const channelTypeFilter = {
|
|
|
- all: {
|
|
|
- text: <FormattedMessage id="channel.type.all.title" />,
|
|
|
- status: "Default",
|
|
|
- },
|
|
|
- translation: {
|
|
|
- text: <FormattedMessage id="channel.type.translation.label" />,
|
|
|
- status: "Success",
|
|
|
- },
|
|
|
- nissaya: {
|
|
|
- text: <FormattedMessage id="channel.type.nissaya.label" />,
|
|
|
- status: "Processing",
|
|
|
- },
|
|
|
- commentary: {
|
|
|
- text: <FormattedMessage id="channel.type.commentary.label" />,
|
|
|
- status: "Default",
|
|
|
- },
|
|
|
- original: {
|
|
|
- text: <FormattedMessage id="channel.type.original.label" />,
|
|
|
- status: "Default",
|
|
|
- },
|
|
|
-};
|
|
|
-
|
|
|
export interface IResNumberResponse {
|
|
|
ok: boolean;
|
|
|
message: string;
|
|
|
@@ -82,7 +59,7 @@ const ProjectListWidget = ({
|
|
|
onSelect,
|
|
|
}: IWidget) => {
|
|
|
const intl = useIntl();
|
|
|
- const [activeKey, setActiveKey] = useState<React.Key | undefined>("all");
|
|
|
+ const [activeKey, setActiveKey] = useState<React.Key | undefined>("instance");
|
|
|
const [openCreate, setOpenCreate] = useState(false);
|
|
|
|
|
|
useEffect(() => {
|
|
|
@@ -130,13 +107,6 @@ const ProjectListWidget = ({
|
|
|
|
|
|
return (
|
|
|
<>
|
|
|
- {channelType ? (
|
|
|
- <Alert
|
|
|
- message={`仅显示版本类型${channelType}`}
|
|
|
- type="success"
|
|
|
- closable
|
|
|
- />
|
|
|
- ) : undefined}
|
|
|
<ProTable<IProjectData>
|
|
|
actionRef={ref}
|
|
|
columns={[
|
|
|
@@ -305,8 +275,8 @@ const ProjectListWidget = ({
|
|
|
activeKey,
|
|
|
items: [
|
|
|
{
|
|
|
- key: "all",
|
|
|
- label: intl.formatMessage({ id: "labels.all" }),
|
|
|
+ key: "instance",
|
|
|
+ label: "项目",
|
|
|
},
|
|
|
{
|
|
|
key: "workflow",
|