Merge branch 'ljj_dev' into dev

szh-new
lijingjia 3 months ago
commit a5b093f368

@ -187,7 +187,7 @@
}
function handleChange(_, ...args) {
// emit('change', _, ...args)
emit('change', _, ...args)
emitData.value = args
}
const getPopupContainer = triggerNode => {

@ -151,7 +151,8 @@
? rulesMessageJoinLabel
: globalRulesMessageJoinLabel
const defaultMsg = createPlaceholderMessage(component) + `${joinLabel ? label : ''}`
async function validator(rule: any, value: any) {
function validator(rule: any, value: any) {
const msg = rule.message || defaultMsg
if (value === undefined || isNull(value)) {
//
@ -186,12 +187,12 @@
*/
if (getRequired) {
if (!rules || rules.length === 0) {
// rules = [{ required: getRequired, validator }]
rules = [{ required: getRequired, validator }]
} else {
const requiredIndex: number = rules.findIndex((rule) => Reflect.has(rule, 'required'))
if (requiredIndex === -1) {
// rules.push({ required: getRequired, validator })
rules.push({ required: getRequired, validator })
}
}
}

@ -1,3 +1,8 @@
/*
* @Desc:
* @Author: lijj
* @Date: 2024-05-13 09:06:51
*/
import type { UnwrapRef, Ref, WritableComputedRef, DeepReadonly } from 'vue'
import {
reactive,
@ -50,9 +55,9 @@ export function useRuleFormItem<T extends Recordable>(
if (isEqual(value, defaultState.value)) return
innerState.value = value as T[keyof T]
nextTick(() => {
emit?.(changeEvent, value, ...(toRaw(unref(emitData)) || []))
})
// nextTick(() => {
// emit?.(changeEvent, value, ...(toRaw(unref(emitData)) || []))
// })
},
})

@ -5,6 +5,7 @@
-->
<template>
<a-spin :spinning="logLoading">
<h4 v-if="logList.length"></h4>
<a-timeline style="margin-left: 89px; margin-top: 20px;">
<a-timeline-item v-for="item in logList" :key="item.id">
<div style="position: relative;">

@ -90,7 +90,7 @@
loading.value = true
BringInBookingSlotToOrder({ seaExportId: props.id, slots }).then(res => {
// createMessage.success(res.data)
emit('createTask', 'WAIT_SPACE_RELEASE')
// emit('createTask', 'WAIT_SPACE_RELEASE')
visible.value = false
loading.value = false
}).catch(() => {

@ -242,6 +242,7 @@ export const basicInfoFormSchema: FormSchema[] = [
resultField: 'data',
immediate: false,
onChange: (e, obj) => {
console.log(obj)
if (e && obj) {
formModel.carrierId = obj.id
}
@ -631,9 +632,9 @@ export const mailingInfoFormSchemaR: FormSchema[] = [
field: 'etd',
label: '开船日期',
component: 'DatePicker',
required: false,
rules: [{ required: true, message: '请选择开船日期' }],
dynamicDisabled: false,
// defaultValue: '',
defaultValue: undefined,
colProps: { span: 5 },
componentProps: {
allowClear: true,
@ -644,9 +645,8 @@ export const mailingInfoFormSchemaR: FormSchema[] = [
field: 'closingDate',
label: '截港时间',
component: 'DatePicker',
required: false,
dynamicDisabled: false,
// defaultValue: '',
defaultValue: null,
colProps: { span: 5 },
componentProps: {
showTime: true,
@ -658,9 +658,8 @@ export const mailingInfoFormSchemaR: FormSchema[] = [
field: 'closeDocDate',
label: '截单时间',
component: 'DatePicker',
required: false,
dynamicDisabled: false,
// defaultValue: '',
defaultValue: null,
colProps: { span: 5 },
componentProps: {
showTime: true,
@ -910,7 +909,6 @@ export const mailingInfoFormSchemaR: FormSchema[] = [
valueField: 'ediCode',
immediate: false,
onChange: (e, obj) => {
console.log(obj)
if (e && obj) {
formModel.transPortId = obj.id
formModel.transPort = obj.portName

@ -92,7 +92,7 @@
import { useRoute } from 'vue-router'
import { Divider } from 'ant-design-vue';
//
// import { updateFormItem } from '/@/hooks/web/common'
import { updateFormItem } from '/@/hooks/web/common'
const route = useRoute()
//
const source = ref(route.query.source || 'edit')
@ -119,8 +119,7 @@
showActionButtonGroup: false,
size: 'small',
})
console.log(basicInfoFormSchema)
// updateFormItem(updateSchema, 10)
updateFormItem(updateSchema, 10)
setTimeout(() => {
console.log(basicInfoFormSchema)
}, 100)

@ -87,7 +87,6 @@
cargoInfoFormSchema3,
cargoInfoFormSchema4,
} from './baseInfo'
console.log(cargoInfoFormSchema2)
import { ref, watch, onMounted, computed } from 'vue'
import { useRoute } from 'vue-router'
import { getDictOption } from '/@/utils/dictUtil'

@ -58,19 +58,16 @@
</span>
</div>
</a-spin>
<div class="line"></div>
<div class="line" v-show="booGoodsStatusItem.length"></div>
<a-spin :spinning="spinning" :delay="delayTime">
<div style="min-height: 60px; overflow: hidden;">
<div style="min-height: 60px; overflow: hidden;" v-show="booGoodsStatusItem.length">
<div
v-for="(serive, sindex) in booGoodsStatusItem"
class="goods-status"
:class="{ isBr: changeGoods && serive.isBr }"
:key="`${serive.configId}_${sindex}`"
>
<span v-if="(sindex - 3) % 4 != 0" style="position: absolute; right: 8px; color: #257AFA;">···</span>
<div class="edit-box" @click.stop="FnOpenEdit(serive)">
<Icon icon="ant-design:edit-outlined" />
</div>
<span v-if="(sindex - 3) % 4 != 0" style="position: absolute; right: -5px; color: #257AFA;">···</span>
<a-tooltip>
<template v-if="(serive.actDate || serive.actRemark) && !serive.isBr" #title>
<p v-if="serive.actDate">{{ serive.actDate }}</p>
@ -105,6 +102,7 @@
<div v-else class="round" @click="saveGoodsStatus(serive)"></div>
<div class="showName" :class="{ 'show-name-active': serive.isYield }">
{{ serive.showName }}
<span @click.stop="FnOpenEdit(serive)" class="edit-box iconfont icon-bianji1"></span>
</div>
</div>
</div>
@ -289,7 +287,6 @@
</a-card> -->
<div class="card" style="padding-bottom: 15px;">
<Divider type="horizontal" />
<h4>日志</h4>
<!-- 日志组件 -->
<DsJournal :id="id" />
</div>
@ -1269,10 +1266,13 @@
}
.goods-status {
display: inline-block;
width: 25%;
width: 20%;
height: 70px;
position: relative;
float: left;
.goods-content {
text-align: center;
}
}
.no-data {
img {
@ -1281,33 +1281,35 @@
}
}
.is-yield {
width: 46px;
height: 26px;
background: #257AFA;
width: 22px;
height: 22px;
background: #17A6A3;
text-align: center;
color: #ffffff;
border-radius: 15px;
line-height: 26px;
line-height: 22px;
margin: 0 auto;
span {
font-size: 18px!important;
margin-right: 0;
}
}
.showName {
margin-top: 5px!important;
font-size: 12px!important;
color: #7A8798;
width: 48px;
text-align: center;
margin: 0 auto;
line-height: 14px;
}
.show-name-active {
font-weight: 600;
}
.edit-box {
display: none;
position: absolute;
right: 4px;
bottom: 23px;
color: #257AFA;
cursor: pointer;
}
.goods-status:hover {
.edit-box {
@ -1315,10 +1317,11 @@
}
}
.round {
width: 46px;
height: 26px;
width: 22px;
height: 22px;
border-radius: 15px;
border: 2px solid #E8EBED;
margin: 0 auto;
}
.isBr {
display: none;

@ -15,8 +15,8 @@ enum Api {
info = '/mainApi/PrintTemplate/GetSysPrintModuleInfo',
delete = '/mainApi/ClientParam/BatchDelClientParam',
GetTenantParamDataSelectList = '/mainApi/ClientParam/GetTenantParamDataSelectList',
GetOpenSqlPrintInfo = '/printApi/OpenPrint/GetOpenSqlPrintInfo'
GetOpenSqlPrintInfo = '/printApi/OpenPrint/GetOpenSqlPrintInfo',
DownLoadSqlPrintFile = '/printApi/OpenPrint/DownLoadSqlPrintFile'
}
// 模版列表 (Auth)
export function GetSysPrintTemplateList(data) {
@ -69,7 +69,7 @@ export function GetSysPrintTemplateInfo(params) {
})
}
// 删除 (Auth)
// sql打印模版
export function GetOpenSqlPrintInfo(data: PageRequest) {
return request<DataResult>({
url: Api.GetOpenSqlPrintInfo,
@ -86,7 +86,7 @@ export function GetTenantParamDataSelectList(query) {
})
}
// sql打印模版
// 删除 (Auth)
export function BatchDelClientParam(data: PageRequest) {
return request<DataResult>({
url: Api.delete,
@ -94,3 +94,12 @@ export function BatchDelClientParam(data: PageRequest) {
data
})
}
// 下载打印源文件
export function DownLoadSqlPrintFile(data: PageRequest) {
return request<DataResult>({
url: Api.DownLoadSqlPrintFile,
method: 'post',
data
})
}

@ -253,7 +253,17 @@ export const temFormSchema: FormSchema[] = [
label: ' ',
slot: 'sqlModel',
component: 'Input',
colProps: { span: 12 },
colProps: { span: 6 },
show: ({ values }) => {
return values.isUseDataSource && values.id
}
},
{
field: 'downModel',
label: ' ',
slot: 'downModel',
component: 'Input',
colProps: { span: 6 },
show: ({ values }) => {
return values.isUseDataSource && values.id
}

@ -15,6 +15,9 @@
<template #sqlModel="{ model }">
<a-button key="submit" type="primary" :loading="loading" @click="sqlPrint(model)">sql</a-button>
</template>
<template #downModel="{ model }">
<a-button key="submit" type="primary" :loading="loading" @click="sqlDownLoad(model)">sql</a-button>
</template>
</BasicForm>
<!--右下角按钮-->
<template #footer>
@ -57,7 +60,7 @@
//
import { temFormSchema } from '../columns'
//
import { EditSysPrintTemplate, GetSysPrintTemplateInfo, GetOpenSqlPrintInfo } from '../api'
import { EditSysPrintTemplate, GetSysPrintTemplateInfo, GetOpenSqlPrintInfo, DownLoadSqlPrintFile } from '../api'
//
import { useMessage } from '/@/hooks/web/useMessage'
// Emits
@ -93,10 +96,26 @@
}
setModalProps({ loading: false })
})
//
const sqlDownLoad = (model) => {
const userStore = useUserStore()
if (!model.inParamColumn) {
return createMessage.warning('请先填写入口参数!')
}
const postData = {
"tenantId": userStore.getUserInfo.tenantId,
"templateId": model.id,
"paramJsonStr": model.inParamColumn,
"printType": "1"
}
DownLoadSqlPrintFile(postData).then(res => {
if (res.succeeded) {
console.log(res)
}
})
}
// sql
const sqlPrint = (model) => {
console.log(model)
const userStore = useUserStore()
if (!model.inParamColumn) {
return createMessage.warning('请先填写入口参数!')
@ -109,6 +128,7 @@
}
GetOpenSqlPrintInfo(postData).then(res => {
if (res.succeeded) {
window.open(`http://118.190.144.189:3008/printtempfile/${res.data}`)
return createMessage.success('打印成功!')
}
})

Loading…
Cancel
Save