Skip to content

Commit d5aaa5c

Browse files
committed
deploy: 2bfab9d
1 parent e14ef9a commit d5aaa5c

File tree

11 files changed

+161
-133
lines changed

11 files changed

+161
-133
lines changed

injectables/BackendsService.html

Lines changed: 48 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -353,8 +353,8 @@ <h3 id="methods">
353353

354354
<tr>
355355
<td class="col-md-4">
356-
<div class="io-line">Defined in <a href="" data-line="362"
357-
class="link-to-prism">src/core/backends/backends.service.ts:362</a></div>
356+
<div class="io-line">Defined in <a href="" data-line="390"
357+
class="link-to-prism">src/core/backends/backends.service.ts:390</a></div>
358358
</td>
359359
</tr>
360360

@@ -447,8 +447,8 @@ <h3 id="methods">
447447

448448
<tr>
449449
<td class="col-md-4">
450-
<div class="io-line">Defined in <a href="" data-line="234"
451-
class="link-to-prism">src/core/backends/backends.service.ts:234</a></div>
450+
<div class="io-line">Defined in <a href="" data-line="244"
451+
class="link-to-prism">src/core/backends/backends.service.ts:244</a></div>
452452
</td>
453453
</tr>
454454

@@ -529,8 +529,8 @@ <h3 id="methods">
529529

530530
<tr>
531531
<td class="col-md-4">
532-
<div class="io-line">Defined in <a href="" data-line="277"
533-
class="link-to-prism">src/core/backends/backends.service.ts:277</a></div>
532+
<div class="io-line">Defined in <a href="" data-line="293"
533+
class="link-to-prism">src/core/backends/backends.service.ts:293</a></div>
534534
</td>
535535
</tr>
536536

@@ -611,8 +611,8 @@ <h3 id="methods">
611611

612612
<tr>
613613
<td class="col-md-4">
614-
<div class="io-line">Defined in <a href="" data-line="320"
615-
class="link-to-prism">src/core/backends/backends.service.ts:320</a></div>
614+
<div class="io-line">Defined in <a href="" data-line="342"
615+
class="link-to-prism">src/core/backends/backends.service.ts:342</a></div>
616616
</td>
617617
</tr>
618618

@@ -693,8 +693,8 @@ <h3 id="methods">
693693

694694
<tr>
695695
<td class="col-md-4">
696-
<div class="io-line">Defined in <a href="" data-line="371"
697-
class="link-to-prism">src/core/backends/backends.service.ts:371</a></div>
696+
<div class="io-line">Defined in <a href="" data-line="399"
697+
class="link-to-prism">src/core/backends/backends.service.ts:399</a></div>
698698
</td>
699699
</tr>
700700

@@ -915,8 +915,8 @@ <h3 id="methods">
915915

916916
<tr>
917917
<td class="col-md-4">
918-
<div class="io-line">Defined in <a href="" data-line="191"
919-
class="link-to-prism">src/core/backends/backends.service.ts:191</a></div>
918+
<div class="io-line">Defined in <a href="" data-line="198"
919+
class="link-to-prism">src/core/backends/backends.service.ts:198</a></div>
920920
</td>
921921
</tr>
922922

@@ -1405,10 +1405,10 @@ <h3 id="inputs">
14051405
}
14061406

