我的任务 - 订舱详情lara登记

dev
lilu 2 years ago
parent 68d797d826
commit 6ad6a0ae56

@ -95,7 +95,7 @@
<% for (var i in htmlWebpackPlugin.options.cdn && htmlWebpackPlugin.options.cdn.css) { %>
<link rel="stylesheet" href="<%= htmlWebpackPlugin.options.cdn.css[i] %>" />
<% } %>
<link rel="stylesheet" href="//at.alicdn.com/t/c/font_3756681_4cwmrpk5p89.css" />
<link rel="stylesheet" href="//at.alicdn.com/t/c/font_3756681_4vmbyasfc5t.css" />
<!-- 1.8K仔百度收录 -->
<meta name="baidu-site-verification" content="code-QVfBYJ5laQ" />
</head>

@ -128,7 +128,7 @@ export function DownloadAttach (parameter) {
return axios({
url: '/TaskManage/DownloadAttach',
method: 'post',
data: parameter
data: parameter
})
}
@ -144,12 +144,23 @@ export function GetBookingOrderInfo (parameter) {
}
/**
* lara 记录
* lara 记录 -- 有问题
*/
export function LaraPaperRegistPost (parameter) {
return axios({
url: '/TaskManage/LaraPaperRegistPost',
method: 'post',
data: parameter
data: parameter
})
}
/**
* 发送SI
*/
export function SendShippingOrder (parameter) {
return axios({
url: '/TaskManage/SendShippingOrder',
method: 'get',
params: parameter
})
}

@ -0,0 +1,34 @@
// 封装到一个js文件里面避免使用时代码累赘
import { message } from 'ant-design-vue';
/*
h: 是content自带的参数表示createElement
content文本内容
*/
const createElementVNode = (h, content) => {
// 定义文本内容及样式(这里的样式延用的官方的)
const innerText = h('span', { style: { color: '#4a5970', fontSize: '14px' } }, content);
// 自定义关闭图标
const innerIcon = h('a-icon', {
style: { marginLeft: '10px', color: '#ccc', cursor: 'pointer' },
attrs: { type: 'close' },
on: { click: () => message.destroy() },
});
// 合到一个 VNode 节点中
const container = h('span', {}, [innerText, innerIcon]);
// 最终返回
return container;
};
// 由于 message 有多种状态,这里需要额外处理
const dtMessage = {};
// 给 dtMessage 循环赋值不同类型的 message函数
['error', 'success', 'info', 'warning', 'warn'].forEach((type) => {
dtMessage[type] = (content, duration, onClose) => {
// 处理 message[type](config) 参数为对象类型
if (typeof content === 'object') {
return message[type]({ ...content, content: h => createElementVNode(h, content?.content) });
}
return message[type](h => createElementVNode(h, content), duration, onClose);
};
});
export default dtMessage;

@ -29,7 +29,9 @@ const constantRouterComponents = {
BookingDetailNew: () => import('@/views/main/BookingLedgerNew/detail'),
CustomerInformationManagementAdd: () => import('@/views/main/Customer/addForm'),
CustomerInformationManagementEdit: () => import('@/views/main/Customer/editForm'),
TaskmanageDetail: () => import('@/views/main/Taskmanage/TaskmanageDetail')
TaskmanageDetail: () => import('@/views/main/Taskmanage/TaskmanageDetail'),
TaskLaraRecord: () => import('@/views/main/Taskmanage/TaskLaraRecord'),
TaskLaraRegist: () => import('@/views/main/Taskmanage/TaskLaraRegist')
}
// 前端未找到页面路由(固定不用改)、原来为 /404
@ -153,6 +155,28 @@ const userAccount = [
show: false
},
component: 'TaskmanageDetail'
},
{
name: 'TaskLaraRecord',
path: '/commontaskmanage/TaskLaraRecord',
pid: 0,
id: 183184,
meta: {
title: 'LARA 提单纸登记记录',
show: false
},
component: 'TaskLaraRecord'
},
{
name: 'TaskLaraRegist',
path: '/commontaskmanage/TaskLaraRegist',
pid: 0,
id: 183185,
meta: {
title: 'LARA提单纸登记',
show: false
},
component: 'TaskLaraRegist'
}
]

@ -1478,7 +1478,7 @@ export default {
}
</style>
<style lang="less">
<style lang="less" scoped>
@import url('../index.less');
.from-label {

@ -1219,7 +1219,7 @@ export default {
}
}
</script>
<style lang="less">
<style lang="less" scoped>
/*.ant-layout{
background: #f4f4f4;
}*/

