i want to insert text box value which opens when click the check box.how to append check box value in ajax.itried below code but it is showing Unexpected token
formData.append('monday', $('input[name="monday"]:checked').val() == 'monday' ? $('[name="tmonday"]').val());
Related
i am using mat-radio-group to bind my data. here data & value are same. which means i have 4 value binded and all 4 value are same. So to differentiate the radio buttons i added index as last value for every radio button.
Now i want to fetch this radio button value into my typescript and also eliminate the lastcharacter(which is index). so i use ngModel & ngModelChange.
I can get the output. but the `mat-radio-button' is not selecting
Here is my code
`
<mat-radio-group class="radioButtonAxis" [(ngModel)]="ngM_Fax" (ngModelChange)="onFaxChange($event)">
<mat-radio-button *ngFor='let data of resultSet;index as i' [value]='data.Fax+i'>{{data.Fax}}</mat-radio-button>
</mat-radio-group>
onFaxChange(value){
this.ngM_Fax = value.substring(0, value.length - 1);
}
`
expecting your help on this.
You are using ngModel wrong. The right value is always in this.ngM_Fax, but it has to match 100% [value]. If you want to use the variable without the index, i would suggest to use an extra variable.
Here is a working StackBlitz.
The "autoNumeric" plugin fills the input fields with zeros as soon as the field got focused or even hovered over. I want to let end user leave some fields blank. Blank is not the same as zero. Is there any solution?
Check the documentation for the emptyInputBehavior option in the AutoNumericOptions.js file:
/* Defines what should be displayed in the element if the raw value is an empty string ('').
* - 'focus' : The currency sign is displayed when the input receives focus (default)
* - 'press' : The currency sign is displayed whenever a key is being pressed
* - 'always' : The currency sign is always displayed
* - 'zero' : A zero is displayed ('rounded' with or without a currency sign) if the input has no value on focus out
* - 'null' : When the element is empty, the `rawValue` and the element value/text is set to `null`. This also allows to set the value to `null` using `anElement.set(null)`.
*/
emptyInputBehavior: {
null : 'null',
focus : 'focus',
press : 'press',
always: 'always',
zero : 'zero',
},
What you want is to set emptyInputBehavior to 'focus' (which is the default), and you won't get any 'zero' added to your input.
This is with the version v4 in next.
In my usecase, setting the emptyInputBehavior to 'null' worked:
emptyInputBehavior: 'null'
That way, when the input field is emptied, its value is set to null.
I have a simple TextBox in my Precision Design related to a Field in Temporary Table.
I need to show this TextBox only If the it value under Temporary Table is pupulated : so if the value field is pupulated (is a string) I show the Text Box , otherwise I don't show the text Box.
I need to set Visibility by Expression :
Which is the best way forward over ?
Thanks!
You can use iif function. Press fx button, here you can writte your code.
iif function evaluate a condition and return 1 of 2 options, for example, in your case you need show one value only if exist.
check this code:
=iif(fields!YourFieldName.value = "", true, false)
if your field is a number
=iif(fields!YourFieldName.value = 0, true, false)
This code evaluate the value of your field and only populate the value if is complete.
I am entering the value in select list through below code
b.select_list(:id,'something').select('hi how are you')
And yes it's choosing as expected and it appears in the select list, but the value which is entered has not actually stored in the browser variable behind screen, So the wrong page arrives due to the missing value in select_list, But when I choose manually,it happening and the right page arrives. How would I rectify this error?
Code on the page look like this,
select value="-1" origValue="-1" tabindex="249" class="QuestionnaireSelect" name="nameid" id="2000007#2000064" style= ""
onkeypress="onComboKeyPress(this)" onchange="closeAfterUnload = false" onmousedown="onFocusFieldHandler(this)" helpTextInfo="" onblur="releaseCurrentFocusField()" onclick="closeAfterUnload = false"
I am using Pentaho report designer 5.0 CE.
My report is having two groups, and one group contains row band with elements and values like,
Group1
Group2
Label1 - Value1
Label2 - Value2
Label3 - Value3
...
I need to show a row only if the value is not empty(without leaving blank space).
I set the 'invisible-consumes-space' property to false (band level). The blank space is still there.
how could i hide a label & value (entire row) if the value is empty?
have you tried to put the label element and value element in a band. assumingly value is printed by name field.
this is your band.
-----------------
|label | name |
-----------------
select the band from structure tree and go to style tab->size&position -> visible option.
then open the expression tab and paste
=IF(ISBLANK([Name]);"False"; "True")
OR
=IF(LEN([Name])<=0;"False"; "True")
I use the one below to hide all the group headers & footers when there is no data.
set no data band -> hide-on-canvas option to false. Add a message
field and let's say 'No data available for selected date range'
And set all Report Header & Footer's visible option to:
=IF(ISEMPTYDATA();"False"; "True")
And it works.
Hope helps to you too.
And empty string is not the same as an invisible element. Use the "visible" style instead and add your formula to the band's "visible" style setting to hide the band and all its subbands.