Disable of submit button based on 3 fields(2 input fields and one checkbox) validation - vue.js

I am trying to enable the submit button if user enters the Password field, the confirm Password field and checks the terms and conditions checkbox, if any of these field is blank, the submit button should get disabled.
For me the button is only getting enabled if user provides all of the above fields, but once it is enabled, the button is not getting disabled if user removes any of the field values and make it blank.
Can someone Please help ?
<div>
<wb-button v-bind:disabled="disableSubmitButton" v-if="showFinalSubmit" v-on:click="validatePassword" type="submit" size="m" variant="primary">
{{ t("submit") }}
</wb-button>
<div>

Related

PayPal Variables Add ref number

I'm struggling to add a variable to my PayPal payment form I need users to add a ref number so that I can identify the order so for example,
I normally use the email link option rather than the form option
Add Ref No :
Add Personal Message :
any help would so much appreciated
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="HUMXQRA7T9Z3L">
<input type="image" src="https://www.paypalobjects.com/en_US/GB/i/btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal – The safer, easier way to pay online!">
<img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1">
</form>
You're using a hosted button, so edit the button at www.paypal.com/buttons , view your saved buttons , find your button and edit it using the action menu.
In the Customize Button box, check the option to add a text field, and save your changes. This will generate new code to copy.
The hosted editor will only generate one text field, so if you need a button with more you'll need to create a new button with the first text field, and in step 2 uncheck the option to save the button at PayPal. When the code is created, click to remove the code protection. This will result in an unhosted button. Copy it to a text editor, and you can then extend the single text field to be two text fields, incrementing the ID number from e.g. 0 to 1 as is necessary for the second field.
You can read about HTML variables for PayPal buttons.

Why the field in webbrowser is still consider as empty even I already set its value?

enter image description hereI'm trying to automate our ticketing system using visual basic. However, I can't save the profile because the field in webbrowser is still read as empty even I already set its value:
I also tried to set the attribute originalvalue, prekeyvalue etc. but still not working. But if you manual type the value in the field, it will work.
My code below:
WebBrowser1.Document.GetElementById("mb8a86d99-tb").SetAttribute("value", "EMAIL")
The information of field below:
<input datatype="0" id="mb8a86d99-tb" aria-required="true" role="textbox" aria-labelledby="mb8a86d99-lb" class="fld text fld fld_req" ctype="textbox" li="mb8a86d99-img" maxlength="512" style=";width:225.0px;" async="1" ae="setvalue" type="text" value="" ov="" work="1" fldinfo="{"lookup":"valuelist","dsid":"TSDTKTSOURCE","inttype":"0","afindex":"0","length":"512","required":true}" title="" originalvalue="" prekeyvalue="" stoptcclick="true">
This kind of problem seems to occur in some web pages when the form containing your input does not get activated (it's a form of protection on client-side made to avoid the insertion of values programmatically).
If you manually type the value in it, the form turns active because you're clicking on the input which is a child of the form. However, if you do it programmatically, the activation is not triggered and so the value that you add to the HTML is not taken by the client.
You can try to emulate the activation of the form with the Focus method on your input:
WebBrowser1.Document.GetElementById("mb8a86d99-tb").Focus
WebBrowser1.Document.GetElementById("mb8a86d99-tb").SetAttribute("value", "EMAIL")
If that still doesn't work, try to add a Application.Wait(TimeSerial(Hour(Now()), Minute(Now()), Second(Now()) + 2)) between one command and the other to let the form the time to actually activate itself.

trigger (ngOnChange) by code to bind the changed model value

I have an input field that takes a date and use pipe to change the output accordingly and with that I am using
(ngOnChange)="myvalye=myFunction($event)"
to update the value. now I have a button whose onclick i want to reset all the data. Below is the code for refrence.
<mydatepicker [ngModel]="mydate | datepipe" (ngModelChange)="mydate=myFun()"/></mydatepicker>
<button class="btn btn-default" (click)="reset()">Reset</button>
so on click of reset button myValue is not getting changed in input box.
datepicker library can be found here

Asp net mvc 4 Kendo dropdownlist

I have a kendo drop down list it binds on page load.
I have a filter section and I filter one drop down list and I click the submit button and its submitting the page.
When I am clicking the submit button I validates the drop down list whether the user selects the valid input or user types invalid data.
When I clicking the submit button, I save the valid data in hidden field and assigns the value to model property.
After submits the page the selected value(before submits) is selected in dropdownlist.
If now I submit the page once again the drop down list selected index comes as -1.
How to validate this drop down list in the above scenario?
You need to set it's value from model when rendering the page again.
You can easily set by following way using jquery:
$(document).ready(function(){
var dropdownlist = $("#movies").data("kendoDropDownList")
dropdownlist.value($("#value").val());
});

How to use a confirmation dialog box in Odoo?

I'd like to get a value in a confirmation dialog bow in odoo.
I have a form with a select. When I choose a value in the select and click the save button, I have a diablog box with a message. In this message I'd like to get the selected value.
Any idea ?
<button string="save"
icon="gtk-ok"
type="object"
name="update_year"
confirm="The selected year is XXXX. Confirm ?"/>