|
|
@@ -30,13 +30,15 @@ export class MCOMUNFORMComponent implements OnInit {
|
|
|
if (this.data.action == 'Registrar') {
|
|
|
return new FormGroup({
|
|
|
nombre: new FormControl('', Validators.required),
|
|
|
- rfc_unidad: new FormControl('', [Validators.required, Validators.pattern("^(([A-ZÑ&]{3})([0-9]{2})([0][13578]|[1][02])(([0][1-9]|[12][\\d])|[3][01])([A-Z0-9]{3}))|" +
|
|
|
- "(([A-ZÑ&]{3})([0-9]{2})([0][13456789]|[1][012])(([0][1-9]|[12][\\d])|[3][0])([A-Z0-9]{3}))|" +
|
|
|
- "(([A-ZÑ&]{3})([02468][048]|[13579][26])[0][2]([0][1-9]|[12][\\d])([A-Z0-9]{3}))|" +
|
|
|
- "(([A-ZÑ&]{3})([0-9]{2})[0][2]([0][1-9]|[1][0-9]|[2][0-8])([A-Z0-9]{3}))$;")]),
|
|
|
+ rfc_unidad: new FormControl('',
|
|
|
+ [
|
|
|
+ Validators.required,
|
|
|
+ Validators.pattern("(([A-ZÑ&]{4})([0-9]{2})([0][123456789]|[1][012])([0][1-9]|[1][0-9]|[2][0-9]|[3][0-1])([A-Z0-9]{3}))")
|
|
|
+ ]
|
|
|
+ ),
|
|
|
rfc_empresa: new FormControl(
|
|
|
this.usuario_session.RFCEMPRESA,
|
|
|
- [ Validators.minLength(12)]
|
|
|
+ [ Validators.minLength(13)]
|
|
|
),
|
|
|
id_usuario_registra: new FormControl(
|
|
|
this._encService.desencriptar(this.usuario_session.IDUSUARIO),
|
|
|
@@ -51,10 +53,9 @@ export class MCOMUNFORMComponent implements OnInit {
|
|
|
),
|
|
|
rfc_unidad: new FormControl(
|
|
|
{ value: this.data.item.RFCUNIDAD, disabled: true },
|
|
|
- [Validators.required, Validators.pattern("^(([A-ZÑ&]{3})([0-9]{2})([0][13578]|[1][02])(([0][1-9]|[12][\\d])|[3][01])([A-Z0-9]{3}))|" +
|
|
|
- "(([A-ZÑ&]{3})([0-9]{2})([0][13456789]|[1][012])(([0][1-9]|[12][\\d])|[3][0])([A-Z0-9]{3}))|" +
|
|
|
- "(([A-ZÑ&]{3})([02468][048]|[13579][26])[0][2]([0][1-9]|[12][\\d])([A-Z0-9]{3}))|" +
|
|
|
- "(([A-ZÑ&]{3})([0-9]{2})[0][2]([0][1-9]|[1][0-9]|[2][0-8])([A-Z0-9]{3}))$;")]
|
|
|
+ [ Validators.required,
|
|
|
+ Validators.pattern("(([A-ZÑ&]{4})([0-9]{2})([0][123456789]|[1][012])([0][1-9]|[1][0-9]|[2][0-9]|[3][0-1])([A-Z0-9]{3}))")
|
|
|
+ ]
|
|
|
),
|
|
|
rfc_empresa: new FormControl(
|
|
|
this._encService.desencriptar(this.usuario_session.RFCEMPRESA),
|