This commit is contained in:
zmj 2024-03-30 17:09:54 +08:00
parent ad76547862
commit 2496a4447d
43 changed files with 217 additions and 107 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.4 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 936 B

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.6 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

View File

@ -15,7 +15,7 @@
<slot></slot>
<el-table-column :label="item.label" v-for="(item, index) in config.tableConfig" :key="index"
:prop="item[value]">
<template #default="{ row }">
<template #default="{ row, $index }">
<!-- 下拉框 -->
<el-form-item v-if="item.select" label-width="0">
<el-select v-model="row[item.value]">
@ -38,7 +38,15 @@
@input="row[item.value] = row[item.value].replace(/\d+/g, '')" />
</el-form-item>
<el-form-item :prop="item.check ? item.value : ''" v-else label-width="0">
<el-form-item v-else-if="item.check" label-width="0" :prop="`${item.check[0]}[${$index}].${item.value}`"
:rules="item?.check ? {
validator: item.check[1],
trigger: ['blur'],
} : ''">
<el-input v-model="row[item.value]" :type="item.type == 'number' ? 'number' : 'text'" />
</el-form-item>
<el-form-item v-else label-width="0">
<el-input v-model="row[item.value]" :type="item.type == 'number' ? 'number' : 'text'" />
</el-form-item>
</template>

View File

@ -5,11 +5,14 @@
:class="menuName == item.name ? 'bg-primary-light-9 text-primary' : ''">
{{ item.name }}
</div> -->
<div class="mr-5 cursor-pointer flex items-center flex-col transition-all duration-300 h-28 "
@click="menuClick(item)" v-for="(item, index) in menuList" v-show="item.paths != 'workbench'">
<el-image class="w-[35px] h-[35px] mb-[5px]"
:src="menuName == item.name ? getImgById(item.id)?.actImg : getImgById(item.id)?.img" />
{{ item.name }}
<div class="mr-2 cursor-pointer flex items-center flex-col transition-all duration-300 px-[8px] hover:bg-primary-light-9 hover:text-primary "
@click=" menuClick(item)" v-for="(item, index) in menuList" v-show="item.paths != 'workbench'"
:style="menuName == item.name ? { 'transform': 'scale(1.1)' } : ''">
<div class="w-[40px] h-[40px] duration-300 mt-[5px] mb-[2px] !bg-[length:100%_100%]"
:style="menuName == item.name ? { background: `url(${getImgById(item.id)?.img})` } : { background: `url(${getImgById(item.id)?.actImg})` }">
</div>
<span :class="menuName == item.name ? 'text-primary' : ''"> {{ item.name }}</span>
</div>
</div>
</template>
@ -73,7 +76,4 @@ const getImgById = (id: number) => {
return { img: '/index/CWGLACT.png', actImg: "/index/CWGL.png" }
}
}
</script>

View File

@ -1,6 +1,6 @@
<template>
<div class="flex">
<div class="menu flex-1 flex flex-wrap px-4 mt-0">
<div class="menu flex-1 flex flex-wrap px-4 mt-3">
<div v-for="(item, index) in tabsLists" class="flex py-1 px-5 cursor-pointer mb-2 items-center"
:class="{ act: (currentRoute == item.fullPath) }">
<span v-show="currentRoute == item.fullPath" class="w-1.5 h-1.5 mr-1 bg-primary rounded"></span>

View File

