Run generators

This commit is contained in:
Melody Becker 2024-11-20 13:39:17 +01:00
parent 378f94fa97
commit 9d28b20fe0
4 changed files with 364 additions and 239 deletions

View file

@ -0,0 +1,58 @@
// Code generated by cmd/RolesApiTypeGenerator DO NOT EDIT.
// If you need to refresh the content, run go generate again
import Model, { attr } from '@ember-data/model';
export default class RoleModel extends Model {
@attr() declare createdAt: Date
@attr() declare updatedAt: Date
@attr() declare name: string
@attr() declare priority: number
@attr() declare isUserRole: boolean
@attr() declare isBuiltIn: boolean
@attr() declare canSendMedia?: boolean
@attr() declare canSendFollowerOnlyNotes?: boolean
@attr() declare canIncludeLinks?: boolean
@attr() declare hasMentionCountLimit?: boolean
@attr() declare scanCreatedFollowerOnlyNotes?: boolean
@attr() declare canAffectOtherAdmins?: boolean
@attr() declare canConfirmWithheldNotes?: boolean
@attr() declare canSendCustomEmotes?: boolean
@attr() declare scanCreatedLocalNotes?: boolean
@attr() declare canOverwriteDisplayNames?: boolean
@attr() declare canRecoverDeletedNotes?: boolean
@attr() declare canManageAds?: boolean
@attr() declare canFederateBsky?: boolean
@attr() declare autoCwPostsText?: string
@attr() declare scanCreatedPublicNotes?: boolean
@attr() declare withholdNotesForManualApproval?: boolean
@attr() declare canSendReplies?: boolean
@attr() declare autoNsfwMedia?: boolean
@attr() declare canSendCustomReactions?: boolean
@attr() declare canSendLocalNotes?: boolean
@attr() declare canSendPrivateNotes?: boolean
@attr() declare canFederateFedi?: boolean
@attr() declare withholdNotesBasedOnRegex?: boolean
@attr() declare fullAdmin?: boolean
@attr() declare canSendAnnouncements?: boolean
@attr() declare canQuote?: boolean
@attr() declare canIncludeSurvey?: boolean
@attr() declare canChangeDisplayName?: boolean
@attr() declare blockedUsers?: Array<string>
@attr() declare canMentionOthers?: boolean
@attr() declare autoCwPosts?: boolean
@attr() declare canSendPublicNotes?: boolean
@attr() declare mentionLimit?: number
@attr() declare scanCreatedPrivateNotes?: boolean
@attr() declare withholdNotesRegexes?: Array<string>
@attr() declare canAssignRoles?: boolean
@attr() declare canSupressInteractionsBetweenUsers?: boolean
@attr() declare canManageCustomEmotes?: boolean
@attr() declare canViewDeletedNotes?: boolean
@attr() declare canBoost?: boolean
@attr() declare canSubmitReports?: boolean
@attr() declare canLogin?: boolean
@attr() declare disallowInteractionsWith?: Array<string>
@attr() declare canDeleteNotes?: boolean
@attr() declare canManageAvatarDecorations?: boolean
}

View file

@ -0,0 +1,8 @@
// Code generated by cmd/RolesApiConverter DO NOT EDIT.
// If you need to refresh the content, run go generate again
package server
import "gitlab.com/mstarongitlab/linstrom/storage"
func convertRoleStorageToLinstrom(r storage.Role) linstromRole {
return linstromRole{Id:r.ID,CreatedAt:r.CreatedAt,UpdatedAt:r.UpdatedAt,Name:r.Name,Priority:r.Priority,IsUserRole:r.IsUserRole,IsBuiltIn:r.IsBuiltIn,CanSendAnnouncements:r.CanSendAnnouncements,CanIncludeSurvey:r.CanIncludeSurvey,CanSubmitReports:r.CanSubmitReports,CanMentionOthers:r.CanMentionOthers,WithholdNotesBasedOnRegex:r.WithholdNotesBasedOnRegex,CanSendMedia:r.CanSendMedia,CanSendLocalNotes:r.CanSendLocalNotes,ScanCreatedFollowerOnlyNotes:r.ScanCreatedFollowerOnlyNotes,CanOverwriteDisplayNames:r.CanOverwriteDisplayNames,CanDeleteNotes:r.CanDeleteNotes,CanSupressInteractionsBetweenUsers:r.CanSupressInteractionsBetweenUsers,CanManageAds:r.CanManageAds,BlockedUsers:r.BlockedUsers,CanLogin:r.CanLogin,AutoCwPosts:r.AutoCwPosts,WithholdNotesRegexes:r.WithholdNotesRegexes,ScanCreatedPublicNotes:r.ScanCreatedPublicNotes,ScanCreatedLocalNotes:r.ScanCreatedLocalNotes,CanAffectOtherAdmins:r.CanAffectOtherAdmins,CanAssignRoles:r.CanAssignRoles,CanSendFollowerOnlyNotes:r.CanSendFollowerOnlyNotes,CanBoost:r.CanBoost,CanFederateBsky:r.CanFederateBsky,HasMentionCountLimit:r.HasMentionCountLimit,DisallowInteractionsWith:r.DisallowInteractionsWith,CanViewDeletedNotes:r.CanViewDeletedNotes,CanSendCustomReactions:r.CanSendCustomReactions,CanSendReplies:r.CanSendReplies,CanIncludeLinks:r.CanIncludeLinks,CanChangeDisplayName:r.CanChangeDisplayName,CanSendPrivateNotes:r.CanSendPrivateNotes,MentionLimit:r.MentionLimit,WithholdNotesForManualApproval:r.WithholdNotesForManualApproval,CanRecoverDeletedNotes:r.CanRecoverDeletedNotes,AutoCwPostsText:r.AutoCwPostsText,ScanCreatedPrivateNotes:r.ScanCreatedPrivateNotes,CanSendCustomEmotes:r.CanSendCustomEmotes,CanSendPublicNotes:r.CanSendPublicNotes,CanQuote:r.CanQuote,CanFederateFedi:r.CanFederateFedi,CanManageAvatarDecorations:r.CanManageAvatarDecorations,AutoNsfwMedia:r.AutoNsfwMedia,FullAdmin:r.FullAdmin,CanConfirmWithheldNotes:r.CanConfirmWithheldNotes,CanManageCustomEmotes:r.CanManageCustomEmotes,}
}

