Browse Source

导入文件夹

hanyuqing
hanyuqing 6 months ago
parent
commit
0488479813
  1. BIN
      gyxtp/src/assets/img2/cloud.png
  2. 1
      gyxtp/src/view/Home.vue
  3. 2
      gyxtp/src/view/Home1.vue
  4. 8
      gyxtp/src/view/articleInfo.vue
  5. 30
      gyxtp/src/view/create.vue
  6. 29
      gyxtp/src/view/docInfo.vue
  7. 6
      gyxtp/src/view/graphPageCopy0926.vue
  8. 6
      gyxtp/src/view/graphPageNB927.vue
  9. 8
      gyxtp/src/view/pointArticleInfo.vue
  10. 60
      gyxtp/src/view/small.vue
  11. 4
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/ZhyDocmubanController.java
  12. 4
      ruoyi-common/src/main/java/com/ruoyi/common/constant/Constants.java
  13. 2
      ruoyi-ui/.env.development
  14. 2
      ruoyi-ui/.env.production
  15. 20
      ruoyi-ui/src/views/system/battle/index.vue
  16. 5
      ruoyi-ui/src/views/system/create/index.vue
  17. 1135
      ruoyi-ui/src/views/system/fileManage/index1.vue
  18. 2
      ruoyi-ui/src/views/system/question/index.vue
  19. 12
      ruoyi-ui/src/views/system/relationship/index.vue
  20. 2
      ruoyi-ui/src/views/system/smart/question.vue
  21. 44
      ruoyi-ui/src/views/system/smart/trainImg.vue
  22. 3
      ruoyi-ui/src/views/system/task/index.vue

BIN
gyxtp/src/assets/img2/cloud.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 858 B

1
gyxtp/src/view/Home.vue

