完成修改

This commit is contained in:
RenCheng 2025-03-04 18:50:42 +08:00
parent a36470bd91
commit 3dcbc025f2
5 changed files with 19 additions and 10 deletions

View File

@ -83,6 +83,12 @@
console.log(data); console.log(data);
// //
if(data.content.length >0){ if(data.content.length >0){
var char = "当前同步百分比:";
let index = content.indexOf(char);
if (index >= 0) {
let result = content.substring(index + char.length,content.length - 1); // "V"
this.percent = result;
}
this.contentList.unshift(data.content); this.contentList.unshift(data.content);
} }
}, },

View File

@ -286,7 +286,7 @@ export default {
currentRow.uploadStatus = 2 currentRow.uploadStatus = 2
currentRow.result = res currentRow.result = res
} else { // } else { //
const formData = this.buildFileFormData(file.name, file.size, fileMD5Value, 1, 1, file, false,fileMD5Value) const formData = this.buildFileFormData(file.name, file.size, fileMD5Value, 0, 0, file, false,fileMD5Value)
const url = '/fileDataLink/uploadFile' const url = '/fileDataLink/uploadFile'
try { try {
const res = await postAction(url, formData) const res = await postAction(url, formData)

View File

@ -248,9 +248,10 @@ export default {
this.$message.warning("必须选择文件上传目录"); this.$message.warning("必须选择文件上传目录");
return; return;
} }
this.$refs.modalForm.add(); console.log("dirid=" + this.searchFile.dirId)
this.$refs.modalForm.title = "文件上传"; this.$refs.modalForm.title = "文件上传";
this.$refs.modalForm.dirId = this.searchFile.dirId; this.$refs.modalForm.dirId = this.searchFile.dirId;
this.$refs.modalForm.add();
}, },
getcountFileNum(){ getcountFileNum(){
var that = this; var that = this;

View File

@ -89,10 +89,7 @@ export default {
type: Boolean, type: Boolean,
default: false default: false
}, },
dirId: { //
type: String,
default: ''
}
}, },
data () { data () {
return { return {
@ -106,6 +103,7 @@ export default {
pageNum :1, pageNum :1,
pageSize:999999999 pageSize:999999999
}, },
dirId:""
} }
}, },
created () { created () {
@ -206,7 +204,8 @@ export default {
*/ */
customRequestUpload ({ file }) { customRequestUpload ({ file }) {
// //
if(this.dirId == "" || this.dirId ==null && this.dirId == undefined){ console.log("upthis.dirId="+this.dirId)
if(this.dirId.length <= 0){
this.$message.error('文件目录选择异常请刷新页面') this.$message.error('文件目录选择异常请刷新页面')
return; return;
} }
@ -301,7 +300,7 @@ export default {
currentRow.uploadStatus = 2 currentRow.uploadStatus = 2
currentRow.result = res currentRow.result = res
} else { // } else { //
const formData = this.buildFileFormData(file.name, file.size, fileMD5Value, 1, 1, file, false,fileMD5Value) const formData = this.buildFileFormData(file.name, file.size, fileMD5Value, 0, 0, file, false,fileMD5Value)
const url = '/file/uoloadFile' const url = '/file/uoloadFile'
try { try {
const res = await postAction(url, formData) const res = await postAction(url, formData)

View File

@ -17,7 +17,6 @@
:max-file="999999" :max-file="999999"
:can-download="false" :can-download="false"
accept=".docx,.doc,.png,jpg,.pdf,.mp4" accept=".docx,.doc,.png,jpg,.pdf,.mp4"
:dirId="dirId"
/> />
</a-spin> </a-spin>
</a-modal> </a-modal>
@ -53,7 +52,11 @@ import SliceUpload from './SliceUpload'
methods: { methods: {
add () { add () {
this.visible =true; this.visible =true;
setTimeout(()=>{
this.$refs.technicalUpload.dirId = this.dirId;
this.$refs.technicalUpload.deleteFile(); this.$refs.technicalUpload.deleteFile();
},300)
}, },
onOk(value) { onOk(value) {
this.model.startDate = moment(value[0],dateFormat); this.model.startDate = moment(value[0],dateFormat);