mirror of https://github.com/rocboss/paopao-ce
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
919 lines
41 KiB
919 lines
41 KiB
// Code generated by Yesql. DO NOT EDIT.
|
|
// versions:
|
|
// - Yesql v1.5.0
|
|
|
|
package cc
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/alimy/yesql"
|
|
"github.com/jmoiron/sqlx"
|
|
)
|
|
|
|
const (
|
|
_AuthorizationManage_BeFriendIds = `SELECT user_id FROM @contact WHERE friend_id=? AND status=2 AND is_del=0`
|
|
_AuthorizationManage_IsFriend = `SELECT status FROM @contact WHERE user_id=? AND friend_id=? AND is_del=0`
|
|
_AuthorizationManage_MyFriendSet = `SELECT friend_id FROM @contact WHERE user_id=? AND status=2 AND is_del=0`
|
|
_Comment_GetCommentById = `SELECT * FROM @comment WHERE id=? AND is_del=0`
|
|
_Comment_GetCommentContentsByIds = `SELECT * FROM @comment_content WHERE comment_id IN ?`
|
|
_Comment_GetCommentCount = `SELECT count(*) FROM @comment WHERE post_id=:post_id AND is_del=0`
|
|
_Comment_GetCommentReplyById = `SELECT * FROM @comment_reply WHERE id=? AND is_del=0`
|
|
_Comment_GetCommentThumbs = `SELECT * FROM @tweet_comment_thumbs WHERE user_id=? AND tweet_id=?`
|
|
_Comment_GetComments = `SELECT * FROM @comment WHERE post_id=? AND is_del=0 ORDER BY %order% LIMIT ? OFFSET ?`
|
|
_Comment_GetCommmentRepliesByIds = `SELECT * FROM @comment_reply WHERE comment_id IN ? ORDER BY id ASC`
|
|
_Comment_GetUsersByIds = `SELECT id, nickname, username, status, avatar, is_admin FROM @user WHERE id IN ?`
|
|
_CommentManage_CreateComment = `INSERT INTO @comment (post_id, user_id, ip, ip_loc, created_on) VALUES (?, ?, ?, ?, ?)`
|
|
_CommentManage_CreateCommentContent = `INSERT INTO @comment_content (comment_id, user_id, content, type, sort, created_on) VALUES (?, ?, ?, ?, ?, ?)`
|
|
_CommentManage_CreateCommentReply = `INSERT INTO @comment_reply (comment_id, user_id, content, at_user_id, ip, ip_loc, created_on) VALUES (?, ?, ?, ?, ?, ?, ?)`
|
|
_CommentManage_CreateThumbsUpdownComment = `INSERT INTO @tweet_comment_thumbs (user_id, tweet_id, comment_id, reply_id, is_thumbs_up, is_thumbs_down, comment_type, created_on) VALUES (:user_id, :tweet_id, :comment_id, :reply_id, :is_thumbs_up, :is_thumbs_down, :comment_type, :created_on)`
|
|
_CommentManage_DeleteComment = `UPDATE @comment SET deleted_on=?, is_del=1 WHERE id=? AND is_del=0`
|
|
_CommentManage_DeleteCommentReply = `UPDATE @comment_reply SET deleted_on=?, is_del=1 WHERE id=? AND is_del=0`
|
|
_CommentManage_DeleteCommentThumbs = `UPDATE @tweet_comment_thumbs SET deleted_on=?, is_del=1 WHERE user_id=? AND tweet_id=? AND comment_id=? AND is_del=0`
|
|
_CommentManage_DeleteReplyThumbs = `UPDATE @tweet_comment_thumbs SET deleted_on=?, is_del=1 WHERE user_id=? AND comment_id=? AND reply_id=? AND is_del=0`
|
|
_CommentManage_GetCommentReplyThumb = `SELECT * FROM @tweet_comment_thumbs WHERE user_id=? AND tweet_id=? AND comment_id=? AND reply_id=? AND comment_type=1 AND is_del=0`
|
|
_CommentManage_GetTweetCommentThumb = `SELECT * FROM @tweet_comment_thumbs WHERE user_id=? AND tweet_id=? AND comment_id=? AND comment_type=0 AND is_del=0`
|
|
_CommentManage_UpdateCommentThumbsCount = `UPDATE @comment SET thumbs_up_count=?, thumbs_down_count=?, modified_on=? WHERE id=? AND is_del=0`
|
|
_CommentManage_UpdateReplyThumbsCount = `UPDATE @comment_reply SET thumbs_up_count=?, thumbs_down_count=?, modified_on=? WHERE id=? AND is_del=0`
|
|
_CommentManage_UpdateThumbsUpdownComment = `UPDATE @tweet_comment_thumbs SET is_thumbs_up=:is_thumbs_up, is_thumbs_down=:is_thumbs_down, modified_on=:modified_on WHERE id=:id AND is_del=0`
|
|
_ContactManager_AddFriendMsgsUpdate = `UPDATE @message SET reply_id=?, modified_on=? WHERE ((sender_user_id = ? AND receiver_user_id = ?) OR (sender_user_id = ? AND receiver_user_id = ?)) AND type = ? AND reply_id = ?`
|
|
_ContactManager_CreateContact = `INSERT INTO @contact (user_id, friend_id, status, created_on) VALUES (?, ?, ?, ?)`
|
|
_ContactManager_CreateMessage = `INSERT INTO @message (sender_user_id, receiver_user_id, type, brief, content, reply_id, created_on) VALUES (:sender_user_id, :receiver_user_id, :type, :brief, :content, :reply_id, :created_on)`
|
|
_ContactManager_DelFriend = `UPDATE @contact SET status=4, is_del=1, deleted_on=? WHERE id=?`
|
|
_ContactManager_FreshContactStatus = `UPDATE @contact SET status=?, modified_on=?, is_del=0 WHERE id=?`
|
|
_ContactManager_GetContact = `SELECT id, user_id, friend_id, group_id, remark, status, is_top, is_black, notice_enable, is_del FROM @contact WHERE user_id=? AND friend_id=?`
|
|
_ContactManager_GetContacts = `SELECT id, user_id, friend_id, group_id, remark, status, is_top, is_black, notice_enable, is_del FROM @contact WHERE (user_id=? AND friend_id=?) OR (user_id=? AND friend_id=?)`
|
|
_ContactManager_GetUserFriend = `SELECT id, user_id, friend_id, group_id, remark, status, is_top, is_black, notice_enable, is_del FROM @contact WHERE user_id=? AND friend_id=? AND is_del=0`
|
|
_ContactManager_IsFriend = `SELECT true FROM @contact WHERE user_id=? AND friend_id=? AND is_del=0 AND status=2`
|
|
_ContactManager_ListFriend = `SELECT c.friend_id user_id, u.username username, u.nickname nickname, u.avatar avatar, u.phone phone FROM @contact c JOIN @user u ON c.friend_id=u.id WHERE user_id=? AND status=2 AND is_del=0 ORDER BY u.nickname ASC LIMIT ? OFFSET ?`
|
|
_ContactManager_RejectFriendMsgsUpdate = `UPDATE @message SET reply_id=?, modified_on=? WHERE sender_user_id = ? AND receiver_user_id = ? AND type = ? AND reply_id = ?`
|
|
_ContactManager_TotalFriendsById = `SELECT count(*) FROM @contact WHERE user_id=? AND status=2 AND is_del=0 LIMIT ? OFFSET ?`
|
|
_FollowIndexA_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_FollowIndex_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_FriendIndexA_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_FriendIndex_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_LightIndexA_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_LightIndex_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_Message_CreateMessage = `SELECT * FROM @user WHERE username=?`
|
|
_Message_GetMessageById = `SELECT * FROM @user WHERE username=?`
|
|
_Message_GetMessageCount = `SELECT * FROM @user WHERE username=?`
|
|
_Message_GetMessages = `SELECT * FROM @user WHERE username=?`
|
|
_Message_GetUnreadCount = `SELECT * FROM @user WHERE username=?`
|
|
_Message_ReadMessage = `SELECT * FROM @user WHERE username=?`
|
|
_Security_CreatePhoneCaptcha = `SELECT * FROM @user WHERE username=?`
|
|
_Security_GetLatestPhoneCaptcha = `SELECT * FROM @user WHERE username=?`
|
|
_Security_SendPhoneCaptcha = `SELECT * FROM @user WHERE username=?`
|
|
_Security_UsePhoneCaptcha = `SELECT * FROM @user WHERE username=?`
|
|
_SimpleIndexA_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_SimpleIndex_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_TopicA_DecrTagsById = `UPDATE @tag SET quote_num=quote_num-1, modified_on=? WHERE id IN (?)`
|
|
_TopicA_HotTags = `SELECT t.id id, t.user_id user_id, t.tag tag, t.quote_num quote_num, u.id, u.nickname, u.username, u.status, u.avatar, u.is_admin FROM @tag t JOIN @user u ON t.user_id = u.id WHERE t.is_del = 0 AND t.quote_num > 0 ORDER BY t.quote_num DESC LIMIT ? OFFSET ?`
|
|
_TopicA_IncrTagsById = `UPDATE @tag SET quote_num=quote_num+1, is_del=0, modified_on=? WHERE id IN (?)`
|
|
_TopicA_InsertTag = `INSERT INTO @tag (user_id, tag, created_on, modified_on, quote_num) VALUES (?, ?, ?, ?, 1)`
|
|
_TopicA_NewestTags = `SELECT t.id id, t.user_id user_id, t.tag tag, t.quote_num quote_num, u.id, u.nickname, u.username, u.status, u.avatar, u.is_admin FROM @tag t JOIN @user u ON t.user_id = u.id WHERE t.is_del = 0 AND t.quote_num > 0 ORDER BY t.id DESC LIMIT ? OFFSET ?`
|
|
_TopicA_TagsByIdA = `SELECT id FROM @tag WHERE id IN (?) AND is_del = 0 AND quote_num > 0`
|
|
_TopicA_TagsByIdB = `SELECT id, user_id, tag, quote_num FROM @tag WHERE id IN (?)`
|
|
_TopicA_TagsByKeywordA = `SELECT id, user_id, tag, quote_num FROM @tag WHERE is_del = 0 ORDER BY quote_num DESC LIMIT 6`
|
|
_TopicA_TagsByKeywordB = `SELECT id, user_id, tag, quote_num FROM @tag WHERE is_del = 0 AND tag LIKE ? ORDER BY quote_num DESC LIMIT 6`
|
|
_TopicA_TagsForIncr = `SELECT id, user_id, tag, quote_num FROM @tag WHERE tag IN (?)`
|
|
_TweetA_AttachmentByTweetId = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_FavoriteByTweetId = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_ReactionByTweetId = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_TweetInfoById = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_TweetItemById = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_UserFavorites = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_UserReactions = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_UserTweetsByAdmin = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_UserTweetsByFriend = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_UserTweetsByGuest = `SELECT * FROM @user WHERE username=?`
|
|
_TweetA_UserTweetsBySelf = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetPostAttachmentBill = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetPostById = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetPostContentById = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetPostContetnsByIds = `SELECT id, user_id, tag, quote_num FROM @tag WHERE tag IN (?)`
|
|
_Tweet_GetPostCount = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetPosts = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetUserPostCollection = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetUserPostCollectionCount = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetUserPostCollections = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetUserPostStar = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetUserPostStarCount = `SELECT * FROM @user WHERE username=?`
|
|
_Tweet_GetUserPostStars = `SELECT * FROM @user WHERE username=?`
|
|
_TweetHelpA_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_TweetHelp_GetPostContentByIds = `SELECT * FROM @user WHERE username=?`
|
|
_TweetHelp_GetUsersByIds = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManageA_UserInfo = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_AddAttachment = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_AddPost = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_AddPostCollection = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_AddPostContent = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_AddPostStar = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_DelPost = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_DelPostCollection = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_DelPostStar = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_LockPost = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_StickPost = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_UpdatePost = `SELECT * FROM @user WHERE username=?`
|
|
_TweetManage_VisiblePost = `SELECT * FROM @user WHERE username=?`
|
|
_UserManage_AddUser = `SELECT * FROM @user WHERE username=?`
|
|
_UserManage_GetUserById = `SELECT * FROM @user WHERE username=?`
|
|
_UserManage_GetUserByPhone = `SELECT * FROM @user WHERE username=?`
|
|
_UserManage_GetUserByUsername = `SELECT * FROM @user WHERE username=?`
|
|
_UserManage_GetUsersByIds = `SELECT * FROM @user WHERE username=?`
|
|
_UserManage_GetUsersByKeyword = `SELECT * FROM @user WHERE username=?`
|
|
_UserManage_UpdateUser = `SELECT * FROM @user WHERE username=?`
|
|
_Wallet_CreateRecharge = `SELECT * FROM @user WHERE username=?`
|
|
_Wallet_GetRechargeById = `SELECT * FROM @user WHERE username=?`
|
|
_Wallet_GetUserWalletBillCount = `SELECT * FROM @user WHERE username=?`
|
|
_Wallet_GetUserWalletBills = `SELECT * FROM @user WHERE username=?`
|
|
_Wallet_HandlePostAttachementBought = `SELECT * FROM @user WHERE username=?`
|
|
_Wallet_HandleRechargeSuccess = `SELECT * FROM @user WHERE username=?`
|
|
)
|
|
|
|
type AuthorizationManage struct {
|
|
yesql.Namespace `yesql:"authorization_manage"`
|
|
BeFriendIds *sqlx.Stmt `yesql:"be_friend_ids"`
|
|
IsFriend *sqlx.Stmt `yesql:"is_friend"`
|
|
MyFriendSet *sqlx.Stmt `yesql:"my_friend_set"`
|
|
}
|
|
|
|
type Comment struct {
|
|
yesql.Namespace `yesql:"comment"`
|
|
GetCommentContentsByIds string `yesql:"get_comment_contents_by_ids"`
|
|
GetComments string `yesql:"get_comments"`
|
|
GetCommmentRepliesByIds string `yesql:"get_commment_replies_by_ids"`
|
|
GetUsersByIds string `yesql:"get_users_by_ids"`
|
|
GetCommentById *sqlx.Stmt `yesql:"get_comment_by_id"`
|
|
GetCommentReplyById *sqlx.Stmt `yesql:"get_comment_reply_by_id"`
|
|
GetCommentThumbs *sqlx.Stmt `yesql:"get_comment_thumbs"`
|
|
GetCommentCount *sqlx.NamedStmt `yesql:"get_comment_count"`
|
|
}
|
|
|
|
type CommentManage struct {
|
|
yesql.Namespace `yesql:"comment_manage"`
|
|
CreateComment *sqlx.Stmt `yesql:"create_comment"`
|
|
CreateCommentContent *sqlx.Stmt `yesql:"create_comment_content"`
|
|
CreateCommentReply *sqlx.Stmt `yesql:"create_comment_reply"`
|
|
DeleteComment *sqlx.Stmt `yesql:"delete_comment"`
|
|
DeleteCommentReply *sqlx.Stmt `yesql:"delete_comment_reply"`
|
|
DeleteCommentThumbs *sqlx.Stmt `yesql:"delete_comment_thumbs"`
|
|
DeleteReplyThumbs *sqlx.Stmt `yesql:"delete_reply_thumbs"`
|
|
GetCommentReplyThumb *sqlx.Stmt `yesql:"get_comment_reply_thumb"`
|
|
GetTweetCommentThumb *sqlx.Stmt `yesql:"get_tweet_comment_thumb"`
|
|
UpdateCommentThumbsCount *sqlx.Stmt `yesql:"update_comment_thumbs_count"`
|
|
UpdateReplyThumbsCount *sqlx.Stmt `yesql:"update_reply_thumbs_count"`
|
|
CreateThumbsUpdownComment *sqlx.NamedStmt `yesql:"create_thumbs_updown_comment"`
|
|
UpdateThumbsUpdownComment *sqlx.NamedStmt `yesql:"update_thumbs_updown_comment"`
|
|
}
|
|
|
|
type ContactManager struct {
|
|
yesql.Namespace `yesql:"contact_manager"`
|
|
AddFriendMsgsUpdate *sqlx.Stmt `yesql:"add_friend_msgs_update"`
|
|
CreateContact *sqlx.Stmt `yesql:"create_contact"`
|
|
DelFriend *sqlx.Stmt `yesql:"del_friend"`
|
|
FreshContactStatus *sqlx.Stmt `yesql:"fresh_contact_status"`
|
|
GetContact *sqlx.Stmt `yesql:"get_contact"`
|
|
GetContacts *sqlx.Stmt `yesql:"get_contacts"`
|
|
GetUserFriend *sqlx.Stmt `yesql:"get_user_friend"`
|
|
IsFriend *sqlx.Stmt `yesql:"is_friend"`
|
|
ListFriend *sqlx.Stmt `yesql:"list_friend"`
|
|
RejectFriendMsgsUpdate *sqlx.Stmt `yesql:"reject_friend_msgs_update"`
|
|
TotalFriendsById *sqlx.Stmt `yesql:"total_friends_by_id"`
|
|
CreateMessage *sqlx.NamedStmt `yesql:"create_message"`
|
|
}
|
|
|
|
type FollowIndex struct {
|
|
yesql.Namespace `yesql:"follow_index"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type FollowIndexA struct {
|
|
yesql.Namespace `yesql:"follow_index_a"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type FriendIndex struct {
|
|
yesql.Namespace `yesql:"friend_index"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type FriendIndexA struct {
|
|
yesql.Namespace `yesql:"friend_index_a"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type LightIndex struct {
|
|
yesql.Namespace `yesql:"light_index"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type LightIndexA struct {
|
|
yesql.Namespace `yesql:"light_index_a"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type Message struct {
|
|
yesql.Namespace `yesql:"message"`
|
|
GetMessageById *sqlx.Stmt `yesql:"get_message_by_id"`
|
|
GetUnreadCount *sqlx.Stmt `yesql:"get_unread_count"`
|
|
CreateMessage *sqlx.NamedStmt `yesql:"create_message"`
|
|
GetMessageCount *sqlx.NamedStmt `yesql:"get_message_count"`
|
|
GetMessages *sqlx.NamedStmt `yesql:"get_messages"`
|
|
ReadMessage *sqlx.NamedStmt `yesql:"read_message"`
|
|
}
|
|
|
|
type Security struct {
|
|
yesql.Namespace `yesql:"security"`
|
|
GetLatestPhoneCaptcha *sqlx.Stmt `yesql:"get_latest_phone_captcha"`
|
|
SendPhoneCaptcha *sqlx.Stmt `yesql:"send_phone_captcha"`
|
|
CreatePhoneCaptcha *sqlx.NamedStmt `yesql:"create_phone_captcha"`
|
|
UsePhoneCaptcha *sqlx.NamedStmt `yesql:"use_phone_captcha"`
|
|
}
|
|
|
|
type SimpleIndex struct {
|
|
yesql.Namespace `yesql:"simple_index"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type SimpleIndexA struct {
|
|
yesql.Namespace `yesql:"simple_index_a"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type TopicA struct {
|
|
yesql.Namespace `yesql:"topic_a"`
|
|
DecrTagsById string `yesql:"decr_tags_by_id"`
|
|
IncrTagsById string `yesql:"incr_tags_by_id"`
|
|
TagsByIdA string `yesql:"tags_by_id_a"`
|
|
TagsByIdB string `yesql:"tags_by_id_b"`
|
|
TagsForIncr string `yesql:"tags_for_incr"`
|
|
HotTags *sqlx.Stmt `yesql:"hot_tags"`
|
|
InsertTag *sqlx.Stmt `yesql:"insert_tag"`
|
|
NewestTags *sqlx.Stmt `yesql:"newest_tags"`
|
|
TagsByKeywordA *sqlx.Stmt `yesql:"tags_by_keyword_a"`
|
|
TagsByKeywordB *sqlx.Stmt `yesql:"tags_by_keyword_b"`
|
|
}
|
|
|
|
type Tweet struct {
|
|
yesql.Namespace `yesql:"tweet"`
|
|
GetPostContetnsByIds string `yesql:"get_post_contetns_by_ids"`
|
|
GetPostAttachmentBill *sqlx.Stmt `yesql:"get_post_attachment_bill"`
|
|
GetPostById *sqlx.Stmt `yesql:"get_post_by_id"`
|
|
GetPostContentById *sqlx.Stmt `yesql:"get_post_content_by_id"`
|
|
GetPostCount *sqlx.Stmt `yesql:"get_post_count"`
|
|
GetPosts *sqlx.Stmt `yesql:"get_posts"`
|
|
GetUserPostCollection *sqlx.Stmt `yesql:"get_user_post_collection"`
|
|
GetUserPostCollectionCount *sqlx.Stmt `yesql:"get_user_post_collection_count"`
|
|
GetUserPostCollections *sqlx.Stmt `yesql:"get_user_post_collections"`
|
|
GetUserPostStar *sqlx.Stmt `yesql:"get_user_post_star"`
|
|
GetUserPostStarCount *sqlx.Stmt `yesql:"get_user_post_star_count"`
|
|
GetUserPostStars *sqlx.Stmt `yesql:"get_user_post_stars"`
|
|
}
|
|
|
|
type TweetA struct {
|
|
yesql.Namespace `yesql:"tweet_a"`
|
|
AttachmentByTweetId *sqlx.Stmt `yesql:"attachment_by_tweet_id"`
|
|
FavoriteByTweetId *sqlx.Stmt `yesql:"favorite_by_tweet_id"`
|
|
ReactionByTweetId *sqlx.Stmt `yesql:"reaction_by_tweet_id"`
|
|
TweetInfoById *sqlx.Stmt `yesql:"tweet_info_by_id"`
|
|
TweetItemById *sqlx.Stmt `yesql:"tweet_item_by_id"`
|
|
UserFavorites *sqlx.Stmt `yesql:"user_favorites"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
UserReactions *sqlx.Stmt `yesql:"user_reactions"`
|
|
UserTweetsByAdmin *sqlx.Stmt `yesql:"user_tweets_by_admin"`
|
|
UserTweetsByFriend *sqlx.Stmt `yesql:"user_tweets_by_friend"`
|
|
UserTweetsByGuest *sqlx.Stmt `yesql:"user_tweets_by_guest"`
|
|
UserTweetsBySelf *sqlx.Stmt `yesql:"user_tweets_by_self"`
|
|
}
|
|
|
|
type TweetHelp struct {
|
|
yesql.Namespace `yesql:"tweet_help"`
|
|
GetPostContentByIds string `yesql:"get_post_content_by_ids"`
|
|
GetUsersByIds string `yesql:"get_users_by_ids"`
|
|
}
|
|
|
|
type TweetHelpA struct {
|
|
yesql.Namespace `yesql:"tweet_help_a"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type TweetManage struct {
|
|
yesql.Namespace `yesql:"tweet_manage"`
|
|
AddAttachment *sqlx.Stmt `yesql:"add_attachment"`
|
|
AddPost *sqlx.Stmt `yesql:"add_post"`
|
|
AddPostCollection *sqlx.Stmt `yesql:"add_post_collection"`
|
|
AddPostContent *sqlx.Stmt `yesql:"add_post_content"`
|
|
AddPostStar *sqlx.Stmt `yesql:"add_post_star"`
|
|
DelPost *sqlx.Stmt `yesql:"del_post"`
|
|
DelPostCollection *sqlx.Stmt `yesql:"del_post_collection"`
|
|
DelPostStar *sqlx.Stmt `yesql:"del_post_star"`
|
|
LockPost *sqlx.Stmt `yesql:"lock_post"`
|
|
StickPost *sqlx.Stmt `yesql:"stick_post"`
|
|
UpdatePost *sqlx.Stmt `yesql:"update_post"`
|
|
VisiblePost *sqlx.Stmt `yesql:"visible_post"`
|
|
}
|
|
|
|
type TweetManageA struct {
|
|
yesql.Namespace `yesql:"tweet_manage_a"`
|
|
UserInfo *sqlx.Stmt `yesql:"user_info"`
|
|
}
|
|
|
|
type UserManage struct {
|
|
yesql.Namespace `yesql:"user_manage"`
|
|
GetUsersByIds string `yesql:"get_users_by_ids"`
|
|
AddUser *sqlx.Stmt `yesql:"add_user"`
|
|
GetUserById *sqlx.Stmt `yesql:"get_user_by_id"`
|
|
GetUserByPhone *sqlx.Stmt `yesql:"get_user_by_phone"`
|
|
GetUserByUsername *sqlx.Stmt `yesql:"get_user_by_username"`
|
|
GetUsersByKeyword *sqlx.Stmt `yesql:"get_users_by_keyword"`
|
|
UpdateUser *sqlx.Stmt `yesql:"update_user"`
|
|
}
|
|
|
|
type Wallet struct {
|
|
yesql.Namespace `yesql:"wallet"`
|
|
CreateRecharge *sqlx.Stmt `yesql:"create_recharge"`
|
|
GetRechargeById *sqlx.Stmt `yesql:"get_recharge_by_id"`
|
|
GetUserWalletBillCount *sqlx.Stmt `yesql:"get_user_wallet_bill_count"`
|
|
GetUserWalletBills *sqlx.Stmt `yesql:"get_user_wallet_bills"`
|
|
HandlePostAttachementBought *sqlx.Stmt `yesql:"handle_post_attachement_bought"`
|
|
HandleRechargeSuccess *sqlx.Stmt `yesql:"handle_recharge_success"`
|
|
}
|
|
|
|
func BuildAuthorizationManage(p yesql.PreparexBuilder, ctx ...context.Context) (obj *AuthorizationManage, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &AuthorizationManage{}
|
|
if obj.BeFriendIds, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_AuthorizationManage_BeFriendIds))); err != nil {
|
|
return
|
|
}
|
|
if obj.IsFriend, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_AuthorizationManage_IsFriend))); err != nil {
|
|
return
|
|
}
|
|
if obj.MyFriendSet, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_AuthorizationManage_MyFriendSet))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildComment(p yesql.PreparexBuilder, ctx ...context.Context) (obj *Comment, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &Comment{
|
|
GetCommentContentsByIds: p.QueryHook(_Comment_GetCommentContentsByIds),
|
|
GetComments: p.QueryHook(_Comment_GetComments),
|
|
GetCommmentRepliesByIds: p.QueryHook(_Comment_GetCommmentRepliesByIds),
|
|
GetUsersByIds: p.QueryHook(_Comment_GetUsersByIds),
|
|
}
|
|
if obj.GetCommentById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Comment_GetCommentById))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetCommentReplyById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Comment_GetCommentReplyById))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetCommentThumbs, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Comment_GetCommentThumbs))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetCommentCount, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_Comment_GetCommentCount))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildCommentManage(p yesql.PreparexBuilder, ctx ...context.Context) (obj *CommentManage, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &CommentManage{}
|
|
if obj.CreateComment, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_CreateComment))); err != nil {
|
|
return
|
|
}
|
|
if obj.CreateCommentContent, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_CreateCommentContent))); err != nil {
|
|
return
|
|
}
|
|
if obj.CreateCommentReply, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_CreateCommentReply))); err != nil {
|
|
return
|
|
}
|
|
if obj.DeleteComment, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_DeleteComment))); err != nil {
|
|
return
|
|
}
|
|
if obj.DeleteCommentReply, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_DeleteCommentReply))); err != nil {
|
|
return
|
|
}
|
|
if obj.DeleteCommentThumbs, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_DeleteCommentThumbs))); err != nil {
|
|
return
|
|
}
|
|
if obj.DeleteReplyThumbs, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_DeleteReplyThumbs))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetCommentReplyThumb, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_GetCommentReplyThumb))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetTweetCommentThumb, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_GetTweetCommentThumb))); err != nil {
|
|
return
|
|
}
|
|
if obj.UpdateCommentThumbsCount, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_UpdateCommentThumbsCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.UpdateReplyThumbsCount, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_CommentManage_UpdateReplyThumbsCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.CreateThumbsUpdownComment, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_CommentManage_CreateThumbsUpdownComment))); err != nil {
|
|
return
|
|
}
|
|
if obj.UpdateThumbsUpdownComment, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_CommentManage_UpdateThumbsUpdownComment))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildContactManager(p yesql.PreparexBuilder, ctx ...context.Context) (obj *ContactManager, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &ContactManager{}
|
|
if obj.AddFriendMsgsUpdate, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_AddFriendMsgsUpdate))); err != nil {
|
|
return
|
|
}
|
|
if obj.CreateContact, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_CreateContact))); err != nil {
|
|
return
|
|
}
|
|
if obj.DelFriend, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_DelFriend))); err != nil {
|
|
return
|
|
}
|
|
if obj.FreshContactStatus, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_FreshContactStatus))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetContact, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_GetContact))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetContacts, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_GetContacts))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserFriend, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_GetUserFriend))); err != nil {
|
|
return
|
|
}
|
|
if obj.IsFriend, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_IsFriend))); err != nil {
|
|
return
|
|
}
|
|
if obj.ListFriend, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_ListFriend))); err != nil {
|
|
return
|
|
}
|
|
if obj.RejectFriendMsgsUpdate, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_RejectFriendMsgsUpdate))); err != nil {
|
|
return
|
|
}
|
|
if obj.TotalFriendsById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_ContactManager_TotalFriendsById))); err != nil {
|
|
return
|
|
}
|
|
if obj.CreateMessage, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_ContactManager_CreateMessage))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildFollowIndex(p yesql.PreparexBuilder, ctx ...context.Context) (obj *FollowIndex, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &FollowIndex{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_FollowIndex_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildFollowIndexA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *FollowIndexA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &FollowIndexA{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_FollowIndexA_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildFriendIndex(p yesql.PreparexBuilder, ctx ...context.Context) (obj *FriendIndex, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &FriendIndex{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_FriendIndex_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildFriendIndexA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *FriendIndexA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &FriendIndexA{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_FriendIndexA_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildLightIndex(p yesql.PreparexBuilder, ctx ...context.Context) (obj *LightIndex, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &LightIndex{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_LightIndex_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildLightIndexA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *LightIndexA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &LightIndexA{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_LightIndexA_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildMessage(p yesql.PreparexBuilder, ctx ...context.Context) (obj *Message, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &Message{}
|
|
if obj.GetMessageById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Message_GetMessageById))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUnreadCount, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Message_GetUnreadCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.CreateMessage, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_Message_CreateMessage))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetMessageCount, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_Message_GetMessageCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetMessages, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_Message_GetMessages))); err != nil {
|
|
return
|
|
}
|
|
if obj.ReadMessage, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_Message_ReadMessage))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildSecurity(p yesql.PreparexBuilder, ctx ...context.Context) (obj *Security, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &Security{}
|
|
if obj.GetLatestPhoneCaptcha, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Security_GetLatestPhoneCaptcha))); err != nil {
|
|
return
|
|
}
|
|
if obj.SendPhoneCaptcha, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Security_SendPhoneCaptcha))); err != nil {
|
|
return
|
|
}
|
|
if obj.CreatePhoneCaptcha, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_Security_CreatePhoneCaptcha))); err != nil {
|
|
return
|
|
}
|
|
if obj.UsePhoneCaptcha, err = p.PrepareNamedContext(c, p.Rebind(p.QueryHook(_Security_UsePhoneCaptcha))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildSimpleIndex(p yesql.PreparexBuilder, ctx ...context.Context) (obj *SimpleIndex, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &SimpleIndex{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_SimpleIndex_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildSimpleIndexA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *SimpleIndexA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &SimpleIndexA{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_SimpleIndexA_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildTopicA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *TopicA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &TopicA{
|
|
DecrTagsById: p.QueryHook(_TopicA_DecrTagsById),
|
|
IncrTagsById: p.QueryHook(_TopicA_IncrTagsById),
|
|
TagsByIdA: p.QueryHook(_TopicA_TagsByIdA),
|
|
TagsByIdB: p.QueryHook(_TopicA_TagsByIdB),
|
|
TagsForIncr: p.QueryHook(_TopicA_TagsForIncr),
|
|
}
|
|
if obj.HotTags, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TopicA_HotTags))); err != nil {
|
|
return
|
|
}
|
|
if obj.InsertTag, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TopicA_InsertTag))); err != nil {
|
|
return
|
|
}
|
|
if obj.NewestTags, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TopicA_NewestTags))); err != nil {
|
|
return
|
|
}
|
|
if obj.TagsByKeywordA, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TopicA_TagsByKeywordA))); err != nil {
|
|
return
|
|
}
|
|
if obj.TagsByKeywordB, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TopicA_TagsByKeywordB))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildTweet(p yesql.PreparexBuilder, ctx ...context.Context) (obj *Tweet, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &Tweet{
|
|
GetPostContetnsByIds: p.QueryHook(_Tweet_GetPostContetnsByIds),
|
|
}
|
|
if obj.GetPostAttachmentBill, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetPostAttachmentBill))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetPostById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetPostById))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetPostContentById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetPostContentById))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetPostCount, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetPostCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetPosts, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetPosts))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserPostCollection, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetUserPostCollection))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserPostCollectionCount, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetUserPostCollectionCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserPostCollections, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetUserPostCollections))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserPostStar, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetUserPostStar))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserPostStarCount, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetUserPostStarCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserPostStars, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Tweet_GetUserPostStars))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildTweetA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *TweetA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &TweetA{}
|
|
if obj.AttachmentByTweetId, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_AttachmentByTweetId))); err != nil {
|
|
return
|
|
}
|
|
if obj.FavoriteByTweetId, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_FavoriteByTweetId))); err != nil {
|
|
return
|
|
}
|
|
if obj.ReactionByTweetId, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_ReactionByTweetId))); err != nil {
|
|
return
|
|
}
|
|
if obj.TweetInfoById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_TweetInfoById))); err != nil {
|
|
return
|
|
}
|
|
if obj.TweetItemById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_TweetItemById))); err != nil {
|
|
return
|
|
}
|
|
if obj.UserFavorites, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_UserFavorites))); err != nil {
|
|
return
|
|
}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
if obj.UserReactions, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_UserReactions))); err != nil {
|
|
return
|
|
}
|
|
if obj.UserTweetsByAdmin, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_UserTweetsByAdmin))); err != nil {
|
|
return
|
|
}
|
|
if obj.UserTweetsByFriend, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_UserTweetsByFriend))); err != nil {
|
|
return
|
|
}
|
|
if obj.UserTweetsByGuest, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_UserTweetsByGuest))); err != nil {
|
|
return
|
|
}
|
|
if obj.UserTweetsBySelf, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetA_UserTweetsBySelf))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildTweetHelp(p yesql.PreparexBuilder) (obj *TweetHelp, err error) {
|
|
obj = &TweetHelp{
|
|
GetPostContentByIds: p.QueryHook(_TweetHelp_GetPostContentByIds),
|
|
GetUsersByIds: p.QueryHook(_TweetHelp_GetUsersByIds),
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildTweetHelpA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *TweetHelpA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &TweetHelpA{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetHelpA_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildTweetManage(p yesql.PreparexBuilder, ctx ...context.Context) (obj *TweetManage, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &TweetManage{}
|
|
if obj.AddAttachment, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_AddAttachment))); err != nil {
|
|
return
|
|
}
|
|
if obj.AddPost, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_AddPost))); err != nil {
|
|
return
|
|
}
|
|
if obj.AddPostCollection, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_AddPostCollection))); err != nil {
|
|
return
|
|
}
|
|
if obj.AddPostContent, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_AddPostContent))); err != nil {
|
|
return
|
|
}
|
|
if obj.AddPostStar, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_AddPostStar))); err != nil {
|
|
return
|
|
}
|
|
if obj.DelPost, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_DelPost))); err != nil {
|
|
return
|
|
}
|
|
if obj.DelPostCollection, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_DelPostCollection))); err != nil {
|
|
return
|
|
}
|
|
if obj.DelPostStar, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_DelPostStar))); err != nil {
|
|
return
|
|
}
|
|
if obj.LockPost, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_LockPost))); err != nil {
|
|
return
|
|
}
|
|
if obj.StickPost, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_StickPost))); err != nil {
|
|
return
|
|
}
|
|
if obj.UpdatePost, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_UpdatePost))); err != nil {
|
|
return
|
|
}
|
|
if obj.VisiblePost, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManage_VisiblePost))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildTweetManageA(p yesql.PreparexBuilder, ctx ...context.Context) (obj *TweetManageA, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &TweetManageA{}
|
|
if obj.UserInfo, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_TweetManageA_UserInfo))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildUserManage(p yesql.PreparexBuilder, ctx ...context.Context) (obj *UserManage, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &UserManage{
|
|
GetUsersByIds: p.QueryHook(_UserManage_GetUsersByIds),
|
|
}
|
|
if obj.AddUser, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_UserManage_AddUser))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_UserManage_GetUserById))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserByPhone, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_UserManage_GetUserByPhone))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserByUsername, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_UserManage_GetUserByUsername))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUsersByKeyword, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_UserManage_GetUsersByKeyword))); err != nil {
|
|
return
|
|
}
|
|
if obj.UpdateUser, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_UserManage_UpdateUser))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|
|
|
|
func BuildWallet(p yesql.PreparexBuilder, ctx ...context.Context) (obj *Wallet, err error) {
|
|
var c context.Context
|
|
if len(ctx) > 0 && ctx[0] != nil {
|
|
c = ctx[0]
|
|
} else {
|
|
c = context.Background()
|
|
}
|
|
obj = &Wallet{}
|
|
if obj.CreateRecharge, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Wallet_CreateRecharge))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetRechargeById, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Wallet_GetRechargeById))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserWalletBillCount, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Wallet_GetUserWalletBillCount))); err != nil {
|
|
return
|
|
}
|
|
if obj.GetUserWalletBills, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Wallet_GetUserWalletBills))); err != nil {
|
|
return
|
|
}
|
|
if obj.HandlePostAttachementBought, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Wallet_HandlePostAttachementBought))); err != nil {
|
|
return
|
|
}
|
|
if obj.HandleRechargeSuccess, err = p.PreparexContext(c, p.Rebind(p.QueryHook(_Wallet_HandleRechargeSuccess))); err != nil {
|
|
return
|
|
}
|
|
return
|
|
}
|