Commit 4b2dbc40 by zhangquan

修复bug

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