Questions tagged [angular-formly]
angular-formly is an AngularJS module which has a directive to help customize and render JavaScript/JSON configured forms. The formly-form directive and the formlyConfig service are very powerful and bring unmatched maintainability to your application's forms.
401
questions
1
vote
0answers
28 views
Filter Arrays in Angular/Formly
I have an array of fields using formly, I want to filter the array to just include items with specific keys.
const questionSet = [
createInput('hi','hi'),
createInput('hey','hey'),
createInput('...
0
votes
1answer
71 views
'subscribe' is deprecated. Use an observer instead of a complete callback
Hi am having the following error with SonarQube
'subscribe' is deprecated. Use an observer instead of a complete callback.
Am using formly in angular 9.
Thank you for your help and time
...
0
votes
0answers
13 views
How to complete my formly-time component to get value and make output
I´m trying to make a formly time component based on ngx material timepicker.
My problem is how to bind the user value and output this value as a timestamp like the @Input().
I´m very confused with few ...
-1
votes
1answer
22 views
How to override remove method of repeat element and perform both operations of removing and adding some logic in ngx formly angular
I'm using a repeat field in which there is a remove button that works fine normally, but my requirement is to perform some logic while removing the element in which I call a customize function ...
1
vote
1answer
81 views
How to Bind a component on click of element in multiselect of angular formly Reactive forms
I have a reuquirement in which i am using a multiselect dropdwon which also has logo for each row. On click of this logo i want to load other component, like we use viewchild in template driven ...
1
vote
1answer
95 views
Angular 10 - Formly - Accessing a field's value in a custom formly-wrapper
I am using Angular 10 and have a formly-form that includes a select-field called session. That select field allows me to choose one of several dndSession options. The value of each option is an object ...
0
votes
2answers
103 views
Angular formly: is there a way to set default options for all inputs
I'm having a formly form with many mat-inputs (yes, I'm using Material) inside. I want each of them have appearance=outline of cause I can put it inside templateOptions of each input. But that's not ...
0
votes
0answers
65 views
Problems with formly select
I am creating a step form with formly in the last step I am creating a select and it fills correctly with my API but when I want to select an article in one of the selects it first returns a null ...
1
vote
3answers
127 views
Default Date to JSON conversion format in Angular app
Suppose a component (inside the angular app) having several reactive forms containing datepickers (I'm using mat-datepicker from angular material lib) and other inputs. After a user hit "Submit&...
0
votes
0answers
30 views
How to know the valueProp of select in angular formly
I want to know the value of the selected data in my select to send to my service and consult some things
I'm using angular formly and I have my fieldgroup like this
fieldGroup: [
{
key: 'plan',
...
0
votes
0answers
16 views
Angular: what is the best way to import formly lib?
In my app I'm having several lazy-loaded modules that use formly library. I'm try to import and re-export formly module in CoreModule (that is loaded eagerly and imported in AppModule)
@NgModule({
...
0
votes
0answers
21 views
How to navigate autocomplete Options by url in angular formly?
> className: "flex-25 padding-10",
> key: "KindPerList",
> type: "autoComplete",
> templateOptions: {
> label: "Choose Account&...
0
votes
0answers
19 views
How to use Angular Formly Schematics to generate real forms
Is it there an angular schematic to generate HTML forms?
I heard of Formly as being a schematics but I don't need to use tag/component. How to get the HTML code generated so one can edit them.
PS: ...
0
votes
1answer
94 views
Angular email pattern regex validation with apostrophe i.e. ' [duplicate]
Thank you in advance for your help.
I am trying to validate the email address entered with regex pattern
i.e. "pattern": [a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\\.[a-zA-Z]{2,4}$ which is working as ...
0
votes
0answers
98 views
dynamically set the repeating input text field value in angular formly?
I am using the angular-formly for repeating the controls.
component.ts file
this.fields = [
{
key: 'allEmployeeData',
type: 'repeat',
fieldArray: {
...
0
votes
1answer
38 views
return boolean based on object condition inside array of objects
I feel like this is quite a simple question but I've been struggling with it for the last few hours..
data[0].fieldArray.fieldGroup[4].hideExpression = (model: any, formState: any) => {
...
-2
votes
1answer
48 views
When data come with delay the list is not displayed
Below is a select with kendo ui and is called a function. when function is called with delay data is not visibile.
https://stackblitz.com/edit/ngx-formly-ui-kendo-fo1475?file=src%2Fapp%2Fapp.component....
1
vote
2answers
75 views
Binding angular formly select option not work
I'm trying to bind formly select type options using this code :
fieldGroup: [
{
key: 'TimeOffTypeID',
type: 'select',
className: 'flex-40 padding-10',
templateOptions:...
0
votes
0answers
128 views
hideExpression in NGX-FORMLY Dynamic form
I'm trying to build a dynamically form in ngx formly but have an issue with getting it working while keep the separation of concerns. This mostly is working but the problem is passing around the model,...
0
votes
0answers
158 views
Not able to set default value to autocomplete of angular formly using prime-ng
I am using Autocomplete of prime ng in formly, I am not able to set the default value of this field from one of the options in the list. I have gone through the primeng documentation of angular it ...
0
votes
1answer
33 views
Angular Formly: HideExpression does not kick in on page load (Angular 10)
Facing this issue in Angular 10
I have a number of fields on my form. When the user changes the selected value in a dropdown, there is a hideExpression on each field that shows/hides the fields ...
0
votes
2answers
123 views
Angular Formly - Disable individual Radio Options
I'm trying to disable one Radio Button (e.g the first one) Option trough angular formly Fields.
options: [
{
value: 1,
label: 1,
},
...
0
votes
1answer
63 views
Formly, primeng not able to set value of mindate(datepicker) in component using angular
I am using angular formly and primeng. I have FormlyFieldCalendar and AppComponent in place.
Setting the property of minDate in and initialiting the value in FormlyFieldCalendar with minDate works ...
0
votes
0answers
437 views
Fomated input value to insert version like xx.xxx.x with Angular formly
I´m using :
Angular 9
Angular Material
Angular formly
In a form, I need to get an input when the user can insert 3 or 4 integers like {integer}.{integer}.{integer}[.{integer}]
Regex : (([0-9]*.){3,4}...
0
votes
0answers
44 views
Input value going “null” as a string instead of keyword null
I am using angular 8
angular formly
I have two fields one is dropdown i.e. Course and other is othercourse if candidates course is not there in the dropdown second field is an input field
in my ...
0
votes
0answers
19 views
Reusing same set of options for multiple selects
What is a good practice to load options from the same API for two different selects? I am trying to load salesManagerUser set of options for salesPersonUser but I am not too sure what a good practice ...
0
votes
0answers
86 views
How to hide a check box in repeat forms in angular formly
I am using angular formly json powered repeating section to genrate my forms
I am using repeat forms so that user can enter multiple employers details
form includes date of joining , date of exit and ...
0
votes
1answer
222 views
Validate that minimum value does not exceed the maximum value provided in an Angular app
I have two inputs fields in an angular application, minimum and maximum. I would like to show an error message whenever a user enters a minimum value that is greater than the maximum value, that he/ ...
0
votes
2answers
27 views
How to make bootstrap behave like a table with a sticky header?
This is my bootstrap that I need to behave like a table. I also need the header columns to behave like a sticky header on scroll. Is this possible with just bootstrap alone?
The reason I am not using ...
0
votes
2answers
338 views
How to fix “Cannot read property 'options' of undefined” in angular formly?
I'm trying to use Formly in Angular 9 for some dynamicly configured forms.
It was worked well with angular 8, but when I upgrade the project to angular 9, i had the following errors.
My component ...
0
votes
0answers
18 views
Error is not updated in ui with dynamic form array
I have a grid , grid have 7 columns and based on service response field names i have created a control bind the values.
usecase 1: working fine
if grid server response return two rows of data, i ...
1
vote
0answers
92 views
Dynamically Adding Key/Val Pairs in angular formly
I am using ngx-formly to build UI dynamically based on JSON. I am currently having some problems implementing the add/delete functionality for a key/val
Since all my keys/values are dynamically added ...
0
votes
1answer
118 views
Angular formly select shows blank drop down list from backend api call
I am trying to display data in drop down select list using angular formly. The drop down list appear to be blank. Here is the code snippet. Can some please help??
component.ts
this.fields = [
{
...
0
votes
1answer
29 views
ng-show/ng-hide and ng-switch elements showing at the same time
Within an Angular Formly (angularjs) form - I have two spans that I want to switch on a model property condition. Whilst the search text disappears to show the spinner, it subsequently shows both ...
0
votes
0answers
115 views
Customized model values / output ngx-formly
I am trying to use ngx-formly to render forms. (using the FormlyFormConfig Object)
The form is rendering properly and i am getting model values as json object .
But is it possible that instead of ...
0
votes
1answer
485 views
Binding Angular Formly select to a model property for its options
I am working on a legacy Angular Formly form, and I have a select formly-template field for a drop down list:
<select class="form-control" placeholder="choose ..." ng-model="model[options.key]"
...
0
votes
2answers
518 views
How to validate start date and end date in angular formly
I have two simple fields (input) of the start date and end date I just want that end date should not be less than the start date
I am using angular 8
I am using ng module
so from myfile.json file I ...
0
votes
1answer
581 views
Angular Formly Forms - removing add/remove buttons from array type
I've got an issue trying to remove/disable buttons from a customized array component I use with Formly Forms when generating dynamic forms using a json schema (draft 7). I've tried various things to ...
1
vote
1answer
418 views
angular formly form with multiple steps and nested fields
I got assigned to the project that uses formly to build forms. most of them are either plain single page forms or forms out of jsonSchema. I got asked to research nested forms with tabs etc.
https://...
0
votes
0answers
67 views
Custom HTML template with material not working in angular-formly
I have a field in formly and want to customise the field using my own HTML. The field looks like this:
{
className: 'rememberMeField',
key: 'rememberMe',
template: '<mat-checkbox>...
-1
votes
1answer
154 views
How to add tooltip in Angular Formly?
Can someone guide me how to add tooltip in formly like demo given below
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/email
When you hover over input field you will have tooltip.
1
vote
1answer
463 views
Angular CLI 8 - Formly custom select for json schema (draft 4)
I've got some difficulties getting my json schema (draft 4) to fully work with Angular-Formly forms custom templates. I've made several templates for various data types and I'm stuck with a template ...
0
votes
0answers
50 views
CSS content and formly-field
I want to make tooltip for formly field. I managed to do it, but now the only problem I have is how to put content in that tooltip. This is my formly field (note that I will have more fields that ...
0
votes
1answer
189 views
How to add tooltip to formly field
I was trying searching for answer but not efficiently, so here I am.
How to add tooltip to those fields? Tooltip would contain only one sentence and it's not complex.
I should do it for more fields, ...
0
votes
0answers
23 views
Dynamic model with ngx-formly not shown after calll with delay
I have builded a dynamic content with a mockup for data. When dataModel is called directly the interface it goes fine. When try to call with delay with function setTime the data are not shown anymore. ...
0
votes
0answers
993 views
How to use ngx-formly hideExpression to hide and display child elements based on parents value
I am new to angular formly
I want to use formly to build a form for the following scenario:
there are three sibling elements
out of which two elements are dependant on the value of one sibling ...
0
votes
0answers
91 views
get value from dynamically loaded custom component
I use formly to dynamically create an Angular reactive forms.
and I use a custom field to load some values from the database and create checkboxes from them.
so, I need to dynamically load this ...
0
votes
1answer
186 views
Disable future dates in Formly Datepicker in Angular
I am using Formly with Material in Angular and have a datepicker. All I want to do is disable future dates so they cannot be selected when selecting a date, I can't seem to find anything online!
...
0
votes
1answer
106 views
Kendo Multiselect Issue on validation
i am using kendo multi-select field in angular formly. In html file i am using for checking error message. But for this kendo multi-select field. I am not able to find the formControl. for other ...
5
votes
2answers
2k views
Function calls are not supported in decorators but 'FileTypeModule' was called
trying to setup ngx-formly-material-file, but I got an error:
Function calls are not supported in decorators but 'FileTypeModule' was called
I tried to export FileTypeModule, but got the same error
...