|
@@ -3,7 +3,6 @@ import { FiveIotProjectDailyReportApi } from '@/api/pms/fiveconstructiondailyrep
|
|
|
import { useUserStore } from '@/store/modules/user'
|
|
import { useUserStore } from '@/store/modules/user'
|
|
|
import { rangeShortcuts } from '@/utils/formatTime'
|
|
import { rangeShortcuts } from '@/utils/formatTime'
|
|
|
import { useDebounceFn } from '@vueuse/core'
|
|
import { useDebounceFn } from '@vueuse/core'
|
|
|
-import dayjs from 'dayjs'
|
|
|
|
|
import ConstructionDailyReportDrawer from './components/ConstructionDailyReportDrawer.vue'
|
|
import ConstructionDailyReportDrawer from './components/ConstructionDailyReportDrawer.vue'
|
|
|
import ConstructionDailyReportTable from './components/ConstructionDailyReportTable.vue'
|
|
import ConstructionDailyReportTable from './components/ConstructionDailyReportTable.vue'
|
|
|
import type {
|
|
import type {
|
|
@@ -20,9 +19,6 @@ const initQuery: ConstructionDailyReportQuery = {
|
|
|
pageNo: 1,
|
|
pageNo: 1,
|
|
|
pageSize: 10,
|
|
pageSize: 10,
|
|
|
deptId
|
|
deptId
|
|
|
- // createTime: [
|
|
|
|
|
- // ...rangeShortcuts[2].value().map((item) => dayjs(item).format('YYYY-MM-DD HH:mm:ss'))
|
|
|
|
|
- // ]
|
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
const query = ref<ConstructionDailyReportQuery>({ ...initQuery })
|
|
const query = ref<ConstructionDailyReportQuery>({ ...initQuery })
|
|
@@ -90,16 +86,19 @@ onMounted(() => {
|
|
|
|
|
|
|
|
<template>
|
|
<template>
|
|
|
<div
|
|
<div
|
|
|
- class="grid grid-cols-[auto_1fr] grid-rows-[62px_1fr] gap-4 h-[calc(100vh-20px-var(--top-tool-height)-var(--tags-view-height)-var(--app-footer-height))]">
|
|
|
|
|
|
|
+ class="grid grid-cols-[auto_1fr] grid-rows-[62px_1fr] gap-4 h-[calc(100vh-20px-var(--top-tool-height)-var(--tags-view-height)-var(--app-footer-height))]"
|
|
|
|
|
+ >
|
|
|
<DeptTreeSelect
|
|
<DeptTreeSelect
|
|
|
v-model="query.deptId"
|
|
v-model="query.deptId"
|
|
|
:top-id="158"
|
|
:top-id="158"
|
|
|
:deptId="deptId"
|
|
:deptId="deptId"
|
|
|
:show-title="false"
|
|
:show-title="false"
|
|
|
- class="row-span-2" />
|
|
|
|
|
|
|
+ class="row-span-2"
|
|
|
|
|
+ />
|
|
|
<el-form
|
|
<el-form
|
|
|
size="default"
|
|
size="default"
|
|
|
- class="bg-white dark:bg-[#1d1e1f] rounded-lg shadow px-8 gap-8 flex items-center justify-between">
|
|
|
|
|
|
|
+ class="bg-white dark:bg-[#1d1e1f] rounded-lg shadow px-8 gap-8 flex items-center justify-between"
|
|
|
|
|
+ >
|
|
|
<div class="flex items-center gap-8">
|
|
<div class="flex items-center gap-8">
|
|
|
<el-form-item label="项目">
|
|
<el-form-item label="项目">
|
|
|
<el-input
|
|
<el-input
|
|
@@ -107,7 +106,8 @@ onMounted(() => {
|
|
|
placeholder="请输入项目名称"
|
|
placeholder="请输入项目名称"
|
|
|
clearable
|
|
clearable
|
|
|
@keyup.enter="handleQuery()"
|
|
@keyup.enter="handleQuery()"
|
|
|
- class="!w-240px" />
|
|
|
|
|
|
|
+ class="!w-240px"
|
|
|
|
|
+ />
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
<el-form-item label="生产任务">
|
|
<el-form-item label="生产任务">
|
|
|
<el-input
|
|
<el-input
|
|
@@ -115,7 +115,8 @@ onMounted(() => {
|
|
|
placeholder="请输入生产任务"
|
|
placeholder="请输入生产任务"
|
|
|
clearable
|
|
clearable
|
|
|
@keyup.enter="handleQuery()"
|
|
@keyup.enter="handleQuery()"
|
|
|
- class="!w-240px" />
|
|
|
|
|
|
|
+ class="!w-240px"
|
|
|
|
|
+ />
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
<el-form-item label="创建时间">
|
|
<el-form-item label="创建时间">
|
|
|
<el-date-picker
|
|
<el-date-picker
|
|
@@ -126,14 +127,17 @@ onMounted(() => {
|
|
|
end-placeholder="结束日期"
|
|
end-placeholder="结束日期"
|
|
|
:shortcuts="rangeShortcuts"
|
|
:shortcuts="rangeShortcuts"
|
|
|
:default-time="[new Date('1 00:00:00'), new Date('1 23:59:59')]"
|
|
:default-time="[new Date('1 00:00:00'), new Date('1 23:59:59')]"
|
|
|
- class="!w-260px" />
|
|
|
|
|
|
|
+ class="!w-260px"
|
|
|
|
|
+ />
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</div>
|
|
</div>
|
|
|
<el-form-item>
|
|
<el-form-item>
|
|
|
<el-button type="primary" @click="handleQuery()">
|
|
<el-button type="primary" @click="handleQuery()">
|
|
|
<Icon icon="ep:search" class="mr-5px" /> 搜索
|
|
<Icon icon="ep:search" class="mr-5px" /> 搜索
|
|
|
</el-button>
|
|
</el-button>
|
|
|
- <el-button @click="resetQuery"> <Icon icon="ep:refresh" class="mr-5px" /> 重置 </el-button>
|
|
|
|
|
|
|
+ <el-button @click="resetQuery">
|
|
|
|
|
+ <Icon icon="ep:refresh" class="mr-5px" /> 重置
|
|
|
|
|
+ </el-button>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-form>
|
|
</el-form>
|
|
|
|
|
|
|
@@ -144,28 +148,36 @@ onMounted(() => {
|
|
|
:page-no="query.pageNo"
|
|
:page-no="query.pageNo"
|
|
|
:page-size="query.pageSize"
|
|
:page-size="query.pageSize"
|
|
|
@size-change="handleSizeChange"
|
|
@size-change="handleSizeChange"
|
|
|
- @current-change="handleCurrentChange">
|
|
|
|
|
|
|
+ @current-change="handleCurrentChange"
|
|
|
|
|
+ >
|
|
|
<template #action="{ row }">
|
|
<template #action="{ row }">
|
|
|
<el-button
|
|
<el-button
|
|
|
|
|
+ v-if="row.status === 0"
|
|
|
link
|
|
link
|
|
|
- type="success"
|
|
|
|
|
- @click="handleOpenForm(row.id!, 'readonly')"
|
|
|
|
|
- v-hasPermi="['pms:iot-five-daily-report:query']">
|
|
|
|
|
- 查看
|
|
|
|
|
|
|
+ type="primary"
|
|
|
|
|
+ @click="handleOpenForm(row.id!, 'edit')"
|
|
|
|
|
+ v-hasPermi="['pms:iot-five-daily-report:update']"
|
|
|
|
|
+ >
|
|
|
|
|
+ 填报
|
|
|
</el-button>
|
|
</el-button>
|
|
|
<el-button
|
|
<el-button
|
|
|
- v-show="row.status === 0 || row.status === undefined || row.status === null"
|
|
|
|
|
|
|
+ v-else-if="row.status === 1"
|
|
|
link
|
|
link
|
|
|
- type="primary"
|
|
|
|
|
- @click="handleOpenForm(row.id!, 'edit')"
|
|
|
|
|
- v-hasPermi="['pms:iot-five-daily-report:update']">
|
|
|
|
|
- 编辑
|
|
|
|
|
|
|
+ type="success"
|
|
|
|
|
+ @click="handleOpenForm(row.id!, 'readonly')"
|
|
|
|
|
+ v-hasPermi="['pms:iot-five-daily-report:query']"
|
|
|
|
|
+ >
|
|
|
|
|
+ 查看
|
|
|
</el-button>
|
|
</el-button>
|
|
|
</template>
|
|
</template>
|
|
|
</ConstructionDailyReportTable>
|
|
</ConstructionDailyReportTable>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
- <ConstructionDailyReportDrawer ref="formRef" v-model:visible="visible" :load-list="loadList" />
|
|
|
|
|
|
|
+ <ConstructionDailyReportDrawer
|
|
|
|
|
+ ref="formRef"
|
|
|
|
|
+ v-model:visible="visible"
|
|
|
|
|
+ :load-list="loadList"
|
|
|
|
|
+ />
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<style scoped>
|
|
<style scoped>
|