@ -84,7 +84,6 @@ export default {
dialogVisible: false, dialogVisible: false,
disabled: true, disabled: true,
type: 'word', type: 'word',
updateUrl: "http://localhost:10031/common/upload",
fileList: [], fileList: [],
lsList: [], lsList: [],
rmList:[], rmList:[],

2
gyxtp/src/view/Home1.vue

@ -1037,7 +1037,7 @@ export default {
this.haveImg = false; this.haveImg = false;
}else { }else {
this.haveImg = true; this.haveImg = true;
this.src = "http://localhost:10031" + this.contentInfo.docVideo; // this.src = "http://localhost:10031" + this.contentInfo.docVideo;
var imgs = this.contentInfo.docImgs; var imgs = this.contentInfo.docImgs;
this.imgsList = imgs.split(","); this.imgsList = imgs.split(",");

8
gyxtp/src/view/articleInfo.vue

@ -553,14 +553,6 @@ export default {
} else { } else {
this.haveImg = true; this.haveImg = true;
//
if (this.contentInfo.docVideo) {
const videoPrefix = "http://localhost:10031";
this.videoUrls = this.contentInfo.docVideo.split(',').map(video => videoPrefix + video.trim());
} else {
this.videoUrls = [];
}
// //
if (this.contentInfo.docImgs) { if (this.contentInfo.docImgs) {
this.imgsList = this.contentInfo.docImgs.split(","); this.imgsList = this.contentInfo.docImgs.split(",");

30
gyxtp/src/view/create.vue

@ -418,7 +418,6 @@ export default {
dialogImageUrl: "", dialogImageUrl: "",
disabled: true, disabled: true,
type: 'word', type: 'word',
updateUrl: "http://localhost:10031/common/upload",
fileList: [], fileList: [],
lsList: [], lsList: [],
rmList:[], rmList:[],
@ -804,21 +803,20 @@ export default {
this.getAll(); this.getAll();
this.getTitleByGroup() this.getTitleByGroup()
// // WebSocket
// WebSocket // this.socket = new WebSocket('ws://localhost:10031/api/ws?userId=123'); //
this.socket = new WebSocket('ws://localhost:10031/api/ws?userId=123'); // //
// //
// // this.socket.addEventListener('open', (event) => {
this.socket.addEventListener('open', (event) => { // console.log('WebSocket ');
console.log('WebSocket 连接已建立'); // this.messages.push('');
this.messages.push('已连接到服务端'); // });
}); //
// //
// // this.socket.addEventListener('message', (event) => {
this.socket.addEventListener('message', (event) => { // console.log(':', event.data);
console.log('收到消息:', event.data); // this.messages.push(event.data);
this.messages.push(event.data); // });
});
} }
}; };

29
gyxtp/src/view/docInfo.vue

@ -65,7 +65,7 @@
<!-- </div>--> <!-- </div>-->
<div class="oneTitle" @click="chooseInfo=2" style="cursor: pointer"> <div class="oneTitle" @click="chooseInfo=2" style="cursor: pointer">
<div class="huiBlock"></div> <div class="huiBlock"></div>
<div class="huiTitle">图片视频</div> <div class="huiTitle">知识图片</div>
</div> </div>
@ -85,7 +85,7 @@
<!-- </div>--> <!-- </div>-->
<div class="oneTitle" style="background-color: #e4e4e4;cursor: pointer"> <div class="oneTitle" style="background-color: #e4e4e4;cursor: pointer">
<div class="chengBlock"></div> <div class="chengBlock"></div>
<div class="chengTitle">图片视频</div> <div class="chengTitle">知识图片</div>
</div> </div>
@ -106,7 +106,7 @@
<!-- </div>--> <!-- </div>-->
<div class="oneTitle" @click="chooseInfo=2" style="cursor: pointer"> <div class="oneTitle" @click="chooseInfo=2" style="cursor: pointer">
<div class="huiBlock"></div> <div class="huiBlock"></div>
<div class="huiTitle">图片视频</div> <div class="huiTitle">知识图片</div>
</div> </div>
@ -127,7 +127,7 @@
<!-- </div>--> <!-- </div>-->
<div class="oneTitle" @click="chooseInfo=2" style="cursor: pointer"> <div class="oneTitle" @click="chooseInfo=2" style="cursor: pointer">
<div class="huiBlock"></div> <div class="huiBlock"></div>
<div class="huiTitle">图片视频</div> <div class="huiTitle">知识图片</div>
</div> </div>
@ -395,7 +395,8 @@ const graphOptions = {
force_line_elastic: 0.1 // 线1, :0.1 -- 10 force_line_elastic: 0.1 // 线1, :0.1 -- 10
// force_node_repulsion: 1, // 1:0.1 -- 10 // force_node_repulsion: 1, // 1:0.1 -- 10
// force_line_elastic: 1 // 线1, :0.1 -- 10 // force_line_elastic: 1 // 线1, :0.1 -- 10
} },
backgroundColor: "#2d3562"
}; };
export default { export default {
name: 'docInfo', name: 'docInfo',
@ -796,23 +797,22 @@ export default {
} else { } else {
this.haveImg = true; this.haveImg = true;
//
if (this.contentInfo.docVideo) {
const videoPrefix = "http://localhost:10031";
this.videoUrls = this.contentInfo.docVideo.split(',').map(video => videoPrefix + video.trim());
} else {
this.videoUrls = [];
}
// //
if (this.contentInfo.docImgs) { if (this.contentInfo.docImgs) {
var lidt = this.contentInfo.docImgs.split(","); var lidt = this.contentInfo.docImgs.split(",");
for(let a=0;a<lidt.length;a++){ for(let a=0;a<lidt.length;a++){
if(lidt[a].includes("http")){
var kkk=lidt[a];
this.imgsList.push(kkk)
}else{
var kkk = "http://127.0.0.1:10031"+lidt[a]; var kkk = "http://127.0.0.1:10031"+lidt[a];
// var kkk=lidt[a];
this.imgsList.push(kkk) this.imgsList.push(kkk)
} }
}
} }
} }
@ -2063,5 +2063,8 @@ margin-top: 0.2vw;
.el-tree-node__expand-icon { .el-tree-node__expand-icon {
font-size: 1.2vw !important; font-size: 1.2vw !important;
} }
.rel-graph-loading{
background-color: transparent!important;
}
</style> </style>

6
gyxtp/src/view/graphPageCopy0926.vue

@ -361,7 +361,8 @@ export default {
layoutName: 'center', // 使 center layoutName: 'center', // 使 center
levelDistance: '1000,1000,1000,1000,3000,3000,3000,3000', // levelDistance: '1000,1000,1000,1000,3000,3000,3000,3000', //
startAngle: -Math.PI / 2, // -90° startAngle: -Math.PI / 2, // -90°
} },
backgroundColor: "#2d3562"
}, },
currentNode: {}, // currentNode: {}, //
attrbutes: [],//线 attrbutes: [],//线
@ -1693,4 +1694,7 @@ tr {
background-color: rgba(64, 158, 255,0.2); background-color: rgba(64, 158, 255,0.2);
color:#409eff color:#409eff
} }
.rel-graph-loading{
background-color: transparent!important;
}
</style> </style>

