angularjs-forms

Typescript error Property does not exist on type

让人想犯罪 __ 提交于 2019-11-29 02:39:19
I am new to angularjs 2 and ionic 2. I am working with angularjs form with Validators, FormControl and FormGroup. Everything is good when I execute the project using ionic serve --lab. but when I build that project it gives error: Property 'username' does not exist on type. login.ts import { Component } from '@angular/core'; import { LoadingController, NavController } from 'ionic-angular'; import { AuthService } from '../../service/authService'; import {Validators, FormBuilder, FormGroup, FormControl } from '@angular/forms'; @Component({ selector: 'page-login', templateUrl: 'login.html' })

Typescript error Property does not exist on type

戏子无情 提交于 2019-11-27 16:58:36
问题 I am new to angularjs 2 and ionic 2. I am working with angularjs form with Validators, FormControl and FormGroup. Everything is good when I execute the project using ionic serve --lab. but when I build that project it gives error: Property 'username' does not exist on type. login.ts import { Component } from '@angular/core'; import { LoadingController, NavController } from 'ionic-angular'; import { AuthService } from '../../service/authService'; import {Validators, FormBuilder, FormGroup,

Can I access a form in the controller?

浪尽此生 提交于 2019-11-26 15:47:30
I'm currently using the following. $scope.$$childHead.customerForm[firstName] , so that: <form name="customerForm"> <input type="text" name="firstName" ng-model="data.customer.firstName" tabindex="1" ng-disabled="!data.editable" validationcustomer /> </form> But this only works in Chrome. Now I tried the following: $scope.editCustomerForm[firstName] , so that: <form name="customerForm" ng-model="editCustomerForm"> <input type="text" name="firstName" ng-model="data.customer.firstName" tabindex="1" ng-disabled="!data.editable" validationcustomer /> </form> Which doesn't work. Note my form is

Can I access a form in the controller?

让人想犯罪 __ 提交于 2019-11-26 04:36:51
问题 I\'m currently using the following. $scope.$$childHead.customerForm[firstName] , so that: <form name=\"customerForm\"> <input type=\"text\" name=\"firstName\" ng-model=\"data.customer.firstName\" tabindex=\"1\" ng-disabled=\"!data.editable\" validationcustomer /> </form> But this only works in Chrome. Now I tried the following: $scope.editCustomerForm[firstName] , so that: <form name=\"customerForm\" ng-model=\"editCustomerForm\"> <input type=\"text\" name=\"firstName\" ng-model=\"data