primeng

PrimeNg calender displayed with broken design in angular 2

旧街凉风 提交于 2019-12-24 19:17:24
问题 I have used primeNg module from primefaces in angular 2 for creating a timepicker. I got it to work but it is displayed with broken design. Is there anything else to add for getting the design correct. Codes I used: package versions: "primeng": "^1.0.0-beta.7", "primeui": "^4.1.10" Module.ts: import { CalendarModule } from 'primeng/primeng'; imports: [CalendarModule] Html: <p-calendar [(ngModel)]="value" showTime="showTime" formControlName="date1" hourFormat="12"></p-calendar> Currently what

PrimeNG set the page for the first using lazy loading table

谁都会走 提交于 2019-12-24 11:35:53
问题 I'm using component p-table with "Paginator" and "Lazy loading", and I made one search component with what I need. I am trying to fix the problem when I filter and the page index is on another page. example: page index = 2 Filtering text = texto. Then, I update the records on table and the quantity of pages. But the page index continues with 2, if the result has more or equal quantity of index pages. I've try changing the value from Event but it does not apply. Documentation PrimeNG lazy

primeNG dataTable colspan tbody - solution

怎甘沉沦 提交于 2019-12-24 11:29:24
问题 I came across this problem like many other where you want a col span for tbody instead of just headers given in the PrimeNG Documentation. I tried to use some directives and Javascript to add it programatically. I am demonstrating the code here. I am not sure if this is a universal solution and would work for everybody but this will definitely act as a starter for solution of your problem. 回答1: Create a custom directive: colspan.ts import { Directive, ElementRef } from '@angular/core';

Custom content dropdown not working in PrimeNG?

南笙酒味 提交于 2019-12-24 11:01:22
问题 I'm implementing a custom content dropdown. Is not working properly. It does not set selectedTestType value and It gives undefined value in the onChangeTestTypes . <p-dropdown name="classTestTypeCombobox" [options]="TestTypes" [(ngModel)]="selectedTestType" [style]="{'width':'150px'}" filter="filter" [disabled]="this.isProdCodeDisabled" appendTo="body" required #classTestTypeCombobox="ngModel" (ngModelChange)="onChangeTestTypes($event)"> <ng-template let-TestType pTemplate="item"> <div class=

issue with contextMenu and CRUD table ngPrime angular2

孤者浪人 提交于 2019-12-24 09:58:13
问题 I am using ngprime in my angular2 application. I am using DataTable for my table view and able to sort, filter but when I try to use Crud functionality or ContextMenu I am getting errors... My AppModule import {SplitButtonModule} from "primeng/components/splitbutton/splitbutton"; @NgModule({ declarations: [ AppComponent, CarsComponent, ModsComponent ], imports: [ BrowserModule, FormsModule, HttpModule, routing, DataTableModule, SharedModule, ButtonModule, DropdownModule, TieredMenuModule,

Primeng calendar: Set date from database

馋奶兔 提交于 2019-12-24 08:38:24
问题 I'm using primeng calendar but i can't set the date from database. This is my date from server: 2018-04-17T16:41:47.683 When i try to change format to "YYYY.MM.DD HH.MM" witht moment, i get this error on console: Uncaught (in promise): Unexpected literal at position 2 When i convert my datetime to string, i get same error and i don't know what to do. Please help Here is my code: Component.html <p-calendar id="StartDate" inputStyleClass="form-control" [showIcon]="true" showTime="true"

TypeScript class Date property returns a string [duplicate]

会有一股神秘感。 提交于 2019-12-24 07:40:04
问题 This question already has an answer here : Promise not returning a valid class instance [duplicate] (1 answer) Closed last year . I've a model class in typeScript: export class Season { ID: number; Start: Date; } And this is my component : export class SeasonsComponent{ seasons: Season[]; selectedSeason: Season; constructor( private configService: ConfigService, private notificationsService: NotificationsService, ) { } ngOnInit(): void { this.selectedSeason = new Season(); this.getSeasons();

Angular2RC4-Primeng Menubar routerlink does not go to my routes after click

梦想的初衷 提交于 2019-12-23 12:43:13
问题 I am using Menubar from primeng for my app. I got the Menu showing, but I wasn't able to make the routing working in my app. I set specific link's route say "reports/89", but when I click the menu corresponding to the link it tries to go to the "localhost:3000/r/e/p/o/r/t/s/8/9" which obviously does not exist. I checked the items object containing my menus and the routerLink is correctly pointing at "reports/89". What is going on here and why primeng puts / among every characters in the link.

asp.net core, angular 2, PrimeNG

本秂侑毒 提交于 2019-12-23 08:37:21
问题 I use aspnetcore-spa template as starting point to create admin panel. Next I add PrimeNG library to use it's components. Unfortunately, when I import i.e. ButtonModule to app.module.ts and refresh, I get an error 'Event is undefined'. I can't figure out what is the reason for several days, so can anyone help me? UPDATE So first of all I generate the stub with yo aspnetcore-spa Next npm install font-awesome primeng --save Then I add font-awesome and PrimeNG css files to webpack.config.vendor

asp.net core, angular 2, PrimeNG

对着背影说爱祢 提交于 2019-12-23 08:36:50
问题 I use aspnetcore-spa template as starting point to create admin panel. Next I add PrimeNG library to use it's components. Unfortunately, when I import i.e. ButtonModule to app.module.ts and refresh, I get an error 'Event is undefined'. I can't figure out what is the reason for several days, so can anyone help me? UPDATE So first of all I generate the stub with yo aspnetcore-spa Next npm install font-awesome primeng --save Then I add font-awesome and PrimeNG css files to webpack.config.vendor