提交 47dcb386 authored 作者: chscls@163.com's avatar chscls@163.com

富文本bug

上级 fbb8c007
...@@ -64,7 +64,7 @@ export default class DraftEditor extends React.Component { ...@@ -64,7 +64,7 @@ export default class DraftEditor extends React.Component {
constructor(props) { constructor(props) {
super(props); super(props);
const value = props.value || {}; const value = props.value || {};
const editorState = changeToDraftState2(blocks)
this.state = { this.state = {
editorState: value.editorState, editorState: value.editorState,
......
差异被折叠。
...@@ -71,7 +71,7 @@ import { Base16Encode } from '../Base16/index'; ...@@ -71,7 +71,7 @@ import { Base16Encode } from '../Base16/index';
import { getToken } from '../utils/token'; import { getToken } from '../utils/token';
import { formulaList } from '../excelInitFuc/functionList'; import { formulaList } from '../excelInitFuc/functionList';
import FilePreview from '../filePreview'; import FilePreview from '../filePreview';
import DraftEditor from '../App/DraftEditor'; import DraftEditorCom from '../App/DraftEditorCom';
const Item = MobileList.Item; const Item = MobileList.Item;
const Brief = Item.Brief; const Brief = Item.Brief;
function getBase64(value) { function getBase64(value) {
...@@ -2877,12 +2877,12 @@ export default class tableCom extends Component { ...@@ -2877,12 +2877,12 @@ export default class tableCom extends Component {
break; break;
case 'RichText': case 'RichText':
cm = getFieldDecorator(dataColumn.base52, { cm = getFieldDecorator(dataColumn.base52, {
initialValue: { editorState: changeToDraftState(initValue) }, initialValue: initValue,
rules: rules:
json.vlds && json.vlds.length > 0 json.vlds && json.vlds.length > 0
? json.vlds ? json.vlds
: [{ required: required, message: '请输入' }], : [{ required: required, message: '请输入' }],
})(<DraftEditor placeholder={json.placeholder} />); })(<DraftEditorCom placeholder={json.placeholder} />);
if (get === 'mobile' && json.isLabel && title) { if (get === 'mobile' && json.isLabel && title) {
cm = ( cm = (
<Form.Item <Form.Item
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论