版本升级
This commit is contained in:
parent
b3b1dde262
commit
a5579d4091
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "aix-win-ws",
|
||||
"version": "2.5.18",
|
||||
"version": "2.5.19",
|
||||
"description": "",
|
||||
"main": "./out/main/index.js",
|
||||
"author": "上海交大重庆人工智能研究院",
|
||||
|
@ -44,7 +44,7 @@
|
|||
"@vue-office/excel": "^1.7.11",
|
||||
"@vue-office/pdf": "^2.0.2",
|
||||
"@vueuse/core": "^10.11.0",
|
||||
"aix-plugins-aitools": "^1.1.10",
|
||||
"aix-plugins-aitools": "^1.1.24",
|
||||
"animate.css": "^4.1.1",
|
||||
"circular-json": "^0.5.9",
|
||||
"clipboard": "^2.0.11",
|
||||
|
|
|
@ -1,78 +1,11 @@
|
|||
<template>
|
||||
<!-- <form @submit.prevent="submitForm" enctype="multipart/form-data">-->
|
||||
<form action="https://wzyzoss.eos-chongqing-3.cmecloud.cn" method="post" enctype="multipart/form-data">
|
||||
<!-- action 是具体要上传的地址 -->
|
||||
<!--
|
||||
|
||||
上传后文件(Object)名:
|
||||
<input type="input" name="key" :value="uploadData.key" placeholder="文件名" style="width: 400px"/><br/><br/>
|
||||
|
||||
ACL:
|
||||
<input type="hidden" name="acl" :value="uploadData.acl" placeholder="文件 ACL" style="width: 400px"/><br/><br/>
|
||||
|
||||
Content-Type:
|
||||
<input type="input" name="Content-Type" :value="uploadData['Content-Type']" placeholder="文件类型" style="width: 400px"/><br/><br/>
|
||||
|
||||
X-Amz-Credential:
|
||||
<input type="text" name="X-Amz-Credential" :value="uploadData['x-amz-credential']" placeholder="X-Amz-Credential,从后端程序返回中获取" style="width: 400px"/><br/><br/>
|
||||
|
||||
X-Amz-Algorithm:
|
||||
<input type="text" name="X-Amz-Algorithm" :value="uploadData['x-amz-algorithm']" placeholder="X-Amz-Algorithm, 从后端程序返回中获取" style="width: 400px"/><br/><br/>
|
||||
|
||||
X-Amz-Date:
|
||||
<input type="text" name="X-Amz-Date" :value="uploadData['x-amz-date']" placeholder="X-Amz-Date 从后端程序返回中获取" style="width: 400px"><br/><br/>
|
||||
|
||||
Policy:
|
||||
<input type="text" name="Policy" :value="uploadData.policy" placeholder="Policy 从后端程序返回中获取" style="width: 400px"/><br/><br/>
|
||||
|
||||
X-Amz-Signature:
|
||||
<input type="text" name="X-Amz-Signature" :value="uploadData['x-amz-signature']" placeholder="X-Amz-Signature 从后端程序返回中获取" style="width: 400px"/><br/><br/>
|
||||
-->
|
||||
|
||||
选择文件(Object)
|
||||
<input type="file" name="file" @change="handleFileChange" style="width: 400px"/> <br/><br/>
|
||||
<input type="submit" name="submit" value="上传到 EOS" style="width: 400px"/><br/><br/>
|
||||
<el-button @click="uploadFile">上传</el-button>
|
||||
</form>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {ref, onMounted} from "vue"
|
||||
import {createSignature, sessionToken} from "@/api/file";
|
||||
import axios from "axios"
|
||||
|
||||
const url = "https://wzyzoss.eos-chongqing-3.cmecloud.cn"
|
||||
const uploadData = ref({
|
||||
"bucket": "wzyzoss",
|
||||
"x-amz-date": "20250113T061000Z",
|
||||
"x-amz-signature": "2d6fba9f27544bfc7414d660e2e73aafdaf02fe3de45e68f59d580276239cd07",
|
||||
"acl": "private",
|
||||
"x-amz-algorithm": "AWS4-HMAC-SHA256",
|
||||
"key": "wzyzossa",
|
||||
"x-amz-credential": "07ICFAF4IWWZP6RH0WCG/20250113/us-east-1/s3/aws4_request",
|
||||
"Content-Type": null,
|
||||
"policy": "eyJleHBpcmF0aW9uIjoiMjAyNS0wMS0xM1QwNzoxMDowMC42NzVaIiwiY29uZGl0aW9ucyI6W3sieC1hbXotZGF0ZSI6IjIwMjUwMTEzVDA2MTAwMFoifSx7ImFjbCI6InByaXZhdGUifSx7ImJ1Y2tldCI6Ind6eXpvc3MifSxbInN0YXJ0cy13aXRoIiwiJGtleSIsInd6eXpvc3NhIl0sWyJzdGFydHMtd2l0aCIsIiRDb250ZW50LVR5cGUiLCJudWxsIl0seyJ4LWFtei1hbGdvcml0aG0iOiJBV1M0LUhNQUMtU0hBMjU2In0seyJ4LWFtei1jcmVkZW50aWFsIjoiMDdJQ0ZBRjRJV1daUDZSSDBXQ0cvMjAyNTAxMTMvdXMtZWFzdC0xL3MzL2F3czRfcmVxdWVzdCJ9LFsiY29udGVudC1sZW5ndGgtcmFuZ2UiLDEsMTAwMDAwXV19"
|
||||
})
|
||||
|
||||
|
||||
|
||||
const submitForm = ()=> {
|
||||
let formData = new FormData();
|
||||
for (const formDataKey in formData) {
|
||||
formData.append(formDataKey, formData[formDataKey]);
|
||||
}
|
||||
axios.post(url, formData, {
|
||||
headers: {
|
||||
'Content-Type': 'multipart/form-data'
|
||||
}
|
||||
})
|
||||
.then(response => {
|
||||
console.log('表单提交成功,服务器响应:', response.data);
|
||||
})
|
||||
.catch(error => {
|
||||
console.log('表单提交失败:', error);
|
||||
});
|
||||
}
|
||||
|
||||
const S3Data = {
|
||||
apiVersion: "2006-03-01",
|
||||
|
@ -104,6 +37,7 @@ const uploadFile = ()=>{
|
|||
Body: selectedFile
|
||||
}
|
||||
console.log(params)
|
||||
console.log(s3)
|
||||
s3.putObject(params, function (err, data) {
|
||||
console.log(err,data)
|
||||
});
|
||||
|
@ -112,9 +46,6 @@ const uploadFile = ()=>{
|
|||
|
||||
onMounted(()=>{
|
||||
console.log(AWS)
|
||||
/*createSignature({objectName:"123.jpg",contentType:"image/png"}).then(res=>{
|
||||
uploadData.value = res.body
|
||||
})*/
|
||||
sessionToken().then(res=>{
|
||||
uploadMessage.value = res.data
|
||||
console.log(res.data)
|
||||
|
|
|
@ -15,16 +15,16 @@ emits: {
|
|||
}
|
||||
-->
|
||||
<template>
|
||||
<div class="page-mindmap flex flex-col h-full">
|
||||
<div class="mindmap-header flex items-center justify-between pl-5">
|
||||
<div class="flex w-1/2 items-center justify-between">
|
||||
<div class="page-mindmap">
|
||||
<div class="mindmap-header">
|
||||
<div class="mindmap-title">
|
||||
<div>
|
||||
<b>AI思维导图</b> <span class="ml-5">《{{ props.title }}》</span>
|
||||
<b>AI思维导图</b> <span class="">《{{ props.title }}》</span>
|
||||
</div>
|
||||
<div>
|
||||
<template v-if="isEdit">
|
||||
<el-button class="mr-3" @click="isEdit = false">取消</el-button>
|
||||
<el-button type="success" class="mr-3" @click="isEdit = false">保存</el-button>
|
||||
<el-button class="" @click="isEdit = false">取消</el-button>
|
||||
<el-button type="success" class="" @click="isEdit = false">保存</el-button>
|
||||
</template>
|
||||
<!-- <el-button v-else type="primary" class="mr-3" @click="isEdit = true">编辑</el-button>-->
|
||||
</div>
|
||||
|
@ -34,9 +34,9 @@ emits: {
|
|||
<el-button @click="outputImg" type="primary">导出图片</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mindmap-main flex flex-1" style="overflow: auto;">
|
||||
<div class="w-1/3 h-full p-3 main-left flex flex-col" v-loading="loadingAnswer" style="overflow: auto;">
|
||||
<div class="flex flex-1" style="overflow: auto;">
|
||||
<div class="mindmap-main" style="overflow: auto;">
|
||||
<div class="mindmap-main-left" v-loading="loadingAnswer" style="overflow: auto;">
|
||||
<div class="main-left-content" style="overflow: auto;">
|
||||
<v-md-editor v-model="resMarkdown" :mode="isEdit ? 'edit' : 'preview'" />
|
||||
</div>
|
||||
<div class="main-left-ipt">
|
||||
|
@ -53,7 +53,7 @@ emits: {
|
|||
<!-- <el-input style="float: left;" v-model="textVal" size="large" placeholder="请输入信息对内容进一步调整" /><el-button>发送</el-button>-->
|
||||
</div>
|
||||
</div>
|
||||
<div class="w-2/3 h-full main-right">
|
||||
<div class="mindmap-main-right">
|
||||
<mindmap v-if="rootData" :timetravel="true" :drag="true" :zoom="true" :edit="true"
|
||||
:center-btn="true" :fit-btn="true" :ctm="true" :add-node-btn="true"
|
||||
v-model="rootData"></mindmap>
|
||||
|
@ -223,24 +223,54 @@ watch(() => resMarkdown.value, () => {
|
|||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.mindmap-header {
|
||||
.page-mindmap{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
|
||||
.mindmap-header {
|
||||
background: #fff;
|
||||
height: 45px;
|
||||
border-radius: 5px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.main-left {
|
||||
background: #fff;
|
||||
border-radius: 5px;
|
||||
.main-left-ipt {
|
||||
height: 40px;
|
||||
padding: 0 20px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
.main-right{
|
||||
|
||||
.mindmap-main{
|
||||
display: flex;
|
||||
flex: 1;
|
||||
flex-direction: row;
|
||||
.mindmap-main-left {
|
||||
background: #fff;
|
||||
flex-basis: 34%;
|
||||
border-radius: 5px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
.main-left-content{
|
||||
flex: 1;
|
||||
}
|
||||
.main-left-ipt {
|
||||
height: 50px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
.mindmap-main-right{
|
||||
border: 1px solid #ccc;
|
||||
flex-basis: 66%;
|
||||
svg {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
</style>
|
||||
|
|
Loading…
Reference in New Issue