|
294 | 294 | </el-tooltip> |
295 | 295 | </h5> |
296 | 296 | <div class="p-8-12 border-t-dashed lighter"> |
297 | | - <el-scrollbar height="150"> |
| 297 | + <el-scrollbar height="200"> |
298 | 298 | <el-card |
299 | 299 | shadow="never" |
300 | 300 | style="--el-card-padding: 8px" |
|
310 | 310 | style="background: none" |
311 | 311 | noImgZoomIn |
312 | 312 | /> |
| 313 | + |
313 | 314 | <template v-else> -</template> |
314 | 315 | </el-card> |
315 | 316 | </el-scrollbar> |
|
892 | 893 | {{ $t('views.workflow.nodes.variableAggregationNode.Strategy') }} |
893 | 894 | </h5> |
894 | 895 | <div class="p-8-12 border-t-dashed lighter pre-wrap"> |
895 | | - {{ data.strategy }} |
| 896 | + {{ |
| 897 | + data.strategy === 'variable_to_json' |
| 898 | + ? t('views.workflow.nodes.variableAggregationNode.placeholder1') |
| 899 | + : t('views.workflow.nodes.variableAggregationNode.placeholder') |
| 900 | + }} |
896 | 901 | </div> |
897 | 902 | </div> |
898 | 903 | <div |
|
903 | 908 | <h5 class="p-8-12"> |
904 | 909 | {{ group.label + ' ' + $t('common.param.inputParam') }} |
905 | 910 | </h5> |
906 | | - <div class="p-8-12 border-t-dashed lighter"> |
907 | | - <div v-for="(f, i) in group.variable_list" :key="i" class="mb-8"> |
908 | | - <span class="color-secondary">{{ `${f.node_name}.${f.field}` }}:</span> |
909 | | - {{ f.value }} |
| 911 | + <el-scrollbar height="200"> |
| 912 | + <div class="p-8-12 border-t-dashed lighter"> |
| 913 | + <div v-for="(f, i) in group.variable_list" :key="i" class="mb-8"> |
| 914 | + <span class="color-secondary">{{ `${f.node_name}.${f.field}` }}:</span> |
| 915 | + {{ f.value }} |
| 916 | + </div> |
910 | 917 | </div> |
911 | | - </div> |
| 918 | + </el-scrollbar> |
912 | 919 | </div> |
913 | 920 | <div class="card-never border-r-6 mt-8"> |
914 | 921 | <h5 class="p-8-12"> |
|
1106 | 1113 | > |
1107 | 1114 | {{ data.split_strategy }} |
1108 | 1115 | </div> |
| 1116 | + <div class="mb-8"> |
| 1117 | + <span class="color-secondary" |
| 1118 | + >{{ $t('views.workflow.nodes.documentSplitNode.chunk_length.label') }}:</span |
| 1119 | + > |
| 1120 | + {{ data.chunk_size }} |
| 1121 | + </div> |
| 1122 | + {{ data.size }} |
1109 | 1123 | <div class="mb-8"> |
1110 | 1124 | <span class="color-secondary">{{ $t('common.inputContent') }}:</span> |
1111 | | - {{ data.document_list }} |
| 1125 | + {{ data.document_list?.map((v: any) => v.name).join(',') }} |
1112 | 1126 | </div> |
1113 | 1127 | </div> |
1114 | 1128 | </div> |
|
1119 | 1133 | }}) |
1120 | 1134 | </h5> |
1121 | 1135 | <div class="p-8-12 border-t-dashed lighter"> |
1122 | | - <el-radio-group v-model="currentParagraph" class="app-radio-button-group mb-8"> |
1123 | | - <template |
1124 | | - v-for="(paragrapg, ParagraphIndex) in data.paragraph_list" |
1125 | | - :key="ParagraphIndex" |
1126 | | - > |
1127 | | - <el-radio-button :label="paragrapg.name" :value="ParagraphIndex" /> |
1128 | | - </template> |
1129 | | - </el-radio-group> |
1130 | | - <template v-if="data.paragraph_list?.length > 0"> |
1131 | | - <template |
1132 | | - v-for="(paragraph, pId) in data.paragraph_list?.[currentParagraph]?.paragraphs" |
1133 | | - :key="pId" |
1134 | | - > |
1135 | | - <ParagraphCard :data="paragraph" :content="paragraph.content" :index="pId"> |
1136 | | - <template #footer> |
1137 | | - <span class="color-secondary"> |
1138 | | - {{ $t('common.character') }}:{{ paragraph.content.length }}</span |
1139 | | - > |
| 1136 | + <el-tabs v-model="currentParagraph" class="paragraph-tabs"> |
| 1137 | + <template v-for="(item, index) in data.paragraph_list" :key="index"> |
| 1138 | + <el-tab-pane :label="item.name" :name="index"> |
| 1139 | + <template #label> |
| 1140 | + <div class="flex-center"> |
| 1141 | + <span class="ml-4">{{ item?.name }}</span> |
| 1142 | + </div> |
| 1143 | + </template> |
| 1144 | + |
| 1145 | + <template v-for="(paragraph, pId) in item?.paragraphs" :key="pId"> |
| 1146 | + <ParagraphCard :data="paragraph" :content="paragraph.content" :index="pId"> |
| 1147 | + <template #footer> |
| 1148 | + <span class="color-secondary"> |
| 1149 | + {{ $t('common.character') }}:{{ paragraph.content.length }}</span |
| 1150 | + > |
| 1151 | + </template> |
| 1152 | + </ParagraphCard> |
1140 | 1153 | </template> |
1141 | | - </ParagraphCard> |
| 1154 | + </el-tab-pane> |
1142 | 1155 | </template> |
1143 | | - </template> |
1144 | | - <template v-else> -</template> |
| 1156 | + </el-tabs> |
1145 | 1157 | </div> |
1146 | 1158 | </div> |
1147 | 1159 | </template> |
1148 | 1160 | <!-- 知识库写入 --> |
1149 | 1161 | <template v-if="data.type === WorkflowType.KnowledgeWriteNode"> |
| 1162 | + <div class="card-never border-r-6 mt-8"> |
| 1163 | + <h5 class="p-8-12">{{ $t('chat.executionDetails.writeContent') }}</h5> |
| 1164 | + <div class="p-8-12 border-t-dashed lighter"> |
| 1165 | + <el-tabs v-model="currentWriteContent" class="paragraph-tabs"> |
| 1166 | + <template v-for="(item, index) in data.write_content" :key="index"> |
| 1167 | + <el-tab-pane :label="item.name" :name="index"> |
| 1168 | + <template #label> |
| 1169 | + <div class="flex-center"> |
| 1170 | + <span class="ml-4">{{ item?.name }}</span> |
| 1171 | + </div> |
| 1172 | + </template> |
| 1173 | + |
| 1174 | + <template v-for="(paragraph, pId) in item?.paragraphs" :key="pId"> |
| 1175 | + <ParagraphCard :data="paragraph" :content="paragraph.content" :index="pId"> |
| 1176 | + <template #footer> |
| 1177 | + <span class="color-secondary"> |
| 1178 | + {{ $t('common.character') }}:{{ paragraph.content.length }}</span |
| 1179 | + > |
| 1180 | + </template> |
| 1181 | + </ParagraphCard> |
| 1182 | + </template> |
| 1183 | + </el-tab-pane> |
| 1184 | + </template> |
| 1185 | + </el-tabs> |
| 1186 | + </div> |
| 1187 | + </div> |
| 1188 | + </template> |
| 1189 | + <!-- Web站点 --> |
| 1190 | + <template v-if="data.type === WorkflowType.DataSourceWebNode"> |
1150 | 1191 | <div class="card-never border-r-6"> |
1151 | 1192 | <h5 class="p-8-12"> |
1152 | 1193 | {{ $t('common.param.inputParam') }} |
1153 | 1194 | </h5> |
1154 | 1195 | <div class="p-8-12 border-t-dashed lighter"> |
1155 | | - <span class="color-secondary" |
1156 | | - >{{ $t('views.workflow.nodes.documentSplitNode.chunk_length.label') }}:</span |
1157 | | - > |
1158 | | - {{ data.size }} |
| 1196 | + <p class="mb-8 color-secondary"> |
| 1197 | + {{ $t('views.document.form.selector.label') }}:{{ data.input_params.selector }} |
| 1198 | + </p> |
| 1199 | + <p class="mb-8 color-secondary"> |
| 1200 | + {{ $t('views.document.form.source_url.label') }}:{{ |
| 1201 | + data.input_params.source_url |
| 1202 | + }} |
| 1203 | + </p> |
1159 | 1204 | </div> |
1160 | 1205 | </div> |
1161 | | - <div class="card-never border-r-6 mt-8"> |
1162 | | - <h5 class="p-8-12">{{ $t('chat.executionDetails.writeContent') }}</h5> |
| 1206 | + <div class="card-never border-r-6"> |
| 1207 | + <h5 class="p-8-12"> |
| 1208 | + {{ $t('common.param.outputParam') }} |
| 1209 | + </h5> |
1163 | 1210 | <div class="p-8-12 border-t-dashed lighter"> |
1164 | | - <el-radio-group v-model="currentWriteContent" class="app-radio-button-group mb-8"> |
1165 | | - <template |
1166 | | - v-for="(paragrapg, ParagraphIndex) in data.write_content" |
1167 | | - :key="ParagraphIndex" |
1168 | | - > |
1169 | | - <el-radio-button :label="paragrapg.name" :value="ParagraphIndex" /> |
1170 | | - </template> |
1171 | | - </el-radio-group> |
1172 | | - <template v-if="data.write_content?.length > 0"> |
1173 | | - <template |
1174 | | - v-for="(paragraph, pId) in data.write_content?.[currentWriteContent] |
1175 | | - ?.paragraphs" |
1176 | | - :key="pId" |
| 1211 | + <el-scrollbar height="200"> |
| 1212 | + <el-card |
| 1213 | + shadow="never" |
| 1214 | + style="--el-card-padding: 8px" |
| 1215 | + v-for="(file_content, index) in data.output_params" |
| 1216 | + :key="index" |
| 1217 | + class="mb-8" |
1177 | 1218 | > |
1178 | | - <ParagraphCard :data="paragraph" :content="paragraph.content" :index="pId"> |
1179 | | - <template #footer> |
1180 | | - <span class="color-secondary"> |
1181 | | - {{ $t('common.character') }}:{{ paragraph.content.length }}</span |
1182 | | - > |
1183 | | - </template> |
1184 | | - </ParagraphCard> |
1185 | | - </template> |
1186 | | - </template> |
1187 | | - <template v-else> -</template> |
| 1219 | + <MdPreview |
| 1220 | + v-if="file_content" |
| 1221 | + ref="editorRef" |
| 1222 | + editorId="preview-only" |
| 1223 | + :modelValue="file_content" |
| 1224 | + style="background: none" |
| 1225 | + noImgZoomIn |
| 1226 | + /> |
| 1227 | + <template v-else> -</template> |
| 1228 | + </el-card> |
| 1229 | + </el-scrollbar> |
1188 | 1230 | </div> |
1189 | 1231 | </div> |
1190 | 1232 | </template> |
|
0 commit comments