大屏以及质量管理
This commit is contained in:
@ -4,8 +4,8 @@
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
<el-card shadow="hover">
|
||||
<el-form ref="queryFormRef" :model="queryParams" :inline="true">
|
||||
<el-form-item label="发生日期" prop="happenDate">
|
||||
<el-date-picker clearable v-model="queryParams.happenDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择发生日期" />
|
||||
<el-form-item label="发生日期" prop="dateOfOccurrence">
|
||||
<el-date-picker clearable v-model="queryParams.dateOfOccurrence" type="date" value-format="YYYY-MM-DD" placeholder="请选择发生日期" />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
|
||||
@ -19,42 +19,21 @@
|
||||
<el-card shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<!-- <el-col :span="1.5">
|
||||
<el-button type="primary" plain icon="Plus" @click="handleAdd" v-hasPermi="['quality:qualityConstructionLog:add']">新增</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button type="success" plain icon="Edit" :disabled="single" @click="handleUpdate()" v-hasPermi="['quality:qualityConstructionLog:edit']">修改</el-button>
|
||||
</el-col> -->
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="danger"
|
||||
plain
|
||||
icon="Delete"
|
||||
:disabled="multiple"
|
||||
@click="handleDelete()"
|
||||
v-hasPermi="['quality:qualityConstructionLog:remove']"
|
||||
>删除</el-button
|
||||
>
|
||||
</el-col>
|
||||
<!-- <el-col :span="1.5">
|
||||
<el-button type="warning" plain icon="Download" @click="handleExport" v-hasPermi="['quality:qualityConstructionLog:export']">导出</el-button>
|
||||
</el-col> -->
|
||||
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
</template>
|
||||
|
||||
<el-table v-loading="loading" :data="qualityConstructionLogList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table v-loading="loading" :data="qualityConstructionLogList">
|
||||
<el-table-column label="序号" align="center" type="index" width="70" />
|
||||
|
||||
<el-table-column label="生产情况" align="center" prop="productionStatus" width="410">
|
||||
<el-table-column label="生产情况" align="center" prop="condition" width="410">
|
||||
<template #default="scope">
|
||||
<el-tooltip placement="top" effect="dark">
|
||||
<template #content>
|
||||
<div class="w-670px">{{ scope.row.productionStatus }}</div>
|
||||
<div class="w-670px">{{ scope.row.condition }}</div>
|
||||
</template>
|
||||
<el-text truncated>
|
||||
{{ scope.row.productionStatus }}
|
||||
{{ scope.row.condition }}
|
||||
</el-text>
|
||||
</el-tooltip>
|
||||
</template>
|
||||
@ -71,19 +50,15 @@
|
||||
</el-tooltip>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="发生日期" align="center" prop="happenDate" width="180">
|
||||
<el-table-column label="发生日期" align="center" prop="dateOfOccurrence" width="180">
|
||||
<template #default="scope">
|
||||
<span>{{ parseTime(scope.row.happenDate, '{y}-{m}-{d}') }}</span>
|
||||
<span>{{ parseTime(scope.row.dateOfOccurrence, '{y}-{m}-{d}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="创建者" align="center" prop="createBy" />
|
||||
<el-table-column label="备注" align="center" prop="remark" />
|
||||
<el-table-column label="创建者" align="center" prop="createdBy" />
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||
<template #default="scope">
|
||||
<el-button link type="primary" icon="View" @click="handleUpdate(scope.row)">详情</el-button>
|
||||
<el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['quality:qualityConstructionLog:remove']">
|
||||
删除
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@ -133,7 +108,7 @@ const dialog = reactive<DialogOption>({
|
||||
|
||||
const initFormData: QualityConstructionLogForm = {
|
||||
id: undefined,
|
||||
projectId: currentProject.value.id,
|
||||
projectId: currentProject.value.goId,
|
||||
happenDate: undefined,
|
||||
productionStatus: undefined,
|
||||
technologyQuality: undefined,
|
||||
@ -145,7 +120,7 @@ const data = reactive<PageData<QualityConstructionLogForm, QualityConstructionLo
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
projectId: currentProject.value.id,
|
||||
projectId: currentProject.value.goId,
|
||||
happenDate: undefined,
|
||||
params: {}
|
||||
},
|
||||
@ -162,8 +137,8 @@ const { queryParams, form, rules } = toRefs(data);
|
||||
const getList = async () => {
|
||||
loading.value = true;
|
||||
const res = await listQualityConstructionLog(queryParams.value);
|
||||
qualityConstructionLogList.value = res.rows;
|
||||
total.value = res.total;
|
||||
qualityConstructionLogList.value = res.data.list;
|
||||
total.value = res.data.total;
|
||||
loading.value = false;
|
||||
};
|
||||
|
||||
@ -251,7 +226,7 @@ const handleExport = () => {
|
||||
|
||||
//监听项目id刷新数据
|
||||
const listeningProject = watch(
|
||||
() => currentProject.value.id,
|
||||
() => currentProject.value.goId,
|
||||
(nid, oid) => {
|
||||
queryParams.value.projectId = nid;
|
||||
form.value.projectId = nid;
|
||||
|
Reference in New Issue
Block a user