Commit 45862b69 by 肖康

微信列表页面

parent f18ba5b2
...@@ -20,7 +20,7 @@ const mutations = { ...@@ -20,7 +20,7 @@ const mutations = {
state.wechatArticleList = state.wechatArticleList.concat(payload.data.list); state.wechatArticleList = state.wechatArticleList.concat(payload.data.list);
//计算总页码 //计算总页码
state.limits = Math.ceil(payload.data.total / 4); state.limits = Math.ceil(payload.data.total / 10);
//判断数据是否加载完成 //判断数据是否加载完成
if (payload.page >= state.limits) { if (payload.page >= state.limits) {
...@@ -30,20 +30,15 @@ const mutations = { ...@@ -30,20 +30,15 @@ const mutations = {
} }
const actions = { const actions = {
wechatArticle({commit}, payload) { wechatArticle({commit}, payload) {
state.loadStatus = true;
var params = { var params = {
type_id: payload.type_id, type_id: payload.type_id,
page: payload.page, page: payload.page,
limit: payload.limit limit: payload.limit
} }
Services.wechatArticle(qs.stringify(params)).then((res) => { Services.wechatArticle(qs.stringify(params)).then((res) => {
let data = res.data; let data = res.data;
state.loadStatus = false; state.loadStatus = false;
if (data.err_code == 0) { if (data.err_code == 0) {
commit({ commit({
type: 'wechatArticle', type: 'wechatArticle',
...@@ -51,11 +46,6 @@ const actions = { ...@@ -51,11 +46,6 @@ const actions = {
page: payload.page, page: payload.page,
limit: payload.limit limit: payload.limit
}); });
} else {
Toast({
message: data.err_msg,
duration: 20000
});
} }
}).catch(function (err) { }).catch(function (err) {
state.loadStatus = false; state.loadStatus = false;
......
...@@ -39,17 +39,17 @@ ...@@ -39,17 +39,17 @@
import Vue from 'vue'; import Vue from 'vue';
import {mapState} from 'vuex' import {mapState} from 'vuex'
import {List, Loading} from 'vant'; import {List} from 'vant';
import Header from '@/views/common/Header.vue'; import Header from '@/views/common/Header.vue';
Vue.use(List).use(Loading); Vue.use(List);
export default { export default {
name: 'wxlist', name: 'wxlist',
data() { data() {
return { return {
page: 0, page: 0,
limit: 4, limit: 10,
loading: false loading: false
} }
}, },
......
<!DOCTYPE HTML><html lang=zh-CN><head><title></title><meta name=author content=www.ichunt.com><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0,user-scalable=no,minimal-ui"><meta http-equiv=Content-Type content="text/html;charset=utf-8"><meta name=apple-mobile-web-app-capable content=yes><meta name=apple-mobile-web-app-status-bar-style content=black><meta name=format-detection content="telephone=no"><meta http-equiv=Expires content=-1><meta http-equiv=Cache-Control content=no-cache><meta http-equiv=Pragma content=no-cache><meta name=full-screen content=yes><meta name=browsermode content=application><meta name=x5-fullscreen content=true><meta name=x5-page-mode content=app><meta name=description content=猎芯网,快速成长的专业电子元器件商城,贸泽(MOUSER)全系产品、e络盟(element14)树莓派系列产品授权经销商,已获得多轮风险投资。为客户提供电子元器件现货,IC采购,进口报关,电子元器件寄售,供应链金融等一站式电子元器件采购服务。><meta name=keywords content=猎芯网,电子元器件采购,电子元器件商城,电子元器件现货,IC采购网,电子元器件寄售,电子元件,元器件商城,元器件采购,电子商城,><link rel=icon href=//h5static.ichunt.com/favicon.ico><link rel=stylesheet href=/v3/dist/res/m/css/font/iconfont.css><script src=/h5/view/get_time.php></script><script>var fwtimes = window.fwtime - (Math.floor((new Date().getTime()) / 1000)); //获取服务器时间差</script><script src=https://res.wx.qq.com/open/js/jweixin-1.3.2.js charset=utf-8></script><script src=//h5static.ichunt.com/static/js/flexible.min.js charset=utf-8></script><script src=//h5static.ichunt.com/static/js/shence.min.js charset=utf-8></script><link href=//h5static.ichunt.com/css/chunk-1144b73a.43c91bcb.css rel=prefetch><link href=//h5static.ichunt.com/css/chunk-37ba70a3.d7e46390.css rel=prefetch><link href=//h5static.ichunt.com/css/chunk-5498eef5.e5216386.css rel=prefetch><link href=//h5static.ichunt.com/css/chunk-682cf93e.fb3a1b2a.css rel=prefetch><link href=//h5static.ichunt.com/js/chunk-1144b73a.ea7151f2.js rel=prefetch><link href=//h5static.ichunt.com/js/chunk-37ba70a3.920bbbbd.js rel=prefetch><link href=//h5static.ichunt.com/js/chunk-5498eef5.a53bcd31.js rel=prefetch><link href=//h5static.ichunt.com/js/chunk-682cf93e.66494e24.js rel=prefetch><link href=//h5static.ichunt.com/css/app.adc8e432.css rel=preload as=style><link href=//h5static.ichunt.com/css/chunk-vendors.fa7e75a9.css rel=preload as=style><link href=//h5static.ichunt.com/js/app.f1672d98.js rel=preload as=script><link href=//h5static.ichunt.com/js/chunk-vendors.e68ea566.js rel=preload as=script><link href=//h5static.ichunt.com/css/chunk-vendors.fa7e75a9.css rel=stylesheet><link href=//h5static.ichunt.com/css/app.adc8e432.css rel=stylesheet></head><body class=boxsiz><noscript><strong>网站出现了一点小问题,正在紧急修复中.......</strong></noscript><div id=app></div><script>function SetCookie(name, value, time, domain) { <!DOCTYPE HTML><html lang=zh-CN><head><title></title><meta name=author content=www.ichunt.com><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0,user-scalable=no,minimal-ui"><meta http-equiv=Content-Type content="text/html;charset=utf-8"><meta name=apple-mobile-web-app-capable content=yes><meta name=apple-mobile-web-app-status-bar-style content=black><meta name=format-detection content="telephone=no"><meta http-equiv=Expires content=-1><meta http-equiv=Cache-Control content=no-cache><meta http-equiv=Pragma content=no-cache><meta name=full-screen content=yes><meta name=browsermode content=application><meta name=x5-fullscreen content=true><meta name=x5-page-mode content=app><meta name=description content=猎芯网,快速成长的专业电子元器件商城,贸泽(MOUSER)全系产品、e络盟(element14)树莓派系列产品授权经销商,已获得多轮风险投资。为客户提供电子元器件现货,IC采购,进口报关,电子元器件寄售,供应链金融等一站式电子元器件采购服务。><meta name=keywords content=猎芯网,电子元器件采购,电子元器件商城,电子元器件现货,IC采购网,电子元器件寄售,电子元件,元器件商城,元器件采购,电子商城,><link rel=icon href=//h5static.ichunt.com/favicon.ico><link rel=stylesheet href=/v3/dist/res/m/css/font/iconfont.css><script src=/h5/view/get_time.php></script><script>var fwtimes = window.fwtime - (Math.floor((new Date().getTime()) / 1000)); //获取服务器时间差</script><script src=https://res.wx.qq.com/open/js/jweixin-1.3.2.js charset=utf-8></script><script src=//h5static.ichunt.com/static/js/flexible.min.js charset=utf-8></script><script src=//h5static.ichunt.com/static/js/shence.min.js charset=utf-8></script><link href=//h5static.ichunt.com/css/chunk-383c5e1e.d7e46390.css rel=prefetch><link href=//h5static.ichunt.com/css/chunk-406d08fd.43c91bcb.css rel=prefetch><link href=//h5static.ichunt.com/css/chunk-8fb1c5d8.57c33e9d.css rel=prefetch><link href=//h5static.ichunt.com/css/chunk-d0644cb4.e5216386.css rel=prefetch><link href=//h5static.ichunt.com/js/chunk-383c5e1e.2663d4f1.js rel=prefetch><link href=//h5static.ichunt.com/js/chunk-406d08fd.1f0254c2.js rel=prefetch><link href=//h5static.ichunt.com/js/chunk-8fb1c5d8.a171398d.js rel=prefetch><link href=//h5static.ichunt.com/js/chunk-d0644cb4.4fb90a16.js rel=prefetch><link href=//h5static.ichunt.com/css/app.adc8e432.css rel=preload as=style><link href=//h5static.ichunt.com/css/chunk-vendors.59ded326.css rel=preload as=style><link href=//h5static.ichunt.com/js/app.9e7c4153.js rel=preload as=script><link href=//h5static.ichunt.com/js/chunk-vendors.1b4108eb.js rel=preload as=script><link href=//h5static.ichunt.com/css/chunk-vendors.59ded326.css rel=stylesheet><link href=//h5static.ichunt.com/css/app.adc8e432.css rel=stylesheet></head><body class=boxsiz><noscript><strong>网站出现了一点小问题,正在紧急修复中.......</strong></noscript><div id=app></div><script>function SetCookie(name, value, time, domain) {
domain = domain ? ";domain=" + domain : ""; domain = domain ? ";domain=" + domain : "";
var Days = time; var Days = time;
var exp = new Date(); var exp = new Date();
...@@ -224,4 +224,4 @@ ...@@ -224,4 +224,4 @@
user_rank: '0' user_rank: '0'
}); });
sensors.quick('autoTrack'); sensors.quick('autoTrack');
}</script><script src=//h5static.ichunt.com/js/chunk-vendors.e68ea566.js></script><script src=//h5static.ichunt.com/js/app.f1672d98.js></script></body></html> }</script><script src=//h5static.ichunt.com/js/chunk-vendors.1b4108eb.js></script><script src=//h5static.ichunt.com/js/app.9e7c4153.js></script></body></html>
\ No newline at end of file \ No newline at end of file
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
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 sign in to comment