@ -24,6 +24,7 @@ export function isEmail(data: string) {
// input框校验
//电话
export function checkPhone(rules: any, value: any, callback: any) {
/^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$/.test(
value
)

View File

@ -1,7 +1,6 @@
<template>
<div class="edit-popup">
<popup ref="popupRef" :title="popupTitle" :async="true" width="80vw" @confirm="handleSubmit"
@close="handleClose">
<popup ref="popupRef" :title="popupTitle" :async="true" width="80vw" @confirm="handleSubmit" @close="handleClose">
<el-form ref="formRef" :model="formData" label-width="120px" :rules="formRules">
<el-row>
<el-col :span="8">
@ -58,8 +57,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="总投资(元)" prop="total_investment">
<el-input v-model="formData.total_investment" clearable placeholder="请输入总投资(元)"
type="number" />
<el-input v-model="formData.total_investment" clearable placeholder="请输入总投资(元)" type="number" />
</el-form-item>
</el-col>
<el-col :span="8">
@ -76,8 +74,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="合同金额">
<el-input v-model="formData.contract_amount" clearable placeholder="请输入合同金额"
type="number" />
<el-input v-model="formData.contract_amount" clearable placeholder="请输入合同金额" type="number" />
</el-form-item>
</el-col>
<el-col :span="8">
@ -101,14 +98,14 @@
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="咨询开始日期">
<el-form-item label="咨询开始日期" prop="consult_start_date">
<el-date-picker class="flex-1 !flex" v-model="formData.consult_start_date" clearable
value-format="YYYY-MM-DD" placeholder="选择咨询开始日期">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="咨询结束日期">
<el-form-item label="咨询结束日期" prop="consult_end_date">
<el-date-picker class="flex-1 !flex" v-model="formData.consult_end_date" clearable
value-format="YYYY-MM-DD" placeholder="选择咨询结束日期">
</el-date-picker>
@ -116,8 +113,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="工程状态" prop="engineering_status">
<el-select class="flex-1" v-model="formData.engineering_status" clearable
placeholder="请选择建设区域">
<el-select class="flex-1" v-model="formData.engineering_status" clearable placeholder="请选择建设区域">
<el-option v-for="(item, index) in dictData.engineering_status" :key="index"
:label="item.name" :value="item.value" />
</el-select>
@ -126,14 +122,14 @@
<el-col :span="8">
<el-form-item label="咨询类型" prop="consult_type">
<el-select class="flex-1" v-model="formData.consult_type" clearable placeholder="请选择建设区域">
<el-option v-for="(item, index) in dictData.consult_type" :key="index"
:label="item.name" :value="item.value" />
<el-option v-for="(item, index) in dictData.consult_type" :key="index" :label="item.name"
:value="item.value" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="联系电话">
<el-form-item label="联系电话" prop="telephone">
<el-input v-model="formData.telephone" clearable placeholder="请输入联系电话" />
</el-form-item>
</el-col>
@ -170,8 +166,7 @@
<el-col :span="8">
<el-form-item label="项目归档">
<el-checkbox-group v-model="formData.project_archiving">
<el-checkbox :label="item.value" :key="i"
v-for="(item, i) in dictData.project_archiving">
<el-checkbox :label="item.value" :key="i" v-for="(item, i) in dictData.project_archiving">
{{ item.name }}
</el-checkbox>
</el-checkbox-group>
@ -194,8 +189,8 @@
</el-col>
<el-col :span="8">
<el-form-item label="创建时间" prop="create_time">
<el-date-picker class="flex-1 !flex" v-model="formData.create_time" clearable
type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="选择创建时间">
<el-date-picker class="flex-1 !flex" v-model="formData.create_time" clearable type="datetime"
value-format="YYYY-MM-DD HH:mm:ss" placeholder="选择创建时间">
</el-date-picker>
</el-form-item>
</el-col>
@ -214,6 +209,9 @@ import { apiConsultProjectAdd, apiConsultProjectEdit, apiConsultProjectDetail }
import { timeFormat } from '@/utils/util'
import type { PropType } from 'vue'
import useUserStore from "@/stores/modules/user";
import { checkPhone } from "@/utils/validate"
const userStore = useUserStore().userInfo;
defineProps({
@ -271,6 +269,15 @@ const formData = reactive({
})
const chekcDate = (rule: any, value: any, callback: any) => {
if (new Date(formData.consult_end_date) < new Date(formData.consult_start_date)) {
callback(new Error('咨询结束日期不能早于咨询开始日期'))
} else {
callback()
}
}
//
const formRules = reactive<any>({
project_name: [{
@ -362,7 +369,13 @@ const formRules = reactive<any>({
required: true,
message: '请输入咨询结束日期',
trigger: ['blur']
}],
},
{
validator: chekcDate,
trigger: ["blur"],
},
],
engineering_status: [{
required: true,
message: '请输入工程状态',
@ -377,7 +390,12 @@ const formRules = reactive<any>({
required: true,
message: '请输入联系电话',
trigger: ['blur']
}],
},
{
validator: checkPhone,
trigger: ["blur"],
},
],
consult_user: [{
required: true,
message: '请输入委托联系人',

View File

@ -36,9 +36,9 @@
:value="row.business_nature" />
</template>
</el-table-column>
<el-table-column label="合同签订金额" prop="money" show-overflow-tooltip width="120" />
<el-table-column label="甲方签约单位" prop="part_a" show-overflow-tooltip width="120" />
<el-table-column label="签订部门" prop="dept" show-overflow-tooltip width='90' />
<el-table-column label="合同签订金额" prop="money" show-overflow-tooltip width="120" />
<el-table-column label="已开票金额" prop="total_invoice_amount" show-overflow-tooltip />
<el-table-column label="已到账金额" prop="total_refund_amount" show-overflow-tooltip />
<el-table-column label="已结算金额" prop="total_settlement_amount" show-overflow-tooltip />

View File

@ -43,7 +43,7 @@
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="备注" prop="remark">
<el-form-item label="备注">
<el-input v-model="formData.remark" clearable placeholder="请输入备注" type="textarea" />
</el-form-item>
</el-col>
@ -53,7 +53,6 @@
</el-form-item>
</el-col>
<createUserLable flag :formData="formData" />
</el-row>
</el-form>
<el-col :span="24">

View File

@ -36,6 +36,10 @@ const detailConfig = {
},
{
label: "预算分成金额",
value: 'amount',
},
{
label: "结算金额",
value: 'settlement_amount',
},
{

View File

@ -47,7 +47,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="开票编号" prop="invoice_code">
<el-form-item label="开票编号">
<el-input v-model="formData.invoice_code" clearable placeholder="系统自动生成" disabled />
</el-form-item>
</el-col>

View File

@ -235,6 +235,7 @@ const tableConfig = reactive(
{
label: "关联发票",
value: 'invoice',
type: 'number'
},

View File

@ -38,11 +38,11 @@
</el-form-item>
</el-col>
</el-row>
<formTable :formData="formData.contacts" :config="tableConfig"></formTable>
</el-form>
<el-dialog v-model="showDialog" title="选择项目" width="70%">
<dialogTable @customEvent="customEvent" :config="manage_project" />
</el-dialog>
<formTable :formData="formData.contacts" :config="tableConfig"></formTable>
</popup>
</div>
@ -53,7 +53,7 @@ import type { FormInstance } from 'element-plus'
import Popup from '@/components/popup/index.vue'
import { apiManageCompanyAdd, apiManageCompanyEdit, apiManageCompanyDetail, apimanage_company_contacts, apimanage_company_contacts_delete } from '@/api/manage_company'
import { manage_project } from "@/components/dialogTable/dialogTableConfig"
import { checkPhone } from "@/utils/validate"
import { checkPhone, checkEmail } from "@/utils/validate"
import type { PropType } from 'vue'
defineProps({
@ -108,10 +108,13 @@ const tableConfig = reactive(
{
label: "手机号码",
value: 'mobile',
check: true
},
{
label: "电子邮箱",
value: 'email',
check: true
},
{
label: "传真",
@ -164,6 +167,23 @@ const formRules = reactive<any>({
trigger: ['blur']
}
],
mobile: [
{
required: true,
message: '请输入联sd系电话',
trigger: ['blur']
},
{
validator: checkPhone,
trigger: ['blur']
}
],
email: [
{
validator: checkEmail,
trigger: ['blur']
}
],
duty: [{
required: true,
message: '请输入责任范围',

View File

@ -18,7 +18,7 @@
<el-input v-model="formData.position" clearable placeholder="请输入变更及洽商部位" />
</el-form-item>
<el-form-item label="图纸号" prop="drawing_number">
<el-input v-model="formData.drawing_number" clearable placeholder="请输入图纸号" />
<el-input v-model="formData.drawing_number" clearable placeholder="请输入图纸号" v-type="'code'" />
</el-form-item>
<el-form-item label="变更及洽商概述" prop="overview">
<el-input v-model="formData.overview" clearable placeholder="请输入变更及洽商概述" />

View File

@ -1,7 +1,7 @@
<template>
<div class="edit-popup">
<popup ref="popupRef" :title="popupTitle" :async="true" width="550px" @confirm="handleSubmit" @close="handleClose">
<el-form ref="formRef" :model="formData" label-width="120px" :rules="formRules">
<el-form ref="formRef" :model="formData" label-width="130px" :rules="formRules">
<el-form-item label="项目名称" prop="project_name">
<el-input v-model="formData.project_name" clearable placeholder="点击选择项目" readonly
@click="showDialog = true" />

View File

@ -143,7 +143,7 @@
<el-col :span="8">
<el-form-item label="关联合同" prop="contract">
<el-input v-model="formData.contract" clearable placeholder="请输入关联合同" />
<el-input v-model="formData.contract" clearable placeholder="请输入关联合同" v-type="'code'" />
</el-form-item>
</el-col>
<el-col :span="8">

View File

@ -2,7 +2,7 @@
<div class="edit-popup">
<popup ref="popupRef" :async="true" width="80vw" @close="handleClose">
<el-form ref="formRef" :model="formData" label-width="100px">
<el-descriptions column="3" title="工程监理--巡视登记详情" border>
<el-descriptions column="3" title="工程监理--验收登记详情" border>
<el-descriptions-item label="项目名称" label-align="left" align="left">
{{ formData.project_name }}
</el-descriptions-item>

View File

@ -1,7 +1,6 @@
<template>
<div class="edit-popup">
<popup ref="popupRef" :title="popupTitle" :async="true" width="80vw" @confirm="handleSubmit"
@close="handleClose">
<popup ref="popupRef" :title="popupTitle" :async="true" width="80vw" @confirm="handleSubmit" @close="handleClose">
<el-form ref="formRef" :model="formData" label-width="120px" :rules="formRules">
<el-row>
<el-col :span="8">
@ -37,14 +36,14 @@
</el-col>
<el-col :span="8">
<el-form-item label="验收位置" prop="accept_position">
<el-input v-model="formData.accept_position" clearable placeholder="请输入施工人数" />
<el-input v-model="formData.accept_position" clearable placeholder="请输入验收位置" />
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="验收时间" prop="accept_time" label-width="120px">
<el-date-picker class="flex-1 !flex" v-model="formData.accept_time" clearable
type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="选择验收时间">
<el-date-picker class="flex-1 !flex" v-model="formData.accept_time" clearable type="datetime"
value-format="YYYY-MM-DD HH:mm:ss" placeholder="选择验收时间">
</el-date-picker>
</el-form-item>
</el-col>
@ -72,7 +71,7 @@
</el-col>
<el-col :span="8">
<el-form-item label="备注" prop="remark">
<el-form-item label="备注">
<el-input v-model="formData.remark" clearable placeholder="请输入备注" type="textarea" />
</el-form-item>
</el-col>
@ -98,9 +97,9 @@
<div v-if="showDialog2">
<el-dialog v-model="showDialog2" width=" 70%" title="选择施工单位">
<dialogTable :config="supervision_participating_units" :query="{
project_id: formData.project_id,
unit_type: 6
}" @customEvent="customEvent1">
project_id: formData.project_id,
unit_type: 6
}" @customEvent="customEvent1">
</dialogTable>
</el-dialog>
</div>
@ -139,7 +138,7 @@ const flag = ref(false)
//
const popupTitle = computed(() => {
return mode.value == 'edit' ? '编辑工程监理--巡视登记' : '新增工程监理--巡视登记'
return mode.value == 'edit' ? '编辑工程监理--验收登记' : '新增工程监理--验收登记'
})

View File

@ -149,7 +149,7 @@ const tableConfig = reactive(
},
],
deleteApi: apisupervision_problem_delete,
deleteApi: apisupervision_problem_delete
}
)
@ -169,7 +169,15 @@ const customEvent1 = (e) => {
}
//
const chekcDate = (rule: any, value: any, callback: any) => {
if (new Date(formData.end_time) < new Date(formData.start_time)) {
callback(new Error('结束时间不能早于开始时间'))
} else {
callback()
}
}
const formRules = reactive<any>({
project_id: [{
required: true,
@ -200,10 +208,14 @@ const formRules = reactive<any>({
required: true,
message: '请输入结束时间',
trigger: ['blur']
}],
},
{
validator: chekcDate,
trigger: ["blur"],
},],
result: [{
required: true,
message: '请输入检验结果 0-符合标准 1-不符合标准',
message: '请输入检验结果',
trigger: ['blur']
}],
remark: [{

View File

@ -22,12 +22,12 @@
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="单位工程" prop="check_item_name">
<el-input v-model="formData.check_item_name" clearable placeholder="点击选择单位工程" readonly
@click="showDialog1 = true, flag = false" />
@click="showDialog1 = true, flag = false" class="!flex flex-1" />
<ToolTip content="可在监理工作新增检查项添加节点类型为单位工程的节点"
url="/supervision/supervision_work/supervision_check_item"></ToolTip>
</el-form-item>
</el-col>
<el-col :span="8">
@ -40,8 +40,6 @@
<el-input v-model="formData.workers" clearable placeholder="请输入施工人数" type="number" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="管理人数" prop="managers">
<el-input v-model="formData.managers" clearable placeholder="请输入管理人数" type="number" />
@ -61,8 +59,6 @@
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="巡视人员" prop="inspection_user">
<el-input v-model="formData.inspection_user" clearable placeholder="请输入巡视人员" />
@ -79,8 +75,6 @@
<el-input v-model="formData.inspection_content" clearable placeholder="请输入巡视内容" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="设置重点关注" prop="is_importent">
<el-select v-model="formData.is_important" clearable placeholder="请选择" class="flex-1">
@ -100,8 +94,6 @@
@click="showDialog1 = true, flag = true" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="附件" prop="annex">
<uploadAnnex :formData="formData"></uploadAnnex>

View File

@ -1,7 +1,6 @@
<template>
<div class="edit-popup">
<popup ref="popupRef" :title="popupTitle" :async="true" width="80vw" @confirm="handleSubmit"
@close="handleClose">
<popup ref="popupRef" :title="popupTitle" :async="true" width="80vw" @confirm="handleSubmit" @close="handleClose">
<el-form ref="formRef" :model="formData" label-width="120px" :rules="formRules">
<el-row>
<el-col :span="8">
@ -146,6 +145,17 @@ const customEvent1 = (e) => {
formData.company_name = e.project_name
showDialog2.value = false
}
const chekcDate = (rule: any, value: any, callback: any) => {
if (new Date(formData.issue_date) > new Date(formData.reply_date)) {
callback(new Error('下达日期早于要求回复日期'))
} else {
callback()
}
}
//
const formRules = reactive<any>({
project_id: [{
@ -177,7 +187,12 @@ const formRules = reactive<any>({
required: true,
message: '请输入下达日期',
trigger: ['blur']
}],
},
{
validator: chekcDate,
trigger: ['blur']
}
],
rectification_reply_time: [{
required: true,
message: '请输入整改回复时间',

View File

@ -99,6 +99,13 @@ const formData = reactive({
contacts: [],
});
//
function checkPhone1(rules: any, value: any, callback: any) {
console.log(value)
}
const tableConfig = reactive(
{
title: "联系人",
@ -120,13 +127,12 @@ const tableConfig = reactive(
{
label: "手机号码",
value: 'mobile',
check: true
check: ['contacts', checkPhone]
},
{
label: "电子邮箱",
value: 'email',
check: true
check: ['contacts', checkEmail]
},
{
label: "传真",
@ -143,6 +149,7 @@ const customEvent = (e) => {
showDialog.value = false;
};
//
const formRules = reactive<any>({
project_id: [
@ -184,20 +191,6 @@ const formRules = reactive<any>({
trigger: ["blur"],
},
],
mobile: [
{
validator: checkPhone,
trigger: ["blur"],
},
],
email: [
{
validator: checkEmail,
trigger: ["blur"],
},
],
duty: [
{

View File

@ -21,7 +21,7 @@ const detailConfig = {
{
label: "附件",
value: "annex",
value: "rectification_annex",
column: 1
},

View File

@ -144,7 +144,7 @@ import Popup from '@/components/popup/index.vue'
import { apiSupervisionSafetyManagementPersonnelAdd, apiSupervisionSafetyManagementPersonnelEdit, } from '@/api/supervision_safety_management_personnel'
import { supervision_participating_units_qualifications } from "@/components/dialogTable/dialogTableConfig"
import type { PropType } from 'vue'
import { checkIdcard } from "@/utils/validate"
import { checkIdcard, checkPhone } from "@/utils/validate"
defineProps({
@ -161,14 +161,6 @@ const showDialog1 = ref(false)
const handleAvatarSuccess_four = (response: any) => {
if (!Array.isArray(formData.annex)) formData.annex = []
// @ts-ignore
response.code != 0 ? formData.annex.push({ uri: response.data.uri, name: response.data.name }) : ElMessage.error(response.msg);
};
//
const delFileFn = (index: number) => { formData.annex.splice(index, 1) }
//
const popupTitle = computed(() => {
@ -211,6 +203,25 @@ const customEvent1 = (e) => {
showDialog1.value = false
}
const chekcDate = (rule: any, value: any, callback: any) => {
if (new Date(formData.effective_date_one) < new Date(formData.get_date_one)) {
callback(new Error('有效日期不能早于发证时间'))
} else {
callback()
}
}
const chekcDate1 = (rule: any, value: any, callback: any) => {
if (new Date(formData.effective_date_two) < new Date(formData.get_date_two)) {
callback(new Error('有效日期不能早于发证时间'))
} else {
callback()
}
}
//
const formRules = reactive<any>({
project_id: [{
@ -273,6 +284,10 @@ const formRules = reactive<any>({
required: true,
message: '请输入有效日期1',
trigger: ['blur']
},
{
validator: chekcDate,
trigger: ['blur']
}],
qualification_one_status: [{
required: true,
@ -293,6 +308,10 @@ const formRules = reactive<any>({
required: true,
message: '请输入资质编号2',
trigger: ['blur']
},
{
validator: chekcDate1,
trigger: ['blur']
}],
get_date_two: [{
required: true,

View File

@ -1,7 +1,6 @@
<template>
<div class="edit-popup">
<popup ref="popupRef" :title="popupTitle" :async="true" width="550px" @confirm="handleSubmit"
@close="handleClose">
<popup ref="popupRef" :title="popupTitle" :async="true" width="550px" @confirm="handleSubmit" @close="handleClose">
<el-form ref="formRef" :model="formData" label-width="90px" :rules="formRules">
<el-form-item label="项目名称" prop="project_name">
<el-input v-model="formData.project_name" clearable placeholder="点击选择项目" readonly
@ -11,8 +10,8 @@
<el-input v-model="formData.check_user" clearable placeholder="请输入检查人" />
</el-form-item>
<el-form-item label="检查日期" prop="check_date">
<el-date-picker class="flex-1 !flex" v-model="formData.check_date" clearable
value-format="YYYY-MM-DD" placeholder="选择检查日期">
<el-date-picker class="flex-1 !flex" v-model="formData.check_date" clearable value-format="YYYY-MM-DD"
placeholder="选择检查日期">
</el-date-picker>
</el-form-item>
<el-form-item label="检查地点" prop="check_area">
@ -21,10 +20,10 @@
<el-form-item label="问题描述" prop="problem_desc">
<el-input v-model="formData.problem_desc" clearable placeholder="请输入问题描述" />
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-form-item label="备注">
<el-input v-model="formData.remark" clearable placeholder="请输入备注" />
</el-form-item>
<el-form-item label="附件" prop="annex">
<el-form-item label="附件">
<uploadAnnex :formData="formData"></uploadAnnex>
</el-form-item>

View File

@ -105,6 +105,17 @@ const chekcDate = (rule: any, value: any, callback: any) => {
}
}
const chekcDate1 = (rule: any, value: any, callback: any) => {
if (new Date(formData.enter_time) > new Date(formData.validity_period)) {
callback(new Error('请在资格有效期内进场'))
} else {
callback()
}
}
const customEvent1 = (e) => {
formData.unit_qualification_id = e.id
formData.company_name = e.company_name
@ -144,6 +155,10 @@ const formRules = reactive<any>({
required: true,
message: '请输入进场时间',
trigger: ['blur']
},
{
validator: chekcDate1,
trigger: ['blur']
}],
leave_time: [{
required: true,
@ -156,7 +171,7 @@ const formRules = reactive<any>({
}],
status: [{
required: true,
message: '请输入状态 0-有效 1-无效',
message: '请选择状态',
trigger: ['blur']
}],
remark: [{

View File

@ -46,7 +46,7 @@
<el-table-column label="状态" prop="status_text" show-overflow-tooltip />
<el-table-column label="备注" prop="remark" show-overflow-tooltip />
<el-table-column label="创建人" prop="create_user" show-overflow-tooltip />
<el-table-column label="操作" width="120" fixed="right">
<el-table-column label="操作" width="170" fixed="right">
<template #default="{ row }">
<el-button
v-perms="['supervision_qualification_review.supervision_special_operation_personnel/edit']"

View File

@ -168,6 +168,17 @@ const customEvent1 = (e) => {
formData.company_name = e.unit_name
showDialog2.value = false
}
const chekcDate = (rule: any, value: any, callback: any) => {
if (new Date(formData.end_date) < new Date(formData.start_date)) {
callback(new Error('结束日期不能早于开始日期'))
} else {
callback()
}
}
//
const formRules = reactive<any>({
project_id: [{
@ -209,6 +220,10 @@ const formRules = reactive<any>({
required: true,
message: '请输入结束日期',
trigger: ['blur']
},
{
validator: chekcDate,
trigger: ['blur']
}],
test_result: [{
required: true,

View File

@ -70,7 +70,7 @@
<el-table-column label="结束日期" prop="end_date" show-overflow-tooltip />
<el-table-column label="试验结果" prop="test_result_text" show-overflow-tooltip />
<el-table-column label="备注" prop="remark" show-overflow-tooltip />
<el-table-column label="操作" fixed="right" align="center">
<el-table-column label="操作" fixed="right" align="center" width="170px">
<template #default="{ row }">
<el-button v-perms="['supervision_work.supervision_test_blocks_specimens/edit']" type="primary"

View File

@ -2,9 +2,9 @@
<div class="edit-popup">
<popup ref="popupRef" :title="popupTitle" :async="true" width="550px" @confirm="handleSubmit" @close="handleClose">
<el-form ref="formRef" :model="formData" label-width="90px" :rules="formRules">
<el-form-item label="标识" prop="dataid">
<!-- <el-form-item label="标识" prop="dataid">
<el-input v-model="formData.dataid" clearable placeholder="请输入" />
</el-form-item>
</el-form-item> -->
<el-form-item label="所属项目" prop="cost_project_id">
<el-select v-model="formData.cost_project_id" remote filterable :remote-method="queryCostProject"
:loading="loading" class="flex-1">

View File

@ -44,7 +44,7 @@
<el-table border :data="pager.lists" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" />
<el-table-column label="所属项目" prop="project_name" show-overflow-tooltip />
<el-table-column label="标识" prop="dataid" show-overflow-tooltip />
<!-- <el-table-column label="标识" prop="dataid" show-overflow-tooltip /> -->
<el-table-column label="任务编号" prop="num" show-overflow-tooltip />
<el-table-column label="任务名称" prop="name" show-overflow-tooltip />
<el-table-column label="上级类别" prop="superior_sort" show-overflow-tooltip>