Skip to content

Commit

Permalink
[BUGFIXED]-Updated CSV save location
Browse files Browse the repository at this point in the history
  • Loading branch information
ndasanayaka committed Jan 11, 2024
1 parent fb6a887 commit eb8d3f2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
5 changes: 3 additions & 2 deletions src/api/ConfigurationAPI.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@ import request from '@/utils/request'
import Vue from 'vue'

export default {
async execute_metedata_script(fileslist, confid, validate, savecsv) {
async execute_metedata_script(fileslist, confid, validate, savecsv, savefolder) {
let _requestUrl =`${Vue.prototype.$Config.endpoints.wiener}/api/execute/imageMetadataBase64`
const { data } = await request.get(_requestUrl, {
params: {
fileslist : fileslist,
confid : confid,
validate : validate,
savecsv: savecsv
savecsv: savecsv,
savefolder: savefolder
}
})
return data
Expand Down
3 changes: 2 additions & 1 deletion src/views/Configuration.vue
Original file line number Diff line number Diff line change
Expand Up @@ -165,9 +165,10 @@
let validate =true
let confid = this.selectedtag
let files =""
let saveFolder =""
console.log(confid)
try{
const response= await ConfigurationAPI.execute_metedata_script(files, confid, validate, false)
const response= await ConfigurationAPI.execute_metedata_script(files, confid, validate, false, saveFolder)
console.log(response)
Vue.notify({
group: 'datanotif',
Expand Down
8 changes: 4 additions & 4 deletions src/views/Deconvolution.vue
Original file line number Diff line number Diff line change
Expand Up @@ -703,12 +703,11 @@
//let json_data = JSON.stringify(metadataResult)
let file_name = metadataResult.file.split("/").slice(-1)[0].split(".")[0]
console.log(file_name)
console.log(metadataResult.file)
let saveFolder = this.workingItem.setting.outputPath
try{
this.csvloading = true
const response= await ConfigurationAPI.execute_metedata_script(btoa(metadataResult.file), this.selectedtag, false, true)
const response= await ConfigurationAPI.execute_metedata_script(btoa(metadataResult.file), this.selectedtag, false, true, btoa(saveFolder))
this.csvloading = false
this.csvlocation = this.workingItem.setting.outputPath+"/"+file_name+"_metadata.csv"
console.log(this.workingItem.setting.outputPath+"/"+file_name+".csv")
Expand Down Expand Up @@ -1075,6 +1074,7 @@
async getMetadata(fileslist, folder) {
let fileslistbase64 = ''
let saveFolder=''
if (!folder) {
fileslistbase64 = btoa(fileslist)
Expand All @@ -1089,7 +1089,7 @@
try{
console.log(this.selectedtag)
const response= await ConfigurationAPI.execute_metedata_script(fileslistbase64, this.selectedtag, false, false)
const response= await ConfigurationAPI.execute_metedata_script(fileslistbase64, this.selectedtag, false, false, saveFolder)
console.log(response)
let output = response.commandResult
if (output.length > 0) {
Expand Down

0 comments on commit eb8d3f2

Please sign in to comment.