58 lines
1.8 KiB
JavaScript
58 lines
1.8 KiB
JavaScript
/*
|
|
* Author: 黎永顺
|
|
* name:流量不足提醒
|
|
* Description:
|
|
* Date: 2023/7/19
|
|
*/
|
|
import React, { Component } from "react";
|
|
import { WeaCheckbox, WeaFormItem, WeaHelpfulTip, WeaLocaleProvider, WeaSearchGroup } from "ecCom";
|
|
import "./index.less";
|
|
|
|
const getLabel = WeaLocaleProvider.getLabel;
|
|
|
|
class InsufficientTrafficAlert extends Component {
|
|
constructor(props) {
|
|
super(props);
|
|
this.state = {
|
|
remind: "0"
|
|
};
|
|
}
|
|
|
|
render() {
|
|
const { remind } = this.state;
|
|
return (
|
|
<WeaSearchGroup showGroup needTigger={false} className="insufficientAlertWrapper">
|
|
<WeaFormItem label={getLabel(111, "提醒")} labelCol={{ span: 4 }} wrapperCol={{ span: 20 }}>
|
|
<WeaCheckbox display="switch" value={remind} onChange={remind => this.setState({ remind })}/>
|
|
</WeaFormItem>
|
|
{
|
|
remind === "1" &&
|
|
<React.Fragment>
|
|
<WeaFormItem
|
|
label={getLabel(111, "提醒规则")}
|
|
labelCol={{ span: 4 }} wrapperCol={{ span: 20 }}
|
|
>
|
|
<WeaCheckbox display="switch"/>
|
|
</WeaFormItem>
|
|
<WeaFormItem
|
|
label={getLabel(111, "提醒推送方式")}
|
|
labelCol={{ span: 4 }} wrapperCol={{ span: 20 }}
|
|
>
|
|
<WeaCheckbox display="switch"/>
|
|
<WeaHelpfulTip
|
|
width={200} style={{ marginLeft: 10 }}
|
|
title={getLabel(111, "使用云桥之前,请先确认企业微信是否绑定云桥。\n" +
|
|
"使用邮箱之前,请先确认是否设置邮件提醒账号。\n" +
|
|
"使用短信之前,请先确认是否新建签名。")}
|
|
placement="topLeft"
|
|
/>
|
|
</WeaFormItem>
|
|
</React.Fragment>
|
|
}
|
|
</WeaSearchGroup>
|
|
);
|
|
}
|
|
}
|
|
|
|
export default InsufficientTrafficAlert;
|