投标成本核算

This commit is contained in:
ljx
2025-08-23 06:28:18 +08:00
parent f3f8ab0b87
commit 73772f036f
8 changed files with 773 additions and 32 deletions

View File

@ -45,6 +45,8 @@
<script setup lang="ts">
import { useUserStoreHook } from '@/store/modules/user';
import { listOutTable } from '@/api/out/outTable';
const userStore = useUserStoreHook();
const currentProject = computed(() => userStore.selectedProject);
const activeTab = ref('1');
@ -71,7 +73,7 @@ const tabList = [
//切换表单
const handleTabChange = (tab) => {
activeTab.value = tab;
queryParams.value.month = '';
// queryParams.value.month = '';
handleQuery();
};
@ -91,10 +93,26 @@ const getList = async () => {
const params = {
...queryParams.value,
projectId: currentProject.value?.id,
activeTab: activeTab.value
type: activeTab.value
};
console.log(params);
const res = await listOutTable(params);
if (res.code == 200) {
tableData.value = res.rows;
total.value = res.total;
}
};
onMounted(() => {
const currentDate = new Date();
const year = currentDate.getFullYear();
const month = currentDate.getMonth() + 1; // 月份从0开始所以需要加1
// 形成"YYYY-M"格式
const formattedDate = `${year}-${String(month).padStart(2, '0')}`;
queryParams.value.month = formattedDate;
getList();
});
</script>
<style scoped lang="scss"></style>