@ooneex/typeorm 0.16.0 → 0.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,15 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["src/entities/payment/PaymentFeatureEntity.ts", "src/entities/payment/PaymentPlanEntity.ts", "src/entities/payment/PaymentProductEntity.ts", "src/entities/payment/PaymentCouponEntity.ts", "src/entities/payment/PaymentCreditEntity.ts", "src/entities/payment/PaymentSubscriptionEntity.ts"],
4
- "sourcesContent": [
5
- "import type { IFeature } from \"@ooneex/payment\";\nimport { Column, Entity } from \"typeorm\";\nimport { BaseEntity } from \"../common/BaseEntity\";\n\n@Entity({\n name: \"payment_features\",\n})\nexport class PaymentFeatureEntity extends BaseEntity implements IFeature {\n @Column({ name: \"name\", type: \"varchar\", length: 255 })\n name: string;\n\n @Column({ name: \"description\", type: \"text\", nullable: true })\n description?: string;\n\n @Column({\n name: \"is_enabled\",\n type: \"boolean\",\n default: true,\n nullable: true,\n })\n isEnabled?: boolean;\n\n @Column({ name: \"limit\", type: \"int\", nullable: true })\n limit?: number;\n}\n",
6
- "import type { CurrencyCodeType } from \"@ooneex/currencies\";\nimport { ESubscriptionPeriod, type IFeature, type IPlan } from \"@ooneex/payment\";\nimport { Column, Entity, JoinTable, ManyToMany } from \"typeorm\";\nimport { BaseEntity } from \"../common/BaseEntity\";\nimport { PaymentFeatureEntity } from \"./PaymentFeatureEntity\";\n\n@Entity({\n name: \"payment_plans\",\n})\nexport class PaymentPlanEntity extends BaseEntity implements IPlan {\n @Column({ name: \"name\", type: \"varchar\", length: 255 })\n name: string;\n\n @Column({ name: \"description\", type: \"text\", nullable: true })\n description?: string;\n\n @Column({ name: \"currency\", type: \"varchar\", length: 3 })\n currency: CurrencyCodeType;\n\n @Column({ name: \"price\", type: \"decimal\", precision: 10, scale: 2 })\n price: number;\n\n @Column({\n name: \"period\",\n type: \"enum\",\n enum: ESubscriptionPeriod,\n })\n period: ESubscriptionPeriod;\n\n @Column({ name: \"period_count\", type: \"int\", default: 1, nullable: true })\n periodCount?: number;\n\n @ManyToMany(() => PaymentFeatureEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_plans_features\",\n joinColumn: { name: \"plan_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"feature_id\", referencedColumnName: \"id\" },\n })\n features?: IFeature[];\n\n @Column({ name: \"is_active\", type: \"boolean\", default: true, nullable: true })\n isActive?: boolean;\n\n @Column({ name: \"trial_days\", type: \"int\", default: 0, nullable: true })\n trialDays?: number;\n}\n",
7
- "import type { ICategory } from \"@ooneex/category\";\nimport type { CurrencyCodeType } from \"@ooneex/currencies\";\nimport type { IImage } from \"@ooneex/image\";\nimport type { IProduct } from \"@ooneex/payment\";\nimport type { ITag } from \"@ooneex/tag\";\nimport type { ScalarType } from \"@ooneex/types\";\nimport { Column, Entity, JoinTable, ManyToMany } from \"typeorm\";\nimport { BaseEntity } from \"../common/BaseEntity\";\nimport { CategoryEntity } from \"../common/CategoryEntity\";\nimport { TagEntity } from \"../common/TagEntity\";\nimport { ImageEntity } from \"../image/ImageEntity\";\n\n@Entity({\n name: \"payment_products\",\n})\nexport class PaymentProductEntity extends BaseEntity implements IProduct {\n @Column({ name: \"name\", type: \"varchar\", length: 255 })\n name: string;\n\n @Column({ name: \"description\", type: \"text\", nullable: true })\n description?: string;\n\n @ManyToMany(() => CategoryEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_products_categories\",\n joinColumn: { name: \"product_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"category_id\", referencedColumnName: \"id\" },\n })\n categories?: ICategory[];\n\n @Column({ name: \"currency\", type: \"varchar\", length: 3 })\n currency: CurrencyCodeType;\n\n @Column({ name: \"price\", type: \"decimal\", precision: 10, scale: 2 })\n price: number;\n\n @Column({ name: \"barcode\", type: \"varchar\", length: 255, nullable: true })\n barcode?: string;\n\n @ManyToMany(() => ImageEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_products_images\",\n joinColumn: { name: \"product_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"image_id\", referencedColumnName: \"id\" },\n })\n images?: IImage[];\n\n @Column({ name: \"attributes\", type: \"jsonb\", nullable: true })\n attributes?: Record<string, ScalarType>;\n\n @ManyToMany(() => TagEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_products_tags\",\n joinColumn: { name: \"product_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"tag_id\", referencedColumnName: \"id\" },\n })\n tags?: ITag[];\n}\n",
8
- "import type { CurrencyCodeType } from \"@ooneex/currencies\";\nimport { EDiscountType, type ICoupon, type IPlan, type IProduct } from \"@ooneex/payment\";\nimport { Column, Entity, JoinTable, ManyToMany } from \"typeorm\";\nimport { BaseEntity } from \"../common/BaseEntity\";\nimport { PaymentPlanEntity } from \"./PaymentPlanEntity\";\nimport { PaymentProductEntity } from \"./PaymentProductEntity\";\n\n@Entity({\n name: \"payment_coupons\",\n})\nexport class PaymentCouponEntity extends BaseEntity implements ICoupon {\n @Column({ name: \"code\", type: \"varchar\", length: 50, unique: true })\n code: string;\n\n @Column({ name: \"name\", type: \"varchar\", length: 255, nullable: true })\n name?: string;\n\n @Column({ name: \"description\", type: \"text\", nullable: true })\n description?: string;\n\n @Column({\n name: \"discount_type\",\n type: \"enum\",\n enum: EDiscountType,\n })\n discountType: EDiscountType;\n\n @Column({ name: \"discount_value\", type: \"decimal\", precision: 10, scale: 2 })\n discountValue: number;\n\n @Column({ name: \"currency\", type: \"varchar\", length: 3, nullable: true })\n currency?: CurrencyCodeType;\n\n @Column({ name: \"max_uses\", type: \"int\", nullable: true })\n maxUses?: number;\n\n @Column({ name: \"used_count\", type: \"int\", default: 0, nullable: true })\n usedCount?: number;\n\n @Column({ name: \"start_at\", type: \"timestamptz\", nullable: true })\n startAt?: Date;\n\n @Column({ name: \"end_at\", type: \"timestamptz\", nullable: true })\n endAt?: Date;\n\n @Column({ name: \"is_active\", type: \"boolean\", default: true, nullable: true })\n isActive?: boolean;\n\n @Column({\n name: \"minimum_amount\",\n type: \"decimal\",\n precision: 10,\n scale: 2,\n nullable: true,\n })\n minimumAmount?: number;\n\n @ManyToMany(() => PaymentProductEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_coupons_applicable_products\",\n joinColumn: { name: \"coupon_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"product_id\", referencedColumnName: \"id\" },\n })\n applicableProducts?: IProduct[];\n\n @ManyToMany(() => PaymentPlanEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_coupons_applicable_plans\",\n joinColumn: { name: \"coupon_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"plan_id\", referencedColumnName: \"id\" },\n })\n applicablePlans?: IPlan[];\n}\n",
9
- "import type { CurrencyCodeType } from \"@ooneex/currencies\";\nimport type { ICredit } from \"@ooneex/payment\";\nimport { Column, Entity } from \"typeorm\";\nimport { BaseEntity } from \"../common/BaseEntity\";\n\n@Entity({\n name: \"payment_credits\",\n})\nexport class PaymentCreditEntity extends BaseEntity implements ICredit {\n @Column({ name: \"balance\", type: \"decimal\", precision: 10, scale: 2 })\n balance: number;\n\n @Column({ name: \"currency\", type: \"varchar\", length: 3, nullable: true })\n currency?: CurrencyCodeType;\n\n @Column({ name: \"expires_at\", type: \"timestamptz\", nullable: true })\n expiresAt?: Date;\n\n @Column({ name: \"description\", type: \"text\", nullable: true })\n description?: string;\n}\n",
10
- "import type { ICoupon, ICredit, IPlan, ISubscription } from \"@ooneex/payment\";\nimport { Column, Entity, JoinTable, ManyToMany } from \"typeorm\";\nimport { BaseEntity } from \"../common/BaseEntity\";\nimport { PaymentCouponEntity } from \"./PaymentCouponEntity\";\nimport { PaymentCreditEntity } from \"./PaymentCreditEntity\";\nimport { PaymentPlanEntity } from \"./PaymentPlanEntity\";\n\n@Entity({\n name: \"payment_subscriptions\",\n})\nexport class PaymentSubscriptionEntity extends BaseEntity implements Omit<ISubscription, \"isActive\"> {\n @ManyToMany(() => PaymentCouponEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_subscriptions_coupons\",\n joinColumn: { name: \"subscription_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"coupon_id\", referencedColumnName: \"id\" },\n })\n coupons?: ICoupon[];\n\n @ManyToMany(() => PaymentPlanEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_subscriptions_plans\",\n joinColumn: { name: \"subscription_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"plan_id\", referencedColumnName: \"id\" },\n })\n plans?: IPlan[];\n\n @ManyToMany(() => PaymentCreditEntity, {\n nullable: true,\n eager: false,\n cascade: [\"insert\", \"update\"],\n })\n @JoinTable({\n name: \"payment_subscriptions_credits\",\n joinColumn: { name: \"subscription_id\", referencedColumnName: \"id\" },\n inverseJoinColumn: { name: \"credit_id\", referencedColumnName: \"id\" },\n })\n credits?: ICredit[];\n\n @Column({ name: \"start_at\", type: \"timestamptz\" })\n startAt: Date;\n\n @Column({ name: \"end_at\", type: \"timestamptz\", nullable: true })\n endAt?: Date;\n\n @Column({ name: \"is_trial\", type: \"boolean\", default: false, nullable: true })\n isTrial?: boolean;\n\n @Column({ name: \"is_active\", type: \"boolean\", default: true, nullable: true })\n isActive?: boolean;\n}\n"
11
- ],
12
- "mappings": ";6OACA,WAAS,MAAQ,UAMV,AAAM,UAA6B,CAA+B,CAiBzE,CAfE,GADC,EAAO,CAAE,KAAM,OAAQ,KAAM,UAAW,OAAQ,GAAI,CAAC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K,CAAC,EAC7E,0BA5CW,EA4CX,4BAGA,GADC,EAAO,CAAE,KAAM,YAAa,KAAM,UAAW,QAAS,GAAM,SAAU,EAAK,CAAC,EAC7E,0BA/CW,EA+CX,6BA/CW,EAAN,GAHN,EAAO,CACN,KAAM,uBACR,CAAC,GACY",
13
- "debugId": "1671746A056BBCAB64756E2164756E21",
14
- "names": []
15
- }
@@ -1,5 +0,0 @@
1
- // @bun
2
- import{Ba as C}from"./chunk-p22keb3y.js";import{Ga as a}from"./chunk-xrqhqgen.js";import{Ha as e,Ja as t}from"./chunk-59vwmfpm.js";import{Column as n,Entity as z,JoinColumn as E,ManyToOne as V,OneToMany as c}from"typeorm";class r extends a{}e([n({name:"email",type:"varchar",length:255,unique:!0}),t("design:type",String)],r.prototype,"email",void 0),e([n({name:"roles",type:"simple-array"}),t("design:type",Array)],r.prototype,"roles",void 0),e([n({name:"name",type:"varchar",length:255,nullable:!0}),t("design:type",String)],r.prototype,"name",void 0),e([n({name:"last_name",type:"varchar",length:255,nullable:!0}),t("design:type",String)],r.prototype,"lastName",void 0),e([n({name:"first_name",type:"varchar",length:255,nullable:!0}),t("design:type",String)],r.prototype,"firstName",void 0),e([n({name:"username",type:"varchar",length:100,unique:!0,nullable:!0}),t("design:type",String)],r.prototype,"username",void 0),e([V(()=>C,{nullable:!0,eager:!1,cascade:["insert","update"]}),E({name:"avatar_id"}),t("design:type",typeof IImage==="undefined"?Object:IImage)],r.prototype,"avatar",void 0),e([n({name:"bio",type:"text",nullable:!0}),t("design:type",String)],r.prototype,"bio",void 0),e([n({name:"phone",type:"varchar",length:20,nullable:!0}),t("design:type",String)],r.prototype,"phone",void 0),e([n({name:"birth_date",type:"date",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],r.prototype,"birthDate",void 0),e([n({name:"timezone",type:"varchar",length:50,nullable:!0}),t("design:type",String)],r.prototype,"timezone",void 0),e([n({name:"is_email_verified",type:"boolean",default:!1,nullable:!0}),t("design:type",Boolean)],r.prototype,"isEmailVerified",void 0),e([n({name:"is_phone_verified",type:"boolean",default:!1,nullable:!0}),t("design:type",Boolean)],r.prototype,"isPhoneVerified",void 0),e([n({name:"last_active_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],r.prototype,"lastActiveAt",void 0),e([n({name:"email_verified_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],r.prototype,"emailVerifiedAt",void 0),e([n({name:"phone_verified_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],r.prototype,"phoneVerifiedAt",void 0),e([n({name:"last_login_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],r.prototype,"lastLoginAt",void 0),e([n({name:"password_changed_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],r.prototype,"passwordChangedAt",void 0),e([n({name:"two_factor_enabled",type:"boolean",default:!1,nullable:!0}),t("design:type",Boolean)],r.prototype,"twoFactorEnabled",void 0),e([n({name:"two_factor_secret",type:"varchar",length:255,nullable:!0}),t("design:type",String)],r.prototype,"twoFactorSecret",void 0),e([n({name:"recovery_tokens",type:"simple-array",nullable:!0}),t("design:type",Array)],r.prototype,"recoveryTokens",void 0),e([c("SessionEntity","user",{nullable:!0,eager:!1,cascade:["insert","update"]}),t("design:type",Array)],r.prototype,"sessions",void 0),e([c("AccountEntity","user",{nullable:!0,eager:!1,cascade:["insert","update"]}),t("design:type",Array)],r.prototype,"accounts",void 0),e([c("VerificationEntity","user",{nullable:!0,eager:!1,cascade:["insert","update"]}),t("design:type",Array)],r.prototype,"verifications",void 0),r=e([z({name:"users"})],r);import{EAccountType as D}from"@ooneex/user";import{Column as l,Entity as M,JoinColumn as O,ManyToOne as J}from"typeorm";class g extends a{}e([l({name:"provider",type:"varchar",length:100,nullable:!0}),t("design:type",String)],g.prototype,"provider",void 0),e([l({name:"provider_account_id",type:"varchar",length:255,nullable:!0}),t("design:type",String)],g.prototype,"providerAccountId",void 0),e([l({name:"type",type:"enum",enum:D}),t("design:type",typeof D==="undefined"?Object:D)],g.prototype,"type",void 0),e([l({name:"password",type:"varchar",length:255,nullable:!0}),t("design:type",String)],g.prototype,"password",void 0),e([l({name:"access_token",type:"text",nullable:!0}),t("design:type",String)],g.prototype,"accessToken",void 0),e([l({name:"access_token_expires_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],g.prototype,"accessTokenExpiresAt",void 0),e([l({name:"refresh_token",type:"text",nullable:!0}),t("design:type",String)],g.prototype,"refreshToken",void 0),e([l({name:"refresh_token_expires_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],g.prototype,"refreshTokenExpiresAt",void 0),e([l({name:"expires_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],g.prototype,"expiresAt",void 0),e([l({name:"token_type",type:"varchar",length:50,nullable:!0}),t("design:type",String)],g.prototype,"tokenType",void 0),e([l({name:"scope",type:"text",nullable:!0}),t("design:type",String)],g.prototype,"scope",void 0),e([l({name:"id_token",type:"text",nullable:!0}),t("design:type",String)],g.prototype,"idToken",void 0),e([l({name:"session_state",type:"varchar",length:255,nullable:!0}),t("design:type",String)],g.prototype,"sessionState",void 0),e([l({name:"email",type:"varchar",length:255,nullable:!0}),t("design:type",String)],g.prototype,"email",void 0),e([l({name:"email_verified",type:"boolean",default:!1,nullable:!0}),t("design:type",Boolean)],g.prototype,"emailVerified",void 0),e([l({name:"name",type:"varchar",length:255,nullable:!0}),t("design:type",String)],g.prototype,"name",void 0),e([l({name:"picture",type:"varchar",length:500,nullable:!0}),t("design:type",String)],g.prototype,"picture",void 0),e([l({name:"profile",type:"jsonb",nullable:!0}),t("design:type",typeof Record==="undefined"?Object:Record)],g.prototype,"profile",void 0),e([J(()=>r,(m)=>m.accounts,{nullable:!0,eager:!1,onDelete:"CASCADE"}),O({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],g.prototype,"user",void 0),g=e([M({name:"accounts"})],g);import{Column as s,Entity as R,JoinColumn as S,ManyToOne as q}from"typeorm";class b extends a{}e([s({name:"token",type:"varchar",length:255,unique:!0}),t("design:type",String)],b.prototype,"token",void 0),e([s({name:"refresh_token",type:"varchar",length:255,nullable:!0}),t("design:type",String)],b.prototype,"refreshToken",void 0),e([s({name:"user_agent",type:"text",nullable:!0}),t("design:type",String)],b.prototype,"userAgent",void 0),e([s({name:"ip_address",type:"inet",nullable:!0}),t("design:type",String)],b.prototype,"ipAddress",void 0),e([s({name:"device_type",type:"varchar",length:50,nullable:!0}),t("design:type",String)],b.prototype,"deviceType",void 0),e([s({name:"device_name",type:"varchar",length:255,nullable:!0}),t("design:type",String)],b.prototype,"deviceName",void 0),e([s({name:"browser",type:"varchar",length:255,nullable:!0}),t("design:type",String)],b.prototype,"browser",void 0),e([s({name:"operating_system",type:"varchar",length:255,nullable:!0}),t("design:type",String)],b.prototype,"operatingSystem",void 0),e([s({name:"location",type:"varchar",length:255,nullable:!0}),t("design:type",String)],b.prototype,"location",void 0),e([s({name:"is_active",type:"boolean",default:!0}),t("design:type",Boolean)],b.prototype,"isActive",void 0),e([s({name:"expires_at",type:"timestamptz"}),t("design:type",typeof Date==="undefined"?Object:Date)],b.prototype,"expiresAt",void 0),e([s({name:"last_access_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],b.prototype,"lastAccessAt",void 0),e([s({name:"revoked_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],b.prototype,"revokedAt",void 0),e([s({name:"revoked_reason",type:"varchar",length:255,nullable:!0}),t("design:type",String)],b.prototype,"revokedReason",void 0),e([q(()=>r,(m)=>m.sessions,{nullable:!0,eager:!1,onDelete:"CASCADE"}),S({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],b.prototype,"user",void 0),b=e([R({name:"sessions"})],b);import{Column as y,Entity as j,JoinColumn as N,ManyToOne as F}from"typeorm";class f extends a{}e([F(()=>r,{nullable:!0,eager:!1}),N({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],f.prototype,"user",void 0),e([y({name:"user_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],f.prototype,"userId",void 0),e([y({name:"blocked_by",type:"varchar",length:255,nullable:!0}),t("design:type",String)],f.prototype,"blockedBy",void 0),e([y({name:"blocked_by_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],f.prototype,"blockedById",void 0),e([y({name:"reason",type:"text",nullable:!0}),t("design:type",String)],f.prototype,"reason",void 0),f=e([j({name:"users_blocked"})],f);import{Column as h,Entity as L,JoinColumn as G,ManyToOne as H}from"typeorm";class _ extends a{}e([H(()=>r,{nullable:!0,eager:!1}),G({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],_.prototype,"user",void 0),e([h({name:"user_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],_.prototype,"userId",void 0),e([h({name:"followed_by",type:"varchar",length:255,nullable:!0}),t("design:type",String)],_.prototype,"followedBy",void 0),e([h({name:"followed_by_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],_.prototype,"followedById",void 0),_=e([L({name:"users_followed"})],_);import{EVerificationType as w}from"@ooneex/user";import{Column as o,Entity as K,JoinColumn as P,ManyToOne as Q}from"typeorm";class p extends a{}e([o({name:"email",type:"varchar",length:255,nullable:!0}),t("design:type",String)],p.prototype,"email",void 0),e([o({name:"phone",type:"varchar",length:20,nullable:!0}),t("design:type",String)],p.prototype,"phone",void 0),e([o({name:"token",type:"varchar",length:255,unique:!0}),t("design:type",String)],p.prototype,"token",void 0),e([o({name:"type",type:"enum",enum:w}),t("design:type",typeof w==="undefined"?Object:w)],p.prototype,"type",void 0),e([o({name:"code",type:"varchar",length:10,nullable:!0}),t("design:type",String)],p.prototype,"code",void 0),e([o({name:"is_used",type:"boolean",default:!1}),t("design:type",Boolean)],p.prototype,"isUsed",void 0),e([o({name:"used_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],p.prototype,"usedAt",void 0),e([o({name:"expires_at",type:"timestamptz"}),t("design:type",typeof Date==="undefined"?Object:Date)],p.prototype,"expiresAt",void 0),e([o({name:"attempts_count",type:"int",default:0}),t("design:type",Number)],p.prototype,"attemptsCount",void 0),e([o({name:"max_attempts",type:"int",default:5}),t("design:type",Number)],p.prototype,"maxAttempts",void 0),e([o({name:"ip_address",type:"inet",nullable:!0}),t("design:type",String)],p.prototype,"ipAddress",void 0),e([o({name:"user_agent",type:"text",nullable:!0}),t("design:type",String)],p.prototype,"userAgent",void 0),e([o({name:"metadata",type:"jsonb",nullable:!0}),t("design:type",typeof Record==="undefined"?Object:Record)],p.prototype,"metadata",void 0),e([o({name:"description",type:"text",nullable:!0}),t("design:type",String)],p.prototype,"description",void 0),e([Q(()=>r,(m)=>m.verifications,{nullable:!0,eager:!1,onDelete:"CASCADE"}),P({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],p.prototype,"user",void 0),p=e([K({name:"verifications"})],p);import{EProfileUpdateStatus as T}from"@ooneex/user";import{Column as i,Entity as W,JoinColumn as U,ManyToOne as B}from"typeorm";class v extends a{}e([i({name:"changed_fields",type:"simple-array"}),t("design:type",Array)],v.prototype,"changedFields",void 0),e([i({name:"previous_values",type:"jsonb",nullable:!0}),t("design:type",typeof Record==="undefined"?Object:Record)],v.prototype,"previousValues",void 0),e([i({name:"new_values",type:"jsonb",nullable:!0}),t("design:type",typeof Record==="undefined"?Object:Record)],v.prototype,"newValues",void 0),e([i({name:"update_reason",type:"varchar",length:255,nullable:!0}),t("design:type",String)],v.prototype,"updateReason",void 0),e([i({name:"ip_address",type:"inet",nullable:!0}),t("design:type",String)],v.prototype,"ipAddress",void 0),e([i({name:"user_agent",type:"text",nullable:!0}),t("design:type",String)],v.prototype,"userAgent",void 0),e([i({name:"requires_verification",type:"boolean",default:!1,nullable:!0}),t("design:type",Boolean)],v.prototype,"requiresVerification",void 0),e([i({name:"status",type:"enum",enum:T}),t("design:type",typeof T==="undefined"?Object:T)],v.prototype,"status",void 0),e([i({name:"applied_at",type:"timestamptz",nullable:!0}),t("design:type",typeof Date==="undefined"?Object:Date)],v.prototype,"appliedAt",void 0),e([i({name:"metadata",type:"jsonb",nullable:!0}),t("design:type",typeof Record==="undefined"?Object:Record)],v.prototype,"metadata",void 0),e([i({name:"description",type:"text",nullable:!0}),t("design:type",String)],v.prototype,"description",void 0),e([B(()=>r,{nullable:!0,eager:!1,onDelete:"CASCADE"}),U({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],v.prototype,"user",void 0),e([B(()=>p,{nullable:!0,eager:!1}),U({name:"verification_id"}),t("design:type",typeof IVerification==="undefined"?Object:IVerification)],v.prototype,"verification",void 0),v=e([W({name:"user_profile_updates"})],v);import{Column as d,Entity as X,JoinColumn as Y,ManyToOne as Z}from"typeorm";class I extends a{}e([Z(()=>r,{nullable:!0,eager:!1}),Y({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],I.prototype,"user",void 0),e([d({name:"user_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],I.prototype,"userId",void 0),e([d({name:"reason",type:"varchar",length:255}),t("design:type",String)],I.prototype,"reason",void 0),e([d({name:"description",type:"text",nullable:!0}),t("design:type",String)],I.prototype,"description",void 0),e([d({name:"reported_by",type:"varchar",length:255,nullable:!0}),t("design:type",String)],I.prototype,"reportedBy",void 0),e([d({name:"reported_by_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],I.prototype,"reportedById",void 0),I=e([X({name:"users_reports"})],I);import{Column as u,Entity as $,JoinColumn as ee,ManyToOne as te}from"typeorm";class x extends a{}e([te(()=>r,{nullable:!0,eager:!1}),ee({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],x.prototype,"user",void 0),e([u({name:"user_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],x.prototype,"userId",void 0),e([u({name:"followers_count",type:"int",default:0,nullable:!0}),t("design:type",Number)],x.prototype,"followersCount",void 0),e([u({name:"following_count",type:"int",default:0,nullable:!0}),t("design:type",Number)],x.prototype,"followingCount",void 0),e([u({name:"blocked_count",type:"int",default:0,nullable:!0}),t("design:type",Number)],x.prototype,"blockedCount",void 0),e([u({name:"views_count",type:"int",default:0,nullable:!0}),t("design:type",Number)],x.prototype,"viewsCount",void 0),e([u({name:"reports_count",type:"int",default:0,nullable:!0}),t("design:type",Number)],x.prototype,"reportsCount",void 0),x=e([$({name:"users_stats"})],x);import{Column as k,Entity as re,JoinColumn as ne,ManyToOne as ae}from"typeorm";class A extends a{}e([ae(()=>r,{nullable:!0,eager:!1}),ne({name:"user_id"}),t("design:type",typeof IUser==="undefined"?Object:IUser)],A.prototype,"user",void 0),e([k({name:"user_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],A.prototype,"userId",void 0),e([k({name:"viewed_by",type:"varchar",length:255,nullable:!0}),t("design:type",String)],A.prototype,"viewedBy",void 0),e([k({name:"viewed_by_id",type:"varchar",length:25,nullable:!0}),t("design:type",String)],A.prototype,"viewedById",void 0),A=e([re({name:"users_viewed"})],A);
3
- export{r as ra,g as sa,b as ta,f as ua,_ as va,p as wa,v as xa,I as ya,x as za,A as Aa};
4
-
5
- //# debugId=BD134E5F54A47B2B64756E2164756E21