Commit ce4e592c authored by zhanglw's avatar zhanglw

黄页产品列表

parent 732cdb39
......@@ -293,9 +293,6 @@
</el-form>
<div slot="footer" class="dialog-footer" style="text-align: center">
<el-button @click="cancelView">关闭</el-button>
<!-- <el-button type="danger" @click="submitForm()">预览</el-button>-->
<el-button type="primary" @click="submitForm()">保存</el-button>
<el-button v-if="formData.homePageId" type="success" @click="submitForm(true)">发布</el-button>
</div>
</el-dialog>
</template>
......
......@@ -56,9 +56,6 @@
</el-form>
<div slot="footer" class="dialog-footer" style="text-align: center">
<el-button @click="cancelView">关闭</el-button>
<!-- <el-button type="danger" @click="submitForm()">预览</el-button>-->
<el-button type="primary" @click="submitForm()">保存</el-button>
<el-button v-if="formData.newsPageId" type="success" @click="submitForm(true)">发布</el-button>
</div>
</el-dialog>
</template>
......
......@@ -135,11 +135,13 @@
<el-input v-model="formData.registeredCapital" type="number" placeholder="请输入数字" class="cell-input" />
</div>
</el-form-item>
<el-form-item label="注册地址:" class="form-cell">
<el-form-item label="注册地址:" class="form-cell" required>
<div class="cell-box">
<el-form-item prop="registeredAddressProvince" style="margin: 0;display: inline-block;">
<el-select v-model="formData.registeredAddressProvince" placeholder="省" style="width: 120px" @change="findAreaByCodeAndType(formData.registeredAddressProvince,2, 'cityOpts')">
<el-option v-for="item in provinceOpts" :key="item.id" :label="item.name" :value="item.code" />
</el-select>
</el-form-item>
<el-select v-model="formData.registeredAddressCity" placeholder="市" style="width: 160px" @change="findAreaByCodeAndType(formData.registeredAddressCity,3, 'countyOpts')">
<el-option v-for="item in cityOpts" :key="item.id" :label="item.name" :value="item.code" />
</el-select>
......@@ -240,7 +242,8 @@ export default {
registeredCapital: { required: true, message: '请填写注册资本', trigger: 'blur' },
enterpriseIntroduction: { required: true, message: '请填写企业介绍', trigger: 'blur' },
mainProductsIntroduction: { required: true, message: '请填写主营产品介绍', trigger: 'blur' },
businessScopeIntroduction: { required: true, message: '请填写业务范围介绍', trigger: 'blur' }
businessScopeIntroduction: { required: true, message: '请填写业务范围介绍', trigger: 'blur' },
registeredAddressProvince: { required: true, message: '请填写注册省份', trigger: 'blur' }
}
}
},
......
......@@ -135,11 +135,13 @@
<el-input v-model="formData.registeredCapital" type="number" placeholder="请输入数字" class="cell-input" />
</div>
</el-form-item>
<el-form-item label="注册地址:" class="form-cell">
<el-form-item label="注册地址:" class="form-cell" required>
<div class="cell-box">
<el-form-item prop="registeredAddressProvince" style="margin: 0;display: inline-block;">
<el-select v-model="formData.registeredAddressProvince" placeholder="省" style="width: 120px" @change="findAreaByCodeAndType(formData.registeredAddressProvince,2, 'cityOpts')">
<el-option v-for="item in provinceOpts" :key="item.id" :label="item.name" :value="item.code" />
</el-select>
</el-form-item>
<el-select v-model="formData.registeredAddressCity" placeholder="市" style="width: 160px" @change="findAreaByCodeAndType(formData.registeredAddressCity,3, 'countyOpts')">
<el-option v-for="item in cityOpts" :key="item.id" :label="item.name" :value="item.code" />
</el-select>
......@@ -239,7 +241,8 @@ export default {
registeredCapital: { required: true, message: '请填写注册资本', trigger: 'blur' },
enterpriseIntroduction: { required: true, message: '请填写企业介绍', trigger: 'blur' },
mainProductsIntroduction: { required: true, message: '请填写主营产品介绍', trigger: 'blur' },
businessScopeIntroduction: { required: true, message: '请填写业务范围介绍', trigger: 'blur' }
businessScopeIntroduction: { required: true, message: '请填写业务范围介绍', trigger: 'blur' },
registeredAddressProvince: { required: true, message: '请填写注册省份', trigger: 'blur' }
}
}
},
......
......@@ -31,9 +31,10 @@
<img v-if="item.isGood" src="@/assets/home_images/recommend.png" class="stamp" title="推荐" style="top: 10px;right: 8px">
<img v-if="item.isHot" src="@/assets/home_images/hot.png" class="stamp" title="热门" style="top: 0;left: 0">
<el-image
:src="item.imgSrc?imgSrcStart+'/img'+item.imgSrc:defaultImgProduct"
:preview-src-list="item.imgSrcList.length?item.imgSrcList:[defaultImgProduct]"
class="touch"
:src="item.imgSrc?imgSrcStart+'/productPic/'+item.imgSrc:defaultImgProduct"
style="width:284px;height: 284px;margin: 0 32px 4px"
@click="goToDetails(item, '/product/details')"
>
<div slot="placeholder" class="image-slot">加载中<span class="dot">...</span></div>
</el-image>
......@@ -154,9 +155,9 @@
<div class="search-box">
<el-row style="padding-top: 10px">
<el-col :span="2">
<div class="search-item" :class="query.type===undefined?'active':''">
<span class="touch label" @click="setQuertType()">默认排序</span>
<span v-if="query.type===undefined">
<div class="search-item" :class="query.type===''?'active':''">
<span class="touch label" @click="setQuertType('')">默认排序</span>
<span v-if="query.type===''">
<i v-if="query.sort" class="el-icon-sort-up touch" />
<i v-else class="el-icon-sort-down touch" />
</span>
......@@ -187,7 +188,7 @@
<el-input v-model="query.minPrice" placeholder="请输入价格(元)" clearable style="width: 140px" />
~
<el-input v-model="query.maxPrice" placeholder="请输入价格(元)" clearable style="width: 140px" />
<div class="btn touch">确 定</div>
<div class="btn touch" @click="search">确 定</div>
</div>
</div>
</el-col>
......@@ -199,9 +200,10 @@
<img v-if="item.isGood" src="@/assets/home_images/recommend.png" class="stamp" title="推荐" style="top: 10px;right: 8px">
<img v-if="item.isHot" src="@/assets/home_images/hot.png" class="stamp" title="热门" style="top: 0;left: 0">
<el-image
:src="item.imgSrc?imgSrcStart+'/img'+item.imgSrc:defaultImgProduct"
:preview-src-list="item.imgSrcList.length?item.imgSrcList:[defaultImgProduct]"
class="touch"
:src="item.imgSrc?imgSrcStart+'/productPic/'+item.imgSrc:defaultImgProduct"
style="width:284px;height: 284px;margin: 0 32px 4px"
@click="goToDetails(item, '/product/details')"
>
<div slot="placeholder" class="image-slot">加载中<span class="dot">...</span></div>
</el-image>
......@@ -277,12 +279,11 @@ export default {
defaultImgSystem: default_system,
imgSrcStart: process.env.VUE_APP_BASE_API,
page: 1,
pageSize: 10,
total: 33,
pageSize: 12,
total: 0,
query: {
keyword: '',
area: undefined,
type: undefined,
supplierId: '',
type: '',
sort: false
},
mapDom: null,
......@@ -428,11 +429,22 @@ export default {
},
mounted() {
this.$nextTick(() => {
this.query.supplierId = this.$route.params.id
this.search()
})
},
methods: {
onDictReady(dict) {},
search() {
HttpReq.webClientApi.productGetHardwareList({
page: this.page - 1,
pageSize: this.pageSize,
...this.query
}).then((res) => {
this.productList = res.data.hardwareList.data
this.total = res.data.hardwareList.total
})
},
tabChange(tabIndex) {
if (this.tabIndex === tabIndex) {
return
......@@ -456,6 +468,8 @@ export default {
this.mapDom.resize()
}
/* eslint-enable */
} else {
this.search()
}
},
setQuertType(type) {
......@@ -503,7 +517,7 @@ export default {
}
},
loadData() {
this.search()
},
goTop() {
document.body.scrollTop = 0
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment