|
@@ -830,6 +830,15 @@ export default {
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
let textList = this.textInput.trim().split('\n');
|
|
let textList = this.textInput.trim().split('\n');
|
|
|
|
|
+ for (let i = 0; i < textList.length; i++) {
|
|
|
|
|
+ if (textList[i].trim()) {
|
|
|
|
|
+ if (textList[i].indexOf(':') === -1) {
|
|
|
|
|
+ // 如果不包含描述、语境或者角色名
|
|
|
|
|
+ this.$message.error('缺少角色或语境,请补全');
|
|
|
|
|
+ return false;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
textList.forEach((item) => {
|
|
textList.forEach((item) => {
|
|
|
if (item.trim()) {
|
|
if (item.trim()) {
|
|
|
let obj = {
|
|
let obj = {
|