Commit a76e2c1e authored by rocosen's avatar rocosen

joblist

joblist
parent 04d22d2e
...@@ -316,6 +316,8 @@ const ProjectMembers = () => { ...@@ -316,6 +316,8 @@ const ProjectMembers = () => {
</Box> </Box>
<div style={{ color: renderProgress(item.state) }} className={styles.tabBoxStatusText}>{item.completeNum + "/" + item.totalNum}</div> <div style={{ color: renderProgress(item.state) }} className={styles.tabBoxStatusText}>{item.completeNum + "/" + item.totalNum}</div>
</Box> </Box>
<Box className={styles.tabBoxJobOperate}> <Box className={styles.tabBoxJobOperate}>
<img alt="" <img alt=""
src={item.state === "RUNNING" ? jobStop : jobDel} src={item.state === "RUNNING" ? jobStop : jobDel}
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
import { memo, useCallback, useEffect, useMemo, useState } from "react"; import { memo, useCallback, useEffect, useMemo, useState } from "react";
import styles from "../index.module.css"; import styles from "../index.module.css";
import { Box, Typography } from "@mui/material"; import { Box, Typography } from "@mui/material";
import Button from "@mui/material/Button"; import Button from "@/components/mui/Button";
import Dialog from "@/components/mui/Dialog"; import Dialog from "@/components/mui/Dialog";
import OutlinedInput from "@mui/material/OutlinedInput"; import OutlinedInput from "@mui/material/OutlinedInput";
import SearchIcon from "@mui/icons-material/Search"; import SearchIcon from "@mui/icons-material/Search";
...@@ -37,13 +37,10 @@ const AddTemplate = (props: any) => { ...@@ -37,13 +37,10 @@ const AddTemplate = (props: any) => {
endAdornment={<SearchIcon style={{ color: "#8A9099" }} />} endAdornment={<SearchIcon style={{ color: "#8A9099" }} />}
/> />
<Button <Button
style={{ backgroundColor: "#1370FF", marginLeft: "12px" }} click={addTemplateCallback}
variant="contained" size={"small"}
onClick={addTemplateCallback} text={'添加模版' + (selectTemplateData.length === 0 ? "" : `(${selectTemplateData.length})`)}
size="small" />
>
添加模版{selectTemplateData.length === 0 ? "" : `(${selectTemplateData.length})`}
</Button>
</Box> </Box>
{ {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
import { memo, useCallback, useEffect, useMemo, useState } from "react"; import { memo, useCallback, useEffect, useMemo, useState } from "react";
import styles from "../index.module.css"; import styles from "../index.module.css";
import { Box, Typography } from "@mui/material"; import { Box, Typography } from "@mui/material";
import Button from "@mui/material/Button"; import Button from "@/components/mui/Button";
import usePass from "@/hooks/usePass"; import usePass from "@/hooks/usePass";
const TemplateBox = (props: any) => { const TemplateBox = (props: any) => {
...@@ -23,27 +23,15 @@ const TemplateBox = (props: any) => { ...@@ -23,27 +23,15 @@ const TemplateBox = (props: any) => {
display: 'flex', justifyContent: 'end' display: 'flex', justifyContent: 'end'
}} > }} >
{ {
isPass("PROJECT_WORKBENCH_FLOES_USE", 'MANAGER') && <Button isPass("PROJECT_WORKBENCH_FLOES_USE", 'MANAGER') &&
style={{ backgroundColor: "#F0F2F5", color: "#565C66" }} <Button size={"small"} text={'删除模版'} click={() => { props.startDialog(info.id) }} style={{ backgroundColor: "#F0F2F5", color: "#565C66" }} />
variant="contained"
onClick={() => { props.startDialog(info.id) }}
size="small"
>
删除模版
</Button>
} }
{ {
isPass("PROJECT_WORKBENCH_FLOES_USE", 'USER') && <Button isPass("PROJECT_WORKBENCH_FLOES_USE", 'USER') &&
style={{ backgroundColor: "#1370FF", marginLeft: "12px" }} <Button size={"small"} text={'使用模版'} click={() => { }} style={{ marginLeft: "12px" }} />
variant="contained"
// onClick={addTemplateBlock}
size="small"
>
使用模版
</Button>
} }
</Box> </Box>
</Box> </Box >
); );
}; };
......
...@@ -11,8 +11,8 @@ import { Box, Typography } from "@mui/material"; ...@@ -11,8 +11,8 @@ import { Box, Typography } from "@mui/material";
import styles from "./index.module.css"; import styles from "./index.module.css";
import OutlinedInput from "@mui/material/OutlinedInput"; import OutlinedInput from "@mui/material/OutlinedInput";
import SearchIcon from "@mui/icons-material/Search"; import SearchIcon from "@mui/icons-material/Search";
// import Button from "@/components/mui/Button"; import Button from "@/components/mui/Button";
import Button from "@mui/material/Button"; // import Button from "@mui/material/Button";
import Add from "@mui/icons-material/Add"; import Add from "@mui/icons-material/Add";
import useMyRequest from "@/hooks/useMyRequest"; import useMyRequest from "@/hooks/useMyRequest";
import TemplateBox from "./components/templateBox" import TemplateBox from "./components/templateBox"
...@@ -198,15 +198,8 @@ const ProjectMembers = observer(() => { ...@@ -198,15 +198,8 @@ const ProjectMembers = observer(() => {
/> />
{ {
templateList.length > 0 && isPass("PROJECT_WORKBENCH_FLOES_ADD", 'MANAGER') && <Button templateList.length > 0 && isPass("PROJECT_WORKBENCH_FLOES_ADD", 'MANAGER') &&
style={{ backgroundColor: "#1370FF " }} <Button text={'添加工作流模版'} img={<Add />} click={addTemplateBlock} size={'small'} />
variant="contained"
onClick={addTemplateBlock}
startIcon={<Add />}
size="small"
>
添加工作流模版
</Button>
} }
</Box> </Box>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment