@things-factory/integration-pos 5.0.0-alpha.5 → 5.0.0-alpha.52
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,12 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.posStoresResolver = void 0;
|
|
4
|
-
const shell_1 = require("@things-factory/shell");
|
|
5
4
|
const typeorm_1 = require("typeorm");
|
|
5
|
+
const shell_1 = require("@things-factory/shell");
|
|
6
6
|
const entities_1 = require("../../../entities");
|
|
7
7
|
exports.posStoresResolver = {
|
|
8
8
|
async posStores(_, params, context) {
|
|
9
|
-
const
|
|
9
|
+
const { domain } = context.state;
|
|
10
|
+
const convertedParams = (0, shell_1.convertListParams)(params, { domain });
|
|
10
11
|
const [items, total] = await (0, typeorm_1.getRepository)(entities_1.PosStore).findAndCount(Object.assign(Object.assign({}, convertedParams), { relations: ['domain', 'creator', 'updater'] }));
|
|
11
12
|
return { items, total };
|
|
12
13
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pos-stores.js","sourceRoot":"","sources":["../../../../server/graphql/resolvers/pos/pos-stores.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"pos-stores.js","sourceRoot":"","sources":["../../../../server/graphql/resolvers/pos/pos-stores.ts"],"names":[],"mappings":";;;AAAA,qCAAuC;AAEvC,iDAAoE;AAEpE,gDAA4C;AAE/B,QAAA,iBAAiB,GAAG;IAC/B,KAAK,CAAC,SAAS,CAAC,CAAM,EAAE,MAAiB,EAAE,OAAY;QACrD,MAAM,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,KAAK,CAAA;QAChC,MAAM,eAAe,GAAG,IAAA,yBAAiB,EAAC,MAAM,EAAE,EAAE,MAAM,EAAE,CAAC,CAAA;QAC7D,MAAM,CAAC,KAAK,EAAE,KAAK,CAAC,GAAG,MAAM,IAAA,uBAAa,EAAC,mBAAQ,CAAC,CAAC,YAAY,iCAC5D,eAAe,KAClB,SAAS,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,SAAS,CAAC,IAC3C,CAAA;QACF,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAA;IACzB,CAAC;CACF,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@things-factory/integration-pos",
|
|
3
|
-
"version": "5.0.0-alpha.
|
|
3
|
+
"version": "5.0.0-alpha.52",
|
|
4
4
|
"main": "dist-server/index.js",
|
|
5
5
|
"browser": "client/index.js",
|
|
6
6
|
"things-factory": true,
|
|
@@ -25,18 +25,18 @@
|
|
|
25
25
|
"test": "DEBUG=things-factory:* NODE_ENV=development npx mocha -r ts-node/register ./test/**/*spec.ts"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@things-factory/apptool-ui": "^5.0.0-alpha.
|
|
29
|
-
"@things-factory/auth-ui": "^5.0.0-alpha.
|
|
30
|
-
"@things-factory/biz-base": "^5.0.0-alpha.
|
|
31
|
-
"@things-factory/code-ui": "^5.0.0-alpha.
|
|
32
|
-
"@things-factory/context-ui": "^5.0.0-alpha.
|
|
33
|
-
"@things-factory/grist-ui": "^5.0.0-alpha.
|
|
34
|
-
"@things-factory/i18n-base": "^5.0.0-alpha.
|
|
35
|
-
"@things-factory/integration-ui": "^5.0.0-alpha.
|
|
36
|
-
"@things-factory/more-ui": "^5.0.0-alpha.
|
|
37
|
-
"@things-factory/resource-ui": "^5.0.0-alpha.
|
|
38
|
-
"@things-factory/setting-ui": "^5.0.0-alpha.
|
|
39
|
-
"@things-factory/system-ui": "^5.0.0-alpha.
|
|
28
|
+
"@things-factory/apptool-ui": "^5.0.0-alpha.52",
|
|
29
|
+
"@things-factory/auth-ui": "^5.0.0-alpha.52",
|
|
30
|
+
"@things-factory/biz-base": "^5.0.0-alpha.52",
|
|
31
|
+
"@things-factory/code-ui": "^5.0.0-alpha.52",
|
|
32
|
+
"@things-factory/context-ui": "^5.0.0-alpha.52",
|
|
33
|
+
"@things-factory/grist-ui": "^5.0.0-alpha.52",
|
|
34
|
+
"@things-factory/i18n-base": "^5.0.0-alpha.52",
|
|
35
|
+
"@things-factory/integration-ui": "^5.0.0-alpha.52",
|
|
36
|
+
"@things-factory/more-ui": "^5.0.0-alpha.52",
|
|
37
|
+
"@things-factory/resource-ui": "^5.0.0-alpha.52",
|
|
38
|
+
"@things-factory/setting-ui": "^5.0.0-alpha.52",
|
|
39
|
+
"@things-factory/system-ui": "^5.0.0-alpha.52",
|
|
40
40
|
"debug": "^4.1.1",
|
|
41
41
|
"node-fetch": "^2.6.0"
|
|
42
42
|
},
|
|
@@ -50,5 +50,5 @@
|
|
|
50
50
|
"nock": "^13.0.2",
|
|
51
51
|
"should": "^13.2.3"
|
|
52
52
|
},
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "dd9c8f2e256e256e42bd9bd26db5eaa955f85620"
|
|
54
54
|
}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
-
import { ListParam, convertListParams } from '@things-factory/shell'
|
|
2
1
|
import { getRepository } from 'typeorm'
|
|
2
|
+
|
|
3
|
+
import { convertListParams, ListParam } from '@things-factory/shell'
|
|
4
|
+
|
|
3
5
|
import { PosStore } from '../../../entities'
|
|
4
6
|
|
|
5
7
|
export const posStoresResolver = {
|
|
6
8
|
async posStores(_: any, params: ListParam, context: any) {
|
|
7
|
-
const
|
|
9
|
+
const { domain } = context.state
|
|
10
|
+
const convertedParams = convertListParams(params, { domain })
|
|
8
11
|
const [items, total] = await getRepository(PosStore).findAndCount({
|
|
9
12
|
...convertedParams,
|
|
10
13
|
relations: ['domain', 'creator', 'updater']
|