@redneckz/wildless-cms-uni-blocks 0.14.690 → 0.14.691

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,16 +1,24 @@
1
1
  import { type FormState } from '../ApplicationLeadForm/getInitialFormState';
2
2
  export declare const getDeliveryData: (formData: FormState) => {
3
- courierDeliveryFlg: boolean;
3
+ courierDeliveryFlg: true;
4
4
  deliveryDate: string;
5
5
  deliveryTimeCd: {
6
6
  value: string;
7
7
  };
8
+ } | {
9
+ courierDeliveryFlg?: undefined;
10
+ deliveryDate?: undefined;
11
+ deliveryTimeCd?: undefined;
8
12
  };
9
13
  export declare const getOfficeCode: (formData: FormState) => {
10
14
  office: {
11
15
  id: string;
12
- } | undefined;
16
+ };
17
+ } | {
18
+ office?: undefined;
13
19
  };
14
20
  export declare const getSixthStepData: (formData: FormState) => {
15
21
  participantAddresses: any[];
22
+ } | {
23
+ participantAddresses?: undefined;
16
24
  };
@@ -1,16 +1,24 @@
1
1
  import { type FormState } from '../ApplicationLeadForm/getInitialFormState';
2
2
  export declare const getDeliveryData: (formData: FormState) => {
3
- courierDeliveryFlg: boolean;
3
+ courierDeliveryFlg: true;
4
4
  deliveryDate: string;
5
5
  deliveryTimeCd: {
6
6
  value: string;
7
7
  };
8
+ } | {
9
+ courierDeliveryFlg?: undefined;
10
+ deliveryDate?: undefined;
11
+ deliveryTimeCd?: undefined;
8
12
  };
9
13
  export declare const getOfficeCode: (formData: FormState) => {
10
14
  office: {
11
15
  id: string;
12
- } | undefined;
16
+ };
17
+ } | {
18
+ office?: undefined;
13
19
  };
14
20
  export declare const getSixthStepData: (formData: FormState) => {
15
21
  participantAddresses: any[];
22
+ } | {
23
+ participantAddresses?: undefined;
16
24
  };
@@ -4,25 +4,34 @@ const dateToISO_1 = require("../../utils/dateToISO");
4
4
  const utils_1 = require("../CreditForm/utils");
5
5
  const getDeliveryData = (formData) => {
6
6
  const { methodObtain, deliveryDate = '' } = formData;
7
- return {
8
- courierDeliveryFlg: methodObtain === 'courier',
9
- deliveryDate: (0, dateToISO_1.dateToISO)(deliveryDate),
10
- deliveryTimeCd: { value: 'TIME_2' },
11
- };
7
+ const isCourierDelivery = methodObtain === 'courier';
8
+ return isCourierDelivery
9
+ ? {
10
+ courierDeliveryFlg: isCourierDelivery,
11
+ deliveryDate: (0, dateToISO_1.dateToISO)(deliveryDate),
12
+ deliveryTimeCd: { value: 'TIME_2' },
13
+ }
14
+ : {};
12
15
  };
13
16
  exports.getDeliveryData = getDeliveryData;
14
17
  const getOfficeCode = (formData) => {
15
- const { addressRetail } = formData;
16
- return {
17
- office: addressRetail?.key ? { id: addressRetail.key } : undefined,
18
- };
18
+ const { addressRetail, methodObtain } = formData;
19
+ const isOfficeObtain = addressRetail?.key && methodObtain === 'office';
20
+ return isOfficeObtain
21
+ ? {
22
+ office: { id: addressRetail.key },
23
+ }
24
+ : {};
19
25
  };
20
26
  exports.getOfficeCode = getOfficeCode;
21
27
  const getSixthStepData = (formData) => {
22
- const { addressCourier } = formData;
23
- return {
24
- participantAddresses: (0, utils_1.getParticipantAddresses)({ addressCourier }),
25
- };
28
+ const { addressCourier, methodObtain } = formData;
29
+ const isCourierDelivery = methodObtain === 'courier';
30
+ return isCourierDelivery
31
+ ? {
32
+ participantAddresses: (0, utils_1.getParticipantAddresses)({ addressCourier }),
33
+ }
34
+ : {};
26
35
  };
27
36
  exports.getSixthStepData = getSixthStepData;
