Merge branch 'master' of http://222.71.165.188:3000/yunxi/jigangSCM2
commit
744508c6a4
After Width: | Height: | Size: 4.5 KiB |
After Width: | Height: | Size: 18 KiB |
Before Width: | Height: | Size: 18 KiB After Width: | Height: | Size: 4.5 KiB |
@ -0,0 +1,147 @@
|
||||
<template>
|
||||
<el-dialog title="选择商品" :close-on-click-modal="false" :visible.sync="visible"
|
||||
class="JNPF-dialog JNPF-dialog_center" lock-scroll append-to-body width="800px">
|
||||
<el-row class="JNPF-common-search-box" :gutter="16">
|
||||
<el-form @submit.native.prevent>
|
||||
<el-col :span="10">
|
||||
<el-form-item label="关键词">
|
||||
<el-input v-model="keyword" placeholder="请输入关键词查询" clearable
|
||||
@keyup.enter.native="search()" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search"
|
||||
@click="search()">{{ $t('common.search') }}
|
||||
</el-button>
|
||||
<el-button icon="el-icon-refresh-right" @click="refresh()">{{ $t('common.reset') }}
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
<div class="JNPF-common-search-box-right">
|
||||
<el-tooltip effect="dark" :content="$t('common.refresh')" placement="top">
|
||||
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
|
||||
@click="search()" />
|
||||
</el-tooltip>
|
||||
</div>
|
||||
</el-row>
|
||||
<JNPF-table v-loading="listLoading" :data="list" hasC @selection-change="handleSelectionChange"
|
||||
:border="false">
|
||||
<el-table-column prop="name" label="商品名称" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="code" label="商品编码" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="productTypeIds" label="商品类型" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="shortName" label="商品简称" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="spec" label="商品规格" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="barCode" label="商品条码" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="inventoryTypes" label="存货类型" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="inventoryUnitIds" label="库存单位" align="left">
|
||||
</el-table-column>
|
||||
</JNPF-table>
|
||||
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
|
||||
@pagination="init" />
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="visible = false">{{ $t('common.cancelButton') }}</el-button>
|
||||
<el-button type="primary" @click="select()">{{ $t('common.confirmButton') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import request from '@/utils/request'
|
||||
import {
|
||||
GoodsList
|
||||
} from '@/api/extend/order'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
listLoading: true,
|
||||
keyword: '',
|
||||
list: [],
|
||||
total: 0,
|
||||
listQuery: {
|
||||
superQueryJson: '',
|
||||
currentPage: 1,
|
||||
pageSize: 20,
|
||||
sort: "desc",
|
||||
sidx: "",
|
||||
},
|
||||
excludeIdList: [],
|
||||
checked: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(excludeIdList, val) {
|
||||
this.visible = true
|
||||
this.listLoading = true
|
||||
if (excludeIdList) {
|
||||
this.excludeIdList = excludeIdList;
|
||||
}
|
||||
let query = {
|
||||
...this.listQuery,
|
||||
keyword: this.keyword,
|
||||
excludeIdList: this.excludeIdList,
|
||||
dataType: 0,
|
||||
id: val,
|
||||
}
|
||||
request({
|
||||
url: `/api/scm/ProductWarehouse/getBomProductlist`,
|
||||
method: 'post',
|
||||
data: query
|
||||
}).then(res => {
|
||||
this.list = res.data.list
|
||||
this.listLoading = false
|
||||
this.total = res.data.pagination.total
|
||||
})
|
||||
},
|
||||
refresh() {
|
||||
this.keyword = ''
|
||||
this.listQuery.currentPage = 1
|
||||
this.listQuery.pageSize = 20
|
||||
this.listQuery.sort = "desc"
|
||||
this.listQuery.sidx = ""
|
||||
this.init()
|
||||
},
|
||||
search() {
|
||||
this.listQuery.currentPage = 1
|
||||
this.listQuery.pageSize = 20
|
||||
this.listQuery.sort = "desc"
|
||||
this.listQuery.sidx = ""
|
||||
this.init()
|
||||
},
|
||||
select() {
|
||||
if (!this.checked.length) return
|
||||
this.visible = false
|
||||
this.$emit('refreshDataList', this.checked)
|
||||
},
|
||||
handleSelectionChange(val) {
|
||||
this.checked = val
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
>>> .el-dialog__body {
|
||||
height: 70vh;
|
||||
padding: 0 0 10px !important;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
|
||||
.JNPF-common-search-box {
|
||||
margin-bottom: 0;
|
||||
|
||||
.JNPF-common-search-box-right {
|
||||
padding: 10px 10px 0 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,149 @@
|
||||
<template>
|
||||
<el-dialog title="选择商品" :close-on-click-modal="false" :visible.sync="visible"
|
||||
class="JNPF-dialog JNPF-dialog_center" lock-scroll append-to-body width="800px">
|
||||
<el-row class="JNPF-common-search-box" :gutter="16">
|
||||
<el-form @submit.native.prevent>
|
||||
<el-col :span="10">
|
||||
<el-form-item label="关键词">
|
||||
<el-input v-model="keyword" placeholder="请输入关键词查询" clearable
|
||||
@keyup.enter.native="search()" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search"
|
||||
@click="search()">{{ $t('common.search') }}
|
||||
</el-button>
|
||||
<el-button icon="el-icon-refresh-right" @click="refresh()">{{ $t('common.reset') }}
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form>
|
||||
<div class="JNPF-common-search-box-right">
|
||||
<el-tooltip effect="dark" :content="$t('common.refresh')" placement="top">
|
||||
<el-link icon="icon-ym icon-ym-Refresh JNPF-common-head-icon" :underline="false"
|
||||
@click="search()" />
|
||||
</el-tooltip>
|
||||
</div>
|
||||
</el-row>
|
||||
<JNPF-table v-loading="listLoading" :data="list" hasC @selection-change="handleSelectionChange"
|
||||
:border="false">
|
||||
<el-table-column prop="name" label="商品名称" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="code" label="商品编码" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="productTypeIds" label="商品类型" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="shortName" label="商品简称" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="spec" label="商品规格" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="barCode" label="商品条码" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="inventoryTypes" label="存货类型" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="inventoryNumber" label="可用库存" align="left">
|
||||
</el-table-column>
|
||||
<el-table-column prop="inventoryUnitIds" label="库存单位" align="left">
|
||||
</el-table-column>
|
||||
</JNPF-table>
|
||||
<pagination :total="total" :page.sync="listQuery.currentPage" :limit.sync="listQuery.pageSize"
|
||||
@pagination="init" />
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="visible = false">{{ $t('common.cancelButton') }}</el-button>
|
||||
<el-button type="primary" @click="select()">{{ $t('common.confirmButton') }}</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import request from '@/utils/request'
|
||||
import {
|
||||
GoodsList
|
||||
} from '@/api/extend/order'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
visible: false,
|
||||
listLoading: true,
|
||||
keyword: '',
|
||||
list: [],
|
||||
total: 0,
|
||||
listQuery: {
|
||||
superQueryJson: '',
|
||||
currentPage: 1,
|
||||
pageSize: 20,
|
||||
sort: "desc",
|
||||
sidx: "",
|
||||
},
|
||||
excludeIdList: [],
|
||||
checked: []
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init(excludeIdList, val) {
|
||||
this.visible = true
|
||||
this.listLoading = true
|
||||
if (excludeIdList) {
|
||||
this.excludeIdList = excludeIdList;
|
||||
}
|
||||
let query = {
|
||||
...this.listQuery,
|
||||
keyword: this.keyword,
|
||||
excludeIdList: this.excludeIdList,
|
||||
dataType: 0,
|
||||
id: val,
|
||||
}
|
||||
request({
|
||||
url: `/api/scm/ProductWarehouse/postInventoryReportlossProductlist`,
|
||||
method: 'post',
|
||||
data: query
|
||||
}).then(res => {
|
||||
this.list = res.data.list
|
||||
this.listLoading = false
|
||||
this.total = res.data.pagination.total
|
||||
})
|
||||
},
|
||||
refresh() {
|
||||
this.keyword = ''
|
||||
this.listQuery.currentPage = 1
|
||||
this.listQuery.pageSize = 20
|
||||
this.listQuery.sort = "desc"
|
||||
this.listQuery.sidx = ""
|
||||
this.init()
|
||||
},
|
||||
search() {
|
||||
this.listQuery.currentPage = 1
|
||||
this.listQuery.pageSize = 20
|
||||
this.listQuery.sort = "desc"
|
||||
this.listQuery.sidx = ""
|
||||
this.init()
|
||||
},
|
||||
select() {
|
||||
if (!this.checked.length) return
|
||||
this.visible = false
|
||||
this.$emit('refreshDataList', this.checked)
|
||||
},
|
||||
handleSelectionChange(val) {
|
||||
this.checked = val
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
>>> .el-dialog__body {
|
||||
height: 70vh;
|
||||
padding: 0 0 10px !important;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
|
||||
.JNPF-common-search-box {
|
||||
margin-bottom: 0;
|
||||
|
||||
.JNPF-common-search-box-right {
|
||||
padding: 10px 10px 0 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in new issue