摘要: dispatch:含有异步操作,eg:向后台提交数据,写法: this.$store.dispatch('mutations方法名',值) commit:同步操作,写法:this.$store.commit('mutations方法名',值) 阅读全文
posted @ 2018-08-13 15:04 刘丑丑鱼香肉丝 阅读(824) 评论(0) 推荐(0) 编辑
摘要: 类型于get(query) 和 post(params) 1.query方式传参和接收参数 传参: this.$router.push({ path:"/xxx" query:{ id:id} }) 接收参数:this.$router.query.id 2.params方法传参合接收参数 传参: t 阅读全文
posted @ 2018-08-13 14:30 刘丑丑鱼香肉丝 阅读(665) 评论(0) 推荐(0) 编辑
摘要: JS: $.ajaxPrefilter( function (options) { if (options.crossDomain && jQuery.support.cors) { var http = (window.location.protocol 'http:' ? 'http:' : ' 阅读全文
posted @ 2018-08-09 15:16 刘丑丑鱼香肉丝 阅读(9747) 评论(4) 推荐(1) 编辑
只有注册用户登录后才能阅读该文。 阅读全文
posted @ 2018-08-09 15:06 刘丑丑鱼香肉丝 阅读(5) 评论(0) 推荐(0) 编辑