View file

@ -0,0 +1,59 @@
// Code generated by cmd/RolesApiTypeGenerator DO NOT EDIT.
// If you need to refresh the content, run go generate again
package server
import "time"
type linstromRole struct {
Id uint `jsonapi:"primary,roles"`
CreatedAt time.Time `jsonapi:"attr,created-at"`
UpdatedAt time.Time `jsonapi:"attr,updated-at"`
Name string `jsonapi:"attr,name"`
Priority uint32 `jsonapi:"attr,priority"`
IsUserRole bool `jsonapi:"attr,is-user-role"`
IsBuiltIn bool `jsonapi:"attr,is-built-in"`
CanQuote *bool `jsonapi:"attr,can-quote"`
CanFederateFedi *bool `jsonapi:"attr,can-federate-fedi"`
DisallowInteractionsWith []string `jsonapi:"attr,disallow-interactions-with"`
WithholdNotesRegexes []string `jsonapi:"attr,withhold-notes-regexes"`
FullAdmin *bool `jsonapi:"attr,full-admin"`
CanViewDeletedNotes *bool `jsonapi:"attr,can-view-deleted-notes"`
CanSendCustomReactions *bool `jsonapi:"attr,can-send-custom-reactions"`
CanSendFollowerOnlyNotes *bool `jsonapi:"attr,can-send-follower-only-notes"`
CanLogin *bool `jsonapi:"attr,can-login"`
AutoCwPostsText *string `jsonapi:"attr,auto-cw-posts-text"`
WithholdNotesForManualApproval *bool `jsonapi:"attr,withhold-notes-for-manual-approval"`
CanDeleteNotes *bool `jsonapi:"attr,can-delete-notes"`
CanSendLocalNotes *bool `jsonapi:"attr,can-send-local-notes"`
CanIncludeLinks *bool `jsonapi:"attr,can-include-links"`
AutoCwPosts *bool `jsonapi:"attr,auto-cw-posts"`
WithholdNotesBasedOnRegex *bool `jsonapi:"attr,withhold-notes-based-on-regex"`
CanAffectOtherAdmins *bool `jsonapi:"attr,can-affect-other-admins"`
CanAssignRoles *bool `jsonapi:"attr,can-assign-roles"`
CanSendMedia *bool `jsonapi:"attr,can-send-media"`
BlockedUsers []string `jsonapi:"attr,blocked-users"`
AutoNsfwMedia *bool `jsonapi:"attr,auto-nsfw-media"`
CanConfirmWithheldNotes *bool `jsonapi:"attr,can-confirm-withheld-notes"`
CanOverwriteDisplayNames *bool `jsonapi:"attr,can-overwrite-display-names"`
CanManageAds *bool `jsonapi:"attr,can-manage-ads"`
CanIncludeSurvey *bool `jsonapi:"attr,can-include-survey"`
CanSubmitReports *bool `jsonapi:"attr,can-submit-reports"`
ScanCreatedFollowerOnlyNotes *bool `jsonapi:"attr,scan-created-follower-only-notes"`
CanManageCustomEmotes *bool `jsonapi:"attr,can-manage-custom-emotes"`
CanManageAvatarDecorations *bool `jsonapi:"attr,can-manage-avatar-decorations"`
CanSendAnnouncements *bool `jsonapi:"attr,can-send-announcements"`
CanBoost *bool `jsonapi:"attr,can-boost"`
ScanCreatedPublicNotes *bool `jsonapi:"attr,scan-created-public-notes"`
HasMentionCountLimit *bool `jsonapi:"attr,has-mention-count-limit"`
MentionLimit *uint32 `jsonapi:"attr,mention-limit"`
CanSendCustomEmotes *bool `jsonapi:"attr,can-send-custom-emotes"`
CanChangeDisplayName *bool `jsonapi:"attr,can-change-display-name"`
ScanCreatedLocalNotes *bool `jsonapi:"attr,scan-created-local-notes"`
CanSupressInteractionsBetweenUsers *bool `jsonapi:"attr,can-supress-interactions-between-users"`
CanSendReplies *bool `jsonapi:"attr,can-send-replies"`
CanFederateBsky *bool `jsonapi:"attr,can-federate-bsky"`
CanMentionOthers *bool `jsonapi:"attr,can-mention-others"`
ScanCreatedPrivateNotes *bool `jsonapi:"attr,scan-created-private-notes"`
CanRecoverDeletedNotes *bool `jsonapi:"attr,can-recover-deleted-notes"`
CanSendPublicNotes *bool `jsonapi:"attr,can-send-public-notes"`
CanSendPrivateNotes *bool `jsonapi:"attr,can-send-private-notes"`
}

File diff suppressed because one or more lines are too long