摘要: 所有的要用到全局的比如说 vue 、router、初始页面app 、 ElementUI。。。。 都需要导入和定义 阅读全文
posted @ 2019-02-21 15:57 我就是要叫鱼摆摆 阅读(947) 评论(0) 推荐(0)
摘要: export function formatDate(date,fmt){ if (/(y+)/.test(fmt)) { fmt = fmt.replace(RegExp.$1, (date.getFullYear() + '').substr(4 - RegExp.$1.length)); } 阅读全文
posted @ 2019-02-21 15:26 我就是要叫鱼摆摆 阅读(287) 评论(0) 推荐(0)
摘要: 封装的router 要在main.js里面导入 import router from './router' 1.先要在component里面新建 xxx.vue 2.在router文件夹里的js import xxx from ‘@/component/xxx' Vue.use(Router); e 阅读全文
posted @ 2019-02-21 15:18 我就是要叫鱼摆摆 阅读(459) 评论(0) 推荐(0)
摘要: Vue.prototype.$post=post;Vue.prototype.$get=get;Vue.prototype.$delete=del;Vue.prototype.$patch=patch; 阅读全文
posted @ 2019-02-21 13:57 我就是要叫鱼摆摆 阅读(1669) 评论(0) 推荐(0)
摘要: template: <div @click="up"> <span :class="{colors:isactive false }" v-if="isactive false" >上线</span> <span :class="{colors2:isactive true}" v-if="isac 阅读全文
posted @ 2019-02-21 13:54 我就是要叫鱼摆摆 阅读(1900) 评论(0) 推荐(0)
摘要: 1.在删除的点击上 带ID 2.在data 写一个参数装ID 3.点确认带 装ID的参数 方法一: this.msg.splice(this.msg.find(msg=>{ return msg.id==id }),1 ) 方法二: this.msg.splice(this.msg[id],1) 方 阅读全文
posted @ 2019-01-22 16:03 我就是要叫鱼摆摆 阅读(4945) 评论(0) 推荐(0)
摘要: HTML: <div> <div >验证码</div> <input id="identifying" type="text" placeholder="请输验证码" style="width: 36%; color: #999; border: none;" /> <a id="btn_code" 阅读全文
posted @ 2018-09-17 12:51 我就是要叫鱼摆摆 阅读(111) 评论(0) 推荐(0)
摘要: js: function del(obj){ var id=$(obj).data("id"); $("#"+id).remove(); } html: <div id="itemid"> <div>1</div> <div> <span data-id="itemid" onclick="del( 阅读全文
posted @ 2018-09-17 12:15 我就是要叫鱼摆摆 阅读(1681) 评论(0) 推荐(0)
摘要: 数据绑定: <script type="text/javascript"> $(function() { get_shouhuo_detail(); }) function get_shouhuo_detail() { //条件验证 //比如验证是否登陆,未登陆就跳转到登陆页面 //接口:获取收货地 阅读全文
posted @ 2018-06-07 18:32 我就是要叫鱼摆摆 阅读(243) 评论(0) 推荐(0)
摘要: 实现切换: 方法一: $(function(){ // $("#ypzw").hide(); // $("#gzjy").hide(); // $("#xzyq").hide(); // $("#gzdd").hide(); // $("#one").click(function() { // $( 阅读全文
posted @ 2018-06-07 10:16 我就是要叫鱼摆摆 阅读(185) 评论(0) 推荐(0)