会员
周边
众包
新闻
博问
闪存
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
lemonlemontree
博客园
首页
博问
闪存
新随笔
订阅
管理
上一页
1
2
2017年7月5日
django处理Template中None类型值
摘要: {{ request.user.mobile|default_if_none:'' }}字段为空时指定其值
阅读全文
posted @ 2017-07-05 23:02 lemonlemontree
阅读(427)
评论(0)
推荐(0)
编辑
2017年6月27日
django处理choices
摘要: model定义gender = models.CharField(max_length=2, choices=(('male', u'男'), ('female', u'nv')), verbose_name=u'性别')html取值object.get_gender_display
阅读全文
posted @ 2017-06-27 00:34 lemonlemontree
阅读(1291)
评论(0)
推荐(0)
编辑
2017年6月12日
list切片
摘要: 切片: 通过指定下标的方式来获得某一个数据元素,或者通过指定下标范围来获得一组序列的元素,这种访问序列的方式叫做切片。 访问某一个数据元素的的语法如下: sequence[index] sequence是序列名,index是想要访问的元素对应的偏移量,偏移量可以是正值,范围是:0<=index<=l
阅读全文
posted @ 2017-06-12 23:17 lemonlemontree
阅读(224)
评论(0)
推荐(0)
编辑
pycharm快捷键
摘要: 1、编辑(Editing) Ctrl + Space 基本的代码完成(类、方法、属性)Ctrl + Alt + Space 快速导入任意类Ctrl + Shift + Enter 语句完成Ctrl + P 参数信息(在方法中调用参数)Ctrl + Q 快速查看文档Shift + F1 外部文档Ctr
阅读全文
posted @ 2017-06-12 21:19 lemonlemontree
阅读(158)
评论(0)
推荐(0)
编辑
2017年6月1日
网页基础布局
摘要: <div class="container-fluid"> <div class="row-fluid"> <div class="span12"> <div class="navbar"> <div class="navbar-inner"> <div class="container-fluid
阅读全文
posted @ 2017-06-01 23:20 lemonlemontree
阅读(145)
评论(0)
推荐(0)
编辑
login布局
摘要: <div class="container-fluid"> <div class="row-fluid"> <div class="span12"> <div class="row-fluid"> <div class="span6"> </div> <div class="span6"> </di
阅读全文
posted @ 2017-06-01 22:59 lemonlemontree
阅读(245)
评论(0)
推荐(0)
编辑
2017年5月30日
git命令
摘要: git init # 初始化本地git仓库(创建新仓库) git config --global user.name "xxx" # 配置用户名 git config --global user.email "xxx@xxx.com" # 配置邮件 git config --global color
阅读全文
posted @ 2017-05-30 22:51 lemonlemontree
阅读(172)
评论(0)
推荐(0)
编辑
Python error: Microsoft Visual C++ 9.0 is required 解决方案
摘要: 在Windows7x64下使用pip安装包的时候提示报错:Microsoft Visual C++ 9.0 is required (Unable to find vcvarsall.bat) 环境:windows10 x64 ,python2.7 ,VS2015 原因:windows下使用pip安
阅读全文
posted @ 2017-05-30 20:22 lemonlemontree
阅读(9077)
评论(0)
推荐(0)
编辑
上一页
1
2