mounted() {
this.createTiming()
},
watch: {
$route(to, from) {
if (this.$route.path != '/videoList') {
this.dest...
3年前 (2022-05-15)
喜欢
当组件设置keep-alive后,不会直接调用这个销毁周期函数,而是会在生命周期函数新增两个,activated和deactivated;
当第一次进入页面是,生命周期函数执行是这样的,简单描述一下:
created()->mounted()->activated()...
3年前 (2022-05-15)
喜欢
根据用户登录后返回的菜单列表,判断页面是否有权限访问。
import Vue from 'vue'
import Router from 'vue-router'
import { Message } from 'element-ui'
Vue.use(Router)
fun...
3年前 (2022-05-13)
喜欢
unknown mutation type: programManagementx
今天项目添加了store,结果一直提示
unknown mutation type: programManagementx
排查来排查去,发现store已经存在了,自己又添加了一个文件,但是这个...
3年前 (2022-05-12)
喜欢
import _ from 'lodash'
watch: {
item: {
handler (newVal) {
console.log(newVal)
this.getdata2()
},
de...
3年前 (2022-05-12)
喜欢
要求:video在没有播放视频的时候,视频中间要显示播放按钮,播放时,隐藏播放按钮。
<div class="videoBox" v-if="data.contentType==2">
&l...
3年前 (2022-05-12)
喜欢
vue 全屏和退出全屏功能,每次都要手写感觉好麻烦,干脆封装成一个组件,以后可以复用。vue实现网页进入全屏和退出全屏
如果传值id,则指定id全屏,如果没传,则是页面全屏。
<template>
<div class="full" @c...
3年前 (2022-05-11)
喜欢
代码
/**
* @Author: 858834013@qq.com
* @Name: businessScope
* @Date: 2022-05-9
* @Desc: select同步复选
*/
<template>
<div>
<...
3年前 (2022-05-09)
喜欢
html
<el-upload action="#" accept=".txt" :on-change="handleChangeUpload" :auto-upload="false...
3年前 (2022-05-07)
喜欢
uniapp微信小程序开发时,遇到一个奇怪的问题,点击指定区域弹出选择框,但是在输入框输入内容时,点击其他区域的选择框是,发现软键盘并没有隐藏,但是选择框弹出了,导致软键盘遮挡了选择框,排查发现是因为点击的区域是另外一个输入框,但是这个输入框是禁止输入内容导致的。
<in...
3年前 (2022-05-06)
喜欢