Commit 9ae16bc5 by zhaochengxiang

模型重点关注

parent d026f37c
......@@ -300,36 +300,24 @@ tr.drop-over-upward td {
}
}
.yy-btn {
svg {
fill: @icon-color !important;
}
&:hover {
.anticon {
&:not(.customStyle) {
svg {
fill: @icon-hover-color !important;
fill: @icon-color !important;
}
&:hover {
svg {
fill: @icon-hover-color !important;
}
}
}
}
.btn-group {
.anticon {
svg {
fill: @icon-color !important;
}
&:hover {
svg {
fill: @icon-hover-color !important;
}
}
}
.anticon-disable {
&.anticon-disable {
svg {
fill: @icon-disable-color !important;
}
&:hover {
svg {
fill: @icon-disable-color !important;
......@@ -338,22 +326,28 @@ tr.drop-over-upward td {
}
}
.primary-bg-container {
background-color: #196AD2;
svg {
&.icon {
fill: @icon-color !important;
.yy-btn {
svg {
fill: @icon-grey-color !important;
&:hover {
fill: @icon-hover-color !important;
}
}
&.greyIcon {
fill: @icon-grey-color !important;
&:hover {
svg {
fill: #fff !important;
}
fill: #fff !important;
}
}
}
.primary-bg-container {
background-color: #196AD2;
}
.yy-card-head {
min-height: 40px !important;
}
\ No newline at end of file
......@@ -263,7 +263,7 @@ const AssetAction = (props) => {
(currentAction!=='detail') && <Tooltip title='取消编辑'>
<Button
onClick={onCancelButtonClick}
icon={<CancelSvg style={{ width: 20, height: 20 }} />}
icon={<CancelSvg className='greyIcon' style={{ width: 20, height: 20 }} />}
type='text'
/>
</Tooltip>
......@@ -272,7 +272,7 @@ const AssetAction = (props) => {
<Button
loading={confirmLoading}
onClick={onActionButtonClick}
icon={(currentAction==='detail')?<EditSvg style={{ width: 20, height: 20 }} />: <SaveSvg style={{ width: 20, height: 20 }} />}
icon={(currentAction==='detail')?<EditSvg className='greyIcon' style={{ width: 20, height: 20 }} />: <SaveSvg className='greyIcon' style={{ width: 20, height: 20 }} />}
type='text'
/>
</Tooltip>
......@@ -281,7 +281,7 @@ const AssetAction = (props) => {
<Tooltip title={fullScreen?'取消全屏':'全屏'}>
<Button
onClick={onFullScreenClick}
icon={fullScreen?<CancelFullScreenSvg style={{ width: 20, height: 20 }} />: <FullScreenSvg style={{ width: 20, height: 20 }} />}
icon={fullScreen?<CancelFullScreenSvg className='greyIcon' style={{ width: 20, height: 20 }} />: <FullScreenSvg className='greyIcon' style={{ width: 20, height: 20 }} />}
type='text'
/>
</Tooltip>
......
......@@ -587,7 +587,7 @@ const AssetTree = (props) => {
className={classes}
title={ (reference===AssetBrowseReference||reference===ResourceBrowseReference || reference===AssetMountReference) ? null : (
<div
className='flex px-2 btn-group'
className='flex px-2'
style={{
height: 40,
alignItems: 'center',
......
import React, { useState, useCallback, useRef, useEffect } from 'react';
import { Input, Form, Typography, Button, Select, Row, Col, Popover, Checkbox, Tooltip, Table, Pagination, Space } from 'antd';
import { CheckOutlined, PlusOutlined, QuestionCircleOutlined, DeleteOutlined } from '@ant-design/icons';
import { CheckOutlined, PlusOutlined, QuestionCircleOutlined, DeleteOutlined, HeartOutlined, HeartFilled } from '@ant-design/icons';
import { DndProvider, useDrag, useDrop } from 'react-dnd';
import { HTML5Backend } from 'react-dnd-html5-backend';
import update from 'immutability-helper';
......@@ -423,23 +423,23 @@ const ImportActionTable = (props) => {
return '';
}
},
{
title: '重点关注',
width: 75,
dataIndex: 'needAttention',
editable: (type==='model'?true:false),
render: (needAttention, record, index) => {
if (!needAttention) {
return '-';
} else if (needAttention === true) {
return (
<CheckOutlined />
)
}
return '';
}
},
// {
// title: '重点关注',
// width: 75,
// dataIndex: 'needAttention',
// editable: (type==='model'?true:false),
// render: (needAttention, record, index) => {
// if (!needAttention) {
// return '-';
// } else if (needAttention === true) {
// return (
// <CheckOutlined />
// )
// }
// return '';
// }
// },
{
title: '业务含义',
dataIndex: 'remark',
......@@ -920,7 +920,7 @@ const ImportActionTable = (props) => {
{
title: '操作',
dataIndex: 'action',
width: (action==='flow')?180:90,
width: (action==='flow')?220:130,
fixed: 'right',
render: (_, record) => {
return (
......@@ -963,6 +963,31 @@ const ImportActionTable = (props) => {
editable && <React.Fragment>
{
<React.Fragment>
<Tooltip title={record.needAttention ? '取消送审关注': '送审关注'}>
<Button
className='mr-3'
size='small'
type='text'
icon={record.needAttention ? <HeartFilled className='customStyle' style={{ color: 'red' }} /> : <HeartOutlined />}
onClick={(event) => {
event.stopPropagation();
if (record.needAttention === null) {
record.needAttention = true;
} else {
record.needAttention = !record.needAttention;
}
setData(data);
moveRowRef.current.data = data;
onChange && onChange(data, false);
if (!record.needAttention) {
preSaveDataModel(record);
}
}}
/>
</Tooltip>
<Button
className='mr-3'
size='small'
......@@ -978,7 +1003,7 @@ const ImportActionTable = (props) => {
className='mr-3'
size='small'
type='text'
icon={<DeleteOutlined style={{ color: 'red' }} />}
icon={<DeleteOutlined className='customStyle' style={{ color: 'red' }} />}
onClick={(event) => {
event.stopPropagation();
remove(record);
......@@ -1091,14 +1116,13 @@ const ImportActionTable = (props) => {
setColumns(_columns);
} else {
//非编辑状态下 隐藏重点关注
let _columns = hasValidateReports ? includeValidateColumn: cols;
if (action === 'flow') {
_columns = hasValidateReports ? includeValidateEditableColumn: editableColumn;
}
_columns = _columns.filter((col) => col.dataIndex!=='needAttention');
// _columns = _columns.filter((col) => col.dataIndex!=='needAttention');
setColumns(_columns);
}
......
......@@ -434,7 +434,7 @@ const ModelTree = (props) => {
<div className={classes}>
{
(refrence==='') && <div
className='p-3 btn-group'
className='p-3'
style={{
display: 'flex',
borderBottom: "1px solid #EFEFEF",
......
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