@social-mail/social-mail-web-server 1.4.948 → 1.4.950

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,7 +1,8 @@
1
1
  import Page from "@entity-access/server-pages/dist/Page.js";
2
2
  import PhonePeGateway from "../../../../../server/services/payment-gateways/PhonePeGateway.js";
3
+ import Content from "@entity-access/server-pages/dist/Content.js";
3
4
  export default class extends Page {
4
5
  gateway: PhonePeGateway;
5
- run(): Promise<import("@entity-access/server-pages/dist/Content.js").Redirect>;
6
+ run(): Promise<Content>;
6
7
  }
7
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/wwwroot/routes/pg-i/phone-pe/create/index.tsx"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,0CAA0C,CAAC;AAC5D,OAAO,cAAc,MAAM,mEAAmE,CAAC;AAE/F,MAAM,CAAC,OAAO,MAAO,SAAQ,IAAI;IAG7B,OAAO,EAAE,cAAc,CAAC;IAElB,GAAG;CASZ"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/wwwroot/routes/pg-i/phone-pe/create/index.tsx"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,0CAA0C,CAAC;AAC5D,OAAO,cAAc,MAAM,mEAAmE,CAAC;AAG/F,OAAO,OAAO,MAAM,6CAA6C,CAAC;AAElE,MAAM,CAAC,OAAO,MAAO,SAAQ,IAAI;IAG7B,OAAO,EAAE,cAAc,CAAC;IAElB,GAAG;CAmBZ"}
@@ -10,12 +10,23 @@ var __metadata = (this && this.__metadata) || function (k, v) {
10
10
  import Inject from "@entity-access/entity-access/dist/di/di.js";
11
11
  import Page from "@entity-access/server-pages/dist/Page.js";
12
12
  import PhonePeGateway from "../../../../../server/services/payment-gateways/PhonePeGateway.js";
13
+ import HtmlDocument from "@entity-access/server-pages/dist/html/HtmlDocument.js";
14
+ import XNode from "@entity-access/server-pages/dist/html/XNode.js";
15
+ import Content from "@entity-access/server-pages/dist/Content.js";
13
16
  export default class default_1 extends Page {
14
17
  async run() {
15
18
  const [itemID, currency] = this.childPath;
16
19
  const host = this.request.hostName;
17
20
  const pr = await this.gateway.createPaymentLink({ itemID, currency, host, testMode: this.query.test });
18
- return this.redirect(pr.url);
21
+ return Content.html(XNode.create(HtmlDocument, null,
22
+ XNode.create("head", null,
23
+ XNode.create("title", null, "Creating Payment Request")),
24
+ XNode.create("body", null,
25
+ XNode.create("p", null, "Creating Payment Request ..."),
26
+ XNode.create("script", null,
27
+ "location.href = ",
28
+ JSON.stringify(pr.url),
29
+ ";"))));
19
30
  }
20
31
  }
21
32
  __decorate([
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/wwwroot/routes/pg-i/phone-pe/create/index.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,MAAM,MAAM,4CAA4C,CAAC;AAChE,OAAO,IAAI,MAAM,0CAA0C,CAAC;AAC5D,OAAO,cAAc,MAAM,mEAAmE,CAAC;AAE/F,MAAM,CAAC,OAAO,gBAAO,SAAQ,IAAI;IAK7B,KAAK,CAAC,GAAG;QAEL,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAE,GAAG,IAAI,CAAC,SAAkB,CAAC;QAEpD,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC;QAEnC,MAAM,EAAE,GAAG,MAAM,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;QACvG,OAAO,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC;IACjC,CAAC;CACJ;AAXG;IADC,MAAM;8BACE,cAAc;0CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/wwwroot/routes/pg-i/phone-pe/create/index.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,MAAM,MAAM,4CAA4C,CAAC;AAChE,OAAO,IAAI,MAAM,0CAA0C,CAAC;AAC5D,OAAO,cAAc,MAAM,mEAAmE,CAAC;AAC/F,OAAO,YAAY,MAAM,uDAAuD,CAAC;AACjF,OAAO,KAAK,MAAM,gDAAgD,CAAC;AACnE,OAAO,OAAO,MAAM,6CAA6C,CAAC;AAElE,MAAM,CAAC,OAAO,gBAAO,SAAQ,IAAI;IAK7B,KAAK,CAAC,GAAG;QAEL,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAE,GAAG,IAAI,CAAC,SAAkB,CAAC;QAEpD,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC;QAEnC,MAAM,EAAE,GAAG,MAAM,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;QACvG,OAAO,OAAO,CAAC,IAAI,CAAC,aAAC,YAAY;YAC7B;gBAAM,uDAAuC,CAAO;YACpD;gBACI,uDAEI;gBACJ;;oBACqB,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,GAAG,CAAC;wBAClC,CACN,CACI,CAAC,CAAC;IACrB,CAAC;CACJ;AArBG;IADC,MAAM;8BACE,cAAc;0CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@social-mail/social-mail-web-server",
3
- "version": "1.4.948",
3
+ "version": "1.4.950",
4
4
  "description": "## Phase 1",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -1,6 +1,9 @@
1
1
  import Inject from "@entity-access/entity-access/dist/di/di.js";
2
2
  import Page from "@entity-access/server-pages/dist/Page.js";
3
3
  import PhonePeGateway from "../../../../../server/services/payment-gateways/PhonePeGateway.js";
4
+ import HtmlDocument from "@entity-access/server-pages/dist/html/HtmlDocument.js";
5
+ import XNode from "@entity-access/server-pages/dist/html/XNode.js";
6
+ import Content from "@entity-access/server-pages/dist/Content.js";
4
7
 
5
8
  export default class extends Page {
6
9
 
@@ -14,7 +17,17 @@ export default class extends Page {
14
17
  const host = this.request.hostName;
15
18
 
16
19
  const pr = await this.gateway.createPaymentLink({ itemID, currency, host, testMode: this.query.test });
17
- return this.redirect(pr.url);
20
+ return Content.html(<HtmlDocument>
21
+ <head><title>Creating Payment Request</title></head>
22
+ <body>
23
+ <p>
24
+ Creating Payment Request ...
25
+ </p>
26
+ <script>
27
+ location.href = {JSON.stringify(pr.url)};
28
+ </script>
29
+ </body>
30
+ </HtmlDocument>);
18
31
  }
19
32
  }
20
33