|
@@ -5,7 +5,7 @@ import styles from './style.module.less'
|
|
|
const { TabPane } = Tabs
|
|
|
const { TextArea } = Input;
|
|
|
export default function ActionDynamic(props) {
|
|
|
- const { commentsList = [], changeRecordList = null, executionUseCase = null, onPulishComments, getComListAndLogList, showLog = true } = props
|
|
|
+ const { commentsList = [], changeRecordList = null, executionUseCase = null, isShowComments = true, onPulishComments, getComListAndLogList, showLog = true } = props
|
|
|
const [commentText, setCommentText] = useState('')
|
|
|
function back(isSuccess = true) {
|
|
|
if(isSuccess) {
|
|
@@ -15,7 +15,7 @@ export default function ActionDynamic(props) {
|
|
|
return (
|
|
|
<div className={styles.actionDynamic}>
|
|
|
<Tabs defaultActiveKey="1" animated={false} onChange={(e) => getComListAndLogList && getComListAndLogList(e) }>
|
|
|
- <TabPane tab="评论" key="1">
|
|
|
+ {isShowComments && <TabPane tab="评论" key="1">
|
|
|
<div className={styles.tabbox}>
|
|
|
{
|
|
|
commentsList.map((item, index) => (
|
|
@@ -35,7 +35,7 @@ export default function ActionDynamic(props) {
|
|
|
<div className={styles.btn}>
|
|
|
<Button type="primary" onClick={() => onPulishComments(commentText, (isSuccess) => back(isSuccess))}>发表评论</Button>
|
|
|
</div>
|
|
|
- </TabPane>
|
|
|
+ </TabPane>}
|
|
|
{changeRecordList && <TabPane tab="变更记录" key="2">
|
|
|
<div className={styles.tabbox}>
|
|
|
{
|