舱单弹窗

szh-new
lijingjia 4 months ago
parent 5f99ad50ca
commit 7a79138839

@ -0,0 +1,218 @@
<!--
* @Author: lijj
* @Date: 2024-05-06 09:18:47
* @Description: 邮件发送弹窗组件
-->
<template>
<div>
<a-modal
class="ds-form-detail ds-modal-small"
v-model:visible="visible"
v-if="visible"
title="邮件发送"
width="640px"
:maskClosable="false"
>
<a-spin :spinning="loading">
<div>
<a-form
layout="vertical"
autocomplete="off"
class="ant-form-small"
>
<div class="flex" style="justify-content: space-between;">
<a-form-item
label="关键字"
>
<a-input v-model:value="name" @keyup.enter="search" style="width: 400px;"></a-input>
</a-form-item>
<div>
<a-button @click="reset"> </a-button>
<a-button @click="search" type="primary"> </a-button>
</div>
</div>
</a-form>
</div>
<div>
<h4>模版</h4>
</div>
<a-row :gutter="10">
<a-col :span="12" v-for="item in modelData" class="mb10" :key="item.id">
<div class="model-card">
<span class="tem-name">
{{ item.templateName }}
</span>
<span class="flex flex-btns">
<dl @click="toPrint(item.id, '1')">
<dt><img src="../../assets/images/PDF2.png" alt=""></dt>
<dd>pdf</dd>
</dl>
<dl @click="toPrint(item.id, '2', item.name)">
<dt><img src="../../assets/images/xksx2.png" alt=""></dt>
<dd>xlsx</dd>
</dl>
<dl @click="toPrint(item.id, '3')">
<dt><img src="../../assets/images/DOC2.png" alt=""></dt>
<dd>doc</dd>
</dl>
</span>
</div>
</a-col>
</a-row>
<div v-show="!modelData.length" class="no-data">
<span class="iconfont icon-wushuju" :style="{ fontSize: '50px' }"></span>
<div class="mb10">暂无数据</div>
</div>
</a-spin>
<template #footer>
</template>
</a-modal>
</div>
</template>
<script lang="ts" setup name="DsPrint">
import { ref, defineExpose, defineProps } from 'vue'
import { GetOpenPrintTemplateList, GetOpenJsonPrintInfo } from '/@/views/operation/seaexport/api/BookingLedger.js'
import { useMessage } from '/@/hooks/web/useMessage'
const { createMessage } = useMessage()
const props = defineProps({
// idid
id: {
type: String,
default: null
}
})
//
const name = ref()
//
const visible = ref(false)
const loading = ref(false)
//
const type = ref('1')
//
const modelData = ref([])
//
const jsonDataStr = ref()
//
const sourceData = ref([])
// (list)
const init = (v) => {
visible.value = true
if (v) jsonDataStr.value = JSON.stringify(v)
loading.value = true
GetOpenPrintTemplateList({ id: props.id }).then(r => {
loading.value = false
//
modelData.value = r.data
sourceData.value = JSON.parse(JSON.stringify(r.data))
}).catch(() => {
loading.value = false
})
}
//
const reset = () => {
name.value = null
modelData.value = sourceData.value
}
//
const search = () => {
if (!name.value) return reset()
const source = JSON.parse(JSON.stringify(sourceData.value))
modelData.value = source.filter(item => {
return item.templateName.includes(name.value)
})
}
const handleOk = () => {
visible.value = false
}
const handleCancel = () => {
visible.value = false
}
//
const toPrint = (id, type, name) => {
const postData = {
jsonDataStr: jsonDataStr.value,
printType: type,
templateId: id
}
loading.value = true
GetOpenJsonPrintInfo(postData).then(res => {
loading.value = false
if (!res.succeeded) {
createMessage.error(res.message)
} else {
let fileURL = `http://60.209.125.238:3009/PrintTempFile/${res.data}`
if (type == 1) {
window.open(fileURL)
} else {
window.open(`//60.209.125.238:3009/PrintTempFile/${res.data}`, '_blank')
}
}
})
}
defineExpose({
init
})
</script>
<style lang="less">
.ds-print {
.message {
font-size: 12px;
color: #f05;
}
.tem-name {
font-size: 12px;
color: #7A8798;
}
.ant-spin-container {
min-height: 270;
}
.model-card {
padding: 10px;
background: #F5F9FC;
border-radius: 2px;
border-left: 1px solid #257AFA;
display: flex;
justify-content: space-between;
align-items: center;
}
.ant-modal-footer {
display: none;
}
.ant-btn {
width: 80px;
margin-left: 10px;
margin-top: 25px;
}
h4 {
margin: 16px 0 13px;
}
dt {
img {
width: 16px;
height: 18px;
}
}
dd {
font-size: 10px;
margin: 0;
color: #257AFA;
}
dl {
margin: 0 10px 0 7px;
cursor: pointer;
}
.flex-btns {
position: relative;
top: 2px;
}
.no-data {
text-align: center;
color: #7A8798;
}
}
</style>

