我的任务 - 订舱详情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) { %> <% for (var i in htmlWebpackPlugin.options.cdn && htmlWebpackPlugin.options.cdn.css) { %>
<link rel="stylesheet" href="<%= htmlWebpackPlugin.options.cdn.css[i] %>" /> <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仔百度收录 --> <!-- 1.8K仔百度收录 -->
<meta name="baidu-site-verification" content="code-QVfBYJ5laQ" /> <meta name="baidu-site-verification" content="code-QVfBYJ5laQ" />
</head> </head>

@ -128,7 +128,7 @@ export function DownloadAttach (parameter) {
return axios({ return axios({
url: '/TaskManage/DownloadAttach', url: '/TaskManage/DownloadAttach',
method: 'post', method: 'post',
data: parameter data: parameter
}) })
} }
@ -144,12 +144,23 @@ export function GetBookingOrderInfo (parameter) {
} }
/** /**
* lara 记录 * lara 记录 -- 有问题
*/ */
export function LaraPaperRegistPost (parameter) { export function LaraPaperRegistPost (parameter) {
return axios({ return axios({
url: '/TaskManage/LaraPaperRegistPost', url: '/TaskManage/LaraPaperRegistPost',
method: 'post', 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'), BookingDetailNew: () => import('@/views/main/BookingLedgerNew/detail'),
CustomerInformationManagementAdd: () => import('@/views/main/Customer/addForm'), CustomerInformationManagementAdd: () => import('@/views/main/Customer/addForm'),
CustomerInformationManagementEdit: () => import('@/views/main/Customer/editForm'), 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 // 前端未找到页面路由(固定不用改)、原来为 /404
@ -153,6 +155,28 @@ const userAccount = [
show: false show: false
}, },
component: 'TaskmanageDetail' 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>
<style lang="less"> <style lang="less" scoped>
@import url('../index.less'); @import url('../index.less');
.from-label { .from-label {

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

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

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

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

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

@ -475,7 +475,7 @@ export default {
} }
} }
</script> </script>
<style scoped lang="less"> <style scoped lang="less" scoped>
.CsForm { .CsForm {
background: #fff; background: #fff;
padding: 25px; 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-button class="list-btn"><i class="iconfont icon-xiazai"></i>正本下载</a-button>
</a-popconfirm> </a-popconfirm>
<a-popconfirm <!-- <a-popconfirm
title="确定登记当前选择项?" title="确定登记当前选择项?"
ok-text="是" ok-text="是"
cancel-text="否" cancel-text="否"
@ -256,8 +256,8 @@
@cancel="cancelFun" @cancel="cancelFun"
> >
<a-button class="list-btn"><i class="iconfont icon-dengjizongshu"></i>LARA登记</a-button> <a-button class="list-btn"><i class="iconfont icon-dengjizongshu"></i>LARA登记</a-button>
</a-popconfirm> </a-popconfirm> -->
<a-popconfirm <!-- <a-popconfirm
title="确定记录当前选择项?" title="确定记录当前选择项?"
ok-text="是" ok-text="是"
cancel-text="否" cancel-text="否"
@ -265,7 +265,7 @@
@cancel="cancelFun" @cancel="cancelFun"
> >
<a-button class="list-btn"><i class="iconfont icon-touzijilu"></i>LARA记录</a-button> <a-button class="list-btn"><i class="iconfont icon-touzijilu"></i>LARA记录</a-button>
</a-popconfirm> </a-popconfirm> -->
</template> </template>
</template> </template>
<template #tools> <template #tools>
@ -290,7 +290,27 @@
<span class="task-tit" @click="changePage(row)">{{ row.taskTitle }}</span> <span class="task-tit" @click="changePage(row)">{{ row.taskTitle }}</span>
</template> </template>
<template #operate="{ row }"> <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> </template>
</vxe-grid> </vxe-grid>
</div> </div>
@ -355,6 +375,7 @@
<script> <script>
import { XCard } from '@/components' import { XCard } from '@/components'
import initData from './modules/initData' import initData from './modules/initData'
import message from '@/components/message/index.js'
import { import {
GetTaskManagePage, GetTaskManagePage,
@ -474,7 +495,8 @@ export default {
this.getParaInfo('SOURCE') this.getParaInfo('SOURCE')
this.getParaInfo('CATEGORY') this.getParaInfo('CATEGORY')
}, },
mounted() {}, mounted() {
},
methods: { methods: {
onSelect(selectedKeys, info) { onSelect(selectedKeys, info) {
console.log('selected', selectedKeys, info) console.log('selected', selectedKeys, info)
@ -790,19 +812,27 @@ export default {
return false return false
} }
pkIdArr.map(item => { pkIdArr.map(item => {
this.DownloadTaskAttach(item) const name = select[pkIdArr.indexOf(item)].taskTitle
this.DownloadTaskAttach(item, name)
}) })
}, },
DownloadTaskAttach (id) { DownloadTaskAttach (id, name) {
DownloadTaskAttach({ DownloadTaskAttach({
taskPKId: id taskPKId: id
}).then((res) => { }).then((res) => {
if (res.success) { if (res.message) {
debugger message.error(`${name}下载失败:${res.message}`, 0)
// return false
} else {
this.$message.error(res.message)
} }
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) => { }).catch((err) => {
console.log(err) console.log(err)
}) })
@ -868,7 +898,6 @@ export default {
}) })
query = query.substring(0, query.length - 1) query = query.substring(0, query.length - 1)
console.log(query) console.log(query)
debugger
LaraPaperCalc(query).then((res) => { LaraPaperCalc(query).then((res) => {
if (res.success) { if (res.success) {
this.paperCalcRes = res.data this.paperCalcRes = res.data
@ -966,49 +995,14 @@ export default {
}) })
}, },
// LARA // LARA
laraPaperRegistFun () { laraPaperRegistFun (data) {
const select = this.$refs.xGrid.getCheckboxRecords() console.log('跳转页面', data)
const pkIdArr = select.map((item, index) => { this.$router.push({ name: 'TaskLaraRegist', query: { taskPKId: data.pkId } })
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)
})
}, },
// LARA // LARA
laraRecordFun () { laraRecordFun (data) {
const select = this.$refs.xGrid.getCheckboxRecords() console.log('跳转页面', data)
const pkIdArr = select.map((item, index) => { this.$router.push({ name: 'TaskLaraRecord', query: { taskPKId: data.pkId } })
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)
})
}, },
}, },
} }
@ -1062,4 +1056,13 @@ export default {
margin-left: 10px; margin-left: 10px;
} }
} }
.operate-btn{
width: 30px;
text-align: center;
display: inline-block;
&:nth-of-type(1) {
color: @primary-color;
}
}
</style> </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: 'mBlNo', width: 200, title: '提单号', showHeaderOverflow: true, sortable: true },
{ field: 'etd', width: 180, title: '开船日期', showHeaderOverflow: true, sortable: true }, { field: 'etd', width: 180, title: '开船日期', showHeaderOverflow: true, sortable: true },
{ field: 'complateDealName', width: 150, 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