|
@@ -8,6 +8,7 @@ import { FormBuilder, Validators, FormGroup } from '@angular/forms';
|
|
|
import { BaseCustomerIndustry } from 'app/entity/basedata/base-customer-industry';
|
|
|
import { BaseCustomerIndustryService } from 'app/services/basedata/base-customer-industry.service';
|
|
|
import { I18NService } from '@core';
|
|
|
+// import { NzInputNumberModule } from 'ng-zorro-antd/input-number';
|
|
|
|
|
|
@Component({
|
|
|
selector: 'app-basedata-merchants-industry-add',
|
|
@@ -28,6 +29,7 @@ export class BasedataMerchantsIndustryAddComponent implements OnInit {
|
|
|
code: [{ value: '', disabled: true }, []], //客商编码
|
|
|
name: [null, [Validators.required]], //客商名称
|
|
|
status: [null], //是否启用
|
|
|
+ sort: ['number', [Validators.required]], //数字输入框 客商名称排序
|
|
|
});
|
|
|
//新增子集获取父节点id
|
|
|
// if(this.parentId&&this.parentId!=="0"){
|
|
@@ -41,7 +43,7 @@ export class BasedataMerchantsIndustryAddComponent implements OnInit {
|
|
|
|
|
|
// 确定 按钮(添加一级)
|
|
|
submitForm(): any {
|
|
|
- console.log('----');
|
|
|
+ // console.log('----');
|
|
|
return new Promise(resolve => {
|
|
|
for (const i in this.validateForm.controls) {
|
|
|
this.validateForm.controls[i].markAsDirty();
|
|
@@ -78,4 +80,20 @@ export class BasedataMerchantsIndustryAddComponent implements OnInit {
|
|
|
}
|
|
|
//实例化函数
|
|
|
baseCustomerIndustry: BaseCustomerIndustry = {};
|
|
|
+
|
|
|
+ onInput($event) {
|
|
|
+ // if (!$event) {
|
|
|
+ // console.log($event);
|
|
|
+ // return;
|
|
|
+ // }
|
|
|
+ // const target = $event.target;
|
|
|
+ // console.log(target);
|
|
|
+ // const reg = /^(\d)+$/;
|
|
|
+ // target.value = target.value.replace(reg, '');
|
|
|
+ // console.log(target.value);
|
|
|
+ }
|
|
|
+ // 数值改变时回调
|
|
|
+ changeMethod() {
|
|
|
+ console.log('?/?');
|
|
|
+ }
|
|
|
}
|