File tree 7 files changed +11
-11
lines changed
pages/workspace/accounting/nsqs
7 files changed +11
-11
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ function NSQSAdvancedPage({policy}: WithPolicyProps) {
22
22
const styles = useThemeStyles ( ) ;
23
23
const policyID = policy ?. id ;
24
24
const nsqsConfig = policy ?. connections ?. netsuiteQuickStart ?. config ;
25
- const isAutoSyncEnabled = nsqsConfig ?. autoSync . enabled ?? false ;
25
+ const isAutoSyncEnabled = nsqsConfig ?. autoSync ? .enabled ?? false ;
26
26
const approvalAccount = nsqsConfig ?. approvalAccount ?? '' ;
27
27
const nsqsData = policy ?. connections ?. netsuiteQuickStart ?. data ;
28
28
const payableAccounts : NSQSPayableAccount [ ] = useMemo ( ( ) => nsqsData ?. payableAccounts ?? [ ] , [ nsqsData ?. payableAccounts ] ) ;
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ function NSQSCustomersDisplayedAsPage({policy}: WithPolicyProps) {
23
23
const styles = useThemeStyles ( ) ;
24
24
const policyID = policy ?. id ;
25
25
const nsqsConfig = policy ?. connections ?. netsuiteQuickStart ?. config ;
26
- const importType = nsqsConfig ?. syncOptions . mapping . customers ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
26
+ const importType = nsqsConfig ?. syncOptions ? .mapping ? .customers ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
27
27
28
28
const sectionData : Array < SelectorType < Option > > = Options . map ( ( option ) => ( {
29
29
keyForList : option ,
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ function NSQSCustomersPage({policy}: WithPolicyProps) {
23
23
const styles = useThemeStyles ( ) ;
24
24
const policyID = policy ?. id ;
25
25
const nsqsConfig = policy ?. connections ?. netsuiteQuickStart ?. config ;
26
- const importType = nsqsConfig ?. syncOptions . mapping . customers ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
26
+ const importType = nsqsConfig ?. syncOptions ? .mapping ? .customers ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
27
27
const isImportEnabled = importType !== CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
28
28
29
29
const toggleImport = useCallback ( ( ) => {
Original file line number Diff line number Diff line change @@ -19,8 +19,8 @@ function NSQSImportPage({policy}: WithPolicyProps) {
19
19
const styles = useThemeStyles ( ) ;
20
20
const policyID = policy ?. id ;
21
21
const nsqsConfig = policy ?. connections ?. netsuiteQuickStart ?. config ;
22
- const customersImportType = nsqsConfig ?. syncOptions . mapping . customers ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
23
- const projectsImportType = nsqsConfig ?. syncOptions . mapping . projects ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
22
+ const customersImportType = nsqsConfig ?. syncOptions ? .mapping ? .customers ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
23
+ const projectsImportType = nsqsConfig ?. syncOptions ? .mapping ? .projects ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
24
24
25
25
return (
26
26
< ConnectionLayout
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ function NSQSProjectsDisplayedAsPage({policy}: WithPolicyProps) {
23
23
const styles = useThemeStyles ( ) ;
24
24
const policyID = policy ?. id ;
25
25
const nsqsConfig = policy ?. connections ?. netsuiteQuickStart ?. config ;
26
- const importType = nsqsConfig ?. syncOptions . mapping . projects ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
26
+ const importType = nsqsConfig ?. syncOptions ? .mapping ? .projects ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
27
27
28
28
const sectionData : Array < SelectorType < Option > > = Options . map ( ( option ) => ( {
29
29
keyForList : option ,
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ function NSQSProjectsPage({policy}: WithPolicyProps) {
23
23
const styles = useThemeStyles ( ) ;
24
24
const policyID = policy ?. id ;
25
25
const nsqsConfig = policy ?. connections ?. netsuiteQuickStart ?. config ;
26
- const importType = nsqsConfig ?. syncOptions . mapping . projects ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
26
+ const importType = nsqsConfig ?. syncOptions ? .mapping ? .projects ?? CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
27
27
const isImportEnabled = importType !== CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES . NETSUITE_DEFAULT ;
28
28
29
29
const toggleImport = useCallback ( ( ) => {
Original file line number Diff line number Diff line change @@ -1105,7 +1105,7 @@ type NSQSConnectionData = {
1105
1105
*/
1106
1106
type NSQSConnectionConfig = OnyxCommon . OnyxValueWithOfflineFeedback < {
1107
1107
/** Configuration of automatic synchronization from NSQS to the app */
1108
- autoSync : {
1108
+ autoSync ? : {
1109
1109
/** Job ID of the synchronization */
1110
1110
jobID : string ;
1111
1111
@@ -1114,9 +1114,9 @@ type NSQSConnectionConfig = OnyxCommon.OnyxValueWithOfflineFeedback<{
1114
1114
} ;
1115
1115
1116
1116
/** Configuration options pertaining to sync */
1117
- syncOptions : {
1117
+ syncOptions ? : {
1118
1118
/** Configuration of import settings from NSQS to Expensify */
1119
- mapping : {
1119
+ mapping ? : {
1120
1120
/** How NSQS customers are displayed as */
1121
1121
customers : ValueOf < typeof CONST . NSQS_INTEGRATION_ENTITY_MAP_TYPES > ;
1122
1122
@@ -1136,7 +1136,7 @@ type NSQSConnectionConfig = OnyxCommon.OnyxValueWithOfflineFeedback<{
1136
1136
1137
1137
/** NSQS credentials */
1138
1138
credentials : {
1139
- /** Encrypted token for NSQS authentification */
1139
+ /** Encrypted token for NSQS authentication */
1140
1140
accessToken : string ;
1141
1141
1142
1142
/** The company ID */
You can’t perform that action at this time.
0 commit comments