Documentation ¶
Index ¶
- func CommentDelByKey(db *youdb.DB, aid string, cid uint64) error
- func CommentSetByKey(db *youdb.DB, aid string, cid uint64, obj Comment) error
- func LinkSet(db *youdb.DB, obj Link)
- func UserGetIdByName(db *youdb.DB, name string) string
- func UserUpdate(db *youdb.DB, obj User) error
- type Article
- type ArticleFeedListItem
- type ArticleLi
- type ArticleListItem
- type ArticleMini
- type ArticlePageInfo
- type ArticleRelative
- type ArticleTag
- type Category
- type CategoryMini
- type CategoryPageInfo
- type Comment
- type CommentListItem
- type CommentPageInfo
- type Link
- type User
- type UserMini
- type UserPageInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CommentSetByKey ¶
Types ¶
type Article ¶
type Article struct { Id uint64 `json:"id"` Uid uint64 `json:"uid"` Cid uint64 `json:"cid"` RUid uint64 `json:"ruid"` Title string `json:"title"` Content string `json:"content"` ClientIp string `json:"clientip"` Tags string `json:"tags"` AddTime uint64 `json:"addtime"` EditTime uint64 `json:"edittime"` Comments uint64 `json:"comments"` CloseComment bool `json:"closecomment"` Hidden bool `json:"hidden"` }
type ArticleFeedListItem ¶
type ArticleFeedListItem struct { Id uint64 Uid uint64 Name string Cname string Title string AddTimeFmt string EditTimeFmt string Des string }
func ArticleFeedCategoryList ¶
func ArticleFeedCategoryList(db *youdb.DB, cid string, limit, tz int) []ArticleFeedListItem
func ArticleFeedList ¶
func ArticleFeedList(db *youdb.DB, limit, tz int) []ArticleFeedListItem
type ArticleListItem ¶
type ArticleListItem struct { Id uint64 `json:"id"` Uid uint64 `json:"uid"` Name string `json:"name"` Avatar string `json:"avatar"` Cid uint64 `json:"cid"` Cname string `json:"cname"` Ruid uint64 `json:"ruid"` Rname string `json:"rname"` Title string `json:"title"` EditTime uint64 `json:"edittime"` EditTimeFmt string `json:"edittimefmt"` Comments uint64 `json:"comments"` }
type ArticleMini ¶
type ArticlePageInfo ¶
type ArticlePageInfo struct { Items []ArticleListItem `json:"items"` HasPrev bool `json:"hasprev"` HasNext bool `json:"hasnext"` FirstKey uint64 `json:"firstkey"` FirstScore uint64 `json:"firstscore"` LastKey uint64 `json:"lastkey"` LastScore uint64 `json:"lastscore"` }
func ArticleList ¶
func ArticleList(db *youdb.DB, cmd, tb, key, score string, limit, tz int) ArticlePageInfo
func ArticleNotificationList ¶
func ArticleNotificationList(db *youdb.DB, ids string, tz int) ArticlePageInfo
func UserArticleList ¶
func UserArticleList(db *youdb.DB, cmd, tb, key string, limit, tz int) ArticlePageInfo
type ArticleRelative ¶
func ArticleGetRelative ¶
func ArticleGetRelative(db *youdb.DB, aid uint64, tags string) ArticleRelative
type ArticleTag ¶
文章添加、编辑后传给后台任务的信息
type Category ¶
type CategoryMini ¶
func CategoryGetMain ¶
func CategoryGetMain(db *youdb.DB, currentCobj Category) []CategoryMini
func CategoryHot ¶
func CategoryHot(db *youdb.DB, limit int, hide string) []CategoryMini
type CategoryPageInfo ¶
type CategoryPageInfo struct { Items []Category `json:"items"` HasPrev bool `json:"hasprev"` HasNext bool `json:"hasnext"` FirstKey uint64 `json:"firstkey"` LastKey uint64 `json:"lastkey"` }
func CategoryList ¶
func CategoryList(db *youdb.DB, cmd, key string, limit int) CategoryPageInfo
type Comment ¶
type CommentListItem ¶
type CommentListItem struct { Id uint64 `json:"id"` Aid uint64 `json:"aid"` Uid uint64 `json:"uid"` Flag int `json:"flag"` Name string `json:"name"` Avatar string `json:"avatar"` Content string `json:"content"` ContentFmt template.HTML AddTime uint64 `json:"addtime"` AddTimeFmt string `json:"addtimefmt"` Fold bool `json:"fold"` }
type CommentPageInfo ¶
type CommentPageInfo struct { Items []CommentListItem `json:"items"` HasPrev bool `json:"hasprev"` HasNext bool `json:"hasnext"` FirstKey uint64 `json:"firstkey"` LastKey uint64 `json:"lastkey"` }
func CommentList ¶
type Link ¶
type User ¶
type User struct { Id uint64 `json:"id"` Name string `json:"name"` Gender string `json:"gender"` Flag int `json:"flag"` Avatar string `json:"avatar"` Password string `json:"password"` Email string `json:"email"` Url string `json:"url"` Articles uint64 `json:"articles"` Replies uint64 `json:"replies"` RegTime uint64 `json:"regtime"` LastPostTime uint64 `json:"lastposttime"` LastReplyTime uint64 `json:"lastreplytime"` LastLoginTime uint64 `json:"lastlogintime"` About string `json:"about"` Notice string `json:"notice"` NoticeNum int `json:"noticenum"` Hidden bool `json:"hidden"` Session string `json:"session"` IgnoreNode string `json:"ignorenode"` IgnoreUser string `json:"ignoreuser"` Theme string `json:"theme"` IgnoreLimitedUsers bool `json:"ignorelimitedusers"` }
type UserPageInfo ¶
type UserPageInfo struct { Items []User `json:"items"` HasPrev bool `json:"hasprev"` HasNext bool `json:"hasnext"` FirstKey uint64 `json:"firstkey"` LastKey uint64 `json:"lastkey"` }
func UserListByFlag ¶
func UserListByFlag(db *youdb.DB, cmd, tb, key string, limit int) UserPageInfo
Click to show internal directories.
Click to hide internal directories.