ออกคำสั่ง
This commit is contained in:
parent
73c41d9b01
commit
671c7103ab
7 changed files with 86 additions and 61 deletions
|
|
@ -9,10 +9,15 @@ const $q = useQuasar();
|
|||
const mixin = useCounterMixin();
|
||||
const { showLoader, hideLoader, messageError } = mixin;
|
||||
|
||||
async function genReport(data: any, fileName: string, type: string = "docx") {
|
||||
async function genReport(
|
||||
data: any,
|
||||
fileName: string,
|
||||
type: string = "docx",
|
||||
folder: string = ""
|
||||
) {
|
||||
showLoader();
|
||||
await axios
|
||||
.post(`${config.API.reportTemplate}/docx`, data, {
|
||||
.post(`${config.API.reportTemplate}/docx${folder}`, data, {
|
||||
headers:
|
||||
type == "docx"
|
||||
? {
|
||||
|
|
|
|||
|
|
@ -12,11 +12,12 @@ const { showLoader, hideLoader, messageError } = mixin;
|
|||
async function genReportXLSX(
|
||||
data: any,
|
||||
fileName: string,
|
||||
type: string = "xlsx"
|
||||
type: string = "xlsx",
|
||||
folder: string = ""
|
||||
) {
|
||||
showLoader();
|
||||
await axios
|
||||
.post(`${config.API.reportTemplate}/xlsx`, data, {
|
||||
.post(`${config.API.reportTemplate}/xlsx${folder}`, data, {
|
||||
headers:
|
||||
type == "xlsx"
|
||||
? {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue