Browse Source

【pad前端】静态暂存

ag_report_nev
安虹睿 12 months ago
parent
commit
f10d16855a
  1. 8
      fe/PC/src/components/currenDescriptions/index.vue
  2. 2
      fe/PC/src/layout/index.vue
  3. 448
      fe/PC/src/router/index.js
  4. 10
      fe/PC/src/styles/padMain.scss
  5. 247
      fe/PC/src/views/padManage/isPadForTransferLibJob_new.vue

8
fe/PC/src/components/currenDescriptions/index.vue

@ -12,7 +12,7 @@
:label="item.label"
v-for="(item, index) in tabsDesTions"
:key="index"
:labelStyle="{'text-align': 'right','padding-right':'10px'}"
:labelStyle="labelStyle"
>
<span v-if="item.type && item.type == 'date'">{{
propsData[item.prop] | formatOnlyDate
@ -127,6 +127,12 @@ export default {
}
},
props: {
labelStyle:{
type: Object,
default: () => {
return {'text-align': 'right','padding-right':'10px'}
}
},
title: {
type: String,
default: ''

2
fe/PC/src/layout/index.vue

@ -57,7 +57,7 @@ export default {
data() {
return {
//
isOnlyAppMainPages:['isPadForTransferLibJob','isPadForKittingPack']
isOnlyAppMainPages:['isPadForTransferLibJob','isPadForTransferLibJob_new','isPadForKittingPack']
}
},
methods: {

448
fe/PC/src/router/index.js

@ -172,6 +172,22 @@ export const constantRoutes = [
}
}]
},
{
path: '/',
component: Layout,
redirect: '/isPadForTransferLibJob_new',
hidden: true,
children: [{
path: 'isPadForTransferLibJob_new',
component: () => import('@/views/padManage/isPadForTransferLibJob_new'),
name: 'isPadForTransferLibJob_new',
meta: {
keepAlive : true,
title: '业务库移',
icon: '系统首页',
}
}]
},
// 【平板】 Kitting组包
{
path: '/',
@ -221,294 +237,150 @@ export const constantRoutes = [
// }
// }]
// },
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueRequestZS',
component: () => import('@/views/materialIssueManage/ZS/IssueRequestZS.vue'),
name: 'IssueRequestZS',
meta: {
keepAlive : true,
title: '注塑申请',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueJobZS',
component: () => import('@/views/materialIssueManage/ZS/IssueJobZS.vue'),
name: 'IssueJobZS',
meta: {
keepAlive : true,
title: '注塑任务',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueNoteZS',
component: () => import('@/views/materialIssueManage/ZS/IssueNoteZS.vue'),
name: 'IssueNoteZS',
meta: {
keepAlive : true,
title: '注塑记录',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueRequestPT',
component: () => import('@/views/materialIssueManage/PT/IssueRequestPT.vue'),
name: 'IssueRequestPT',
meta: {
keepAlive : true,
title: '人工发料申请(喷涂)',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueJobPT',
component: () => import('@/views/materialIssueManage/PT/IssueJobPT.vue'),
name: 'IssueJobPT',
meta: {
keepAlive : true,
title: '人工发料任务(喷涂)',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueNotePT',
component: () => import('@/views/materialIssueManage/PT/IssueNotePT.vue'),
name: 'IssueNotePT',
meta: {
keepAlive : true,
title: '人工发料记录(喷涂)',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueRequestZP',
component: () => import('@/views/materialIssueManage/ZP/IssueRequestZP.vue'),
name: 'IssueRequestZP',
meta: {
keepAlive : true,
title: '装配申请',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueJobZP',
component: () => import('@/views/materialIssueManage/ZP/IssueJobZP.vue'),
name: 'IssueJobZP',
meta: {
keepAlive : true,
title: '装配任务',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'IssueNoteZP',
component: () => import('@/views/materialIssueManage/ZP/IssueNoteZP.vue'),
name: 'IssueNoteZP',
meta: {
keepAlive : true,
title: '装配记录',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticRequestZS',
component: () => import('@/views/materialIssueManage/automaticZS/automaticRequestZS.vue'),
name: 'automaticRequestZS',
meta: {
keepAlive : true,
title: '自动叫料(注塑)申请',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticJobZS',
component: () => import('@/views/materialIssueManage/automaticZS/automaticJobZS.vue'),
name: 'automaticJobZS',
meta: {
keepAlive : true,
title: '自动叫料(注塑)任务',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticNoteZS',
component: () => import('@/views/materialIssueManage/automaticZS/automaticNoteZS.vue'),
name: 'automaticNoteZS',
meta: {
keepAlive : true,
title: '自动叫料(注塑)记录',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticRequestPT',
component: () => import('@/views/materialIssueManage/automaticPT/automaticRequestPT.vue'),
name: 'automaticRequestPT',
meta: {
keepAlive : true,
title: '自动叫料(喷涂)申请',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticJobPT',
component: () => import('@/views/materialIssueManage/automaticPT/automaticJobPT.vue'),
name: 'automaticJobPT',
meta: {
keepAlive : true,
title: '自动叫料(喷涂)任务',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticNotePT',
component: () => import('@/views/materialIssueManage/automaticPT/automaticNotePT.vue'),
name: 'automaticNotePT',
meta: {
keepAlive : true,
title: '自动叫料(喷涂)记录',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticRequestZP',
component: () => import('@/views/materialIssueManage/automaticZP/automaticRequestZP.vue'),
name: 'automaticRequestZP',
meta: {
keepAlive : true,
title: '自动叫料(装配)申请',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticJobZP',
component: () => import('@/views/materialIssueManage/automaticZP/automaticJobZP.vue'),
name: 'automaticJobZP',
meta: {
keepAlive : true,
title: '自动叫料(装配)任务',
icon: '成品发运任务',
}
}]
},
{
path: '/',
component: Layout,
redirect: '/gridlayout',
hidden: true,
children: [{
path: 'automaticNoteZP',
component: () => import('@/views/materialIssueManage/automaticZP/automaticNoteZP.vue'),
name: 'automaticNoteZP',
meta: {
keepAlive : true,
title: '自动叫料(装配)记录',
icon: '成品发运任务',
}
}]
},
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticRequestZS',
// component: () => import('@/views/materialIssueManage/automaticZS/automaticRequestZS.vue'),
// name: 'automaticRequestZS',
// meta: {
// keepAlive : true,
// title: '自动叫料(注塑)申请',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticJobZS',
// component: () => import('@/views/materialIssueManage/automaticZS/automaticJobZS.vue'),
// name: 'automaticJobZS',
// meta: {
// keepAlive : true,
// title: '自动叫料(注塑)任务',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticNoteZS',
// component: () => import('@/views/materialIssueManage/automaticZS/automaticNoteZS.vue'),
// name: 'automaticNoteZS',
// meta: {
// keepAlive : true,
// title: '自动叫料(注塑)记录',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticRequestPT',
// component: () => import('@/views/materialIssueManage/automaticPT/automaticRequestPT.vue'),
// name: 'automaticRequestPT',
// meta: {
// keepAlive : true,
// title: '自动叫料(喷涂)申请',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticJobPT',
// component: () => import('@/views/materialIssueManage/automaticPT/automaticJobPT.vue'),
// name: 'automaticJobPT',
// meta: {
// keepAlive : true,
// title: '自动叫料(喷涂)任务',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticNotePT',
// component: () => import('@/views/materialIssueManage/automaticPT/automaticNotePT.vue'),
// name: 'automaticNotePT',
// meta: {
// keepAlive : true,
// title: '自动叫料(喷涂)记录',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticRequestZP',
// component: () => import('@/views/materialIssueManage/automaticZP/automaticRequestZP.vue'),
// name: 'automaticRequestZP',
// meta: {
// keepAlive : true,
// title: '自动叫料(装配)申请',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticJobZP',
// component: () => import('@/views/materialIssueManage/automaticZP/automaticJobZP.vue'),
// name: 'automaticJobZP',
// meta: {
// keepAlive : true,
// title: '自动叫料(装配)任务',
// icon: '成品发运任务',
// }
// }]
// },
// {
// path: '/',
// component: Layout,
// redirect: '/gridlayout',
// hidden: true,
// children: [{
// path: 'automaticNoteZP',
// component: () => import('@/views/materialIssueManage/automaticZP/automaticNoteZP.vue'),
// name: 'automaticNoteZP',
// meta: {
// keepAlive : true,
// title: '自动叫料(装配)记录',
// icon: '成品发运任务',
// }
// }]
// },
]

10
fe/PC/src/styles/padMain.scss

@ -20,10 +20,20 @@
padding: 10px 10px 0 10px;
box-shadow: 1px 1px 5px #ddd;
flex-shrink: 0;
display: flex;
justify-content: space-between;
::v-deep .el-form-item{
margin-bottom: 10px;
}
.pageToTop{
width: 30px;
height: 30px;
flex-shrink: 0;
margin-left: 15px;
padding: 0;
}
}
.padListCard{

247
fe/PC/src/views/padManage/isPadForTransferLibJob_new.vue

@ -1,26 +1,245 @@
<template>
<div class="isPadForTransferLibJobPage">
<div class="isPadForTransferLibJobPage padListPage">
<!-- 搜索头部 -->
<div class="padListHeader">
<div class="leftSearchHeader">
<el-form :inline="true" :model="searchFormData" :size="'mini'">
<el-form-item
v-for="(item,index) in searchForm"
:key="index"
:label="item.label"
>
<!-- input -->
<el-input
v-if="item.type == 'input'"
v-model="searchFormData[item.prop]"
:placeholder="item.label"
clearable
></el-input>
<!-- select -->
<el-select
v-if="item.type == 'select'"
v-model="searchFormData[item.prop]"
:placeholder="item.label"
>
<el-option
v-for="(opItem,opIndex) in item.options"
:key="opIndex"
:label="opItem.label"
:value="opItem.value"
></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="searchHandle">查询</el-button>
<el-button
v-for="(btnItem,btnIndex) in headerButton"
:key="btnIndex"
:type="btnItem.type"
@click="headerButtonClick(btnItem,btnIndex)"
>{{ btnItem.label }}</el-button>
</el-form-item>
</el-form>
</div>
<el-button circle icon="el-icon-upload2" type="primary" class="pageToTop" @click="pageToTopHandle"></el-button>
</div>
<!-- 列表 -->
<div class="padListCard" v-show="padListPager.totalCount" id="padListCard">
<div
class="padListRow"
v-for="(item,index) in padListData"
:key="index"
>
<!-- 主表 -->
<div class="mainDataBox">
<curren-descriptions
:column="5"
:tabsDesTions="padMainColumn"
:propsData="item"
:labelStyle="{'margin-right':'5px'}"
></curren-descriptions>
</div>
<!-- 子表 todo封装时候确定是否为子表直接显示数据-->
<div class="detailDataBox">
<curren-descriptions
:column="4"
:tabsDesTions="padDeatilColumn"
:propsData="item.details[0]"
:labelStyle="{'margin-right':'5px'}"
></curren-descriptions>
</div>
<!-- 按钮 -->
<div class="listRowButtonBox">
<el-button
v-for="(btnItem,btnIndex) in listRowButton"
:key="btnIndex"
:type="btnItem.type"
@click="headerButtonClick(btnItem,btnIndex)"
:size="'mini'"
>{{ btnItem.label }}</el-button>
</div>
</div>
</div>
<!-- 无数据 -->
<el-empty v-show="!padListPager.totalCount || padListPager.totalCount<=0" description="暂无数据"></el-empty>
<!-- 页脚 -->
<div class="padListPager" v-if="padListPager.totalCount">
<div v-loading="padListLoading" element-loading-text="拼命加载中">{{padListPager.currentPage}}/{{padListPager.totalPage}}</div>
</div>
</div>
</template>
<script>
export default {
name: 'isPadForTransferLibJob',
data () {
return {}
import { getPageList } from "@/api/wms-api";
import currenDescriptions from "@/components/currenDescriptions"
export default {
name: 'isPadForTransferLibJob',
components: { currenDescriptions },
data () {
return {
searchFormData:{
number:""
},
methods: {}
searchForm:[
{label:'任务单号',prop:'number',type:'input'},
],
headerButton:[
{
type: 'warning',
label: '查看待执行数据',
name: "showCanHandle",
},
{
type: 'success',
label: '查看所有数据',
name: "showAllData",
},
],
padListLoading:false,
padListData:[],
padMainColumn:[
{label:'任务单号',prop:'number'},
{label:'申请单号',prop:'requestNumber'},
{ label: "状态", prop: "jobStatus",type: "filter", filters: "jobStatus" },
{ label: "创建时间", prop: 'creationTime', type: "dateTime" },
],
padDeatilColumn:[
{label:'物品代码',prop:'itemCode'},
{label:'物品名称',prop:'itemName'},
{label:'物料描述1',prop:'itemDesc1'},
{label:'物料描述2',prop:'itemDesc2'},
{label:'数量',prop:'recommendToQty'},
],
listRowButton:[
{
type: 'primary',
label: '查看余额',
name: "showCanHandle",
},
{
type: 'success',
label: '完成库移',
name: "showAllData",
},
],
padListPager:{
totalCount:null,//
pageSize:10,//
currentPage:0,//
totalPage:null,//
},
searchFilters:[]
}
},
mounted(){
this.getPadList()
let _this = this
document.getElementById("padListCard").addEventListener('scroll', function() {
_this.handleScroll()
});
},
methods: {
pageToTopHandle(){
document.getElementById("padListCard").scrollTop = 0
},
handleScroll(){
let windowHeight = document.getElementById("padListCard").clientHeight;
let scrollHeight = document.getElementById("padListCard").scrollHeight;
let scrollTop = document.getElementById("padListCard").scrollTop;
if (scrollTop + windowHeight >= scrollHeight - 30) {
let page = Number(JSON.stringify(this.padListPager.currentPage + 1))
if(Number(page) > Number(this.padListPager.totalPage))return
console.log('翻页')
this.getPadList(page);
}
},
intSearchFilters(){
let _filters = []
this.searchForm.forEach(item => {
if(this.searchFormData[item.prop]){
_filters.push(
{
logic: 'And',
column: item.prop,
action: item.action || "==",
value: this.searchFormData[item.prop]
}
)
}
});
return _filters
},
getPadList(page=1){
if(this.padListLoading)return
console.log('请求页数',page)
if(page != 1 && (Number(page) > Number(this.padListPager.totalPage)))return
if(page == 1){this.padListData = []}
let params = {
sorting: null,
maxResultCount: this.padListPager.pageSize,
skipCount: this.padListPager.pageSize * (Number(page) - 1),
condition: {
filters: this.intSearchFilters()
}
}
this.padListLoading = true
getPageList(params,'wms/store/transfer-lib-job',true).then(res => {
this.padListData = [
...this.padListData,
...res.items,
];
this.padListPager.totalCount = res.totalCount
this.padListPager.totalPage = Math.ceil(res.totalCount / this.padListPager.pageSize)
this.padListLoading = false
this.padListPager.currentPage = page
}).catch(err => {
this.padListLoading = false
console.log(err)
})
},
//
searchHandle(){
this.getPadList()
},
//
headerButtonClick(item,index){
if(val.name == 'showCanHandle'){
this.PageListParams.condition.filters.push({
logic:"And",
column:"jobStatus",
action:"In",
value: JSON.stringify([1,2,4,30])
})
this.paging();
}
else if(val.name == 'showAllData'){
this.PageListParams.condition.filters = this.PageListParams.condition.filters.filter(obj => obj.column != 'jobStatus');
this.paging();
}
}
}
}
</script>
<style lang="scss" scoped>
.isPadForTransferLibJobPage{
background:#fff;
margin:15px;
height:calc(100% - 30px);
min-width:800px;
overflow:auto;
}
@import "@/styles/padMain.scss";
</style>
Loading…
Cancel
Save