页面调整

This commit is contained in:
zhuangdashia 2025-09-03 00:34:05 +08:00
parent 59cb123198
commit 3d4547d165
5 changed files with 128 additions and 9 deletions

View File

@ -47,9 +47,8 @@ async function getDeptIdOptions(){
}
}
function handleDeptUpdate(value: string, option: CommonType.Option<CommonType.IdType>) {
model.value.branchId = value;
// model.value.branchName = option.label;
model.value.branchName = option.label;
}
</script>

View File

@ -218,6 +218,7 @@ const {
title: '日期',
align: 'center',
minWidth: 120,
fixed: 'right',
ellipsis: true,
resizable: true
},

View File

@ -1,7 +1,8 @@
<script setup lang="ts">
import { ref } from 'vue';
import {onMounted, ref} from 'vue';
import { useNaiveForm } from '@/hooks/common/form';
import { $t } from '@/locales';
import {fetchGetDeptBranchIdSelect} from "@/service/api/system";
defineOptions({
name: 'ManualPricingSearch'
@ -30,6 +31,25 @@ async function search() {
await validate();
emit('search');
}
onMounted(() => {
getDeptIdOptions()
});
const deptIdOptions = ref<CommonType.Option<CommonType.IdType>[]>([]);
//
async function getDeptIdOptions(){
const { error, data } = await fetchGetDeptBranchIdSelect();
if (!error) {
deptIdOptions.value = data.map(item => ({
label: item.deptName,
value: item.deptCategory
}));
}
}
function handleDeptUpdate(value: string, option: CommonType.Option<CommonType.IdType>) {
model.value.branch = option.label;
}
</script>
<template>
@ -39,7 +59,15 @@ async function search() {
<NForm ref="formRef" :model="model" label-placement="left" :label-width="80">
<NGrid responsive="screen" item-responsive>
<NFormItemGi span="24 s:12 m:6" label="支行" path="branch" class="pr-24px">
<NInput v-model:value="model.branch" placeholder="请输入支行" />
<!-- <NInput v-model:value="model.branch" placeholder="请输入支行" />-->
<NSelect
v-model:value="model.branch"
filterable
placeholder="选择支行"
:options="deptIdOptions"
clearable
@update:value="handleDeptUpdate"
/>
</NFormItemGi>
<!-- <NFormItemGi span="24 s:12 m:6" label="员工身份证号" path="idcardNo" class="pr-24px">-->
<!-- <NInput v-model:value="model.idcardNo" placeholder="请输入员工身份证号" />-->

View File

@ -1,7 +1,9 @@
<script setup lang="ts">
import { ref } from 'vue';
import {onMounted, reactive, ref, watch} from 'vue';
import { useNaiveForm } from '@/hooks/common/form';
import { $t } from '@/locales';
import {fetchGetDeptBranchIdSelect, fetchGetDeptSelect, fetchGetDeptUserList} from "@/service/api/system";
import dayjs from "dayjs";
defineOptions({
name: 'PerformanceSearch'
@ -30,6 +32,44 @@ async function search() {
await validate();
emit('search');
}
onMounted(() => {
getDeptIdOptions()
});
const deptIdOptions = ref<CommonType.Option<CommonType.IdType>[]>([]);
const operatorIdOptions = ref<CommonType.Option<CommonType.IdType>[]>([]);
//
async function getDeptIdOptions(){
const { error, data } = await fetchGetDeptBranchIdSelect();
if (!error) {
deptIdOptions.value = data.map(item => ({
label: item.deptName,
value: item.deptCategory
}));
}
}
function handleDeptUpdate(value: string, option: CommonType.Option<CommonType.IdType>) {
model.value.branchId = value;
model.value.branchName = option.label;
}
async function getoperatorIdOptions() {
const { error, data } = await fetchGetDeptUserList(<string | number>model.value.branchId);
if (!error) {
operatorIdOptions.value = data.map(item => ({
label: item.nickName,
value: item.mktNo
}));
}
}
function handleYxNameUpdate(value: string, option: CommonType.Option<CommonType.IdType>) {
model.value.marketerCode = value;
model.value.marketerName = option.label;
}
</script>
<template>
@ -39,13 +79,30 @@ async function search() {
<NForm ref="formRef" :model="model" label-placement="left" :label-width="80">
<NGrid responsive="screen" item-responsive>
<NFormItemGi span="24 s:12 m:6" label="单位" path="branchName" class="pr-24px">
<NInput v-model:value="model.branchName" placeholder="单位" />
<!-- <NInput v-model:value="model.branchName" placeholder="单位" />-->
<NSelect
v-model:value="model.branchName"
filterable
placeholder="选择支行"
:options="deptIdOptions"
clearable
@update:value="handleDeptUpdate"
/>
</NFormItemGi>
<!-- <NFormItemGi span="24 s:12 m:6" label="单位id" path="branchId" class="pr-24px">-->
<!-- <NInput v-model:value="model.branchId" placeholder="请输入单位id" />-->
<!-- </NFormItemGi>-->
<NFormItemGi span="24 s:12 m:6" label="姓名" path="marketerName" class="pr-24px">
<NInput v-model:value="model.marketerName" placeholder="请输入经办人员姓名" />
<!-- <NSelect-->
<!-- v-model:value="model.marketerName"-->
<!-- filterable-->
<!-- placeholder="选择营销人员"-->
<!-- :options="operatorIdOptions"-->
<!-- clearable-->
<!-- @update:value="handleYxNameUpdate"-->
<!-- />-->
</NFormItemGi>
<!-- <NFormItemGi span="24 s:12 m:6" label="经办人员身份证号" path="marketerIdCard" class="pr-24px">-->
<!-- <NInput v-model:value="model.marketerIdCard" placeholder="请输入经办人员身份证号" />-->

View File

@ -1,7 +1,9 @@
<script setup lang="ts">
import { ref } from 'vue';
import {onMounted, ref} from 'vue';
import { useNaiveForm } from '@/hooks/common/form';
import { $t } from '@/locales';
import {fetchGetDeptBranchIdSelect} from "@/service/api/system";
import {useDict} from "@/hooks/business/dict";
defineOptions({
name: 'ValidInvalidSearch'
@ -30,6 +32,28 @@ async function search() {
await validate();
emit('search');
}
const {options: reportValidInvalidOptions} = useDict('report_valid_invalid');
onMounted(() => {
getDeptIdOptions()
});
const deptIdOptions = ref<CommonType.Option<CommonType.IdType>[]>([]);
//
async function getDeptIdOptions(){
const { error, data } = await fetchGetDeptBranchIdSelect();
if (!error) {
deptIdOptions.value = data.map(item => ({
label: item.deptName,
value: item.deptCategory
}));
}
}
function handleDeptUpdate(value: string, option: CommonType.Option<CommonType.IdType>) {
// model.value.branchId = value;
model.value.branchName = option.label;
}
</script>
<template>
@ -39,7 +63,15 @@ async function search() {
<NForm ref="formRef" :model="model" label-placement="left" :label-width="80">
<NGrid responsive="screen" item-responsive>
<NFormItemGi span="24 s:12 m:6" label="支行名称" path="branchName" class="pr-24px">
<NInput v-model:value="model.branchName" placeholder="请输入支行名称" />
<!-- <NInput v-model:value="model.branchName" placeholder="请输入支行名称" />-->
<NSelect
v-model:value="model.branchName"
filterable
placeholder="选择支行"
:options="deptIdOptions"
clearable
@update:value="handleDeptUpdate"
/>
</NFormItemGi>
<NFormItemGi span="24 s:12 m:6" label="员工姓名" path="employeeName" class="pr-24px">
<NInput v-model:value="model.employeeName" placeholder="请输入员工姓名" />
@ -60,7 +92,9 @@ async function search() {
<!-- <NInput v-model:value="model.validBusiness" placeholder="请输入有效的中间业务计价项目" />-->
<!-- </NFormItemGi>-->
<NFormItemGi span="24 s:12 m:6" label="标识" path="checkFlag" class="pr-24px">
<NInput v-model:value="model.checkFlag" placeholder="请输入有效无效标识" />
<!-- <NInput v-model:value="model.checkFlag" placeholder="请输入有效无效标识" />-->
<NSelect v-model:value="model.checkFlag" :options="reportValidInvalidOptions" placeholder="请选择有效无效标识" />
</NFormItemGi>
<NFormItemGi span="24 s:12 m:6" label="记录月份" path="recordMonth" class="pr-24px">
<NInput v-model:value="model.recordMonth" placeholder="请输入记录月份" />