From 64e523ebc4d5381bbc5638a6c4826bc2df9fd4c1 Mon Sep 17 00:00:00 2001 From: Kasi Date: Wed, 4 Jun 2025 13:50:44 +0900 Subject: [PATCH] =?UTF-8?q?func=20:=20=EA=B2=B0=EC=9E=AC=ED=95=A8=20?= =?UTF-8?q?=EA=B2=80=EC=83=89=EA=B8=B0=EB=8A=A5=20=EC=B6=94=EA=B0=80=20fix?= =?UTF-8?q?=20:=20=EB=B3=80=EC=88=98=EC=98=A4=EA=B8=B0=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/app/ApprovalManagement.vue | 28 ++++++++++++++++++---------- src/pages/app/priceManagement.vue | 2 +- 2 files changed, 19 insertions(+), 11 deletions(-) diff --git a/src/pages/app/ApprovalManagement.vue b/src/pages/app/ApprovalManagement.vue index 430cc8e..d1f081a 100644 --- a/src/pages/app/ApprovalManagement.vue +++ b/src/pages/app/ApprovalManagement.vue @@ -10,8 +10,11 @@ import {getContractList} from "/@src/service/contractApi.ts"; onBeforeMount(async () => { - await getIntegratedPaymentList() + await getIntegratedApprovalList() + const userSession = useUserSession() + params.sessionUser = userSession.user.data }) + const isModalOpen = ref(false) const selectedRow = ref(null) const prcsNo = ref('') @@ -63,6 +66,7 @@ const notyf = useNotyf() const params = reactive({ title: '', + sessionUser: '', priceData: [], regSdt:'', regEdt:'', @@ -95,7 +99,7 @@ function formatRegDt(value) { return value ? value.substring(0, 16) : '' } -async function getIntegratedPaymentList() { +async function getIntegratedApprovalList() { const today = new Date() searchParamsList.regSdt = new Date().setDate(today.getDate() - 30) @@ -107,7 +111,7 @@ async function getIntegratedPaymentList() { row: itemsPerPage, sabun: '17131303', // 김진형 17131303, 손원창 17131304 } - + const result = await getIntegratedApproval(approvalParams) params.approvalParams = result.content.map(item => ({ ...item, @@ -153,7 +157,7 @@ const searchApproval = async (item) => { let itemPerChangePage; if(item == totalPages.value){ - const remain = totalPages.value % itemsPerPage + const remain = totalItems.value % itemsPerPage itemPerChangePage = remain === 0? itemsPerPage : remain }else{ itemPerChangePage = itemsPerPage @@ -162,14 +166,15 @@ const searchApproval = async (item) => { const searchParams = { title: params.title, // apprStat: searchParamsList.apprStat, - // regSdt: formatDatefromString(params.regSdt),//등록시작일 - // regEdt: formatDatefromString(params.regEdt),//등록종료일 + regSdt: formatDatefromString(searchParamsList.regSdt),//등록시작일 + regEdt: formatDatefromString(searchParamsList.regEdt),//등록종료일 page: item,//페이지 row: itemPerChangePage, //아이템갯수 sabun: '17131303', // 김진형 17131303, 손원창 17131304 } - console.log('searchParams', searchParams) + console.log('itemPerChangePage', itemPerChangePage) + console.log('itemsPerPage', itemsPerPage) const result = await getIntegratedApproval(searchParams) params.approvalParams = result.content.map(item => ({ @@ -179,6 +184,8 @@ const searchApproval = async (item) => { totalItems.value = result.totalElements totalPages.value = result.totalPages console.log(params.approvalParams) + console.log('itemPerChangePage', itemPerChangePage) + console.log('itemsPerPage', itemsPerPage) } type User = (typeof users)[0] @@ -230,6 +237,7 @@ watch(currentPage, (newParams) => { v-model="params.title" class="input custom-text-filter" placeholder="결재제목" + @keydown.enter="searchApproval(1)" > @@ -243,7 +251,7 @@ watch(currentPage, (newParams) => {
{
{ color="primary" elevated icon="fas fa-search" - @click.stop="searchApproval" + @click.stop="searchApproval(1)" > 검색 diff --git a/src/pages/app/priceManagement.vue b/src/pages/app/priceManagement.vue index 5d9314d..6ef3922 100644 --- a/src/pages/app/priceManagement.vue +++ b/src/pages/app/priceManagement.vue @@ -62,7 +62,7 @@ const searchPrice = async (item) => { let itemPerChangePage; if(item == totalPages.value){ - const remain = totalPages.value % itemsPerPage + const remain = totalItems.value % itemsPerPage itemPerChangePage = remain === 0? itemsPerPage : remain }else{ itemPerChangePage = itemsPerPage