28
37
  //# sourceMappingURL=getSixthStepData.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"getSixthStepData.js","sourceRoot":"","sources":["../../../src/components/CreditCardForm/getSixthStepData.ts"],"names":[],"mappings":";;AAAA,qDAAkD;AAElD,+CAA8D;AAEvD,MAAM,eAAe,GAAG,CAAC,QAAmB,EAAE,EAAE;IACrD,MAAM,EAAE,YAAY,EAAE,YAAY,GAAG,EAAE,EAAE,GAAG,QAAQ,CAAC;IAErD,OAAO;QACL,kBAAkB,EAAE,YAAY,KAA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,MAAM,aAAa,GAAG,CAAC,QAAmB,EAAE,EAAE;IACnD,MAAM,EAAE,aAAa,EAAE,YAAY,EAAE,GAAG,QAAQ,CAAC;IAEjD,MAAM,cAAc,GAAG,aAAa,EAAE,GAAG,IAAI,YAAY,KAAK,QAAQ,CAAC;IAEvE,OAAO,cAAc;QACnB,CAAC,CAAC;YACE,MAAM,EAAE,EAAE,EAAE,EAAE,aAAa,CAAC,GAAG,EAAE;SAClC;QACH,CAAC,CAAC,EAAE,CAAC;AACT,CAAC,CAAC;AAVW,QAAA,aAAa,iBAUxB;AAEK,MAAM,gBAAgB,GAAG,CAAC,QAAmB,EAAE,EAAE;IACtD,MAAM,EAAE,cAAc,EAAE,YAAY,EAAE,GAAG,QAAQ,CAAC;IAElD,MAAM,iBAAiB,GAAG,YAAY,KAAK,SAAS,CAAC;IAErD,OAAO,iBAAiB;QACtB,CAAC,CAAC;YACE,oBAAoB,EAAE,IAAA,+BAAuB,EAAC,EAAE,cAAc,EAAE,CAAC;SAClE;QACH,CAAC,CAAC,EAAE,CAAC;AACT,CAAC,CAAC;AAVW,QAAA,gBAAgB,oBAU3B"}
@@ -1,16 +1,24 @@
1
1
  import { type FormState } from '../ApplicationLeadForm/getInitialFormState';
2
2
  export declare const getDeliveryData: (formData: FormState) => {
3
- courierDeliveryFlg: boolean;
3
+ courierDeliveryFlg: true;
4
4
  deliveryDate: string;
5
5
  deliveryTimeCd: {
6
6
  value: string;
7
7
  };
8
+ } | {
9
+ courierDeliveryFlg?: undefined;
10
+ deliveryDate?: undefined;
11
+ deliveryTimeCd?: undefined;
8
12
  };
9
13
  export declare const getOfficeCode: (formData: FormState) => {
10
14
  office: {
11
15
  id: string;
12
- } | undefined;
16
+ };
17
+ } | {
18
+ office?: undefined;
13
19
  };
14
20
  export declare const getSixthStepData: (formData: FormState) => {
15
21
  participantAddresses: any[];
22
+ } | {
23
+ participantAddresses?: undefined;
16
24
  };
@@ -2,22 +2,31 @@ import { dateToISO } from '../../utils/dateToISO.js';
2
2
  import { getParticipantAddresses } from '../CreditForm/utils.js';
3
3
  export const getDeliveryData = (formData) => {
4
4
  const { methodObtain, deliveryDate = '' } = formData;
5
- return {
6
- courierDeliveryFlg: methodObtain === 'courier',
7
- deliveryDate: dateToISO(deliveryDate),
8
- deliveryTimeCd: { value: 'TIME_2' },
9
- };
5
+ const isCourierDelivery = methodObtain === 'courier';
6
+ return isCourierDelivery
7
+ ? {
8
+ courierDeliveryFlg: isCourierDelivery,
9
+ deliveryDate: dateToISO(deliveryDate),
10
+ deliveryTimeCd: { value: 'TIME_2' },
11
+ }
12
+ : {};
10
13
  };
11
14
  export const getOfficeCode = (formData) => {
12
- const { addressRetail } = formData;
13
- return {
14
- office: addressRetail?.key ? { id: addressRetail.key } : undefined,
15
- };
15
+ const { addressRetail, methodObtain } = formData;
16
+ const isOfficeObtain = addressRetail?.key && methodObtain === 'office';
17
+ return isOfficeObtain
18
+ ? {
19
+ office: { id: addressRetail.key },
20
+ }
21
+ : {};
16
22
  };