14071407
public async syncAllIdentities(options?: ExecuteJobOptions): Promise&lt;any&gt; {
1408-
const syncAllIdentities &#x3D; (await this.identitiesService.find&lt;Identities&gt;({
1408+
const syncAllIdentities &#x3D; await this.identitiesService.find&lt;any&gt;({
14091409
state: IdentityState.TO_SYNC,
1410-
})) as unknown as Identities[];
1411-
const identities &#x3D; syncAllIdentities.map((identity: Identities) &#x3D;&gt; {
1410+
});
1411+
const identities &#x3D; syncAllIdentities.map((identity: any) &#x3D;&gt; {
14121412
return {
14131413
action: ActionType.IDENTITY_UPDATE,
14141414
identity,
@@ -1421,6 +1421,13 @@ <h3 id="inputs">
14211421

14221422
const result &#x3D; {};
14231423
for (const identity of identities) {
1424+
//convertion tableau employeeNumber
1425+
if (identity.identity.primaryEmployeeNumber !&#x3D;&#x3D; null) {
1426+
identity.identity.employeeNumber &#x3D; identity.identity.identityprimaryEmployeeNumber;
1427+
} else {
1428+
//on prend la premiere pour envoyer une chaine et non un tableau pour la compatibilité ldap
1429+
identity.identity.inetOrgPerson.employeeNumber &#x3D; identity.identity.inetOrgPerson.employeeNumber[0];
1430+
}
14241431
try {
14251432
this.logger.debug(&#x60;Syncing identity ${identity.identity._id}&#x60;);
14261433
const [executedJob] &#x3D; await this.executeJob(
@@ -1465,6 +1472,9 @@ <h3 id="inputs">
14651472
// cas des fusion l employeeNumber doit etre celui de l identite primaire
14661473
if (identity.primaryEmployeeNumber !&#x3D;&#x3D; null) {
14671474
identity.inetOrgPerson.employeeNumber &#x3D; identity.primaryEmployeeNumber;
1475+
} else {
1476+
//on prend la premiere pour envoyer une chaine et non un tableau pour la compatibilité ldap
1477+
identity.inetOrgPerson.employeeNumber &#x3D; identity.inetOrgPerson.employeeNumber[0];
14681478
}
14691479
identities.push({
14701480
action: ActionType.IDENTITY_UPDATE,
@@ -1497,7 +1507,13 @@ <h3 id="inputs">
14971507
if (!payload.length) throw new BadRequestException(&#x27;No identities to disable&#x27;);
14981508

14991509
for (const key of payload) {
1500-
const identity &#x3D; await this.identitiesService.findById&lt;Identities&gt;(key);
1510+
const identity &#x3D; await this.identitiesService.findById&lt;any&gt;(key);
1511+
if (identity.primaryEmployeeNumber !&#x3D;&#x3D; null) {
1512+
identity.inetOrgPerson.employeeNumber &#x3D; identity.primaryEmployeeNumber;
1513+
} else {
1514+
//on prend la premiere pour envoyer une chaine et non un tableau pour la compatibilité ldap
1515+
identity.inetOrgPerson.employeeNumber &#x3D; identity.inetOrgPerson.employeeNumber[0];
1516+
}
15011517
if (!identity.lastBackendSync) {
15021518
throw new BadRequestException({
15031519
status: HttpStatus.BAD_REQUEST,
@@ -1540,14 +1556,20 @@ <h3 id="inputs">
15401556
if (!payload.length) throw new BadRequestException(&#x27;No identities to disable&#x27;);
15411557

15421558
for (const key of payload) {
1543-
const identity &#x3D; await this.identitiesService.findById&lt;Identities&gt;(key);
1559+
const identity &#x3D; await this.identitiesService.findById&lt;any&gt;(key);
15441560
if (!identity.lastBackendSync) {
15451561
throw new BadRequestException({
15461562
status: HttpStatus.BAD_REQUEST,
15471563
message: &#x60;Identity ${key} has never been synched&#x60;,
15481564
identity,
15491565
});
15501566
}
1567+
if (identity.primaryEmployeeNumber !&#x3D;&#x3D; null) {
1568+
identity.inetOrgPerson.employeeNumber &#x3D; identity.primaryEmployeeNumber;
1569+
} else {
1570+
//on prend la premiere pour envoyer une chaine et non un tableau pour la compatibilité ldap
1571+
identity.inetOrgPerson.employeeNumber &#x3D; identity.inetOrgPerson.employeeNumber[0];
1572+
}
15511573
identities.push({
15521574
action: ActionType.IDENTITY_DISABLE,
15531575
identity,
@@ -1583,7 +1605,13 @@ <h3 id="inputs">
15831605
if (!payload.length) throw new BadRequestException(&#x27;No identities to disable&#x27;);
15841606

15851607
for (const key of payload) {
1586-
const identity &#x3D; await this.identitiesService.findById&lt;Identities&gt;(key);
1608+
const identity &#x3D; await this.identitiesService.findById&lt;any&gt;(key);
1609+
if (identity.primaryEmployeeNumber !&#x3D;&#x3D; null) {
1610+
identity.inetOrgPerson.employeeNumber &#x3D; identity.primaryEmployeeNumber;
1611+
} else {
1612+
//on prend la premiere pour envoyer une chaine et non un tableau pour la compatibilité ldap
1613+
identity.inetOrgPerson.employeeNumber &#x3D; identity.inetOrgPerson.employeeNumber[0];
1614+
}
15871615
if (!identity.lastBackendSync) {
15881616
throw new BadRequestException({
15891617
status: HttpStatus.BAD_REQUEST,
@@ -1619,7 +1647,7 @@ <h3 id="inputs">
16191647
public async activationIdentity(payload: string, status: boolean, options?: ExecuteJobOptions) {
16201648
let result &#x3D; null;
16211649
if (status &#x3D;&#x3D;&#x3D; true) {
1622-
result &#x3D; await this.enableIdentities([payload], options );
1650+
result &#x3D; await this.enableIdentities([payload], options);
16231651
} else {
16241652
result &#x3D; await this.disableIdentities([payload], options);
16251653
}
@@ -1641,7 +1669,7 @@ <h3 id="inputs">
16411669
},
16421670
{
16431671
...options?.job,
1644-
jobId: (new Types.ObjectId() ).toHexString(),
1672+
jobId: (new Types.ObjectId()).toHexString(),
16451673
attempts: 1,
16461674
},
16471675
);

js/search/search_index.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

modules/IdentitiesJsonformsModule.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,14 +117,14 @@
117117
<title>cluster_IdentitiesJsonformsModule</title>
118118
<polygon fill="none" stroke="black" stroke-dasharray="1,5" points="116,-70 116,-268 380,-268 380,-70 116,-70"/>
119119
</g>
120-
<g id="clust6" class="cluster">
121-
<title>cluster_IdentitiesJsonformsModule_providers</title>
122-
<polygon fill="none" stroke="black" points="124,-78 124,-130 372,-130 372,-78 124,-78"/>
123-
</g>
124120
<g id="clust4" class="cluster">
125121
<title>cluster_IdentitiesJsonformsModule_exports</title>
126122
<polygon fill="none" stroke="black" points="154,-208 154,-260 342,-260 342,-208 154,-208"/>
127123
</g>
124+
<g id="clust6" class="cluster">
125+
<title>cluster_IdentitiesJsonformsModule_providers</title>
126+
<polygon fill="none" stroke="black" points="124,-78 124,-130 372,-130 372,-78 124,-78"/>
127+
</g>
128128
<!-- IdentitiesJsonformsService -->
129129
<g id="node1" class="node">
130130
<title>IdentitiesJsonformsService </title>

modules/IdentitiesJsonformsModule/dependencies.svg

Lines changed: 4 additions & 4 deletions
Loading

modules/IdentitiesModule.html

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -117,71 +117,71 @@
117117
<title>cluster_IdentitiesModule</title>
118118
<polygon fill="none" stroke="black" stroke-dasharray="1,5" points="8,-70 8,-268 669,-268 669,-70 8,-70"/>
119119
</g>
120+
<g id="clust3" class="cluster">
121+
<title>cluster_IdentitiesModule_imports</title>
122+
<polygon fill="none" stroke="black" points="523,-78 523,-130 661,-130 661,-78 523,-78"/>
123+
</g>
120124
<g id="clust6" class="cluster">
121125
<title>cluster_IdentitiesModule_providers</title>
122-
<polygon fill="none" stroke="black" points="162,-78 162,-130 661,-130 661,-78 162,-78"/>
126+
<polygon fill="none" stroke="black" points="16,-78 16,-130 515,-130 515,-78 16,-78"/>
123127
</g>
124128
<g id="clust4" class="cluster">
125129
<title>cluster_IdentitiesModule_exports</title>
126-
<polygon fill="none" stroke="black" points="208,-208 208,-260 366,-260 366,-208 208,-208"/>
127-
</g>
128-
<g id="clust3" class="cluster">
129-
<title>cluster_IdentitiesModule_imports</title>
130-
<polygon fill="none" stroke="black" points="16,-78 16,-130 154,-130 154,-78 16,-78"/>
130+
<polygon fill="none" stroke="black" points="312,-208 312,-260 470,-260 470,-208 312,-208"/>
131131
</g>
132132
<!-- FilestorageModule -->
133133
<g id="node1" class="node">
134134
<title>FilestorageModule</title>
135-
<polygon fill="#8dd3c7" stroke="black" points="145.75,-122 142.75,-126 121.75,-126 118.75,-122 24.25,-122 24.25,-86 145.75,-86 145.75,-122"/>
136-
<text text-anchor="middle" x="85" y="-99.8" font-family="Times,serif" font-size="14.00">FilestorageModule</text>
135+
<polygon fill="#8dd3c7" stroke="black" points="652.75,-122 649.75,-126 628.75,-126 625.75,-122 531.25,-122 531.25,-86 652.75,-86 652.75,-122"/>
136+
<text text-anchor="middle" x="592" y="-99.8" font-family="Times,serif" font-size="14.00">FilestorageModule</text>
137137
</g>
138138
<!-- IdentitiesModule -->
139139
<g id="node2" class="node">
140140
<title>IdentitiesModule</title>
141-
<polygon fill="#8dd3c7" stroke="black" points="342.65,-187 339.65,-191 318.65,-191 315.65,-187 231.35,-187 231.35,-151 342.65,-151 342.65,-187"/>
142-
<text text-anchor="middle" x="287" y="-164.8" font-family="Times,serif" font-size="14.00">IdentitiesModule</text>
141+
<polygon fill="#8dd3c7" stroke="black" points="446.65,-187 443.65,-191 422.65,-191 419.65,-187 335.35,-187 335.35,-151 446.65,-151 446.65,-187"/>
142+
<text text-anchor="middle" x="391" y="-164.8" font-family="Times,serif" font-size="14.00">IdentitiesModule</text>
143143
</g>
144144
<!-- FilestorageModule&#45;&gt;IdentitiesModule -->
145145
<g id="edge1" class="edge">
146146
<title>FilestorageModule&#45;&gt;IdentitiesModule</title>
147-
<path fill="none" stroke="black" d="M85,-122.11C85,-141.34 85,-169 85,-169 85,-169 221.27,-169 221.27,-169"/>
148-
<polygon fill="black" stroke="black" points="221.27,-172.5 231.27,-169 221.27,-165.5 221.27,-172.5"/>
147+
<path fill="none" stroke="black" d="M592,-122.11C592,-141.34 592,-169 592,-169 592,-169 456.72,-169 456.72,-169"/>
148+
<polygon fill="black" stroke="black" points="456.72,-165.5 446.72,-169 456.72,-172.5 456.72,-165.5"/>
149149
</g>
150150
<!-- IdentitiesCrudService -->
151151
<g id="node3" class="node">
152152
<title>IdentitiesCrudService </title>
153-
<polygon fill="#fb8072" stroke="black" points="357.57,-252 216.43,-252 216.43,-216 357.57,-216 357.57,-252"/>
154-
<text text-anchor="middle" x="287" y="-229.8" font-family="Times,serif" font-size="14.00">IdentitiesCrudService </text>
153+
<polygon fill="#fb8072" stroke="black" points="461.57,-252 320.43,-252 320.43,-216 461.57,-216 461.57,-252"/>
154+
<text text-anchor="middle" x="391" y="-229.8" font-family="Times,serif" font-size="14.00">IdentitiesCrudService </text>
155155
</g>
156156
<!-- IdentitiesModule&#45;&gt;IdentitiesCrudService -->
157157
<g id="edge2" class="edge">
158158
<title>IdentitiesModule&#45;&gt;IdentitiesCrudService </title>
159-
<path fill="none" stroke="black" stroke-dasharray="5,2" d="M287,-187.11C287,-187.11 287,-205.99 287,-205.99"/>
160-
<polygon fill="black" stroke="black" points="283.5,-205.99 287,-215.99 290.5,-205.99 283.5,-205.99"/>
159+
<path fill="none" stroke="black" stroke-dasharray="5,2" d="M391,-187.11C391,-187.11 391,-205.99 391,-205.99"/>
160+
<polygon fill="black" stroke="black" points="387.5,-205.99 391,-215.99 394.5,-205.99 387.5,-205.99"/>
161161
</g>
162162
<!-- IdentitiesJsonformsService -->
163163
<g id="node4" class="node">
164164
<title>IdentitiesJsonformsService</title>
165-
<ellipse fill="#fdb462" stroke="black" cx="537" cy="-104" rx="115.74" ry="18"/>
166-
<text text-anchor="middle" x="537" y="-99.8" font-family="Times,serif" font-size="14.00">IdentitiesJsonformsService</text>
165+
<ellipse fill="#fdb462" stroke="black" cx="391" cy="-104" rx="115.74" ry="18"/>
166+
<text text-anchor="middle" x="391" y="-99.8" font-family="Times,serif" font-size="14.00">IdentitiesJsonformsService</text>
167167
</g>
168168
<!-- IdentitiesJsonformsService&#45;&gt;IdentitiesModule -->
169169
<g id="edge3" class="edge">
170170
<title>IdentitiesJsonformsService&#45;&gt;IdentitiesModule</title>
171-
<path fill="none" stroke="black" d="M537,-122.11C537,-141.34 537,-169 537,-169 537,-169 352.79,-169 352.79,-169"/>
172-
<polygon fill="black" stroke="black" points="352.79,-165.5 342.79,-169 352.79,-172.5 352.79,-165.5"/>
171+
<path fill="none" stroke="black" d="M391,-122.11C391,-122.11 391,-140.99 391,-140.99"/>
172+
<polygon fill="black" stroke="black" points="387.5,-140.99 391,-150.99 394.5,-140.99 387.5,-140.99"/>
173173
</g>
174174
<!-- IdentitiesValidationService -->
175175
<g id="node5" class="node">
176176
<title>IdentitiesValidationService</title>
177-
<ellipse fill="#fdb462" stroke="black" cx="287" cy="-104" rx="116.88" ry="18"/>
178-
<text text-anchor="middle" x="287" y="-99.8" font-family="Times,serif" font-size="14.00">IdentitiesValidationService</text>
177+
<ellipse fill="#fdb462" stroke="black" cx="141" cy="-104" rx="116.88" ry="18"/>
178+
<text text-anchor="middle" x="141" y="-99.8" font-family="Times,serif" font-size="14.00">IdentitiesValidationService</text>
179179
</g>
180180
<!-- IdentitiesValidationService&#45;&gt;IdentitiesModule -->
181181
<g id="edge4" class="edge">
182182
<title>IdentitiesValidationService&#45;&gt;IdentitiesModule</title>
183-
<path fill="none" stroke="black" d="M287,-122.11C287,-122.11 287,-140.99 287,-140.99"/>
184-
<polygon fill="black" stroke="black" points="283.5,-140.99 287,-150.99 290.5,-140.99 283.5,-140.99"/>
183+
<path fill="none" stroke="black" d="M141,-122.11C141,-141.34 141,-169 141,-169 141,-169 325.21,-169 325.21,-169"/>
184+
<polygon fill="black" stroke="black" points="325.21,-172.5 335.21,-169 325.21,-165.5 325.21,-172.5"/>
185185
</g>
186186
</g>
187187
</svg>

0 commit comments

Comments
 (0)