✨ feat: 基本数据流程
This commit is contained in:
parent
50b04a4adf
commit
c29f4c6481
@ -117,7 +117,7 @@ function testExpression(item: ResultExpression) {
|
||||
notification.info({
|
||||
message: '提示',
|
||||
description: `${item.title}:${value}`,
|
||||
duration: 2
|
||||
duration: 0
|
||||
})
|
||||
} catch (e) {
|
||||
modal.warning({
|
||||
@ -134,15 +134,19 @@ function parseExpression(str: string) {
|
||||
if (!doc.content || doc.content.length == 0) {
|
||||
return '';
|
||||
}
|
||||
const expressionList = doc.content[0].content;
|
||||
if (!expressionList) return '';
|
||||
const expression = expressionList.map(item => {
|
||||
if (item.type == 'text') {
|
||||
return item.text;
|
||||
}
|
||||
return item.attrs.id
|
||||
}).join('');
|
||||
return expression;
|
||||
const expList: string[] = [];
|
||||
doc.content.forEach(p=>{
|
||||
const expressionList = p.content;
|
||||
if (!expressionList) return;
|
||||
const expression = expressionList.map(item => {
|
||||
if (item.type == 'text') {
|
||||
return item.text;
|
||||
}
|
||||
return item.attrs.id
|
||||
}).join('');
|
||||
expList.push(expression);
|
||||
})
|
||||
return expList.join('');
|
||||
// console.log(JSON.stringify({content:doc.content[0].content}))
|
||||
}
|
||||
</script>
|
||||
|
Loading…
x
Reference in New Issue
Block a user