Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
CiviCRM
Connecteur API Education Nationale France
Commits
15b2eaf9
Commit
15b2eaf9
authored
1 year ago
by
FoucherAurelie
Browse files
Options
Download
Email Patches
Plain Diff
add count for updated
parent
4b68d1b9
3 merge requests
!74
add count for updated
,
!64
v1.6
,
!63
v1.6 - beta 1
Pipeline
#30377
passed with stages
in 14 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
api/v3/EducationNationale.php
+14
-1
api/v3/EducationNationale.php
assets/manage.js
+1
-0
assets/manage.js
templates/CRM/APIEducationNationale/js_vars.tpl
+1
-0
templates/CRM/APIEducationNationale/js_vars.tpl
with
16 additions
and
1 deletion
+16
-1
api/v3/EducationNationale.php
+
14
-
1
View file @
15b2eaf9
...
...
@@ -200,10 +200,23 @@ function civicrm_api3_education_nationale_populate($params) {
'external_identifier'
=>
$external_identifier
,
];
$contact
=
$existing_contacts_identifiers
[
$legacy_external_identifier
];
civicrm_api4
(
'Contact'
,
'update'
,
[
'values'
=>
[
$civi_update
=
civicrm_api4
(
'Contact'
,
'update'
,
[
'values'
=>
[
'id'
=>
$contact
[
'id'
],
'external_identifier'
=>
$external_identifier
,
]]);
if
(
$civi_update
[
'is_error'
]
==
1
)
{
$EducationalInstitutions
[]
=
[
'status'
=>
'error'
,
'id'
=>
$contact
[
'id'
],
'external_identifier'
=>
$external_identifier
,
];
}
else
{
$EducationalInstitutions
[]
=
[
'status'
=>
'updated'
,
'id'
=>
$contact
[
'id'
],
'external_identifier'
=>
$external_identifier
,
];
}
continue
;
}
}
...
...
This diff is collapsed.
Click to expand it.
assets/manage.js
+
1
-
0
View file @
15b2eaf9
...
...
@@ -72,6 +72,7 @@ try {
.
addClass
(
'
crm-flex-box
'
)
.
append
(
'
<div>
'
+
education_nationale
.
i18n
.
imported_rows
.
replace
(
'
%s
'
,
counts
[
'
create
'
])
+
'
</div>
'
)
.
append
(
counts
[
'
exists
'
]
?
'
<div class="has-exists">
'
+
education_nationale
.
i18n
.
existing_rows
.
replace
(
'
%s
'
,
counts
[
'
exists
'
])
+
'
</div>
'
:
'
<div>
'
)
.
append
(
counts
[
'
updated
'
]
?
'
<div class="has-updated">
'
+
education_nationale
.
i18n
.
updated_rows
.
replace
(
'
%s
'
,
counts
[
'
updated
'
])
+
'
</div>
'
:
'
<div>
'
)
.
append
(
counts
[
'
error
'
]
?
'
<div class="has-errors">
'
+
education_nationale
.
i18n
.
error_rows
.
replace
(
'
%s
'
,
counts
[
'
error
'
])
+
'
</div>
'
:
'
<div>
'
)
.
append
(
errors
.
length
?
CRM
.
$
(
'
<details class="list-errors">
'
).
append
(
'
<summary>Errors</summary>
'
).
append
(
errors
)
:
'
<div>
'
)
;
...
...
This diff is collapsed.
Click to expand it.
templates/CRM/APIEducationNationale/js_vars.tpl
+
1
-
0
View file @
15b2eaf9
...
...
@@ -4,6 +4,7 @@ var education_nationale = education_nationale||{};
education_nationale
.
i18n
=
{
error_rows
:
"
{/
literal
}{
ts
domain
=
'connecteur_api_education_nationale_france'
}
%s rows in error
{/
ts
}{
literal
}
"
,
existing_rows
:
"
{/
literal
}{
ts
domain
=
'connecteur_api_education_nationale_france'
}
%s rows already exisiting
{/
ts
}{
literal
}
"
,
updated_rows
:
"
{/
literal
}{
ts
domain
=
'connecteur_api_education_nationale_france'
}
%s rows updated
{/
ts
}{
literal
}
"
,
imported_rows
:
"
{/
literal
}{
ts
domain
=
'connecteur_api_education_nationale_france'
}
%s rows imported
{/
ts
}{
literal
}
"
,
search_by_name
:
"
{/
literal
}{
ts
domain
=
'connecteur_api_education_nationale_france'
}
Search institution. Example : Picasso 93
{/
ts
}{
literal
}
"
};
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets