Commit 4b2dbc40 by zhangquan

修复bug

1 parent 5d5945f5
...@@ -17,8 +17,8 @@ export const fetchConfig = function (isEnv = true) { ...@@ -17,8 +17,8 @@ export const fetchConfig = function (isEnv = true) {
// Object.assign(request, { timeout }) // Object.assign(request, { timeout })
// return Promise.resolve(cfg) // return Promise.resolve(cfg)
// } // }
return new Http().get('https://oss-config.dev.glsx.com.cn/mock/63b39b3e606e962c5e174afb/discover/config') // return new Http().get('https://oss-config.dev.glsx.com.cn/mock/63b39b3e606e962c5e174afb/discover/config')
// return new Http().get('https://oss-config.glsx.com.cn/mock/63c12a6b28a427953783403e/discover/config') return new Http().get('https://oss-config.glsx.com.cn/mock/63c12a6b28a427953783403e/discover/config')
} }
export const config = { export const config = {
......
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
</div> </div>
</div> </div>
<div slot="categorySlot"> <div slot="categorySlot">
<brandCascader :disabled="disabled" @clickItem="selectCategory" class="category-class"></brandCascader> <brandCascader :curInfo="curCategoryInfo" :disabled="disabled" @clickItem="selectCategory" class="category-class"></brandCascader>
</div> </div>
</glsx-combi-form> </glsx-combi-form>
</div> </div>
...@@ -129,6 +129,7 @@ export default { ...@@ -129,6 +129,7 @@ export default {
children: 'categoryName', children: 'categoryName',
label: 'childs' label: 'childs'
}, },
curCategoryInfo:{},
posterOptions: { posterOptions: {
width: '104px', width: '104px',
height: '104px', height: '104px',
......
...@@ -76,6 +76,7 @@ export default { ...@@ -76,6 +76,7 @@ export default {
'curInfo.id':{ 'curInfo.id':{
handler(nVal, oVal){ handler(nVal, oVal){
if(this.curBrand.id==nVal) return
this.curBrand = this.curInfo this.curBrand = this.curInfo
}, },
deep: true deep: true
...@@ -116,6 +117,7 @@ export default { ...@@ -116,6 +117,7 @@ export default {
}, },
// 显示隐藏 // 显示隐藏
switchBrand() { switchBrand() {
if(this.disabled) return
let distance = 0 let distance = 0
try { try {
distance = window.innerHeight - this.$refs.cascaderRef.getBoundingClientRect().y -this.$refs.cascaderRef.getBoundingClientRect().height distance = window.innerHeight - this.$refs.cascaderRef.getBoundingClientRect().y -this.$refs.cascaderRef.getBoundingClientRect().height
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
:close-on-click-modal="false" :close-on-click-modal="false"
@onOk="handleConfirm" @onOk="handleConfirm"
@onCancel="handleClose"> @onCancel="handleClose">
<!-- <glsx-combi-form ref="showSearch" <glsx-combi-form ref="showSearch"
labelWidth="105px" labelWidth="105px"
:formObj="searchForm" :formObj="searchForm"
:formData="searchFormData"> :formData="searchFormData">
...@@ -16,15 +16,14 @@ ...@@ -16,15 +16,14 @@
type="primary" type="primary"
@click="resetTable">查询</el-button> @click="resetTable">查询</el-button>
</span> </span>
</glsx-combi-form> --> </glsx-combi-form>
<GLTable ref="storeRef" <GLTable ref="goodsRef"
:noDataImg="url" :noDataImg="url"
:tableTotal="total"
:searchForm="searchForm" :searchForm="searchForm"
:tableParams="tableParams" :tableParams="tableParams"
:pageConf="pageConf" :pageConf="pageConf"
@refreshTable="getList" @refreshTable="getList"
:tableData="storeList" :getListApi="getListApi"
:hasNum="false" :hasNum="false"
:setTableFinishFun="setTableFinishFun"> :setTableFinishFun="setTableFinishFun">
<div slot="radioHtml" <div slot="radioHtml"
...@@ -53,36 +52,29 @@ export default { ...@@ -53,36 +52,29 @@ export default {
return { return {
url: url, url: url,
searchForm: { searchForm: {
goodsName: ''
}, },
// getListApi: this.$apis.common.getMerchantList,
total: 0, total: 0,
storeList: [], storeList: [],
heightBox: 200, heightBox: 200,
curInfo: {}, curInfo: {},
// 搜索 // 搜索
// searchFormData: [ searchFormData: [
// { {
// label: '商户名称', label: '商品名称',
// name: 'merchantName', name: 'goodsName',
// type: 'input', type: 'input',
// placeholder: '请输入商户名称', placeholder: '请输入商品名称',
// width: '300px', width: '300px',
// labelWidth: '10px' labelWidth: '10px',
// }, isClear: true
// { }
// label: '商户ID', ],
// name: 'merchantId',
// type: 'input',
// inputType: 'number',
// placeholder: '请输入商户ID',
// width: '300px',
// labelWidth: '10px'
// }
// ],
pageConfig: { pageConfig: {
pageSize: 10, pageSize: 10,
currentPage: 1 pageNum: 1
}, },
getListApi: this.$apis.goods.getCarlifeGoodsApi,
tableParams: { tableParams: {
listName: 'list', listName: 'list',
tableColumns: [ tableColumns: [
...@@ -108,7 +100,7 @@ export default { ...@@ -108,7 +100,7 @@ export default {
} }
] ]
}, },
pageConf: { pageSize: 'pageSize', pageNum: 'currentPage', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
baseData: {} baseData: {}
} }
}, },
...@@ -140,34 +132,14 @@ export default { ...@@ -140,34 +132,14 @@ export default {
mounted() { mounted() {
let clientHeight = document.documentElement.clientHeight let clientHeight = document.documentElement.clientHeight
this.heightBox = clientHeight - 0.15 * clientHeight - 425 this.heightBox = clientHeight - 0.15 * clientHeight - 425
this.getList()
}, },
methods: { methods: {
getList(pageCon) {
pageCon && (this.pageConfig = pageCon)
var params = {
merchantId: this.merchantId,
...this.searchForm,
...this.pageConfig
// merchantId: '44209390',
}
this.$apis.goods.getCarlifeGoodsApi(params).then(res => {
this.storeList = res.list
this.total = res.total
let nowIndex = this.pageConfig.pageSize * (this.pageConfig.currentPage - 1)
this.storeList.forEach((item, index) => {
item.idx = index + 1 + nowIndex
})
})
},
resetTable() { resetTable() {
this.$refs.storeRef.page.currentPage = 1 this.$refs.goodsRef.refreshTable()
this.getList()
}, },
setTableFinishFun() { setTableFinishFun() {
this.$refs.staffRef.tableHeightValues = '460px' this.$refs.goodsRef.tableHeightValues = '460px'
}, },
handleClick(item) { handleClick(item) {
...@@ -185,7 +157,15 @@ export default { ...@@ -185,7 +157,15 @@ export default {
} }
</script> </script>
<style lang="scss"> <style lang="scss" scoped>
/deep/.glsx-combi-form .el-form{
.el-form-item{
margin-right: 12px!important;
}
.el-button {
margin-top: 1px;
}
}
.select-store { .select-store {
.storeDailog { .storeDailog {
width: 500px; width: 500px;
......
...@@ -249,7 +249,7 @@ ...@@ -249,7 +249,7 @@
} }
</script> </script>
<style lang="scss"> <style lang="scss" scoped>
.search-wrap{ .search-wrap{
margin-bottom: 12px; margin-bottom: 12px;
.el-input { .el-input {
......
...@@ -359,6 +359,7 @@ export default { ...@@ -359,6 +359,7 @@ export default {
this.searchForm.associationClassifyFirstId = associationClassifyFirstId this.searchForm.associationClassifyFirstId = associationClassifyFirstId
this.searchForm.associationClassifySecondId = associationClassifySecondId this.searchForm.associationClassifySecondId = associationClassifySecondId
this.searchForm.startCreatedDate = this.searchForm.createdDate ? this.searchForm.createdDate + ' 00:00:00' : '' this.searchForm.startCreatedDate = this.searchForm.createdDate ? this.searchForm.createdDate + ' 00:00:00' : ''
this.searchForm.endCreatedDate = this.searchForm.createdDate ? this.searchForm.createdDate + ' 23:59:59' : ''
delete this.searchForm.createdDate delete this.searchForm.createdDate
} }
// delete this.searchForm.createDate // delete this.searchForm.createDate
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!