@things-factory/product-base 6.0.60 → 6.0.70

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/product-base",
3
- "version": "6.0.60",
3
+ "version": "6.0.70",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "client/index.js",
6
6
  "things-factory": true,
@@ -23,9 +23,9 @@
23
23
  "migration:create": "node ../../node_modules/typeorm/cli.js migration:create -d ./server/migrations"
24
24
  },
25
25
  "dependencies": {
26
- "@things-factory/biz-base": "^6.0.60",
26
+ "@things-factory/biz-base": "^6.0.70",
27
27
  "@things-factory/env": "^6.0.49",
28
- "@things-factory/routing-base": "^6.0.60"
28
+ "@things-factory/routing-base": "^6.0.67"
29
29
  },
30
- "gitHead": "d9d824a2cfd93ac110f2c4acd67c4ffc175a8c87"
30
+ "gitHead": "b9c05eb9b7a0aed2bcf7b24bd5851eb047b54391"
31
31
  }
@@ -22,7 +22,7 @@ const debug = require('debug')('things-factory:product-base:product')
22
22
 
23
23
  @Resolver(Product)
24
24
  export class ProductQuery {
25
- @Directive('@privilege(category: "order", privilege: "query")')
25
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
26
26
  @Query(returns => Product)
27
27
  async product(@Arg('sku') sku: string, @Ctx() context: ResolverContext): Promise<Product> {
28
28
  const { domain, user, bizplace } = context.state
@@ -48,7 +48,7 @@ export class ProductQuery {
48
48
  }
49
49
  }
50
50
 
51
- @Directive('@privilege(category: "order", privilege: "query")')
51
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
52
52
  @Query(returns => ProductList)
53
53
  async products(@Args() params: ListParam, @Ctx() context: ResolverContext): Promise<ProductList> {
54
54
  const { domain, user } = context.state
@@ -89,7 +89,7 @@ export class ProductQuery {
89
89
  return { items, total }
90
90
  }
91
91
 
92
- @Directive('@privilege(category: "order", privilege: "query")')
92
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
93
93
  @Query(returns => ProductList)
94
94
  async myBizplaceProducts(@Args() params: ListParam, @Ctx() context: ResolverContext): Promise<ProductList> {
95
95
  try {
@@ -123,7 +123,7 @@ export class ProductQuery {
123
123
  }
124
124
  }
125
125
 
126
- @Directive('@privilege(category: "order", privilege: "query")')
126
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
127
127
  @Query(returns => ProductList)
128
128
  async productsByBizplace(@Args() params: ListParam, @Ctx() context: ResolverContext): Promise<ProductList> {
129
129
  const { domain, user } = context.state
@@ -171,7 +171,7 @@ export class ProductQuery {
171
171
  * @returns pure product data only. there will be no other table joined to avoid
172
172
  * ORM lagging issue (converting to object extremely withdraws the performance)
173
173
  * */
174
- @Directive('@privilege(category: "order", privilege: "query")')
174
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
175
175
  @Query(returns => ProductList)
176
176
  async pureProductsByBizplace(@Args() params: ListParam, @Ctx() context: ResolverContext): Promise<ProductList> {
177
177
  const { domain, user } = context.state
@@ -10,7 +10,7 @@ import { ProductSetList } from './product-set-types'
10
10
 
11
11
  @Resolver(ProductSet)
12
12
  export class ProductSetQuery {
13
- @Directive('@privilege(category: "order", privilege: "query")')
13
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
14
14
  @Query(returns => ProductSetList)
15
15
  async myBizplaceProductSets(@Args() params: ListParam, @Ctx() context: ResolverContext): Promise<ProductSetList> {
16
16
  const { domain, user } = context.state
@@ -57,7 +57,7 @@ export class ProductSetQuery {
57
57
  return { items, total }
58
58
  }
59
59
 
60
- @Directive('@privilege(category: "order", privilege: "query")')
60
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
61
61
  @Query(returns => ProductSetList)
62
62
  async productSets(@Args() params: ListParam, @Ctx() context: ResolverContext): Promise<ProductSetList> {
63
63
  const { domain, user } = context.state
@@ -79,7 +79,7 @@ export class ProductSetQuery {
79
79
  return { items, total }
80
80
  }
81
81
 
82
- @Directive('@privilege(category: "order", privilege: "query")')
82
+ @Directive('@privilege(category: "order", privilege: "query", domainOwnerGranted: true)')
83
83
  @Query(returns => ProductSet)
84
84
  async productSet(@Arg('name') name: string, @Ctx() context: ResolverContext): Promise<ProductSet> {
85
85
  const { domain, user } = context.state