mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-06-30 18:15:11 +00:00
Upgrade ng2-alfresco-webscript
This commit is contained in:
parent
f592c71a7a
commit
815bd31ef5
@ -28,6 +28,7 @@ import { DataTableModule } from 'ng2-alfresco-datatable';
|
|||||||
import { DocumentListModule } from 'ng2-alfresco-documentlist';
|
import { DocumentListModule } from 'ng2-alfresco-documentlist';
|
||||||
import { UploadModule } from 'ng2-alfresco-upload';
|
import { UploadModule } from 'ng2-alfresco-upload';
|
||||||
import { TagModule } from 'ng2-alfresco-tag';
|
import { TagModule } from 'ng2-alfresco-tag';
|
||||||
|
import { WebScriptModule } from 'ng2-alfresco-webscript';
|
||||||
|
|
||||||
import { AppComponent } from './app.component';
|
import { AppComponent } from './app.component';
|
||||||
import { routing } from './app.routes';
|
import { routing } from './app.routes';
|
||||||
@ -36,7 +37,6 @@ import { ALFRESCO_TASKLIST_DIRECTIVES } from 'ng2-activiti-tasklist';
|
|||||||
import { ACTIVITI_PROCESSLIST_DIRECTIVES } from 'ng2-activiti-processlist';
|
import { ACTIVITI_PROCESSLIST_DIRECTIVES } from 'ng2-activiti-processlist';
|
||||||
import { ActivitiForm, ATIVITI_FORM_PROVIDERS } from 'ng2-activiti-form';
|
import { ActivitiForm, ATIVITI_FORM_PROVIDERS } from 'ng2-activiti-form';
|
||||||
import { VIEWERCOMPONENT } from 'ng2-alfresco-viewer';
|
import { VIEWERCOMPONENT } from 'ng2-alfresco-viewer';
|
||||||
import { WEBSCRIPTCOMPONENT } from 'ng2-alfresco-webscript';
|
|
||||||
|
|
||||||
import { AlfrescoTranslationLoader } from 'ng2-alfresco-core';
|
import { AlfrescoTranslationLoader } from 'ng2-alfresco-core';
|
||||||
import { Http } from '@angular/http';
|
import { Http } from '@angular/http';
|
||||||
@ -113,7 +113,8 @@ const ACTIVITI_FORM_DIRECTIVES: any[] = [
|
|||||||
DataTableModule,
|
DataTableModule,
|
||||||
DocumentListModule.forRoot(),
|
DocumentListModule.forRoot(),
|
||||||
UploadModule.forRoot(),
|
UploadModule.forRoot(),
|
||||||
TagModule.forRoot()
|
TagModule.forRoot(),
|
||||||
|
WebScriptModule
|
||||||
],
|
],
|
||||||
declarations: [
|
declarations: [
|
||||||
AppComponent,
|
AppComponent,
|
||||||
@ -122,7 +123,6 @@ const ACTIVITI_FORM_DIRECTIVES: any[] = [
|
|||||||
...ACTIVITI_PROCESSLIST_DIRECTIVES,
|
...ACTIVITI_PROCESSLIST_DIRECTIVES,
|
||||||
...ACTIVITI_FORM_DIRECTIVES,
|
...ACTIVITI_FORM_DIRECTIVES,
|
||||||
...VIEWERCOMPONENT,
|
...VIEWERCOMPONENT,
|
||||||
...WEBSCRIPTCOMPONENT,
|
|
||||||
|
|
||||||
DataTableDemoComponent,
|
DataTableDemoComponent,
|
||||||
SearchComponent,
|
SearchComponent,
|
||||||
|
@ -15,6 +15,15 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
import { NgModule } from '@angular/core';
|
||||||
|
import { HttpModule } from '@angular/http';
|
||||||
|
import { FormsModule } from '@angular/forms';
|
||||||
|
import { CommonModule } from '@angular/common';
|
||||||
|
import { TranslateModule } from 'ng2-translate/ng2-translate';
|
||||||
|
|
||||||
|
import { DataTableModule } from 'ng2-alfresco-datatable';
|
||||||
|
import { CoreModule } from 'ng2-alfresco-core';
|
||||||
|
|
||||||
import { WebscriptComponent } from './src/webscript.component';
|
import { WebscriptComponent } from './src/webscript.component';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -23,10 +32,26 @@ import { WebscriptComponent } from './src/webscript.component';
|
|||||||
|
|
||||||
export * from './src/webscript.component';
|
export * from './src/webscript.component';
|
||||||
|
|
||||||
export default {
|
export const WEBSCRIPT_DIRECTIVES: any[] = [
|
||||||
components: [WebscriptComponent]
|
|
||||||
};
|
|
||||||
|
|
||||||
export const WEBSCRIPTCOMPONENT: [any] = [
|
|
||||||
WebscriptComponent
|
WebscriptComponent
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@NgModule({
|
||||||
|
imports: [
|
||||||
|
CommonModule,
|
||||||
|
FormsModule,
|
||||||
|
HttpModule,
|
||||||
|
TranslateModule,
|
||||||
|
CoreModule,
|
||||||
|
DataTableModule
|
||||||
|
],
|
||||||
|
declarations: [
|
||||||
|
...WEBSCRIPT_DIRECTIVES
|
||||||
|
],
|
||||||
|
providers: [
|
||||||
|
],
|
||||||
|
exports: [
|
||||||
|
...WEBSCRIPT_DIRECTIVES
|
||||||
|
]
|
||||||
|
})
|
||||||
|
export class WebScriptModule {}
|
||||||
|
@ -31,25 +31,25 @@
|
|||||||
"url": "https://github.com/Alfresco/alfresco-ng2-components/issues"
|
"url": "https://github.com/Alfresco/alfresco-ng2-components/issues"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@angular/common": "2.0.0-rc.3",
|
"@angular/common": "2.0.0",
|
||||||
"@angular/compiler": "2.0.0-rc.3",
|
"@angular/compiler": "2.0.0",
|
||||||
"@angular/core": "2.0.0-rc.3",
|
"@angular/core": "2.0.0",
|
||||||
"@angular/http": "2.0.0-rc.3",
|
"@angular/forms": "2.0.0",
|
||||||
"@angular/platform-browser": "2.0.0-rc.3",
|
"@angular/http": "2.0.0",
|
||||||
"@angular/platform-browser-dynamic": "2.0.0-rc.3",
|
"@angular/platform-browser": "2.0.0",
|
||||||
"@angular/router": "3.0.0-alpha.7",
|
"@angular/platform-browser-dynamic": "2.0.0",
|
||||||
"@angular/router-deprecated": "2.0.0-rc.2",
|
"@angular/router": "3.0.0",
|
||||||
"@angular/upgrade": "2.0.0-rc.3",
|
"@angular/upgrade": "2.0.0",
|
||||||
"systemjs": "0.19.27",
|
"core-js": "^2.4.1",
|
||||||
"core-js": "^2.4.0",
|
|
||||||
"alfresco-js-api": "^0.3.0",
|
|
||||||
|
|
||||||
"ng2-translate": "2.2.2",
|
|
||||||
"ng2-alfresco-core": "0.3.2",
|
|
||||||
"ng2-alfresco-datatable": "0.3.2",
|
|
||||||
"reflect-metadata": "^0.1.3",
|
"reflect-metadata": "^0.1.3",
|
||||||
"rxjs": "5.0.0-beta.6",
|
"rxjs": "5.0.0-beta.12",
|
||||||
"zone.js": "^0.6.12"
|
"systemjs": "0.19.27",
|
||||||
|
"zone.js": "^0.6.23",
|
||||||
|
|
||||||
|
"alfresco-js-api": "^0.3.0",
|
||||||
|
"ng2-translate": "2.5.0",
|
||||||
|
"ng2-alfresco-core": "0.3.2",
|
||||||
|
"ng2-alfresco-datatable": "0.3.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/core-js": "^0.9.32",
|
"@types/core-js": "^0.9.32",
|
||||||
|
@ -15,6 +15,7 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
import { PLATFORM_PIPES } from '@angular/core';
|
import { PLATFORM_PIPES } from '@angular/core';
|
||||||
import { describe, expect, it, inject, beforeEachProviders, beforeEach, afterEach, xit } from '@angular/core/testing';
|
import { describe, expect, it, inject, beforeEachProviders, beforeEach, afterEach, xit } from '@angular/core/testing';
|
||||||
import { TestComponentBuilder } from '@angular/compiler/testing';
|
import { TestComponentBuilder } from '@angular/compiler/testing';
|
||||||
@ -212,3 +213,4 @@ describe('Test ng2-alfresco-webscript', () => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
*/
|
||||||
|
@ -16,15 +16,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
import { Component, Input, Output, EventEmitter } from '@angular/core';
|
import { Component, Input, Output, EventEmitter } from '@angular/core';
|
||||||
import {
|
import { AlfrescoAuthenticationService } from 'ng2-alfresco-core';
|
||||||
AlfrescoAuthenticationService,
|
import { ObjectDataTableAdapter } from 'ng2-alfresco-datatable';
|
||||||
CONTEXT_MENU_DIRECTIVES,
|
|
||||||
CONTEXT_MENU_PROVIDERS
|
|
||||||
} from 'ng2-alfresco-core';
|
|
||||||
import {
|
|
||||||
ALFRESCO_DATATABLE_DIRECTIVES,
|
|
||||||
ObjectDataTableAdapter
|
|
||||||
} from 'ng2-alfresco-datatable';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <alfresco-webscript-get [scriptPath]="string"
|
* <alfresco-webscript-get [scriptPath]="string"
|
||||||
@ -57,9 +50,7 @@ import {
|
|||||||
<div *ngIf="contentType === 'TEXT'" id="webscript-data-TEXT" >{{data}}</div>
|
<div *ngIf="contentType === 'TEXT'" id="webscript-data-TEXT" >{{data}}</div>
|
||||||
<div *ngIf="isDataTableContent()" ><alfresco-datatable id="webscript-datatable-wrapper" [data]="data" ></alfresco-datatable><div>
|
<div *ngIf="isDataTableContent()" ><alfresco-datatable id="webscript-datatable-wrapper" [data]="data" ></alfresco-datatable><div>
|
||||||
<div *ngIf="showError" id="error">Error during the deserialization of {{data}} as {{contentType}}</div>
|
<div *ngIf="showError" id="error">Error during the deserialization of {{data}} as {{contentType}}</div>
|
||||||
</div>`,
|
</div>`
|
||||||
directives: [ALFRESCO_DATATABLE_DIRECTIVES, CONTEXT_MENU_DIRECTIVES],
|
|
||||||
providers: [CONTEXT_MENU_PROVIDERS]
|
|
||||||
})
|
})
|
||||||
export class WebscriptComponent {
|
export class WebscriptComponent {
|
||||||
|
|
||||||
@ -90,9 +81,9 @@ export class WebscriptComponent {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Constructor
|
* Constructor
|
||||||
* @param auth
|
* @param authService
|
||||||
*/
|
*/
|
||||||
constructor(public authService: AlfrescoAuthenticationService) {
|
constructor(private authService: AlfrescoAuthenticationService) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user