@ -1328,7 +1328,7 @@ export default {
}
}
</script>
<style lang="less">
<style lang="less" scoped>
.Showtabs {
> .ant-tabs-top-bar {
display: none;

@ -1433,7 +1433,7 @@ export default {
}
</style>
<style lang="less">
<style lang="less" scoped>
@import url('../index.less');
.from-label {

@ -1449,7 +1449,7 @@ export default {
}
}
</script>
<style lang="less">
<style lang="less" scoped>
.from-line {
display: flex;
margin: 0 0 20px 0;

@ -1219,7 +1219,7 @@ export default {
}
}
</script>
<style lang="less">
<style lang="less" scoped>
/*.ant-layout{
background: #f4f4f4;
}*/

@ -475,7 +475,7 @@ export default {
}
}
</script>
<style scoped lang="less">
<style scoped lang="less" scoped>
.CsForm {
background: #fff;
padding: 25px;

@ -0,0 +1,27 @@
<template>
<div class="lara-regist">
<div class="btn-list">
<a-button>导出</a-button>
</div>
<div class="table-box">
<!-- <a-table :columns="boxColumns" :data-source="taskDetail.contaList">
<span slot="seq" slot-scope="seq">{{ Number(seq) + 1 }}</span>
</a-table> -->
</div>
</div>
</template>
<script>
import { XCard } from '@/components'
export default {
components: {
XCard,
},
data() {
return {}
},
methods: {},
}
</script>
<style lang="less" scoped>
</style>

@ -0,0 +1,104 @@
<template>
<div class="lara-regist">
<div class="btn-list">
<a-button type="primary" @click="laraRecordFun"></a-button>
</div>
<div class="table-box">
<a-table :columns="columns" :data-source="laraData"></a-table>
</div>
</div>
</template>
<script>
import { LaraPaperRegist, LaraPaperRegistPost } from '@/api/modular/main/TaskmanageList'
export default {
data() {
return {
taskPKId: this.$route.query.taskPKId,
laraData: [],
// columns
columns: [
{
dataIndex: 'seq',
key: 'seq',
title: '排序',
scopedSlots: { customRender: 'seq' },
},
{
dataIndex: 'a',
key: 'a',
title: '提单号',
},
{
dataIndex: 'b',
key: 'b',
title: 'Page Numbers',
},
{
dataIndex: 'c',
key: 'c',
title: 'Page Number From',
},
{
dataIndex: 'd',
key: 'd',
title: 'Page Number To',
},
{
dataIndex: 's',
key: 's',
title: 'Sum',
},
],
}
},
created() {
this.laraPaperRegistFun()
},
methods: {
// LARA
laraPaperRegistFun() {
LaraPaperRegist({
PKIds: [this.taskPKId],
})
.then((res) => {
if (res.success) {
debugger
//
// this.laraData = res.data
} else {
this.$message.error(res.message)
}
})
.catch((err) => {
console.log(err)
})
},
// LARA
laraRecordFun() {
LaraPaperRegistPost({
taskPKId: this.taskPKId
})
.then((res) => {
debugger
if (res.success) {
this.$message.success('提单登记成功')
} else {
this.$message.error(res.message)
}
})
.catch((err) => {
console.log(err)
})
},
},
}
</script>
<style lang="less" scoped>
.table-box {
width: 100%;
background: #fff;
padding: 20px;
min-height: 100px;
margin-top: 20px;
}
</style>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

@ -248,7 +248,7 @@
>
<a-button class="list-btn"><i class="iconfont icon-xiazai"></i>正本下载</a-button>
</a-popconfirm>
<a-popconfirm
<!-- <a-popconfirm
title="确定登记当前选择项?"
ok-text="是"
cancel-text="否"
@ -256,8 +256,8 @@
@cancel="cancelFun"
>
<a-button class="list-btn"><i class="iconfont icon-dengjizongshu"></i>LARA登记</a-button>
</a-popconfirm>
<a-popconfirm
</a-popconfirm> -->
<!-- <a-popconfirm
title="确定记录当前选择项?"
ok-text="是"
cancel-text="否"
@ -265,7 +265,7 @@
@cancel="cancelFun"
>
<a-button class="list-btn"><i class="iconfont icon-touzijilu"></i>LARA记录</a-button>
</a-popconfirm>
</a-popconfirm> -->
</template>
</template>
<template #tools>
@ -290,7 +290,27 @@
<span class="task-tit" @click="changePage(row)">{{ row.taskTitle }}</span>
</template>
<template #operate="{ row }">
<a-button type="text" icon="vxe-icon-edit">预览附件</a-button>
<!-- <a-button type="text" size="small" icon="vxe-icon-edit"></a-button> -->
<a-tooltip>
<template slot="title">
预览
</template>
<span class="operate-btn iconfont icon-yulan"></span>
</a-tooltip>
<template v-if="taskType === 'ORIGINAL_DOWN'">
<a-tooltip>
<template slot="title">
LARA登记
</template>
<span class="operate-btn iconfont icon-electronic-signature" @click="laraPaperRegistFun(row)"></span>
</a-tooltip>
<a-tooltip>
<template slot="title">
LARA记录
</template>
<span class="operate-btn iconfont icon-touzijilu" @click="laraRecordFun(row)"></span>
</a-tooltip>
</template>
</template>
</vxe-grid>
</div>
@ -355,6 +375,7 @@
<script>
import { XCard } from '@/components'
import initData from './modules/initData'
import message from '@/components/message/index.js'
import {
GetTaskManagePage,
@ -474,7 +495,8 @@ export default {
this.getParaInfo('SOURCE')
this.getParaInfo('CATEGORY')
},
mounted() {},
mounted() {
},
methods: {
onSelect(selectedKeys, info) {
console.log('selected', selectedKeys, info)
@ -790,19 +812,27 @@ export default {
return false
}
pkIdArr.map(item => {
this.DownloadTaskAttach(item)
const name = select[pkIdArr.indexOf(item)].taskTitle
this.DownloadTaskAttach(item, name)
})
},
DownloadTaskAttach (id) {
DownloadTaskAttach (id, name) {
DownloadTaskAttach({
taskPKId: id
}).then((res) => {
if (res.success) {
debugger
//
} else {
this.$message.error(res.message)
if (res.message) {
message.error(`${name}下载失败:${res.message}`, 0)
return false
}
const blob = new Blob([res], { type: `application/pdf;chartset=UTF-8` })
const link = document.createElement('a')
link.style.display = 'none'
link.href = URL.createObjectURL(blob)
link.download = name
document.body.appendChild(link)
link.click()
URL.revokeObjectURL(link.href) // URL
document.body.removeChild(link)
}).catch((err) => {
console.log(err)
})
@ -868,7 +898,6 @@ export default {
})
query = query.substring(0, query.length - 1)
console.log(query)
debugger
LaraPaperCalc(query).then((res) => {
if (res.success) {
this.paperCalcRes = res.data
@ -966,49 +995,14 @@ export default {
})
},
// LARA
laraPaperRegistFun () {
const select = this.$refs.xGrid.getCheckboxRecords()
const pkIdArr = select.map((item, index) => {
return item.pkId
})
if (pkIdArr.length === 0) {
this.$message.error('请选择数据')
return false
}
LaraPaperRegist({
PKIds: pkIdArr
}).then((res) => {
if (res.success) {
this.$message.success('登记成功')
} else {
this.$message.error(res.message)
}
}).catch((err) => {
console.log(err)
})
laraPaperRegistFun (data) {
console.log('跳转页面', data)
this.$router.push({ name: 'TaskLaraRegist', query: { taskPKId: data.pkId } })
},
// LARA
laraRecordFun () {
const select = this.$refs.xGrid.getCheckboxRecords()
const pkIdArr = select.map((item, index) => {
return item.pkId
})
if (pkIdArr.length === 0) {
this.$message.error('请选择数据')
return false
}
console.log('已选择数据', pkIdArr)
LaraPaperRegistPost({
taskPKId: pkIdArr[0]
}).then((res) => {
debugger
if (res.success) {
} else {
this.$message.error(res.message)
}
}).catch((err) => {
console.log(err)
})
laraRecordFun (data) {
console.log('跳转页面', data)
this.$router.push({ name: 'TaskLaraRecord', query: { taskPKId: data.pkId } })
},
},
}
@ -1062,4 +1056,13 @@ export default {
margin-left: 10px;
}
}
.operate-btn{
width: 30px;
text-align: center;
display: inline-block;
&:nth-of-type(1) {
color: @primary-color;
}
}
</style>

@ -1,219 +0,0 @@
<template>
<a-modal
:title="`品名编辑(${type=='edit' ? '修改' : '新增'}`"
:width="900"
:visible="visible"
:confirmLoading="confirmLoading"
:maskClosable="false"
cancelText="关闭"
okText="保存"
@ok="handleSubmit"
@cancel="handleCancel"
>
<a-spin :spinning="formLoading">
<a-form :form="form">
<a-row :gutter="16">
<a-col :span="24">
<a-form-item
label="品名编码"
:labelCol="labelCol2"
:wrapperCol="wrapperCol2"
has-feedback
>
<a-input placeholder="请输入品名编码" v-decorator="['goodsCode', {rules: [{required: true, message: ''}]}]" />
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item
label="品名中文"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
has-feedback
>
<a-input placeholder="请输入品名中文" v-decorator="['goodsNameCN']" />
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item
label="品名英文"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
has-feedback
>
<a-input :rows="4" placeholder="请输入品名英文" v-decorator="['goodsNameEN']"></a-input>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item
label="品名分类"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
has-feedback
>
<auto-complete
:allowClear="true"
placeholder="请输入品名分类"
v-decorator="['goodsCategory']"
class="customer-input"
:data-source="goodsCategoryArr"
:dropdown-match-select-width="false"
:dropdown-style="{ width: '200px' }"
@select="goodsCategorySelect"
@change="goodsCategoryChange"
@focus="goodsCategoryChange"
/>
</a-form-item>
</a-col>
<a-col :span="12">
<a-form-item
label="品名分类名称"
:labelCol="labelCol"
:wrapperCol="wrapperCol"
has-feedback
>
<a-input :rows="4" placeholder="请输入品名分类名称" v-decorator="['goodsCategoryName']"></a-input>
</a-form-item>
</a-col>
<a-col :span="24">
<a-form-item
label="品名描述"
:labelCol="labelCol2"
:wrapperCol="wrapperCol2"
has-feedback
>
<a-textarea :rows="4" placeholder="请输入品名描述" v-decorator="['goodsDesp']"></a-textarea>
</a-form-item>
</a-col>
</a-row>
</a-form>
</a-spin>
</a-modal>
</template>
<script>
import { AutoComplete } from 'ant-design-vue'
import {
QueryParaGoodsCategoryInfo
} from '@/api/modular/main/ProductNameList'
export default {
props: {
type: {
type: String,
default: 'add'
},
fromData: {
type: Object,
default: null
}
},
components: {
AutoComplete
},
data () {
return {
labelCol: {
xs: { span: 24 },
sm: { span: 6 }
},
wrapperCol: {
xs: { span: 24 },
sm: { span: 16 }
},
labelCol2: {
xs: { span: 24 },
sm: { span: 3 }
},
wrapperCol2: {
xs: { span: 24 },
sm: { span: 20 }
},
visible: false,
confirmLoading: false,
formLoading: true,
form: this.$form.createForm(this),
goodsCategory: []
}
},
computed: {
goodsCategoryArr () {
if (this.goodsCategory) {
const arr = []
this.goodsCategory.map((item, index) => {
arr.push(item.goodsCategory)
})
return arr
} else {
return []
}
}
},
watch: {
fromData: {
handler (nval, oval) {
if (!this.formLoading) {
this.$nextTick(() => {
this.form.setFieldsValue(nval)
})
}
},
deep: true
}
},
methods: {
add () {
this.visible = true
this.formLoading = false
},
handleSubmit () {
const { form: { validateFields } } = this
this.confirmLoading = true
validateFields((errors, values) => {
if (!errors) {
this.$emit('ok', values)
} else {
this.confirmLoading = false
}
})
},
handleCancel () {
this.form.resetFields()
this.visible = false
},
getGoodsCategory(name = '') {
// console.log('', name, this.goodsCategory, this.goodsCategoryArr)
QueryParaGoodsCategoryInfo({
queryItem: name,
top: 50
}).then((res) => {
this.goodsCategory = res.data
})
},
goodsCategorySelect(value) {
const index = this.goodsCategoryArr.indexOf(value)
debugger
this.form.setFieldsValue({
goodsCategory: this.goodsCategory[index].goodsCategory || '',
goodsCategoryName: this.goodsCategory[index].goodsCategoryName || ''
})
},
goodsCategoryChange(value) {
this.getGoodsCategory(value)
}
}
}
</script>
<style lang="less" scoped>
.line{
height: 30px;
line-height:30px;
text-align: right;
font-size: 14px;
span{
margin-left: 20px;
}
span:nth-of-type(2){
width: 120px;
display: inline-block;
text-align: left;
}
}
</style>

@ -10,6 +10,6 @@ export default {
{ field: 'mBlNo', width: 200, title: '提单号', showHeaderOverflow: true, sortable: true },
{ field: 'etd', width: 180, title: '开船日期', showHeaderOverflow: true, sortable: true },
{ field: 'complateDealName', width: 150, title: '完成方式', showHeaderOverflow: true, sortable: true },
{ field: 'operate', title: '操作', width: 150, noDraggable: true, slots: { default: 'operate' }, fixed: 'right', resizable: false }
{ field: 'operate', title: '操作', width: 120, noDraggable: true, slots: { default: 'operate' }, fixed: 'right', resizable: false }
]
}

Loading…
Cancel
Save