mirror of
https://github.com/PanJiaChen/vue-element-admin.git
synced 2025-08-10 20:39:48 +08:00
fix: Report change print format. (#695)
Co-authored-by: EdwinBetanc0urt <EdwinBetanco0urt@outlook.com>
This commit is contained in:
parent
97830cdb47
commit
0d30213637
@ -37,7 +37,8 @@ const process = {
|
|||||||
let printFormatsAvailable = []
|
let printFormatsAvailable = []
|
||||||
if (responseProcess.isReport) {
|
if (responseProcess.isReport) {
|
||||||
printFormatsAvailable = await dispatch('getListPrintFormats', {
|
printFormatsAvailable = await dispatch('getListPrintFormats', {
|
||||||
processUuid: containerUuid
|
processUuid: containerUuid,
|
||||||
|
processId: responseProcess.id
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -40,6 +40,7 @@ const reportControl = {
|
|||||||
}) {
|
}) {
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
getListPrintFormats({ commit }, {
|
getListPrintFormats({ commit }, {
|
||||||
processId,
|
processId,
|
||||||
processUuid,
|
processUuid,
|
||||||
@ -70,6 +71,7 @@ const reportControl = {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
getReportViewsFromServer({ commit }, {
|
getReportViewsFromServer({ commit }, {
|
||||||
processId,
|
processId,
|
||||||
processUuid,
|
processUuid,
|
||||||
@ -103,6 +105,7 @@ const reportControl = {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
getDrillTablesFromServer({ commit }, {
|
getDrillTablesFromServer({ commit }, {
|
||||||
processId,
|
processId,
|
||||||
processUuid,
|
processUuid,
|
||||||
@ -140,7 +143,8 @@ const reportControl = {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getReportOutputFromServer({ commit, getters, rootGetters }, {
|
|
||||||
|
getReportOutputFromServer({ state, commit, getters, rootGetters }, {
|
||||||
tableName,
|
tableName,
|
||||||
printFormatUuid,
|
printFormatUuid,
|
||||||
reportViewUuid,
|
reportViewUuid,
|
||||||
@ -154,8 +158,12 @@ const reportControl = {
|
|||||||
}) {
|
}) {
|
||||||
return new Promise(resolve => {
|
return new Promise(resolve => {
|
||||||
if (isEmptyValue(printFormatUuid)) {
|
if (isEmptyValue(printFormatUuid)) {
|
||||||
printFormatUuid = getters.getDefaultPrintFormat(processUuid).printFormatUuid
|
const printFormat = getters.getDefaultPrintFormat(processUuid)
|
||||||
|
if (!isEmptyValue(printFormat)) {
|
||||||
|
printFormatUuid = printFormat.printFormatUuid
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const parametersList = rootGetters.getParametersToServer({
|
const parametersList = rootGetters.getParametersToServer({
|
||||||
containerUuid: processUuid
|
containerUuid: processUuid
|
||||||
})
|
})
|
||||||
|
@ -10,16 +10,15 @@ export function convertListPrintFormats(listPrintFormatsToConvert) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function convertPrintFormat(printFormatToConvert) {
|
export function convertPrintFormat(printFormatToConvert) {
|
||||||
const { id, uuid, name, description } = printFormatToConvert
|
const { name, description } = printFormatToConvert
|
||||||
|
|
||||||
return {
|
return {
|
||||||
id,
|
|
||||||
uuid,
|
|
||||||
name,
|
name,
|
||||||
description,
|
description,
|
||||||
tableName: printFormatToConvert.table_name,
|
tableName: printFormatToConvert.table_name,
|
||||||
isDefault: printFormatToConvert.is_default,
|
isDefault: printFormatToConvert.is_default,
|
||||||
reportViewUuid: printFormatToConvert.report_view_uuid
|
reportViewUuid: printFormatToConvert.report_view_uuid,
|
||||||
|
printFormatUuid: printFormatToConvert.print_format_uuid
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user