Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • web-et-numerique/factory/pamn_plateforme-des-acteurs-de-la-mediation-numerique/pamn_server
1 result
Show changes
Commits on Source (9)
......@@ -2,6 +2,19 @@
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
### [2.0.3](https://forge.grandlyon.com/web-et-numerique/factory/pamn_plateforme-des-acteurs-de-la-mediation-numerique/pamn_server/compare/v2.0.2...v2.0.3) (2023-01-05)
### Features
* rename conseiller ([a88d8c6](https://forge.grandlyon.com/web-et-numerique/factory/pamn_plateforme-des-acteurs-de-la-mediation-numerique/pamn_server/commit/a88d8c62db9d7613f55824b7060e7d93cd335ac8))
* **structure:** optional contact email ([62222dd](https://forge.grandlyon.com/web-et-numerique/factory/pamn_plateforme-des-acteurs-de-la-mediation-numerique/pamn_server/commit/62222dd183ba41b2af811a83ec24c882d240061f))
### Bug Fixes
* Correctly updates index for employer and job ([02a6a2d](https://forge.grandlyon.com/web-et-numerique/factory/pamn_plateforme-des-acteurs-de-la-mediation-numerique/pamn_server/commit/02a6a2ded056d9c9b82ec7241f06b00415521c47))
### [2.0.2](https://forge.grandlyon.com/web-et-numerique/factory/pamn_plateforme-des-acteurs-de-la-mediation-numerique/pamn_server/compare/v2.0.1...v2.0.2) (2022-12-16)
......
{
"name": "ram_server",
"version": "2.0.2",
"version": "2.0.3",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
......
{
"name": "ram_server",
"private": true,
"version": "2.0.2",
"version": "2.0.3",
"description": "Nest TypeScript starter repository",
"license": "MIT",
"scripts": {
"prebuild": "rimraf dist",
"build": "nest build",
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
"start": "ts-node -r tsconfig-paths/register src/main.ts",
"start:dev": "nodemon",
"start:debug": "nodemon --config nodemon-debug.json",
"start:prod": "npm run migrate:up && node dist/src/main",
"doc": "./node_modules/.bin/compodoc compodoc -p tsconfig.json -s -n 'Resin api documentation'",
"dev": "nodemon",
"doc:serve": "./node_modules/.bin/compodoc compodoc -s",
"doc": "./node_modules/.bin/compodoc compodoc -p tsconfig.json -s -n 'Resin api documentation'",
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
"init-db": "node ./scripts/init-db.js",
"lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix",
"migrate:create": "migrate create --template-file ./src/migrations/migrations-utils/template.ts --migrations-dir=\"./src/migrations/scripts\" --compiler=\"ts:./src/migrations/migrations-utils/ts-compiler.js\"",
"migrate:down": "migrate --migrations-dir=\"./src/migrations/scripts\" --compiler=\"ts:./src/migrations/migrations-utils/ts-compiler.js\" down",
"migrate:up": "migrate --migrations-dir=\"./src/migrations/scripts\" --compiler=\"ts:./src/migrations/migrations-utils/ts-compiler.js\" up",
"prebuild": "rimraf dist",
"start": "ts-node -r tsconfig-paths/register src/main.ts",
"release": "standard-version",
"init-db": "node ./scripts/init-db.js",
"start:debug": "nodemon --config nodemon-debug.json",
"start:dev": "nodemon",
"test": "jest --config ./jest.json --coverage",
"test:watch": "jest --config ./jest.json --watch --coverage",
"start:prod": "npm run migrate:up && node dist/src/main",
"test:cov": "jest --config ./jest.json --coverage --ci --reporters=default --reporters=jest-junit",
"test:debug": "node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand",
"test:e2e": "jest --config ./test/jest-e2e.json",
"migrate:create": "migrate create --template-file ./src/migrations/migrations-utils/template.ts --migrations-dir=\"./src/migrations/scripts\" --compiler=\"ts:./src/migrations/migrations-utils/ts-compiler.js\"",
"migrate:up": "migrate --migrations-dir=\"./src/migrations/scripts\" --compiler=\"ts:./src/migrations/migrations-utils/ts-compiler.js\" up",
"migrate:down": "migrate --migrations-dir=\"./src/migrations/scripts\" --compiler=\"ts:./src/migrations/migrations-utils/ts-compiler.js\" down"
"test:watch": "jest --config ./jest.json --watch --coverage"
},
"dependencies": {
"@elastic/elasticsearch": "~8.5.0",
......
......@@ -4,6 +4,3 @@ Une nouvelle structure a été créée:
<a href="<%= config.protocol %>://<%= config.host %><%= config.port ? ':' + config.port : '' %>/acteurs?id=<%= id %>"
><strong><%= structureName %></strong></a
>
<br />
Il est possible que la structure ne soit pas immédiatement visible sur la carto. L'utilisateur doit valider son compte
pour que celle-ci soit visible.
import { Db } from 'mongodb';
import { getDb } from '../migrations-utils/db';
export const up = async () => {
const db: Db = await getDb();
await db.collection('jobs').updateOne({ name: 'Conseiller' }, { $set: { name: 'Conseiller (Caf, Pôle emploi...)' } });
console.log('Update done: "Conseiller" -> "Conseiller (Caf, Pôle emploi...)"');
};
export const down = async () => {
const db: Db = await getDb();
await db.collection('jobs').updateOne({ name: 'Conseiller (Caf, Pôle emploi...)' }, { $set: { name: 'Conseiller' } });
console.log('Update done: "Conseiller (Caf, Pôle emploi...)" -> "Conseiller');
};
......@@ -28,10 +28,7 @@ export class StructureDto {
address: Address;
contactPhone?: string;
@ApiProperty({ required: true })
@IsNotEmpty()
contactMail: string;
contactMail?: string;
website: string;
facebook: string;
......
......@@ -799,7 +799,10 @@ export class UsersService {
{ _id: userId },
{ $set: { employer: employer._id, job: job._id } }
);
if (updated) this.userRegistrySearchService.update(updated);
if (updated) {
const populatedResult = await this.findPopulatedUserRegistryById(updated._id);
this.userRegistrySearchService.update(populatedResult);
}
return updated;
}
......