6
gyxtp/src/view/graphPageNB927.vue

@ -376,7 +376,8 @@ export default {
layoutName: 'center', // 使 center layoutName: 'center', // 使 center
levelDistance: '1000,1000,1000,1000,3000,3000,3000,3000', // levelDistance: '1000,1000,1000,1000,3000,3000,3000,3000', //
startAngle: -Math.PI / 2, // -90° startAngle: -Math.PI / 2, // -90°
} },
backgroundColor: "#2d3562"
}, },
currentNode: {}, // currentNode: {}, //
attrbutes: [],//线 attrbutes: [],//线
@ -1580,4 +1581,7 @@ tr {
background-color: rgba(64, 158, 255,0.2); background-color: rgba(64, 158, 255,0.2);
color:#409eff color:#409eff
} }
.rel-graph-loading{
background-color: transparent!important;
}
</style> </style>

8
gyxtp/src/view/pointArticleInfo.vue

@ -550,14 +550,6 @@ export default {
} else { } else {
this.haveImg = true; this.haveImg = true;
//
if (this.contentInfo.docVideo) {
const videoPrefix = "http://localhost:10031";
this.videoUrls = this.contentInfo.docVideo.split(',').map(video => videoPrefix + video.trim());
} else {
this.videoUrls = [];
}
// //
if (this.contentInfo.docImgs) { if (this.contentInfo.docImgs) {
this.imgsList = this.contentInfo.docImgs.split(","); this.imgsList = this.contentInfo.docImgs.split(",");

60
gyxtp/src/view/small.vue

File diff suppressed because one or more lines are too long

4
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/ZhyDocmubanController.java

@ -35,6 +35,8 @@ import com.ruoyi.system.service.IZhyDocmubanService;
import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.common.core.page.TableDataInfo;
import static com.ruoyi.common.constant.Constants.FILE_MANAGER_DIR;
/** /**
* 图谱模板Controller * 图谱模板Controller
@ -2204,7 +2206,7 @@ public class ZhyDocmubanController extends BaseController
String formattedDate = dateFormat.format(new Date()); String formattedDate = dateFormat.format(new Date());
// 定义基础目录 // 定义基础目录
File baseDir = new File("D:\\project\\gyx\\tupudata\\fileManager"); File baseDir = new File(FILE_MANAGER_DIR);
// 如果基础目录不存在,则创建它(包括所有必需的父目录) // 如果基础目录不存在,则创建它(包括所有必需的父目录)
if (!baseDir.exists() && !baseDir.mkdirs()) { if (!baseDir.exists() && !baseDir.mkdirs()) {
throw new IOException("Failed to create base directory: " + baseDir.getAbsolutePath()); throw new IOException("Failed to create base directory: " + baseDir.getAbsolutePath());

4
ruoyi-common/src/main/java/com/ruoyi/common/constant/Constants.java

@ -181,8 +181,8 @@ public static final String indexPathBattle = "D:\\project\\gyx\\tupudata\\battl
// //
// public static final String indexPathBattle = "C:\\tupudata\\battleManager\\index"; // public static final String indexPathBattle = "C:\\tupudata\\battleManager\\index";
public static final String outPath = "D:\\project\\gyx\\tupudata\\fileOut\\"; public static final String outPath = "D:\\tupudata\\fileOut\\";
public static String TUPUDATA_ROOT = "D:/project/gyx/tupudata"; public static String TUPUDATA_ROOT = "D:/tupudata";
/** /**
* 文章 PDF 存储目录 * 文章 PDF 存储目录

2
ruoyi-ui/.env.development

@ -9,3 +9,5 @@ VUE_APP_BASE_API = '/dev-api'
# 路由懒加载 # 路由懒加载
VUE_CLI_BABEL_TRANSPILE_MODULES = true VUE_CLI_BABEL_TRANSPILE_MODULES = true
VUE_APP_PORT=10031

2
ruoyi-ui/.env.production

@ -6,3 +6,5 @@ ENV = 'production'
# 知识图谱管理系统/生产环境 # 知识图谱管理系统/生产环境
VUE_APP_BASE_API = '/prod-api' VUE_APP_BASE_API = '/prod-api'
VUE_APP_PORT=10031

20
ruoyi-ui/src/views/system/battle/index.vue

@ -236,10 +236,10 @@ export default {
// //
headers: {Authorization: "Bearer " + getToken()}, headers: {Authorization: "Bearer " + getToken()},
// //
url: "http://localhost:10031/system/fileManage/uploadVideo", // url: "http://localhost:10031/system/fileManage/uploadVideo",
url2: "http://localhost:10031", // url2: "http://localhost:10031",
}, },
uploadImgUrl:"http://localhost:10031/common/upload1", // uploadImgUrl:"http://localhost:10031/common/upload1",
form: {}, form: {},
showVideoPath: "", showVideoPath: "",
uploadUrl: "",// uploadUrl: "",//
@ -267,7 +267,7 @@ export default {
isUploading: false, isUploading: false,
updateSupport: 0, updateSupport: 0,
headers: {Authorization: "Bearer " + getToken()}, headers: {Authorization: "Bearer " + getToken()},
url: "http://localhost:10031/system/battle/addFile" // url: "http://localhost:10031/system/battle/addFile"
// url: "http://127.0.0.1:10031/system/battle/addFile" // url: "http://127.0.0.1:10031/system/battle/addFile"
}, },
@ -279,7 +279,7 @@ export default {
isUploading: false, isUploading: false,
updateSupport: 0, updateSupport: 0,
headers: {Authorization: "Bearer " + getToken()}, headers: {Authorization: "Bearer " + getToken()},
url: "http://localhost:10031/system/battle/addBattleFileNew" // url: "http://localhost:10031/system/battle/addBattleFileNew"
}, },
} }
}, },
@ -489,11 +489,11 @@ export default {
mounted() { mounted() {
this.getFileList() this.getFileList()
var socket = new WebSocket('ws://localhost:10031/system/websocket/1'); // var socket = new WebSocket('ws://localhost:10031/system/websocket/1');
let that = this // let that = this
socket.onmessage = function (event) { // socket.onmessage = function (event) {
that.upload.tip = event.data // that.upload.tip = event.data
} // }
}, },
} }
</script> </script>

5
ruoyi-ui/src/views/system/create/index.vue

@ -262,7 +262,6 @@ export default {
dialogVisible: false, dialogVisible: false,
disabled: true, disabled: true,
type: 'word', type: 'word',
updateUrl: "http://localhost:10031/common/upload",
fileList: [], fileList: [],
lsList: [], lsList: [],
rmList:[], rmList:[],
@ -731,7 +730,9 @@ export default {
// WebSocket // WebSocket
getUserProfile().then(response => { getUserProfile().then(response => {
this.userId=response.data.userId this.userId=response.data.userId
this.socket = new WebSocket('ws://localhost:10031/api/ws?userId='+response.data.userId); // let port=process.env.VUE_APP_PORT
console.log(port)
this.socket = new WebSocket('ws://localhost:'+port+'/api/ws?userId='+response.data.userId); //
// //
this.socket.addEventListener('open', (event) => { this.socket.addEventListener('open', (event) => {
console.log('WebSocket 连接已建立'); console.log('WebSocket 连接已建立');

1135
ruoyi-ui/src/views/system/fileManage/index1.vue

File diff suppressed because it is too large

2
ruoyi-ui/src/views/system/question/index.vue

@ -213,7 +213,7 @@ export default {
// //
headers: { Authorization: "Bearer " + getToken() }, headers: { Authorization: "Bearer " + getToken() },
// //
url: "http://localhost:10031/system/excel/question/importData" // url: "http://localhost:10031/system/excel/question/importData"
}, },
// //
form: {}, form: {},

12
ruoyi-ui/src/views/system/relationship/index.vue

@ -148,7 +148,7 @@
@pagination="getList" @pagination="getList"
/> />
<!-- 添加或修改文章关系对话框 --> <!-- 添加或修改关系对话框 -->
<el-dialog :title="title" :visible.sync="open" width="800px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px"> <el-form ref="form" :model="form" :rules="rules" label-width="100px">
<!-- <el-form-item label="关系名称" prop="relationship">--> <!-- <el-form-item label="关系名称" prop="relationship">-->
@ -257,7 +257,7 @@ export default {
showSearch: true, showSearch: true,
// //
total: 0, total: 0,
// //
relationshipList: [], relationshipList: [],
// //
title: "", title: "",
@ -461,7 +461,7 @@ export default {
] ]
}) })
}, },
/** 查询文章关系列表 */ /** 查询关系列表 */
getList() { getList() {
this.loading = true; this.loading = true;
listRelationship(this.queryParams).then(response => { listRelationship(this.queryParams).then(response => {
@ -514,7 +514,7 @@ export default {
this.reset(); this.reset();
this.resultFileList=[] this.resultFileList=[]
this.open = true; this.open = true;
this.title = "添加文章关系"; this.title = "添加关系";
}, },
/** 修改按钮操作 */ /** 修改按钮操作 */
handleUpdate(row) { handleUpdate(row) {
@ -523,7 +523,7 @@ export default {
getRelationship(id).then(response => { getRelationship(id).then(response => {
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改文章关系"; this.title = "修改关系";
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
@ -554,7 +554,7 @@ export default {
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const ids = row.id || this.ids; const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除文章关系编号为"' + ids + '"的数据项?').then(function() { this.$modal.confirm('是否确认删除关系编号为"' + ids + '"的数据项?').then(function() {
return delRelationship(ids); return delRelationship(ids);
}).then(() => { }).then(() => {
this.getList(); this.getList();

2
ruoyi-ui/src/views/system/smart/question.vue

@ -309,7 +309,7 @@ export default {
}, },
data() { data() {
return { return {
uploadUrl: 'http://localhost:10031/common/upload',
imageUrl: [], // URL imageUrl: [], // URL
answers: [], answers: [],
filteredQuestions: [], filteredQuestions: [],

44
ruoyi-ui/src/views/system/smart/trainImg.vue

@ -149,27 +149,27 @@
</el-form-item> </el-form-item>
<el-form-item v-if="fileType==1" label="上传文件" prop="courseUrl"> <!-- <el-form-item v-if="fileType==1" label="上传文件" prop="courseUrl">-->
<el-upload <!-- <el-upload-->
v-model="diaForm.list" <!-- v-model="diaForm.list"-->
:limit="5" <!-- :limit="5"-->
:on-exceed="handleExceed" <!-- :on-exceed="handleExceed"-->
:on-preview="handlePreview" <!-- :on-preview="handlePreview"-->
:before-upload="beforeAvatarUpload" <!-- :before-upload="beforeAvatarUpload"-->
:on-remove="handleRemoveFile" <!-- :on-remove="handleRemoveFile"-->
:headers="reqHeaders" <!-- :headers="reqHeaders"-->
:on-success="onUploadSuccess" <!-- :on-success="onUploadSuccess"-->
action="http://localhost:10031/common/uploadNew1" <!-- action="http://localhost:10031/common/uploadNew1"-->
:file-list="resultFileList" <!-- :file-list="resultFileList"-->
list-type="picture" <!-- list-type="picture"-->
class="upload-files" <!-- class="upload-files"-->
accept=".png,.jpeg,.gif,.pdf,.jpg,.JPG"> <!-- accept=".png,.jpeg,.gif,.pdf,.jpg,.JPG">-->
<div class="upfile-btn"> <!-- <div class="upfile-btn">-->
<d2-icon name="document-upload" class="document-upload" /> <!-- <d2-icon name="document-upload" class="document-upload" />-->
<div>点击上传+拖拽上传</div> <!-- <div>点击上传+拖拽上传</div>-->
</div> <!-- </div>-->
</el-upload> <!-- </el-upload>-->
</el-form-item> <!-- </el-form-item>-->
<el-form-item v-if="fileType==1 && finalImg!=''" label="图片" prop="courseUrl"> <el-form-item v-if="fileType==1 && finalImg!=''" label="图片" prop="courseUrl">
<img :src="finalImg" style="height: 20px;object-fit: contain;"> <img :src="finalImg" style="height: 20px;object-fit: contain;">
</el-form-item> </el-form-item>
@ -265,7 +265,7 @@ export default {
nowId:undefined, nowId:undefined,
openQuestion:false, openQuestion:false,
// uploadUrl: 'http://127.0.0.1:10031/common/upload', // uploadUrl: 'http://127.0.0.1:10031/common/upload',
uploadUrl: 'http://localhost:10031/common/upload', // uploadUrl: 'http://localhost:10031/common/upload',
fileList:[], fileList:[],
dialogImageUrl: '', dialogImageUrl: '',

3
ruoyi-ui/src/views/system/task/index.vue

@ -205,7 +205,8 @@ export default {
mounted() { mounted() {
getUserProfile().then(response => { getUserProfile().then(response => {
this.userId=response.data.userId this.userId=response.data.userId
this.socket = new WebSocket('ws://localhost:10031/api/ws?userId='+response.data.userId); // let port=process.env.VUE_APP_PORT
this.socket = new WebSocket('ws://localhost:'+port+'/api/ws?userId='+response.data.userId); //
// //
this.socket.addEventListener('open', (event) => { this.socket.addEventListener('open', (event) => {
console.log('WebSocket 连接已建立'); console.log('WebSocket 连接已建立');

Loading…
Cancel
Save