mirror of
https://github.com/samiyev/puaros.git
synced 2025-12-27 23:06:54 +05:00
fix: eliminate magic strings and fix aggregate boundary detection
- Extract DDD folder names and repository method suggestions to constants - Fix regex pattern to support relative paths (domain/... without leading /) - Add non-aggregate folder exclusions (constants, shared, factories, etc.) - Remove findAll, exists, count from ORM_QUERY_METHODS (valid domain methods) - Add exists, count, countBy patterns to domainMethodPatterns - Add aggregate boundary test examples
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import { User } from "../user/User"
|
||||
import { Product } from "../product/Product"
|
||||
|
||||
export class Order {
|
||||
private id: string
|
||||
private user: User
|
||||
private product: Product
|
||||
private quantity: number
|
||||
|
||||
constructor(id: string, user: User, product: Product, quantity: number) {
|
||||
this.id = id
|
||||
this.user = user
|
||||
this.product = product
|
||||
this.quantity = quantity
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
export class Product {
|
||||
public price: number
|
||||
|
||||
constructor(price: number) {
|
||||
this.price = price
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
export class User {
|
||||
public email: string
|
||||
|
||||
constructor(email: string) {
|
||||
this.email = email
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user