03 2020 档案
摘要:python 中字典,如下: 1 date = {'a':1,'b':''} 增加或修改的话可以 直接 使用 date[key] = value 的方式 如果想将 date 改成 二级字典 {'a': 1, 'b': {'c': 1}},此时上面这种方法会报错: TypeError: 'str' o
阅读全文
摘要:之前需求是当前时间+5天,写法如下 1 var dataCur = new Date(); //当前日期 2 var dataDef = dataCur.getFullYear() + '-' + (dataCur.getMonth() + 1) + '-' + (dataCur.getDate()
阅读全文
摘要:报错如图,看提示是 属性内的值已被移除更换另一种方式: 原写法: 1 <a target="_blank" href="'http://xxxxxxxx'+{{env}}"> {{env}}</a> 修改后: 1 <a target="_blank" v-bind:href="'http://xxx
阅读全文
摘要:1 window.open('https://www.baidu.com/','top'); 2 #在当前页面打开baidu地址 和 <a href='https://www.baidu.com/'></a> 效果相同 3 4 5 window.location.href = 'https://ww
阅读全文
摘要:更新本地分支的时候,提示让先merge 可以忽略本地改动直接覆盖: 1 git reset --hard 2 git pull
阅读全文
摘要:安装 uwsgi的时候报错,如图 查阅相关文档后,发现需要安装 gcc 和python-dev,命令如下: 1 yum -y install gcc 2 yum -y install python-devel 3 # python 2用python-devel,python3用 python3-de
阅读全文
摘要:查了下文档,是导入包的方式问题,我的报错如下: 修改如下: 1 #原导入包的方式 2 import BeautifulSoup 3 4 5 #更换导入包方式 6 from bs4 import BeautifulSoup
阅读全文
摘要:主要使用 以下方式跳转外部页面,通过路由到指定页面后,再打开外部页面 1 window.location.href = 'http://www.baidu.com' 修改如下: 1.菜单配置 menu.js: 1 let menu = { 2 menus: [ 3 4 { 5 key: '1', d
阅读全文