文生图已经可以生成,但是显示的字错误

This commit is contained in:
王佑琳 2026-03-12 10:06:00 +08:00
parent e13cc2a684
commit 86c3a61d00
3 changed files with 7 additions and 13 deletions

View File

@ -14,8 +14,8 @@ VITE_API_PAY_PREFIX = '/pay'
VITE_API_PAY_TARGET = 'https://sxwz.xueai.art' # http://43.248.133.202 VITE_API_PAY_TARGET = 'https://sxwz.xueai.art' # http://43.248.133.202
# 任务处理模块 # 任务处理模块
VITE_API_WORKFLOW_UPLOAD = 'https://aipaint.xueai.art/aigc/workflow/file/upload' # https://sxwz.xueai.art/workflow https://designtools.xueai.art/workflow VITE_API_WORKFLOW_UPLOAD = 'https://talkingdraw.xueai.art/aigc/workflow/file/upload' # https://sxwz.xueai.art/workflow https://designtools.xueai.art/workflow
VITE_API_WORKFLOW_WS = 'wss://aipaint.xueai.art/testworkflow' VITE_API_WORKFLOW_WS = 'wss://talkingdraw.xueai.art/testworkflow'
# 是否开启KKFileView # 是否开启KKFileView
FILE_OPEN_PREVIEW = false FILE_OPEN_PREVIEW = false

View File

@ -63,7 +63,7 @@ const props = defineProps({
const router = useRouter() const router = useRouter()
const useDisplay = useDisplayStore() const useDisplay = useDisplayStore()
const type = ref('image') const type = ref('text')
const prompt = ref('一个女孩在树下吃苹果') const prompt = ref('一个女孩在树下吃苹果')
const model = ref('flux') const model = ref('flux')
@ -96,9 +96,9 @@ const handleStart = async () => {
console.log('生成开始', isgerenate.value) console.log('生成开始', isgerenate.value)
const imgs = [] const imgs = []
referenceImages.value.forEach((img, index) => { referenceImages.value.forEach((img, index) => {
imgs.push({ name: `image_${index + 1}`, data: img.url }) imgs.push({ name: `image_${index + 1}`, url: img.url })
}) })
console.log('imgs', imgs)
const data = { const data = {
AIGC: 'Painting', AIGC: 'Painting',
platform: 'runninghub', platform: 'runninghub',
@ -136,12 +136,6 @@ watch(() => useDisplay.isSubGerenate, (newValue) => {
watch(() => type.value, (newValue) => { watch(() => type.value, (newValue) => {
console.log('type.value', newValue) console.log('type.value', newValue)
}) })
onMounted(() => {
if (props.generate) {
generate()
}
})
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>

View File

@ -6,7 +6,7 @@ export async function Playload(data,type) {
const nodeInfoList = [] const nodeInfoList = []
if (Array.isArray(data.imgs)) { if (Array.isArray(data.imgs) && data.imgs.length > 0) {
for (const key of data.imgs) { for (const key of data.imgs) {
if (json.nodeInfoList[key.name]) { if (json.nodeInfoList[key.name]) {
console.log(key) console.log(key)
@ -14,7 +14,7 @@ export async function Playload(data,type) {
nodeInfoList.push(json.nodeInfoList[key.name]) nodeInfoList.push(json.nodeInfoList[key.name])
} }
} }
json.nodeInfoList[index].fieldValue = data.imgs.length() - 1 json.nodeInfoList.index.fieldValue = data.imgs.length - 1
} }
if (Array.isArray(data.params)) { if (Array.isArray(data.params)) {