@ -24,7 +24,7 @@
} }
&-title { &-title {
font-size: 16px; font-size: 12px;
font-weight: bold; font-weight: bold;
.base-title { .base-title {
@ -33,8 +33,7 @@
} }
.ant-modal-body { .ant-modal-body {
padding: 20; padding: 0 30px;
> .scrollbar > .scrollbar__bar.is-horizontal { > .scrollbar > .scrollbar__bar.is-horizontal {
display: none; display: none;
} }
@ -107,9 +106,6 @@
} }
} }
.ant-modal-confirm .ant-modal-body {
padding: 24px !important;
}
@media screen and (max-height: 600px) { @media screen and (max-height: 600px) {
.ant-modal { .ant-modal {
top: 60px; top: 60px;

@ -33,6 +33,14 @@
} }
} }
} }
.vben-basic-table {
.ant-table-wrapper {
padding: 0;
}
.ant-table-title {
padding: 8px 0!important;
}
}
} }
.ant-modal-footer { .ant-modal-footer {
border-top: none!important; border-top: none!important;

@ -9,12 +9,6 @@
} }
.ant-table-wrapper { .ant-table-wrapper {
padding: 0!important; padding: 0!important;
.ant-table-title {
padding: 0;
}
.ant-table-title {
padding: 5px 10px!important;
}
} }
.ant-table-selection-column { .ant-table-selection-column {
border-right: 1px solid rgba(232, 232, 232, 1) !important; border-right: 1px solid rgba(232, 232, 232, 1) !important;

@ -40,6 +40,10 @@
<!-- 合同管理 --> <!-- 合同管理 -->
<CustTemplateDetail :client-id="clientId" :customer-name="customerName" class="RUnit" /> <CustTemplateDetail :client-id="clientId" :customer-name="customerName" class="RUnit" />
</a-tab-pane> </a-tab-pane>
<a-tab-pane key="8" tab="客户参数">
<!-- 客户参数表格 -->
<CustomerParams :client-id="clientId" :customer-name="customerName"></CustomerParams>
</a-tab-pane>
</a-tabs> </a-tabs>
<!-- 图片管理 --> <!-- 图片管理 -->
@ -89,6 +93,7 @@
import Menus3 from './menu3/index.vue' import Menus3 from './menu3/index.vue'
import Menus4 from './menu4/index.vue' import Menus4 from './menu4/index.vue'
import CustTemplateDetail from './custTemplateDetail/index.vue' import CustTemplateDetail from './custTemplateDetail/index.vue'
import CustomerParams from './customerParams/index.vue'
import { number } from 'vue-types' import { number } from 'vue-types'
// import Menus5 from './menu5/index.vue' // import Menus5 from './menu5/index.vue'
// import { tr } from 'node_modules/element-plus/es/locale' // import { tr } from 'node_modules/element-plus/es/locale'
@ -183,8 +188,6 @@
activeKey.value = '2' activeKey.value = '2'
const res: API.DataResult = await getCodeGoodsTypeInfo({ id: unref(rowId) }) const res: API.DataResult = await getCodeGoodsTypeInfo({ id: unref(rowId) })
if (res.succeeded) { if (res.succeeded) {
console.log(res, 11111111)
clientId.value = res.data.id clientId.value = res.data.id
customerName.value = res.data.shortName customerName.value = res.data.shortName
res.data.ArrclientTag = [] res.data.ArrclientTag = []

@ -0,0 +1,56 @@
/*
* @Description:
* @Author: lijj
* @Date: 2024-04-25 15:48:33
*/
import { request } from '/@/utils/request'
import { DataResult, PageRequest } from '/@/api/model/baseModel'
enum Api {
list = '/mainApi/ClientParam/GetClientParamList',
edit = '/mainApi/ClientParam//EditClientParam',
info = '/mainApi/ClientParam/GetClientParamInfo',
delete = '/mainApi/ClientParam/BatchDelClientParam',
GetTenantParamDataSelectList = '/mainApi/ClientParam/GetTenantParamDataSelectList'
}
// 列表 (Auth)
export function GetClientParamList(data: PageRequest) {
return request<DataResult>({
url: Api.list,
method: 'post',
data
})
}
// 编辑 (Auth)
export function EditClientParam(data: PageRequest) {
return request<DataResult>({
url: Api.edit,
method: 'post',
data
})
}
// 详情 (Auth)
export function GetClientParamInfo(query) {
return request<DataResult>({
url: Api.info,
method: 'get',
params: query
})
}
// 删除 (Auth)
export function BatchDelClientParam(data: PageRequest) {
return request<DataResult>({
url: Api.delete,
method: 'post',
data
})
}
export function GetTenantParamDataSelectList(query) {
return request<DataResult>({
url: Api.GetTenantParamDataSelectList,
method: 'get',
params: query
})
}

@ -0,0 +1,165 @@
/*
* @Description:
* @Author: lijj
* @Date: 2024-04-25 15:48:33
*/
import { ref } from 'vue'
import { BasicColumn, FormSchema } from '/@/components/Table'
// 引入字典数据
import { getDictOption } from '/@/utils/dictUtil'
import { useOptionsStore } from '/@/store/modules/options'
import { GetTenantParamDataSelectList } from './api'
const optionsStore = useOptionsStore()
const itemNameOption = ref([])
// 模块字典
const modulesDict = await getDictOption('modules')
export const columns: BasicColumn[] = [
{
title: '客户名称',
dataIndex: 'customerName',
width: 150
},
{
title: '客户参数类型',
dataIndex: 'paramType',
width: 150
},
{
title: '客户参数名称',
dataIndex: 'paramName',
width: 200
},
{
title: '备注',
dataIndex: 'note',
width: 200
}
]
export const searchFormSchema: FormSchema[] = [
{
field: 'paramName',
label: '客户参数名称',
colProps: { span: 6 },
component: 'Input'
},
]
export const formSchema: FormSchema[] = [
{
label: '',
field: 'id',
component: 'Input',
defaultValue: '',
show: false
},
{
field: 'paramCode',
label: '客户参数类别',
required: true,
component: 'ApiSelect',
colProps: { span: 12 },
componentProps: ({ formModel }) => {
return {
option: optionsStore.getOptionsByCode('GetTenantParamSelectList'),
labelField: 'paramName',
valueField: 'paramCode',
filterOption: (input: string, option: any) => {
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0
},
onChange: (e, obj) => {
GetTenantParamDataSelectList({ code: e }).then(res => {
itemNameOption.value = res.data
})
if (obj) {
formModel.paramName = obj.label
formModel.paramId = obj.id
formModel.paramType = obj.type
} else {
formModel.paramName = ''
formModel.paramId = ''
formModel.paramType = ''
}
}
}
}
},
{
field: 'itemCode',
label: '客户参数名称',
required: true,
component: 'ApiSelect',
colProps: { span: 12 },
componentProps: ({ formModel }) => {
return {
option: itemNameOption.value,
labelField: 'itemName',
valueField: 'itemCode',
filterOption: (input: string, option: any) => {
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0
},
onChange: (e, obj) => {
if (obj) {
formModel.itemName = obj.label
} else {
formModel.itemName = ''
}
}
}
}
},
{
label: '',
field: 'itemName',
component: 'Input',
defaultValue: '',
show: false
},
{
label: '',
field: 'customerId',
component: 'Input',
defaultValue: '',
show: false
},
{
label: '',
field: 'paramId',
component: 'Input',
defaultValue: '',
show: false
},
{
label: '',
field: 'paramName',
component: 'Input',
defaultValue: '',
show: false
},
{
label: '',
field: 'paramType',
component: 'Input',
defaultValue: '',
show: false
},
{
field: 'customerName',
label: '客户名称',
dynamicDisabled: true,
component: 'Input',
colProps: { span: 12 }
},
{
field: 'orderNo',
label: '排序',
required: true,
component: 'Input',
colProps: { span: 12 }
},
{
field: 'note',
label: '备注',
component: 'InputTextArea',
colProps: { span: 24 }
}
]

@ -0,0 +1,113 @@
<template>
<BasicModal
v-bind="$attrs"
:use-wrapper="true"
:title="getTitle"
:form-schema="formSchema"
width="50%"
@register="registerModal"
@ok="handleSave"
>
<!-- 包装表单 -->
<BasicForm @register="registerForm" />
<!--右下角按钮-->
<template #footer>
<a-button
pre-icon="ant-design:close-outlined"
type="warning"
:loading="loading"
ghost
style="margin-right: 0.8rem"
@click="closeModal"
>
取消
</a-button>
<a-button
type="success"
:loading="loading"
pre-icon="ant-design:check-outlined"
style="margin-right: 0.8rem"
@click="handleSave(false)"
>
仅保存
</a-button>
<a-button
pre-icon="ant-design:check-circle-outlined"
type="primary"
:loading="loading"
@click="handleSave(true)"
>
保存并关闭
</a-button>
</template>
</BasicModal>
</template>
<script lang="ts" setup>
import { ref, computed, unref } from 'vue'
//
import { BasicModal, useModalInner } from '/@/components/Modal'
import { BasicForm, useForm } from '/@/components/Form/index'
//
import { formSchema } from '../columns'
//
import { EditClientParam, GetClientParamInfo } from '../api'
//
import { useMessage } from '/@/hooks/web/useMessage'
// Emits
const emit = defineEmits(['success', 'register'])
const isUpdate = ref(true)
// loading
const loading = ref(false)
const rowId = ref('')
const { createMessage } = useMessage()
const [registerForm, { resetFields, setFieldsValue, validate, updateSchema }] =
useForm({
labelWidth: 100,
schemas: formSchema,
showActionButtonGroup: false,
})
const [registerModal, { setModalProps, closeModal, updateFormField }] = useModalInner(async (data) => {
resetFields()
setModalProps({ confirmLoading: false, loading: true })
isUpdate.value = !!data?.isUpdate
if (unref(isUpdate)) {
setModalProps({ confirmLoading: true });
updateFormField(updateSchema)
rowId.value = data.record.id
const res: API.DataResult = await GetClientParamInfo({ id: unref(rowId) })
if (res.succeeded) {
setFieldsValue({
...res.data,
})
}
} else {
setFieldsValue({
customerId: data.clientId,
customerName: data.customerName
})
}
setModalProps({ loading: false })
})
const getTitle = computed(() => (!unref(isUpdate) ? '新增' : '编辑'))
async function handleSave(exit) {
try {
const values = await validate()
loading.value = true
setModalProps({ confirmLoading: true, loading: true })
const res: API.DataResult = await EditClientParam(values)
loading.value = false
if (res.succeeded) {
createMessage.success(res.message)
emit('success')
} else {
createMessage.error(res.message)
}
exit && closeModal()
} finally {
setModalProps({ confirmLoading: false, loading: false })
}
}
</script>

@ -0,0 +1,125 @@
<template>
<div>
<BasicTable
@register="registerTable"
>
<template #toolbar>
<a-button type="link" @click="handleCreate">
<span class="iconfont icon-tianjia"></span>
新建
</a-button>
</template>
<template #bodyCell="{ column, record }">
<template v-if="column.key === 'action'">
<TableAction
:actions="[
{
icon: 'clarity:note-edit-line',
tooltip: '编辑',
onClick: handleEdit.bind(null, record),
},
{
icon: 'ant-design:delete-outlined',
tooltip: '删除',
color: 'error',
popConfirm: {
title: '是否要删除此条数据?',
okText: '是',
cancelText: '否',
confirm: handleDelete.bind(null, record)
}
}
]"
/>
</template>
</template>
</BasicTable>
<Modal @register="registerModal" @success="handleSuccess" />
</div>
</template>
<script lang="ts" setup>
import { onMounted, defineProps } from 'vue'
import { BasicTable, useTable, TableAction } from '/@/components/Table'
import { formatParams } from '/@/hooks/web/common'
import { GetClientParamList, BatchDelClientParam } from './api'
import { useModal } from '/@/components/Modal'
import Modal from './components/Modal.vue'
import { columns, searchFormSchema } from './columns'
import { useMessage } from '/@/hooks/web/useMessage'
const { notification } = useMessage()
const [registerModal, { openModal }] = useModal()
const props = defineProps({
// id
clientId: {
type: String
},
//
customerName: {
type: String
}
})
const [registerTable, { reload, getForm, getPaginationRef }] = useTable({
api: async (p) => {
const res: API.DataResult = await GetClientParamList(p)
return new Promise((resolve) => {
resolve({ data: [...res.data], total: res.count })
})
},
beforeFetch: (p) => {
return formatParams(p)
},
columns,
isTreeTable: false,
pagination: true,
striped: true,
useSearchForm: false,
showTableSetting: false,
bordered: true,
showIndexColumn: true,
canResize: false,
actionColumn: {
width: 80,
title: '操作',
dataIndex: 'action',
fixed: 'right',
},
id: 10
})
function handleCreate() {
openModal(true, {
customerName: props.customerName,
clientId: props.clientId,
isUpdate: false
})
}
function handleEdit(record: Recordable) {
openModal(true, {
record,
isUpdate: true,
customerName: props.customerName,
clientId: props.clientId
})
}
//
async function handleDelete(record: Recordable) {
const res: API.DataResult = await BatchDelClientParam({
id: '',
ids: [record.id],
})
if (res.succeeded) {
notification.success({ message: res.message, duration: 3 })
reload()
} else {
notification.error({ message: res.message, duration: 3 })
}
}
onMounted(() => {
//
})
function handleSuccess() {
reload()
}
</script>

@ -21,13 +21,24 @@
onClick: handleAudit.bind(null, record), onClick: handleAudit.bind(null, record),
disabled: checkPermissions('op:infoclient:edit'), disabled: checkPermissions('op:infoclient:edit'),
}, },
{
icon: 'ant-design:delete-outlined',
tooltip: '删除',
color: 'error',
popConfirm: {
title: '是否要删除此条数据?',
okText: '是',
cancelText: '否',
confirm: handleDelete.bind(null, record)
}
}
]" ]"
/> />
</template> </template>
</template> </template>
</BasicTable> </BasicTable>
<TenantAuditStepModal @register="registerModal" @success="handleSuccess" /> <TenantAuditStepModal @register="registerModal" @success="handleSuccess" />
<a-modal <!-- <a-modal
:visible="visible" :visible="visible"
title="往来单位信息" title="往来单位信息"
width="70%" width="70%"
@ -35,7 +46,7 @@
@cancel="handleCancel" @cancel="handleCancel"
> >
<ImportFlow v-if="visible" ref="refImportFlow" /> <ImportFlow v-if="visible" ref="refImportFlow" />
</a-modal> </a-modal> -->
</div> </div>
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
@ -47,7 +58,7 @@
import TenantAuditStepModal from './TenantAuditStepModal.vue' import TenantAuditStepModal from './TenantAuditStepModal.vue'
import { columns, searchFormSchema, formSchema } from './columns' import { columns, searchFormSchema, formSchema } from './columns'
import { useMessage } from '/@/hooks/web/useMessage' import { useMessage } from '/@/hooks/web/useMessage'
const { notification } = useMessage() const { createMessage } = useMessage()
let filterInfo: Partial<Recordable<string[]>> = [] let filterInfo: Partial<Recordable<string[]>> = []
let sortInfo: SorterResult = {} let sortInfo: SorterResult = {}
const visible = ref<boolean>(false) const visible = ref<boolean>(false)
@ -130,25 +141,16 @@
}) })
} }
// const handleOk = async () => { //
// let ids = [] async function handleDelete(record: Recordable) {
// refImportFlow.value.getSelectData().forEach((e) => { const res: API.DataResult = await BatchDelClientParam({
// ids.push(e.id) id: '',
// }) ids: [record.id],
// const res: API.DataResult = await importCodeGoodsType({ })
// ids, if (res.succeeded) {
// id: '', createMessage.success(res.message)
// }) reload()
// if (res.succeeded) { }
// notification.success({ message: res.message, duration: 3 })
// } else {
// notification.error({ message: res.message, duration: 3 })
// }
// reload()
// visible.value = false
// }
const handleCancel = () => {
visible.value = false
} }
function handleAudit(record: Recordable) { function handleAudit(record: Recordable) {
if (!checkPermissions('op:infoclient:edit')) { if (!checkPermissions('op:infoclient:edit')) {

@ -1990,11 +1990,11 @@ export function GetBusinessOrderContactList(data) {
} }
// 委托单位联系人编辑 // 委托单位联系人编辑
export function EditBusinessOrderContact(params) { export function EditBusinessOrderContact(data) {
return request({ return request({
url: '/opApi/BusinessOrderContact/EditBusinessOrderContact', url: '/opApi/BusinessOrderContact/EditBusinessOrderContact',
method: 'get', method: 'post',
params data
}) })
} }

@ -711,7 +711,6 @@ export const formSchema: FormSchema[] = [
label: '截港日期', label: '截港日期',
field: 'closingDate', field: 'closingDate',
component: 'DatePicker', component: 'DatePicker',
defaultValue: null,
colProps: { colProps: {
span: 8, span: 8,
}, },

@ -3,20 +3,25 @@
v-bind="$attrs" v-bind="$attrs"
:use-wrapper="true" :use-wrapper="true"
:title="getTitle" :title="getTitle"
:form-schema="personFormSchema"
width="50%" width="50%"
class="person-modal"
@register="registerModal" @register="registerModal"
@ok="handleSave" @ok="handleSave"
> >
<!-- 包装表单 --> <!-- 包装表单 -->
<BasicForm @register="registerForm"> <BasicForm @register="registerForm">
<template #service="item"> <template #customerContactId="data">
<a-select show-search v-model:value="item.opid" <a-select
:default-active-first-option="false" :show-arrow="false" allowClear v-model:value="data.values.customerContactId"
:filter-option="false" :not-found-content="null" :default-active-first-option="false"
:show-arrow="false"
allowClear
:filter-option="false"
:not-found-content="null"
@change="personChange"
> >
<a-select-option v-for="item in personList" :key="item.id" :value="item.id"> <a-select-option v-for="item in personList" :label="item.shortName" :key="item.id" :value="item.id">
{{ item.userName }} {{ item.shortName }}
</a-select-option> </a-select-option>
</a-select> </a-select>
</template> </template>
@ -24,31 +29,18 @@
<!--右下角按钮--> <!--右下角按钮-->
<template #footer> <template #footer>
<a-button <a-button
pre-icon="ant-design:close-outlined"
type="warning"
:loading="loading" :loading="loading"
ghost
style="margin-right: 0.8rem" style="margin-right: 0.8rem"
@click="closeModal" @click="closeModal"
> >
取消 取消
</a-button> </a-button>
<a-button <a-button
type="success"
:loading="loading"
pre-icon="ant-design:check-outlined"
style="margin-right: 0.8rem"
@click="handleSave(false)"
>
仅保存
</a-button>
<a-button
pre-icon="ant-design:check-circle-outlined"
type="primary" type="primary"
:loading="loading" :loading="loading"
@click="handleSave(true)" @click="handleSave(true)"
> >
保存并关闭 保存
</a-button> </a-button>
</template> </template>
</BasicModal> </BasicModal>
@ -116,7 +108,13 @@
}) })
const getTitle = computed(() => (!unref(isUpdate) ? '新增' : '编辑')) const getTitle = computed(() => (!unref(isUpdate) ? '新增' : '编辑'))
//
const personChange = (e, obj) => {
setFieldsValue({
customerContactId: e,
name: obj.label
})
}
async function handleSave(exit) { async function handleSave(exit) {
try { try {
const values = await validate() const values = await validate()
@ -127,8 +125,6 @@
if (res.succeeded) { if (res.succeeded) {
createMessage.success(res.message) createMessage.success(res.message)
emit('success') emit('success')
} else {
createMessage.error(res.message)
} }
exit && closeModal() exit && closeModal()
} finally { } finally {

@ -725,7 +725,7 @@ export const basicInfoFormSchema: FormSchema[] = [
{ {
label: '订舱代理', label: '订舱代理',
field: 'forwarderId', field: 'forwarderId',
labelSlot: 'forwarder', labelSlot: 'forwarderId',
component: 'ApiSelect', component: 'ApiSelect',
required: false, required: false,
dynamicDisabled: false, dynamicDisabled: false,
@ -2673,31 +2673,25 @@ export const otherInfoFormSchema: FormSchema[] = [
// 关系人表单 // 关系人表单
export const personFormSchema: FormSchema[] = [ export const personFormSchema: FormSchema[] = [
{ {
field: 'service', field: 'id',
label: '',
component: 'Input',
show: false
},
{
field: 'customerContactId',
label: '联系人', label: '联系人',
component: 'ApiSelect', component: 'ApiSelect',
required: false, required: false,
dynamicDisabled: false, dynamicDisabled: false,
slot: 'service', slot: 'customerContactId',
// defaultValue: '',
colProps: { span: 12 }, colProps: { span: 12 },
// componentProps: () => { },
// return { {
// api: GetOrderContact, field: 'name',
// params: { label: '',
// id: '' component: 'Input',
// }, show: false
// allowClear: true,
// showSearch: true,
// labelField: 'enName',
// resultField: 'data',
// valueField: 'id',
// immediate: false,
// filterOption: (input: string, option: any) => {
// return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0
// },
// }
// }
}, },
{ {
label: '邮箱', label: '邮箱',
@ -2707,7 +2701,7 @@ export const personFormSchema: FormSchema[] = [
}, },
{ {
label: '电话', label: '电话',
field: 'email', field: 'tel',
component: 'Input', component: 'Input',
colProps: { span: 12 }, colProps: { span: 12 },
}, },
@ -2775,6 +2769,18 @@ export const personColumns: BasicColumn[] = [
sorter: true, sorter: true,
width: 120, width: 120,
}, },
{
dataIndex: 'customerTypeName',
title: '客户类别',
sorter: true,
width: 120,
},
{
dataIndex: 'customerName',
title: '客户名称',
sorter: true,
width: 140,
},
{ {
dataIndex: 'note', dataIndex: 'note',
title: '备注', title: '备注',

@ -11,7 +11,7 @@
:isTransfer="true" :isTransfer="true"
name="基础表单" name="基础表单"
id="0" id="0"
formNo="0" formNo="10"
ref="RefChilrenRef" ref="RefChilrenRef"
> >
<a-button type="link"> <a-button type="link">
@ -24,24 +24,24 @@
<template #customerId="item"> <template #customerId="item">
<span class="iconfont icon-tuandui" @click="openPersonModal(item, '委托单位', 'customerId')"></span> <span class="iconfont icon-tuandui" @click="openPersonModal(item, '委托单位', 'customerId')"></span>
</template> </template>
<!-- <template #truckerId> <template #truckerId="item">
<span class="iconfont icon-tuandui" @click="openPersonModal"></span> <span class="iconfont icon-tuandui" @click="openPersonModal(item, '车队', 'truckerId')"></span>
</template> </template>
<template #carrierId> <template #carrierId="item">
<span class="iconfont icon-tuandui" @click="openPersonModal"></span> <span class="iconfont icon-tuandui" @click="openPersonModal(item, '船公司', 'carrierId')"></span>
</template> </template>
<template #forwarder> <template #forwarderId="item">
<span class="iconfont icon-tuandui" @click="openPersonModal"></span> <span class="iconfont icon-tuandui" @click="openPersonModal(item, '订舱代理', 'forwarderId')"></span>
</template> </template>
<template #shipAgencyId> <template #shipAgencyId="item">
<span class="iconfont icon-tuandui" @click="openPersonModal"></span> <span class="iconfont icon-tuandui" @click="openPersonModal(item, '船代', 'shipAgencyId')"></span>
</template>
<template #yardId="item">
<span class="iconfont icon-tuandui" @click="openPersonModal(item, '场站', 'yardId')"></span>
</template>
<template #customserId="item">
<span class="iconfont icon-tuandui" @click="openPersonModal(item, '报关行', 'customserId')"></span>
</template> </template>
<template #yardId>
<span class="iconfont icon-tuandui" @click="openPersonModal"></span>
</template> -->
<!-- <template #customserId>
<span class="iconfont icon-tuandui" @click="openPersonModal"></span>
</template> -->
<template #isBusinessLocking="item"> <template #isBusinessLocking="item">
<a-input disabled :value="item.isBusinessLocking ? '已锁定' : '未锁定'"></a-input> <a-input disabled :value="item.isBusinessLocking ? '已锁定' : '未锁定'"></a-input>
<span v-if="item.isBusinessLocking" class="iconfont icon-chenggong"></span> <span v-if="item.isBusinessLocking" class="iconfont icon-chenggong"></span>
@ -83,8 +83,8 @@
/> />
</template> </template>
</template> </template>
<template #footer></template>
</BasicTable> </BasicTable>
<template #footer></template>
</a-modal> </a-modal>
<PersonModal @register="registerModal" @success="handleSuccess" /> <PersonModal @register="registerModal" @success="handleSuccess" />
</div> </div>
@ -146,7 +146,18 @@
isTreeTable: false, isTreeTable: false,
pagination: true, pagination: true,
striped: true, striped: true,
useSearchForm: false, formConfig: {
labelWidth: 120,
schemas: [
{
label: '联系人',
field: 'name',
component: 'Input',
colProps: { span: 4 }
}
]
},
useSearchForm: true,
showTableSetting: false, showTableSetting: false,
bordered: true, bordered: true,
showIndexColumn: true, showIndexColumn: true,
@ -178,6 +189,7 @@
let companyType = '' let companyType = ''
// //
const openPersonModal = (item, type, field) => { const openPersonModal = (item, type, field) => {
console.log(item)
if (item?.values[field]) { if (item?.values[field]) {
companyId = item.values[field] companyId = item.values[field]
} else { } else {

@ -3033,7 +3033,7 @@
.pre-order { .pre-order {
margin-left: -15px; margin-left: -15px;
margin-right: -3px; margin-right: -3px;
margin-top: -8px; padding-top: 30px;
} }
.order-btn-list { .order-btn-list {

Loading…
Cancel
Save