cc-core-cli 1.0.109 → 1.0.111

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": "cc-core-cli",
3
- "version": "1.0.109",
3
+ "version": "1.0.111",
4
4
  "description": "Command Line Interface tool for generating project templates for the (Your Platform's Name) platform.",
5
5
  "main": "bin/index.js",
6
6
  "scripts": {
@@ -15,7 +15,7 @@
15
15
  "author": "",
16
16
  "license": "ISC",
17
17
  "dependencies": {
18
- "@shopstack/cc-admin-lib": "^2.5.171"
18
+ "@shopstack/cc-admin-lib": "^2.5.174"
19
19
  },
20
20
  "devDependencies": {
21
21
  "identity-obj-proxy": "^3.0.0",
@@ -179,10 +179,6 @@
179
179
  }
180
180
  }
181
181
 
182
- .editable-row:hover > td {
183
- background-color: inherit !important;
184
- }
185
-
186
182
  .editable-row .editable-cell-value-wrap {
187
183
  border: 1px solid #d9d9d9;
188
184
  border-radius: 4px;
@@ -256,7 +252,7 @@
256
252
 
257
253
  .editable {
258
254
  margin-bottom: 24px;
259
-
255
+
260
256
  .editable-row:hover > td {
261
257
  background-color: inherit !important;
262
258
  }
@@ -761,7 +757,7 @@ h4.ant-typography {
761
757
  width: 100%;
762
758
  height: 100%;
763
759
  left: 0;
764
- // background-color: rgba(0, 0, 0, 0.5);แ
760
+ // background-color: rgba(0, 0, 0, 0.5);แ
765
761
  opacity: 0.9;
766
762
  transition: all 0.3s;
767
763
  content: " ";
@@ -17,7 +17,7 @@
17
17
  "lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix"
18
18
  },
19
19
  "dependencies": {
20
- "@shopstack/cc-core-lib": "^2.5.181"
20
+ "@shopstack/cc-core-lib": "^2.5.184"
21
21
  },
22
22
  "devDependencies": {
23
23
  "@types/bull": "^3.14.4",
@@ -96,7 +96,10 @@ if (+process.env.MONGODB_MAX_POOL_SIZE) {
96
96
  permissions: _.get(req, "permissions", []),
97
97
  headers: _.get(req, "headers", {}),
98
98
  ip: _.get(req, "ip"),
99
+ protocol: _.get(req, "protocol"),
99
100
  hostname: _.get(req, "hostname"),
101
+ url: _.get(req, "url"),
102
+ method: _.get(req, "method"),
100
103
  body: _.get(req, "body", {}),
101
104
  action_profile: _.get(req, "action_profile", {}),
102
105
  permisson_entities: _.get(req, "permisson_entities", {}),
@@ -118,7 +121,10 @@ if (+process.env.MONGODB_MAX_POOL_SIZE) {
118
121
  ip:
119
122
  _.get(req, "socket.remoteAddress") ||
120
123
  _.get(req, "connection.remoteAddress"),
121
- hostname: req.hostname,
124
+ protocol: _.get(req, "protocol"),
125
+ hostname: _.get(req, "hostname"),
126
+ url: _.get(req, "url"),
127
+ method: _.get(req, "method"),
122
128
  body: _.get(req, "body", {}),
123
129
  action_profile: _.get(req, "action_profile", {}),
124
130
  permisson_entities: _.get(req, "permisson_entities", {}),
@@ -221,25 +221,11 @@ async function initial(app: NestFastifyApplication) {
221
221
 
222
222
  async function bootstrap() {
223
223
  dotenv.config();
224
- // const whitelist = _.concat(["0.0.0.0", "127.0.0.1"], [`${process.env.LOOP_BACK_IP}`]);
225
224
  const fastify = new FastifyAdapter({ logger: true, bodyLimit: 104857600 });
226
- // fastify.register(require("fastify-rate-limit"), {
227
- // whitelist,
228
- // timeWindow: 15 * 60 * 1000, // 15 minutes
229
- // max: 100 // limit each IP to 100 requests per windowMs
230
- // });
225
+
231
226
  fastify.register(require("@fastify/cors"), {
232
227
  // put your options here
233
228
  });
234
- fastify.register(require("fastify-xml-body-parser"));
235
-
236
- // fastify.register(require("fastify-raw-body"), {
237
- // field: 'rawBody', // change the default request.rawBody property name
238
- // global: false, // add the rawBody to every request. **Default true**
239
- // encoding: 'utf8', // set it to false to set rawBody as a Buffer **Default utf8**
240
- // runFirst: true, // get the body before any preParsing hook change/uncompress it. **Default false**
241
- // routes: [] // array of routes, **`global`** will be ignored, wildcard routes not supported
242
- // });
243
229
 
244
230
  fastify.register(rTracer.fastifyPlugin, {
245
231
  requestIdFactory: req => ({
@@ -248,7 +234,13 @@ async function bootstrap() {
248
234
  user_agent: req.headers["user-agent"]
249
235
  })
250
236
  });
237
+
238
+ // Register the multipart plugin
239
+ fastify.register(require("@fastify/multipart"), { attachFieldsToBody: true });
251
240
 
241
+ // Register the fastify-xml-body-parser plugin
242
+ fastify.register(require("fastify-xml-body-parser"));
243
+
252
244
  const app = await NestFactory.create<NestFastifyApplication>(
253
245
  AppModule,
254
246
  fastify