@unimaze/billing 0.21.40 → 0.21.42

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.
@@ -30,6 +30,7 @@ var antd_1 = require("antd");
30
30
  var react_intl_1 = require("react-intl");
31
31
  var react_1 = __importStar(require("react"));
32
32
  var SubmitConfirmationSVG_1 = __importDefault(require("./SubmitConfirmationSVG"));
33
+ var icons_1 = require("@ant-design/icons");
33
34
  var translationMessages = (0, react_intl_1.defineMessages)({
34
35
  submitConfirmation_title: {
35
36
  id: "submitConfirmation_title",
@@ -65,20 +66,34 @@ var SubmitConfirmation = function (props) {
65
66
  }
66
67
  }, [form]);
67
68
  var getAttachmentUploadMessage = function (attachmentName) {
68
- return react_1.default.createElement(antd_1.Typography.Title, { level: 5, style: { margin: 5 } }, "".concat(props.intl.formatMessage(translationMessages.submitConfirmation_SuccessfullyUploadedAttachment)).concat(attachmentName));
69
+ return react_1.default.createElement(antd_1.Typography.Text, { style: { margin: 5 } },
70
+ react_1.default.createElement(icons_1.CheckCircleTwoTone, { twoToneColor: "green", style: { marginRight: 5 } }), "".concat(props.intl.formatMessage(translationMessages.submitConfirmation_SuccessfullyUploadedAttachment)).concat(attachmentName));
69
71
  };
70
72
  var getCreatedInvoiceMessage = function () {
71
- return react_1.default.createElement(antd_1.Typography.Title, { level: 5, style: { margin: 5 } }, props.intl.formatMessage(translationMessages.submitConfirmation_successfullyCreatedInvoice));
73
+ return react_1.default.createElement(antd_1.Typography.Text, { style: { margin: 5 } },
74
+ react_1.default.createElement(icons_1.CheckCircleTwoTone, { twoToneColor: "green", style: { marginRight: 5 } }),
75
+ props.intl.formatMessage(translationMessages.submitConfirmation_successfullyCreatedInvoice));
76
+ };
77
+ var cardStyle = {
78
+ width: "auto",
79
+ backgroundColor: "whitesmoke",
80
+ marginTop: 10,
81
+ display: "flex",
82
+ justifyContent: "center"
72
83
  };
73
84
  return (react_1.default.createElement(antd_1.Flex, { justify: "center", style: { padding: "45px" } },
74
85
  react_1.default.createElement(antd_1.Flex, { vertical: true, justify: "center", align: "center", style: { width: "100%", maxWidth: "900px" }, gap: "small" },
75
86
  react_1.default.createElement(SubmitConfirmationSVG_1.default, null),
76
87
  " ",
77
- react_1.default.createElement(antd_1.Progress, { showInfo: false, percent: (numberOfSuccessfulCalls + 1) * percentUnit, success: { percent: numberOfSuccessfulCalls * percentUnit } }),
78
- numberOfSuccessfulCalls >= 1 && getCreatedInvoiceMessage(),
79
- numberOfSuccessfulCalls >= 2 && getAttachmentUploadMessage(attachmentsNames[0]),
80
- numberOfSuccessfulCalls >= 3 && getAttachmentUploadMessage(attachmentsNames[1]),
81
- numberOfSuccessfulCalls >= 4 && getAttachmentUploadMessage(attachmentsNames[2]),
88
+ react_1.default.createElement(antd_1.Flex, { justify: "center", align: "center", style: { width: "100%", maxWidth: "900px" }, gap: "small" },
89
+ react_1.default.createElement(antd_1.Progress, { showInfo: false, percent: (numberOfSuccessfulCalls + 1) * percentUnit, success: { percent: numberOfSuccessfulCalls * percentUnit } }),
90
+ react_1.default.createElement(antd_1.Spin, { size: "small", spinning: totalNumberOfCalls !== numberOfSuccessfulCalls })),
91
+ numberOfSuccessfulCalls >= 1 && react_1.default.createElement(antd_1.Card, { size: "small", style: cardStyle },
92
+ react_1.default.createElement("ul", { style: { listStyleType: 'none', paddingLeft: 0, margin: 0 } },
93
+ react_1.default.createElement("li", null, numberOfSuccessfulCalls >= 1 && getCreatedInvoiceMessage()),
94
+ react_1.default.createElement("li", null, numberOfSuccessfulCalls >= 2 && getAttachmentUploadMessage(attachmentsNames[0])),
95
+ react_1.default.createElement("li", null, numberOfSuccessfulCalls >= 3 && getAttachmentUploadMessage(attachmentsNames[1])),
96
+ react_1.default.createElement("li", null, numberOfSuccessfulCalls >= 4 && getAttachmentUploadMessage(attachmentsNames[2])))),
82
97
  totalNumberOfCalls === numberOfSuccessfulCalls &&
83
98
  react_1.default.createElement(antd_1.Flex, { vertical: true, align: "center", style: { paddingTop: "20px" } },
84
99
  react_1.default.createElement(antd_1.Typography.Title, { level: 2 }, props.intl.formatMessage(translationMessages.submitConfirmation_title)),
@@ -425,7 +425,6 @@ var CreateInvoiceConstructor = function (props) {
425
425
  .then(function (submitInvoiceResponse) {
426
426
  var _a;
427
427
  setNumberOfSuccessfulCalls(numberOfSuccessfulCalls + 1);
428
- antd_1.message.success(intl.formatMessage(exports.translationMessages.createInvoice_successfullySubmittedInvoiceMsg));
429
428
  if (submitInvoiceResponse.status === 201) {
430
429
  var response = submitInvoiceResponse.data;
431
430
  (0, ApiUtility_1.submitAttachmentIfAnyLeft)((_a = response === null || response === void 0 ? void 0 : response.uniqueId) !== null && _a !== void 0 ? _a : "", attachments, props.mapiBaseUrl, token, intl, 1, setNumberOfSuccessfulCalls);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unimaze/billing",
3
- "version": "0.21.40",
3
+ "version": "0.21.42",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",