增加商品库存流水界面
This commit is contained in:
@@ -61,14 +61,19 @@
|
|||||||
:pagination="ipagination"
|
:pagination="ipagination"
|
||||||
:loading="loading"
|
:loading="loading"
|
||||||
@change="handleTableChange">
|
@change="handleTableChange">
|
||||||
|
<span slot="action" slot-scope="text, record">
|
||||||
|
<a @click="showMaterialInOutList(record)">流水</a>
|
||||||
|
</span>
|
||||||
</a-table>
|
</a-table>
|
||||||
</section>
|
</section>
|
||||||
<!-- table区域-end -->
|
<!-- table区域-end -->
|
||||||
|
<material-in-out-list ref="materialInOutList" @ok="modalFormOk"></material-in-out-list>
|
||||||
</a-card>
|
</a-card>
|
||||||
</a-col>
|
</a-col>
|
||||||
</a-row>
|
</a-row>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
import MaterialInOutList from './modules/MaterialInOutList'
|
||||||
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
||||||
import { getAction } from '@/api/manage'
|
import { getAction } from '@/api/manage'
|
||||||
import {queryMaterialCategoryTreeList} from '@/api/api'
|
import {queryMaterialCategoryTreeList} from '@/api/api'
|
||||||
@@ -80,6 +85,7 @@
|
|||||||
name: "MaterialStock",
|
name: "MaterialStock",
|
||||||
mixins:[JeecgListMixin],
|
mixins:[JeecgListMixin],
|
||||||
components: {
|
components: {
|
||||||
|
MaterialInOutList,
|
||||||
JEllipsis
|
JEllipsis
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
@@ -113,7 +119,10 @@
|
|||||||
{title: '单价', dataIndex: 'purchaseDecimal', width: 60},
|
{title: '单价', dataIndex: 'purchaseDecimal', width: 60},
|
||||||
{title: '初始库存', dataIndex: 'initialStock', width: 80},
|
{title: '初始库存', dataIndex: 'initialStock', width: 80},
|
||||||
{title: '当前库存', dataIndex: 'currentStock', width: 80},
|
{title: '当前库存', dataIndex: 'currentStock', width: 80},
|
||||||
{title: '当前库存金额', dataIndex: 'currentStockPrice', width: 80}
|
{title: '当前库存金额', dataIndex: 'currentStockPrice', width: 80},
|
||||||
|
{ title: '库存流水', dataIndex: 'action', align:"center", width: 100,
|
||||||
|
scopedSlots: { customRender: 'action' }
|
||||||
|
}
|
||||||
],
|
],
|
||||||
labelCol: {
|
labelCol: {
|
||||||
xs: { span: 1 },
|
xs: { span: 1 },
|
||||||
@@ -191,6 +200,11 @@
|
|||||||
}
|
}
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
})
|
})
|
||||||
|
},
|
||||||
|
showMaterialInOutList(record) {
|
||||||
|
this.$refs.materialInOutList.show(record);
|
||||||
|
this.$refs.materialInOutList.title = "查看商品库存流水(全部仓库)";
|
||||||
|
this.$refs.materialInOutList.disableSubmit = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,6 +7,9 @@
|
|||||||
cancelText="关闭"
|
cancelText="关闭"
|
||||||
wrapClassName="ant-modal-cust-warp"
|
wrapClassName="ant-modal-cust-warp"
|
||||||
style="top:5%;height: 100%;overflow-y: hidden">
|
style="top:5%;height: 100%;overflow-y: hidden">
|
||||||
|
<template slot="footer">
|
||||||
|
<a-button key="back" @click="handleCancel">取消</a-button>
|
||||||
|
</template>
|
||||||
<!-- table区域-begin -->
|
<!-- table区域-begin -->
|
||||||
<a-table
|
<a-table
|
||||||
bordered
|
bordered
|
||||||
|
|||||||
128
jshERP-web/src/views/report/modules/MaterialInOutList.vue
Normal file
128
jshERP-web/src/views/report/modules/MaterialInOutList.vue
Normal file
@@ -0,0 +1,128 @@
|
|||||||
|
<template>
|
||||||
|
<a-modal
|
||||||
|
:title="title"
|
||||||
|
:width="1000"
|
||||||
|
:visible="visible"
|
||||||
|
@cancel="handleCancel"
|
||||||
|
cancelText="关闭"
|
||||||
|
wrapClassName="ant-modal-cust-warp"
|
||||||
|
style="top:5%;height: 100%;overflow-y: hidden">
|
||||||
|
<template slot="footer">
|
||||||
|
<a-button key="back" @click="handleCancel">取消</a-button>
|
||||||
|
</template>
|
||||||
|
<!-- table区域-begin -->
|
||||||
|
<a-table
|
||||||
|
bordered
|
||||||
|
ref="table"
|
||||||
|
size="middle"
|
||||||
|
rowKey="id"
|
||||||
|
:columns="columns"
|
||||||
|
:dataSource="dataSource"
|
||||||
|
:pagination="ipagination"
|
||||||
|
:loading="loading"
|
||||||
|
@change="handleTableChange">
|
||||||
|
<span slot="numberCustomRender" slot-scope="text, record">
|
||||||
|
<a @click="myHandleDetail(record)">{{record.number}}</a>
|
||||||
|
</span>
|
||||||
|
</a-table>
|
||||||
|
<!-- table区域-end -->
|
||||||
|
<!-- 表单区域 -->
|
||||||
|
<bill-detail ref="billDetail"></bill-detail>
|
||||||
|
</a-modal>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import BillDetail from '../../bill/dialog/BillDetail'
|
||||||
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
||||||
|
import JEllipsis from '@/components/jeecg/JEllipsis'
|
||||||
|
import {findBillDetailByNumber, findFinancialDetailByNumber} from '@/api/api'
|
||||||
|
export default {
|
||||||
|
name: "MaterialInOutList",
|
||||||
|
mixins:[JeecgListMixin],
|
||||||
|
components: {
|
||||||
|
BillDetail,
|
||||||
|
JEllipsis
|
||||||
|
},
|
||||||
|
data () {
|
||||||
|
return {
|
||||||
|
title:"操作",
|
||||||
|
visible: false,
|
||||||
|
disableMixinCreated: false,
|
||||||
|
toFromType: '',
|
||||||
|
// 查询条件
|
||||||
|
queryParam: {
|
||||||
|
materialId:''
|
||||||
|
},
|
||||||
|
tabKey: "1",
|
||||||
|
// 表头
|
||||||
|
columns: [
|
||||||
|
{
|
||||||
|
title: '#',
|
||||||
|
dataIndex: '',
|
||||||
|
key:'rowIndex',
|
||||||
|
width:40,
|
||||||
|
align:"center",
|
||||||
|
customRender:function (t,r,index) {
|
||||||
|
return parseInt(index)+1;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '单据编号', dataIndex: 'number', width: 150,
|
||||||
|
scopedSlots: { customRender: 'numberCustomRender' },
|
||||||
|
},
|
||||||
|
{ title: '类型', dataIndex: 'type', width: 100},
|
||||||
|
{title: '仓库名称', dataIndex: 'depotName', width: 80},
|
||||||
|
{title: '数量', dataIndex: 'basicNumber', width: 80},
|
||||||
|
{title: '日期', dataIndex: 'operTime', width: 180}
|
||||||
|
],
|
||||||
|
labelCol: {
|
||||||
|
xs: { span: 1 },
|
||||||
|
sm: { span: 2 },
|
||||||
|
},
|
||||||
|
wrapperCol: {
|
||||||
|
xs: { span: 10 },
|
||||||
|
sm: { span: 16 },
|
||||||
|
},
|
||||||
|
url: {
|
||||||
|
list: "/depotItem/findDetailByTypeAndMaterialId"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
getQueryParams() {
|
||||||
|
let param = Object.assign({}, this.queryParam, this.isorter);
|
||||||
|
param.field = this.getQueryField();
|
||||||
|
param.currentPage = this.ipagination.current;
|
||||||
|
param.pageSize = this.ipagination.pageSize;
|
||||||
|
return param;
|
||||||
|
},
|
||||||
|
show(record) {
|
||||||
|
this.model = Object.assign({}, record);
|
||||||
|
this.visible = true;
|
||||||
|
this.queryParam.materialId = record.id
|
||||||
|
this.loadData(1)
|
||||||
|
},
|
||||||
|
close () {
|
||||||
|
this.$emit('close');
|
||||||
|
this.visible = false;
|
||||||
|
},
|
||||||
|
handleCancel () {
|
||||||
|
this.close()
|
||||||
|
},
|
||||||
|
myHandleDetail(record) {
|
||||||
|
let that = this
|
||||||
|
this.toFromType = record.fromType
|
||||||
|
findBillDetailByNumber({ number: record.number }).then((res) => {
|
||||||
|
if (res && res.code === 200) {
|
||||||
|
that.$refs.billDetail.show(res.data, record.type);
|
||||||
|
that.$refs.billDetail.title="详情";
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style scoped>
|
||||||
|
@import '~@assets/less/common.less'
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user