17
23
  export const getSixthStepData = (formData) => {
18
- const { addressCourier } = formData;
19
- return {
20
- participantAddresses: getParticipantAddresses({ addressCourier }),
21
- };
24
+ const { addressCourier, methodObtain } = formData;
25
+ const isCourierDelivery = methodObtain === 'courier';
26
+ return isCourierDelivery
27
+ ? {
28
+ participantAddresses: getParticipantAddresses({ addressCourier }),
29
+ }
30
+ : {};
22
31
  };
23
32
  //# sourceMappingURL=getSixthStepData.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"getSixthStepData.js","sourceRoot":"","sources":["../../../src/components/CreditCardForm/getSixthStepData.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD,OAAO,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAE9D,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,QAAmB,EAAE,EAAE;IACrD,MAAM,EAAE,YAAY,EAAE,YAAY,GAAG,EAAE,EAAE,GAAG,QAA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EAAE,CAAC;AACT,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,QAAmB,EAAE,EAAE;IACnD,MAAM,EAAE,aAAa,EAAE,YAAY,EAAE,GAAG,QAAQ,CAAC;IAEjD,MAAM,cAAc,GAAG,aAAa,EAAE,GAAG,IAAI,YAAY,KAAK,QAAQ,CAAC;IAEvE,OAAO,cAAc;QACnB,CAAC,CAAC;YACE,MAAM,EAAE,EAAE,EAAE,EAAE,aAAa,CAAC,GAAG,EAAE;SAClC;QACH,CAAC,CAAC,EAAE,CAAC;AACT,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,QAAmB,EAAE,EAAE;IACtD,MAAM,EAAE,cAAc,EAAE,YAAY,EAAE,GAAG,QAAQ,CAAC;IAElD,MAAM,iBAAiB,GAAG,YAAY,KAAK,SAAS,CAAC;IAErD,OAAO,iBAAiB;QACtB,CAAC,CAAC;YACE,oBAAoB,EAAE,uBAAuB,CAAC,EAAE,cAAc,EAAE,CAAC;SAClE;QACH,CAAC,CAAC,EAAE,CAAC;AACT,CAAC,CAAC"}
@@ -6599,23 +6599,32 @@
6599
6599
 
6600
6600
  const getDeliveryData = (formData) => {
6601
6601
  const { methodObtain, deliveryDate = '' } = formData;
6602
- return {
6603
- courierDeliveryFlg: methodObtain === 'courier',
6604
- deliveryDate: dateToISO(deliveryDate),
6605
- deliveryTimeCd: { value: 'TIME_2' },
6606
- };
6602
+ const isCourierDelivery = methodObtain === 'courier';
6603
+ return isCourierDelivery
6604
+ ? {
6605
+ courierDeliveryFlg: isCourierDelivery,
6606
+ deliveryDate: dateToISO(deliveryDate),
6607
+ deliveryTimeCd: { value: 'TIME_2' },
6608
+ }
6609
+ : {};
6607
6610
  };
6608
6611
  const getOfficeCode = (formData) => {
6609
- const { addressRetail } = formData;
6610
- return {
6611
- office: addressRetail?.key ? { id: addressRetail.key } : undefined,
6612
- };
6612
+ const { addressRetail, methodObtain } = formData;
6613
+ const isOfficeObtain = addressRetail?.key && methodObtain === 'office';
6614
+ return isOfficeObtain
6615
+ ? {
6616
+ office: { id: addressRetail.key },
6617
+ }
6618
+ : {};
6613
6619
  };
6614
6620
  const getSixthStepData = (formData) => {
6615
- const { addressCourier } = formData;
6616
- return {
6617
- participantAddresses: getParticipantAddresses({ addressCourier }),
6618
- };
6621
+ const { addressCourier, methodObtain } = formData;
6622
+ const isCourierDelivery = methodObtain === 'courier';
6623
+ return isCourierDelivery
6624
+ ? {
6625
+ participantAddresses: getParticipantAddresses({ addressCourier }),
6626
+ }
6627
+ : {};
6619
6628
  };
6620
6629
 
6621
6630
  const getThirdStepData$1 = (formData) => {
@@ -9977,7 +9986,7 @@
9977
9986
  slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
9978
9987
  });
9979
9988
 
9980
- const packageVersion = "0.14.689";
9989
+ const packageVersion = "0.14.690";
9981
9990
 
9982
9991
  exports.Blocks = Blocks;
9983
9992
  exports.ContentPage = ContentPage;