Commit 9500e911 authored by EL HAJJIOUI Nabil's avatar EL HAJJIOUI Nabil
Browse files

Rename API Supervision to Logbook Operation

parent 75c791e2
......@@ -326,13 +326,13 @@ public class ServicesData {
public static final String ROLE_GET_ARCHIVE_PROFILES = ROLE_PREFIX + "GET_ARCHIVE_PROFILES";
//------------------------------------ API SUPERVISION -----------------------------------------
//------------------------------------ API LOGBOOK OPERATION -----------------------------------------
public static final String SERVICE_API_SUPERVISION_ROLE = "SUPERVISION_API";
public static final String SERVICE_API_LOGBOOK_OPERATION_ROLE = "LOGBOOK_OPERATION_API";
public static final String ROLE_CREATE_SUPERVISION_ROLE = CREATE_ROLE_PREFIX + SERVICE_API_SUPERVISION_ROLE;
public static final String ROLE_GET_SUPERVISION_ROLE = GET_ROLE_PREFIX + SERVICE_API_SUPERVISION_ROLE;
public static final String ROLE_GET_ALL_SUPERVISION_ROLE = GET_ROLE_PREFIX + "ALL_" + SERVICE_API_SUPERVISION_ROLE;
public static final String ROLE_CREATE_LOGBOOK_OPERATION_ROLE = CREATE_ROLE_PREFIX + SERVICE_API_LOGBOOK_OPERATION_ROLE;
public static final String ROLE_GET_LOGBOOK_OPERATION_ROLE = GET_ROLE_PREFIX + SERVICE_API_LOGBOOK_OPERATION_ROLE;
public static final String ROLE_GET_ALL_LOGBOOK_OPERATION_ROLE = GET_ROLE_PREFIX + "ALL_" + SERVICE_API_LOGBOOK_OPERATION_ROLE;
//@formatter:off
......@@ -414,9 +414,9 @@ public class ServicesData {
ROLE_GET_OPERATIONS,
ROLE_RUN_PROBATIVE_VALUE,
ROLE_CREATE_SUPERVISION_ROLE,
ROLE_GET_SUPERVISION_ROLE,
ROLE_GET_ALL_SUPERVISION_ROLE
ROLE_CREATE_LOGBOOK_OPERATION_ROLE,
ROLE_GET_LOGBOOK_OPERATION_ROLE,
ROLE_GET_ALL_LOGBOOK_OPERATION_ROLE
);
......@@ -521,9 +521,9 @@ public class ServicesData {
ROLE_RUN_AUDITS,
ROLE_RUN_PROBATIVE_VALUE,
ROLE_CREATE_SUPERVISION_ROLE,
ROLE_GET_SUPERVISION_ROLE,
ROLE_GET_ALL_SUPERVISION_ROLE
ROLE_CREATE_LOGBOOK_OPERATION_ROLE,
ROLE_GET_LOGBOOK_OPERATION_ROLE,
ROLE_GET_ALL_LOGBOOK_OPERATION_ROLE
);
//@formatter:on
......
......@@ -200,7 +200,7 @@ db.groups.insert({
"system_secure",
"system_dsl",
"system_probative_value",
"system_supervision_api_profile"
"system_logbook_operation_profile"
],
"readonly": false,
"level": "",
......
......@@ -408,25 +408,25 @@ db.profiles.insert({
});
db.profiles.insert({
"_id": "system_supervision_api_profile",
"_id": "system_logbook_operation_profile",
"identifier" : NumberInt(maxIdProfile++),
"name": "Supervision API Profile",
"description": "Supervision Profile api",
"name": "Journal des Opérations",
"description": "Logbook Operation Profile api",
"tenantIdentifier": NumberInt({{ vitamui_platform_informations.proof_tenant }}),
"applicationName": "SUPERVISION_API_APP",
"applicationName": "LOGBOOK_OPERATION_APP",
"level": "",
"enabled": true,
"readonly": false,
"customerId": "system_customer",
"roles": [
{
"name": "ROLE_CREATE_SUPERVISION_API"
"name": "ROLE_CREATE_LOGBOOK_OPERATION_API"
},
{
"name": "ROLE_GET_SUPERVISION_API"
"name": "ROLE_GET_LOGBOOK_OPERATION_API"
},
{
"name": "ROLE_GET_ALL_SUPERVISION_API"
"name": "ROLE_GET_ALL_LOGBOOK_OPERATION_API"
},
{
"name": "ROLE_LOGBOOKS"
......@@ -464,7 +464,7 @@ db.groups.updateOne( {
"system_secure",
"system_dsl",
"system_probative_value",
"system_supervision_api_profile"
"system_logbook_operation_profile"
]
}
}
......
......@@ -203,14 +203,14 @@ db.applications.insert({
});
db.applications.insert({
"identifier" : "SUPERVISION_API_APP",
"identifier" : "LOGBOOK_OPERATION_APP",
{% if vitamui.referential.base_url is defined %}
"url": "{{ vitamui.referential.base_url }}/supervision-api",
"url": "{{ vitamui.referential.base_url }}/logbook-operation",
{% else %}
"url": "{{ url_prefix }}/referential/supervision-api",
"url": "{{ url_prefix }}/referential/logbook-operation",
{% endif %}
"icon": "vitamui-icon vitamui-icon-api-supervision",
"name": "Supervision des APIs",
"name": "Journal des Opérations",
"category": "referential",
"position": NumberInt(16),
"hasCustomerList": false,
......
......@@ -25,7 +25,7 @@ db.contexts.insert({
"ROLE_GET_CONTEXTS", "ROLE_UPDATE_CONTEXTS", "ROLE_CREATE_CONTEXTS",
"ROLE_GET_SECURITY_PROFILES", "ROLE_UPDATE_SECURITY_PROFILES", "ROLE_CREATE_SECURITY_PROFILES", "ROLE_DELETE_SECURITY_PROFILES",
"ROLE_GET_OPERATIONS", "ROLE_RUN_AUDITS", "ROLE_RUN_PROBATIVE_VALUE",
"ROLE_CREATE_SUPERVISION_API", "ROLE_GET_SUPERVISION_API", "ROLE_GET_ALL_SUPERVISION_API", "ROLE_LOGBOOKS"
"ROLE_CREATE_LOGBOOK_OPERATION_API", "ROLE_GET_LOGBOOK_OPERATION_API", "ROLE_GET_ALL_LOGBOOK_OPERATION_API", "ROLE_LOGBOOKS"
]
});
......
......@@ -111,13 +111,13 @@ const routes: Routes = [
data: {appId: 'PROBATIVE_VALUE_APP'}
},
// =====================================================
// SUPERVISION API
// LOGBOOK OPERATION API
// =====================================================
{
path: 'supervision-api',
loadChildren: () => import('./supervision-api/api-supervision.module').then(m => m.ApiSupervisionModule),
path: 'logbook-operation',
loadChildren: () => import('./logbook-operation/logbook-operation.module').then(m => m.LogbookOperationModule),
canActivate: [AuthGuard, AppGuard],
data: { appId: 'SUPERVISION_API_APP' }
data: { appId: 'LOGBOOK_OPERATION_APP' }
},
// =====================================================
// DSL
......
......@@ -8,7 +8,7 @@
<div class="header-container">
<div class="title">
<div class="status-badge-mini" [ngClass]="event | eventTypeBadgeClass">
<i class="vitamui-icon vitamui-icon-box-hand no-margin"></i>
<i class="vitamui-icon vitamui-icon-api-supervision vitamui-row-icon status-badge"></i>
</div>
<h2>{{ event?.id }}</h2>
</div>
......
......@@ -40,17 +40,17 @@ import { NO_ERRORS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { ActivatedRoute } from '@angular/router';
import { EventTypeBadgeClassPipe } from '../api-supervision-list/event-type-badge-class.pipe';
import { LastEventPipe } from '../api-supervision-list/last-event.pipe';
import { ApiSupervisionDetailComponent } from './api-supervision-detail.component';
import { EventTypeBadgeClassPipe } from '../logbook-operation-list/event-type-badge-class.pipe';
import { LastEventPipe } from '../logbook-operation-list/last-event.pipe';
import { LogbookOperationDetailComponent } from './logbook-operation-detail.component';
describe('ApiSupervisionDetailComponent', () => {
let component: ApiSupervisionDetailComponent;
let fixture: ComponentFixture<ApiSupervisionDetailComponent>;
describe('LogbookOperationDetailComponent', () => {
let component: LogbookOperationDetailComponent;
let fixture: ComponentFixture<LogbookOperationDetailComponent>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ ApiSupervisionDetailComponent, EventTypeBadgeClassPipe, LastEventPipe ],
declarations: [LogbookOperationDetailComponent, EventTypeBadgeClassPipe, LastEventPipe ],
providers: [
{ provide: LogbookService, useValue: {} },
{ provide: AuthService, useValue: {} },
......@@ -62,7 +62,7 @@ describe('ApiSupervisionDetailComponent', () => {
}));
beforeEach(() => {
fixture = TestBed.createComponent(ApiSupervisionDetailComponent);
fixture = TestBed.createComponent(LogbookOperationDetailComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
......
......@@ -34,16 +34,16 @@
* The fact that you are presently reading this means that you have had
* knowledge of the CeCILL-C license and that you accept its terms.
*/
import { animate, style, transition, trigger } from '@angular/animations';
import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { trigger, style, transition, animate } from '@angular/animations';
import { AuthService, Event, LogbookService } from 'ui-frontend-common';
@Component({
selector: 'app-api-supervision-detail',
templateUrl: './api-supervision-detail.component.html',
styleUrls: ['./api-supervision-detail.component.scss'],
selector: 'app-logbook-operation-detail',
templateUrl: './logbook-operation-detail.component.html',
styleUrls: ['./logbook-operation-detail.component.scss'],
animations: [
trigger('fadeInOut', [
transition(':enter', [
......@@ -57,7 +57,7 @@ import { AuthService, Event, LogbookService } from 'ui-frontend-common';
])
]
})
export class ApiSupervisionDetailComponent implements OnInit, OnChanges {
export class LogbookOperationDetailComponent implements OnInit, OnChanges {
@Input() eventId: string;
......@@ -82,7 +82,7 @@ export class ApiSupervisionDetailComponent implements OnInit, OnChanges {
}
openPopup() {
window.open('/api-supervision/tenant/' + this.tenantIdentifier + '/event/' + this.event.id,
window.open('/logbook-operation/tenant/' + this.tenantIdentifier + '/event/' + this.event.id,
'detailPopup', 'width=584, height=713, resizable=no, location=no');
this.emitClose();
}
......
......@@ -38,17 +38,17 @@ import { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
@Component({
selector: 'app-api-supervision-popup',
selector: 'app-logbook-operation-popup',
template: `
<app-api-supervision-detail
<app-logbook-operation-detail
(closePanel)="closePopup()"
[eventId]="eventId"
[tenantIdentifier]="tenantIdentifier"
[isPopup]="true"
></app-api-supervision-detail>
></app-logbook-operation-detail>
`
})
export class ApiSupervisionPopupComponent implements OnInit {
export class LogbookOperationPopupComponent implements OnInit {
eventId: string;
tenantIdentifier: number;
......
......@@ -48,7 +48,7 @@
<td style="width:60px;" class="no-first-cell-padding">
<div class="vitamui-cell-icon aligned">
<div class="status-badge" [ngClass]="event | eventTypeBadgeClass">
<i class="vitamui-icon vitamui-icon-ingest vitamui-row-icon status-badge"></i>
<i class="vitamui-icon vitamui-icon-api-supervision vitamui-row-icon status-badge"></i>
</div>
</div>
</td>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment