1
This commit is contained in:
@ -7,13 +7,13 @@ VITE_APP_ENV = 'development'
|
||||
# 开发环境
|
||||
# VITE_APP_BASE_API = 'http://192.168.110.180:8899'
|
||||
# 李陈杰 209
|
||||
# VITE_APP_BASE_API = 'http://192.168.110.209:8899'
|
||||
VITE_APP_BASE_API = 'http://192.168.110.180:8899'
|
||||
# 李陈杰 209
|
||||
# VITE_APP_BASE_API = 'http://192.168.110.209:8899'
|
||||
# 曾涛
|
||||
VITE_APP_BASE_API = 'http://192.168.110.149:8899'
|
||||
# VITE_APP_BASE_API = 'http://192.168.110.149:8899'
|
||||
# 罗成
|
||||
# VITE_APP_BASE_API = 'http://192.168.110.209:8899'
|
||||
# VITE_APP_BASE_API = 'http://192.168.110.188:8899'
|
||||
# 朱银
|
||||
# VITE_APP_BASE_API = 'http://192.168.110.149:8899'
|
||||
#曾涛
|
||||
|
||||
@ -186,7 +186,7 @@ export const dowloadConstructionUserTemplate = (query: ConstructionUserTemplateF
|
||||
*/
|
||||
export const delConstructionUserMember = (data: ConstructionUserMembeForm) => {
|
||||
return request({
|
||||
url: '/contractor/projectTeamMember/',
|
||||
url: '/project/projectTeamMember/',
|
||||
method: 'delete',
|
||||
data
|
||||
});
|
||||
|
||||
@ -421,6 +421,7 @@ const handleDetail = async (row?: PurchaseDocVO) => {
|
||||
/** 表单重置 */
|
||||
const reset = () => {
|
||||
form.value = { ...initFormData };
|
||||
planList.value = [];
|
||||
purchaseDocFormRef.value?.resetFields();
|
||||
form.value.projectId = currentProject.value?.id;
|
||||
};
|
||||
@ -494,7 +495,7 @@ const submitForm = () => {
|
||||
purchaseDocFormRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
buttonLoading.value = true;
|
||||
form.value.associationList = selectPlanList.value;
|
||||
form.value.associationList = JSON.parse(JSON.stringify(selectPlanList.value));
|
||||
form.value.associationList.forEach((item: any) => {
|
||||
item.planId = item.id;
|
||||
delete item.id;
|
||||
|
||||
@ -1,14 +1,12 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter"
|
||||
:leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
<el-card shadow="hover">
|
||||
<el-form ref="queryFormRef" :model="queryParams" :inline="true">
|
||||
<el-form-item label="请选择项目:" prop="pid" label-width="100">
|
||||
<el-select v-model="queryParams.projectId" placeholder="请选择" @change="handleChange" clearable>
|
||||
<el-option v-for="item in matrixOptions" :key="item.projectId" :label="item.name"
|
||||
:value="item.projectId" />
|
||||
<el-option v-for="item in matrixOptions" :key="item.projectId" :label="item.name" :value="item.projectId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="请选择方阵:" prop="pid" label-width="100" v-if="relevancyStructure == '2'">
|
||||
@ -23,14 +21,23 @@
|
||||
<el-tabs type="border-card" v-model="activeTab" @tab-click="handleTabClick">
|
||||
<el-tab-pane :label="item.name" v-for="item in tabList" :key="item.id" :name="item.id"></el-tab-pane>
|
||||
<el-card shadow="never">
|
||||
<el-table ref="progressCategoryTableRef" v-loading="loading" :data="progressCategoryList" row-key="id"
|
||||
:default-expand-all="isExpandAll" :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
|
||||
v-if="isExpand" border>
|
||||
<el-table
|
||||
ref="progressCategoryTableRef"
|
||||
v-loading="loading"
|
||||
:data="progressCategoryList"
|
||||
row-key="id"
|
||||
:default-expand-all="isExpandAll"
|
||||
:tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
|
||||
v-if="isExpand"
|
||||
border
|
||||
>
|
||||
<el-table-column label="" width="50" type="expand">
|
||||
<template #header>
|
||||
<el-icon class="cursor-pointer text-4! transform-rotate-z--90 transition-all-300"
|
||||
<el-icon
|
||||
class="cursor-pointer text-4! transform-rotate-z--90 transition-all-300"
|
||||
:class="!isExpandAll ? 'transform-rotate-z--90' : 'transform-rotate-z-90'"
|
||||
@click="handleToggleExpandAll">
|
||||
@click="handleToggleExpandAll"
|
||||
>
|
||||
<Expand />
|
||||
</el-icon>
|
||||
</template>
|
||||
@ -40,8 +47,9 @@
|
||||
<el-table-column label="名称" align="center" prop="name" width="170">
|
||||
<template #default="{ row }">
|
||||
<el-tooltip :content="row.remark" placement="top" effect="dark" v-if="row.remark">
|
||||
<span class="flex items-center justify-center"><i
|
||||
class="iconfont icon-wenhao mr-0.5 text-3.5! text-#999"></i>{{ row.name }}</span>
|
||||
<span class="flex items-center justify-center"
|
||||
><i class="iconfont icon-wenhao mr-0.5 text-3.5! text-#999"></i>{{ row.name }}</span
|
||||
>
|
||||
</el-tooltip>
|
||||
<span v-else>{{ row.name }}</span>
|
||||
</template>
|
||||
@ -53,8 +61,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="是否延期" align="center" prop="isDelay" width="100">
|
||||
<template #default="{ row }">
|
||||
<el-tag :type="row.isDelay == '1' ? 'danger' : 'primary'">{{ row.isDelay == '1' ? '是' : '否'
|
||||
}}</el-tag>
|
||||
<el-tag :type="row.isDelay == '1' ? 'danger' : 'primary'">{{ row.isDelay == '1' ? '是' : '否' }}</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计量方式" align="center" prop="unitType" width="100">
|
||||
@ -65,8 +72,7 @@
|
||||
<el-table-column label="总量" align="center" prop="total" width="100" />
|
||||
<el-table-column label="总进度" align="center" prop="projectId">
|
||||
<template #default="{ row }">
|
||||
<el-progress :text-inside="true" :stroke-width="20" :percentage="row.completedPercentage"
|
||||
status="success" />
|
||||
<el-progress :text-inside="true" :stroke-width="20" :percentage="row.completedPercentage" status="success" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划总量" align="center" prop="planTotal" width="100" />
|
||||
@ -82,17 +88,35 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200">
|
||||
<template #default="scope">
|
||||
<el-button type="warning" icon="Download" link size="small" v-if="scope.row.name === '光伏板'"
|
||||
<el-button
|
||||
type="warning"
|
||||
icon="Download"
|
||||
link
|
||||
size="small"
|
||||
v-if="scope.row.name === '光伏板'"
|
||||
@click="openDialog(scope.row, 'importTableStatus', '上传表格')"
|
||||
v-hasPermi="['progress:progressCategory:add']">
|
||||
v-hasPermi="['progress:progressCategory:add']"
|
||||
>
|
||||
导入表格
|
||||
</el-button>
|
||||
<el-button type="success" icon="Plus" link size="small" @click="planRef.openDialog(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:add']">
|
||||
<el-button
|
||||
type="success"
|
||||
icon="Plus"
|
||||
link
|
||||
size="small"
|
||||
@click="planRef.openDialog(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:add']"
|
||||
>
|
||||
计划
|
||||
</el-button>
|
||||
<el-button type="primary" icon="Plus" link size="small" @click="handleDayAdd(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:add']">
|
||||
<el-button
|
||||
type="primary"
|
||||
icon="Plus"
|
||||
link
|
||||
size="small"
|
||||
@click="handleDayAdd(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:add']"
|
||||
>
|
||||
日报
|
||||
</el-button>
|
||||
</template>
|
||||
@ -109,8 +133,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="总进度" align="center" prop="projectId">
|
||||
<template #default="{ row }">
|
||||
<el-progress :text-inside="true" :stroke-width="20" :percentage="row.completedPercentage"
|
||||
status="success" />
|
||||
<el-progress :text-inside="true" :stroke-width="20" :percentage="row.completedPercentage" status="success" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@ -118,8 +141,7 @@
|
||||
<el-table-column label="名称" align="center" prop="name" width="170">
|
||||
<template #default="{ row }">
|
||||
<el-tooltip :content="row.remark" placement="top" effect="dark" v-if="row.remark">
|
||||
<span class="flex items-center justify-center"><i
|
||||
class="iconfont icon-wenhao mr-0.5 text-3.5! text-#999"></i>{{ row.name }}</span>
|
||||
<span class="flex items-center justify-center"><i class="iconfont icon-wenhao mr-0.5 text-3.5! text-#999"></i>{{ row.name }}</span>
|
||||
</el-tooltip>
|
||||
<span v-else>{{ row.name }}</span>
|
||||
</template>
|
||||
@ -142,8 +164,7 @@
|
||||
<el-table-column label="总量" align="center" prop="total" width="100" />
|
||||
<el-table-column label="总进度" align="center" prop="projectId">
|
||||
<template #default="{ row }">
|
||||
<el-progress :text-inside="true" :stroke-width="20" :percentage="row.completedPercentage"
|
||||
status="success" />
|
||||
<el-progress :text-inside="true" :stroke-width="20" :percentage="row.completedPercentage" status="success" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划总量" align="center" prop="planTotal" width="100" />
|
||||
@ -159,17 +180,28 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200">
|
||||
<template #default="scope">
|
||||
<el-button type="warning" icon="Download" link size="small" v-if="scope.row.name === '光伏板'"
|
||||
<el-button
|
||||
type="warning"
|
||||
icon="Download"
|
||||
link
|
||||
size="small"
|
||||
v-if="scope.row.name === '光伏板'"
|
||||
@click="openDialog(scope.row, 'importTableStatus', '上传表格')"
|
||||
v-hasPermi="['progress:progressCategory:add']">
|
||||
v-hasPermi="['progress:progressCategory:add']"
|
||||
>
|
||||
导入表格
|
||||
</el-button>
|
||||
<el-button type="success" icon="Plus" link size="small" @click="planRef.openDialog(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:add']">
|
||||
<el-button
|
||||
type="success"
|
||||
icon="Plus"
|
||||
link
|
||||
size="small"
|
||||
@click="planRef.openDialog(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:add']"
|
||||
>
|
||||
计划
|
||||
</el-button>
|
||||
<el-button type="primary" icon="Plus" link size="small" @click="handleDayAdd(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:add']">
|
||||
<el-button type="primary" icon="Plus" link size="small" @click="handleDayAdd(scope.row)" v-hasPermi="['progress:progressCategory:add']">
|
||||
日报
|
||||
</el-button>
|
||||
</template>
|
||||
@ -180,8 +212,7 @@
|
||||
|
||||
<!-- 导入数据对话框 -->
|
||||
<el-dialog :title="dialog.title" v-model="dialog.importDataStatus" width="500px" append-to-body>
|
||||
<file-upload class="pl-20 pt" v-model="dialog.file" :limit="20" :file-size="50"
|
||||
:file-type="['shp', 'shx', 'dbf']" />
|
||||
<file-upload class="pl-20 pt" v-model="dialog.file" :limit="20" :file-size="50" :file-type="['shp', 'shx', 'dbf']" />
|
||||
<template #footer>
|
||||
<div class="dialog-footer">
|
||||
<el-button :loading="buttonLoading" type="primary" @click="submitForm">确 定</el-button>
|
||||
@ -291,6 +322,9 @@ const getList = async () => {
|
||||
const res = await getProjectSquare(currentProject.value?.id);
|
||||
if (!res.data || res.data.length === 0) {
|
||||
proxy?.$modal.msgWarning('当前项目下没有方阵,请先创建方阵');
|
||||
tabList.value = [];
|
||||
progressCategoryList.value = [];
|
||||
return;
|
||||
} else {
|
||||
let matrixList = res.data.map((item) => {
|
||||
return {
|
||||
@ -367,6 +401,8 @@ const reset = () => {
|
||||
const resetMatrix = () => {
|
||||
matrixValue.value = undefined;
|
||||
queryParams.value.matrixId = undefined;
|
||||
queryParams.value.projectId = undefined;
|
||||
relevancyStructure.value = '1';
|
||||
matrixOptions.value = [];
|
||||
};
|
||||
|
||||
@ -386,7 +422,11 @@ const handleDayAdd = (row: ProgressCategoryVO) => {
|
||||
if (row.unitType === '2') {
|
||||
dailyRef.value.openDialog(row);
|
||||
} else {
|
||||
dailyRateRef.value.openDialog(row);
|
||||
if (!row.workType) {
|
||||
dailyRef.value.openDialog(row);
|
||||
} else {
|
||||
dailyRateRef.value.openDialog(row);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@ -463,8 +503,6 @@ onMounted(() => {
|
||||
const listeningProject = watch(
|
||||
() => currentProject.value?.id,
|
||||
(nid, oid) => {
|
||||
queryParams.value.projectId = nid;
|
||||
form.value.projectId = nid;
|
||||
resetMatrix();
|
||||
getList();
|
||||
}
|
||||
|
||||
@ -1,14 +1,12 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter"
|
||||
:leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
<el-card shadow="hover">
|
||||
<el-form ref="queryFormRef" :model="queryParams" :inline="true">
|
||||
<el-form-item label="请选择项目:" prop="pid" label-width="100">
|
||||
<el-select v-model="queryParams.projectId" placeholder="请选择" @change="handleChange" clearable>
|
||||
<el-option v-for="item in matrixOptions" :key="item.projectId" :label="item.name"
|
||||
:value="item.projectId" />
|
||||
<el-option v-for="item in matrixOptions" :key="item.projectId" :label="item.name" :value="item.projectId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="请选择方阵:" prop="pid" label-width="100" v-if="relevancyStructure == '2'">
|
||||
@ -24,13 +22,18 @@
|
||||
<el-tab-pane :label="item.name" v-for="item in tabList" :key="item.id" :name="item.id"></el-tab-pane>
|
||||
<el-card shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8" style="display: flex; align-items: center;">
|
||||
<el-row :gutter="10" class="mb8" style="display: flex; align-items: center">
|
||||
<el-col :span="1.5">
|
||||
<el-button type="primary" plain icon="Plus" @click="handleAdd()">新增</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<file-upload upload-url="/progress/progressCategory/import" v-model="file" :limit="1"
|
||||
:file-type="['xls', 'xlsx']" :on-upload-success="handleSuccess">
|
||||
<file-upload
|
||||
upload-url="/progress/progressCategory/import"
|
||||
v-model="file"
|
||||
:limit="1"
|
||||
:file-type="['xls', 'xlsx']"
|
||||
:on-upload-success="handleSuccess"
|
||||
>
|
||||
<el-button type="primary" plain icon="upload">导入</el-button>
|
||||
</file-upload>
|
||||
</el-col>
|
||||
@ -69,12 +72,17 @@
|
||||
</div>
|
||||
</el-col>
|
||||
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
|
||||
|
||||
</el-row>
|
||||
</template>
|
||||
<el-table ref="progressCategoryTableRef" v-loading="loading" :data="progressCategoryList" row-key="id"
|
||||
:default-expand-all="isExpandAll" :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
|
||||
max-height="550">
|
||||
<el-table
|
||||
ref="progressCategoryTableRef"
|
||||
v-loading="loading"
|
||||
:data="progressCategoryList"
|
||||
row-key="id"
|
||||
:default-expand-all="isExpandAll"
|
||||
:tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
|
||||
max-height="550"
|
||||
>
|
||||
<!-- <el-table-column label="父类别id" prop="parentId" /> -->
|
||||
<el-table-column label="类别名称" prop="name" width="230" />
|
||||
<el-table-column label="计量方式" align="center" prop="unitType">
|
||||
@ -123,12 +131,10 @@
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||
<template #default="scope">
|
||||
<div>
|
||||
<el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:edit']">
|
||||
<el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['progress:progressCategory:edit']">
|
||||
修改
|
||||
</el-button>
|
||||
<el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)"
|
||||
v-hasPermi="['progress:progressCategory:remove']">
|
||||
<el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['progress:progressCategory:remove']">
|
||||
删除
|
||||
</el-button>
|
||||
</div>
|
||||
@ -142,9 +148,14 @@
|
||||
<el-dialog :title="dialog.title" v-model="dialog.visible" width="500px" append-to-body>
|
||||
<el-form ref="progressCategoryFormRef" :model="form" :rules="rules" label-width="120px">
|
||||
<el-form-item label="父类别" prop="parentId" v-if="!form.id">
|
||||
<el-tree-select v-model="form.parentId" :data="progressCategoryOptions"
|
||||
:props="{ value: 'id', label: 'name', children: 'children' }" value-key="id" placeholder="请选择父类别"
|
||||
check-strictly />
|
||||
<el-tree-select
|
||||
v-model="form.parentId"
|
||||
:data="progressCategoryOptions"
|
||||
:props="{ value: 'id', label: 'name', children: 'children' }"
|
||||
value-key="id"
|
||||
placeholder="请选择父类别"
|
||||
check-strictly
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="计量方式" prop="unitType" v-if="!form.workType && form.unitType != '0'">
|
||||
<el-select v-model="form.unitType" placeholder="请选择关联数据">
|
||||
@ -167,7 +178,7 @@
|
||||
<el-input v-model="form.total" placeholder="请输入数量" />
|
||||
</el-form-item>
|
||||
<el-form-item label="关联数据" prop="workType" v-if="!form.id && form.unitType != '0'">
|
||||
<el-select v-model="form.workType" placeholder="请选择关联数据">
|
||||
<el-select v-model="form.workType" placeholder="请选择关联数据" clearable>
|
||||
<el-option v-for="dict in progress_work_type" :key="dict.value" :label="dict.label" :value="dict.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@ -244,7 +255,7 @@ const dialog = reactive<DialogOption>({
|
||||
visible: false,
|
||||
title: ''
|
||||
});
|
||||
const tempData = ref([])
|
||||
const tempData = ref([]);
|
||||
const initFormData: ProgressCategoryForm = {
|
||||
id: undefined,
|
||||
parentId: undefined,
|
||||
@ -312,16 +323,16 @@ const { queryParams, form, rules } = toRefs(data);
|
||||
const matrixIdList = ref([]);
|
||||
const ownerOutputSum = computed(() => {
|
||||
let sum = 0;
|
||||
tempData.value.forEach(item => {
|
||||
tempData.value.forEach((item) => {
|
||||
sum += Number(item.ownerOutputValue);
|
||||
})
|
||||
return proxy.formatPrice(sum) ?? 0;
|
||||
});
|
||||
return proxy.formatPrice(sum);
|
||||
});
|
||||
const constructionOutputSum = computed(() => {
|
||||
let sum = 0;
|
||||
tempData.value.forEach(item => {
|
||||
tempData.value.forEach((item) => {
|
||||
sum += Number(item.constructionOutputValue);
|
||||
})
|
||||
});
|
||||
return proxy.formatPrice(sum);
|
||||
});
|
||||
/** 查询分项工程单价列表 */
|
||||
@ -329,12 +340,14 @@ const getList = async () => {
|
||||
if (!queryParams.value.projectId) {
|
||||
const res = await getProjectSquare(currentProject.value?.id);
|
||||
if (res.data.length === 0) {
|
||||
proxy?.$modal.msgWarning('当前项目下没有方阵,请先创建方阵');
|
||||
matrixOptions.value = [];
|
||||
queryParams.value.projectId = '';
|
||||
form.value.projectId = '';
|
||||
// proxy?.$modal.msgWarning('当前项目下没有方阵,请先创建方阵');
|
||||
// matrixOptions.value = [];
|
||||
// queryParams.value.projectId = '';
|
||||
// form.value.projectId = '';
|
||||
progressCategoryList.value = [];
|
||||
tabList.value = [];
|
||||
activeTab.value = '';
|
||||
// activeTab.value = '';
|
||||
return;
|
||||
} else {
|
||||
let matrixList = res.data.map((item) => {
|
||||
return {
|
||||
@ -512,6 +525,7 @@ const resetMatrix = () => {
|
||||
matrixValue.value = undefined;
|
||||
queryParams.value.matrixId = undefined;
|
||||
queryParams.value.projectId = undefined;
|
||||
relevancyStructure.value = '1';
|
||||
matrixOptions.value = [];
|
||||
};
|
||||
|
||||
@ -658,7 +672,11 @@ onUnmounted(() => {
|
||||
font-size: 20px;
|
||||
font-weight: 700;
|
||||
color: #262626;
|
||||
font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, sans-serif;
|
||||
font-family:
|
||||
'SF Pro Display',
|
||||
-apple-system,
|
||||
BlinkMacSystemFont,
|
||||
sans-serif;
|
||||
letter-spacing: -0.5px;
|
||||
line-height: 1.2;
|
||||
text-align: center;
|
||||
|
||||
@ -21,8 +21,8 @@
|
||||
<el-date-picker
|
||||
clearable
|
||||
v-model="queryParams.clockDate"
|
||||
type="date"
|
||||
value-format="YYYY-MM-DD"
|
||||
type="month"
|
||||
value-format="YYYY-MM"
|
||||
placeholder="请选择打卡日期"
|
||||
@change="selectDate"
|
||||
/>
|
||||
@ -338,19 +338,22 @@ const handleViewPlayCard = async (data: any) => {
|
||||
/** 查询考勤列表 */
|
||||
const getList = async () => {
|
||||
loading.value = true;
|
||||
const res = await listAttendance(queryParams.value);
|
||||
attendanceList.value = res.rows;
|
||||
total.value = res.total;
|
||||
loading.value = false;
|
||||
try {
|
||||
const res = await listAttendance(queryParams.value);
|
||||
attendanceList.value = res.rows;
|
||||
total.value = res.total;
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
/** 查询近两周考勤列表 */
|
||||
const getListTwoWeek = async () => {
|
||||
loading.value = true;
|
||||
// const res = await listAttendanceTwoWeek(queryParams.value);
|
||||
// attendanceTwoWeekList.value = res.data;
|
||||
// echartsOption.value = { ...option(attendanceTwoWeekList.value) };
|
||||
// commandstatsIntance.value.setOption(echartsOption.value);
|
||||
const res = await listAttendanceTwoWeek(queryParams.value);
|
||||
attendanceTwoWeekList.value = res.data;
|
||||
echartsOption.value = { ...option(attendanceTwoWeekList.value) };
|
||||
commandstatsIntance.value.setOption(echartsOption.value);
|
||||
};
|
||||
|
||||
/** 取消按钮 */
|
||||
|
||||
@ -116,12 +116,15 @@
|
||||
</el-dialog>
|
||||
<!-- 上传退场记录 -->
|
||||
<el-dialog title="员工离场" v-model="memberStatus" width="30%">
|
||||
<el-form :model="memberForm" ref="memberFormRef" :rules="memberRules" label-width="100px" :inline="false">
|
||||
<el-form :model="memberForm" ref="memberFormRef" :rules="memberRules" label-width="120px" :inline="false">
|
||||
<el-form-item label="用户名">
|
||||
<el-input v-model="memberForm.userName" disabled></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="退场文件">
|
||||
<file-upload v-model="memberForm.filePath" :limit="10" :is-show-tip="false" :file-size="50" />
|
||||
<el-form-item label="工资发放凭证">
|
||||
<file-upload v-model="memberForm.salaryVoucherFile" :limit="10" :is-show-tip="false" :file-size="50" />
|
||||
</el-form-item>
|
||||
<el-form-item label="工资结算确认书">
|
||||
<file-upload v-model="memberForm.salaryConfirmationFile" :limit="10" :is-show-tip="false" :file-size="50" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备注">
|
||||
<el-input v-model="memberForm.remark" placeholder="请输入备注" type="textarea"></el-input>
|
||||
@ -163,9 +166,10 @@ const memberStatus = ref(false);
|
||||
interface Props {
|
||||
projectTeamVo: ProjectTeamVO;
|
||||
}
|
||||
const memberForm = reactive<ConstructionUserMembeForm>({
|
||||
const memberForm = reactive<any>({
|
||||
id: undefined,
|
||||
filePath: undefined,
|
||||
salaryConfirmationFile: undefined,
|
||||
salaryVoucherFile: undefined,
|
||||
remark: undefined,
|
||||
userName: undefined
|
||||
});
|
||||
@ -328,8 +332,9 @@ const submitMemberForm = async () => {
|
||||
const handleExit = async (row?: ProjectTeamMemberVO) => {
|
||||
const _ids = row?.id || ids.value;
|
||||
memberForm.userName = row?.memberName;
|
||||
console.log('🚀 ~ handleDelete ~ row:', row);
|
||||
memberForm.id = row?.id;
|
||||
memberForm.salaryVoucherFile = '';
|
||||
memberForm.salaryConfirmationFile = '';
|
||||
memberStatus.value = true;
|
||||
};
|
||||
|
||||
|
||||
@ -103,7 +103,7 @@
|
||||
</template>
|
||||
|
||||
<script setup name="ProjectTeam" lang="ts">
|
||||
import { addProjectTeam, delProjectTeam, getProjectTeam, listProjectTeam, updateProjectTeam,getProjectTeamClockIn } from '@/api/project/projectTeam';
|
||||
import { addProjectTeam, delProjectTeam, getProjectTeam, listProjectTeam, updateProjectTeam, getProjectTeamClockIn } from '@/api/project/projectTeam';
|
||||
import { ProjectTeamForm, ProjectTeamQuery, ProjectTeamVO } from '@/api/project/projectTeam/types';
|
||||
import { useUserStoreHook } from '@/store/modules/user';
|
||||
import UserListDialog from '@/views/project/projectTeam/component/UserListDialog.vue';
|
||||
@ -180,15 +180,14 @@ const getList = async () => {
|
||||
total.value = res.total;
|
||||
loading.value = false;
|
||||
};
|
||||
/** 获取该项目的打开范围 "*/
|
||||
/** 获取该项目的打开范围 "*/
|
||||
const getClockIn = async () => {
|
||||
if(currentProject.value?.id){
|
||||
const res = await getProjectTeamClockIn({projectId:currentProject.value?.id});
|
||||
projectTeamRangeList.value = res.rows
|
||||
if (currentProject.value?.id) {
|
||||
const res = await getProjectTeamClockIn({ projectId: currentProject.value?.id });
|
||||
projectTeamRangeList.value = res.rows;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/** 取消按钮 */
|
||||
const cancel = () => {
|
||||
reset();
|
||||
@ -288,6 +287,7 @@ const listeningProject = watch(
|
||||
queryParams.value.projectId = nid;
|
||||
form.value.projectId = nid;
|
||||
getList();
|
||||
getClockIn();
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
@ -549,6 +549,8 @@ const splitBackEndStrToForm = (resData: any) => {
|
||||
};
|
||||
/** 审核过程按钮操作 */
|
||||
const handleAudit = async (row) => {
|
||||
if(!row.fileId)return proxy?.$modal.msgError('用户资料未上传');
|
||||
|
||||
proxy.$tab.closePage(proxy.$route);
|
||||
proxy.$router.push({
|
||||
path: `/approval/supplierInput/indexEdit`,
|
||||
|
||||
Reference in New Issue
Block a user