Commit 3d6fa891 authored by “lixuyan”'s avatar “lixuyan”

修改内容为空的问题

parent 41580624
......@@ -991,44 +991,48 @@ export default {
formatHTML(statusCode, html) {
if (statusCode === 'Not') {
// 扫码录入
return (
html
.replaceAll(
'##',
"<div class='scan-code'><textarea type='text'placeholder='请填写内容'></textarea><span class='saoma'></span></div>"
)
if (html) {
return (
html
.replaceAll(
'##',
"<div class='scan-code'><textarea type='text'placeholder='请填写内容'></textarea><span class='saoma'></span></div>"
)
// 手工录入
.replaceAll(
'@@',
"<textarea type='text' placeholder='请填写内容'></textarea>"
)
.replaceAll(
'@@',
"<textarea type='text' placeholder='请填写内容'></textarea>"
)
// 日期框
.replaceAll(
'$$',
"<input type='datetime-local' placeholder='请填写日期'>"
)
)
.replaceAll(
'$$',
"<input type='datetime-local' placeholder='请填写日期'>"
)
)
}
} else {
return (
html
.replaceAll(
'##',
"<div class='scan-code'><textarea disabled type='text'placeholder='请填写内容'></textarea><span class='saoma'></span></div>"
)
if (html) {
return (
html
.replaceAll(
'##',
"<div class='scan-code'><textarea disabled type='text'placeholder='请填写内容'></textarea><span class='saoma'></span></div>"
)
// 手工录入
.replaceAll(
'@@',
"<textarea type='text' disabled placeholder='请填写内容'></textarea>"
)
.replaceAll(
'@@',
"<textarea type='text' disabled placeholder='请填写内容'></textarea>"
)
// 日期框
.replaceAll(
'$$',
"<input type='datetime-local' disabled placeholder='请填写日期'>"
)
.replaceAll('saoma', '')
.replaceAll('<input', '<input disabled ')
.replaceAll('<textarea', '<textarea disabled ')
)
.replaceAll(
'$$',
"<input type='datetime-local' disabled placeholder='请填写日期'>"
)
.replaceAll('saoma', '')
.replaceAll('<input', '<input disabled ')
.replaceAll('<textarea', '<textarea disabled ')
)
}
}
},
/**
......
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