lisijie / goblog Goto Github PK
View Code? Open in Web Editor NEW基于beego的简易blog系统
基于beego的简易blog系统
goblog/controllers/admin/article.go
188行 updated 数据库里是 update_time
输入以下命令:
$ go get github.com/lisijie/goblog
提示如下:
#github.com/lisijie/goblog/models
github.com\lisijie\goblog\models\post.go:59: undefined: orm.Col_Minus
试过N次,GOPATH和GOROOT都没问题,其它的golangPrj也能编译和运行,求帮助。
@lisijie
不能保存文章,报错
[ORM] - 2014-03-15 12:23:45 - [Queries/default] - [FAIL / db.Exec / 0.4ms] - [INSERT INTO tb_post
(userid
, author
, title
, color
, urlname
, urltype
, content
, tags
, posttime
, views
, status
, updated
, istop
) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)] - 1
, admin
, ,
, ,
0,
, ``,2014-03-15 12:23:45.844292414 +0800 +0800
,`0`,`0`,`0001-01-01 08:00:00 +0800 +0800`,`0` - Error 1364: Field 'excerpt' doesn't have a default value
用Ueditor上传不了图片。
我在用beego 1.7.2,执行构建时,会有一些地方不兼容了,需要改一下。
如
- this.TplNames = this.moduleName + "/account/login.html"
+ this.TplName = this.moduleName + "/account/login.html"
// ...
- tagobj.Query().Filter("name__in", oldtags).Update(orm.Params{"count": orm.ColValue(orm.Col_Minus, 1)})
+ tagobj.Query().Filter("name__in", oldtags).Update(orm.Params{"count": orm.ColValue(orm.ColMinus, 1)})
// ...
- this.ServeJson()
+ this.ServeJSON()
// ...
- if _, err := os.Stat(beego.ViewsPath + "/" + theme + "/layout.html"); err == nil {
+ if _, err := os.Stat(beego.BConfig.WebConfig.ViewsPath + "/" + theme + "/layout.html"); err == nil {
// ...
你好,因为用了 Ueditor 后台 怎么 防xss 呢?
G:/go/bin/go.exe build -i [G:/gocode/src/github.com/lisijie/goblog]
.\main.go:21: undefined: beego.AppConfigPath
.\main.go:22: undefined: beego.ParseConfig
.\main.go:25: undefined: beego.AppConfigPath
.\main.go:26: undefined: beego.ParseConfig
错误: 进程退出代码 2.
G:/go/bin/go.exe build -i [G:/gocode/src/github.com/lisijie/goblog]
controllers\blog\base.go:39: undefined: beego.ViewsPath
错误: 进程退出代码 2.
Support to locale_en-US
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.