dni-converter

1.0.1 • Public • Published
��# # C o n v e r t t h e s u m o f y o u r A r g e n t i n e D N I ( d o c u m e n t n a t i o n a l o f i d e n t i t y ) a n d g e n d e r t o C U I L ( U n i q u e L a b o r I d e n t i f i c a t i o n C o d e ) # # # # # # # E N G L I S H # T h i s p r o j e c t h e l p s w i t h t h e t e d i o u s t a s k o f g e t t i n g s o m e o n e ' s C U I L w i t h p r e d e s i g n e d m a t h e m a t i c a l f u n c t i o n s t o b e a p p l i e d t o t h e D N I a n d g e t t h e p e r s o n ' s C U I L * T h e U n i q u e L a b o r I d e n t i f i c a t i o n C o d e ( C U I L ) i s n e c e s s a r y a t t h e b e g i n n i n g o f a w o r k a c t i v i t y a n d i s a l s o u s e d t o c o l l e c t b e n e f i t s p r o v i d e d b y A N S E S ( N a t i o n a l S o c i a l S e c u r i t y A d m i n i s t r a t i o n ) a n d / o r c a r r y o u t p r o c e d u r e s w i t h o t h e r e n t i t i e s t h a t r e q u i r e i t * I t c o n s i s t s o f t h e c o m b i n a t i o n o f a p e r s o n ' s D N I a n d t w o n e w n u m b e r s a d d e d t o t h e l e f t o f t h e D N I a n d a n e w o n e t o t h e r i g h t . T h e s e t h r e e n e w n u m b e r s a r e c a l c u l a t e d b a s e d o n a m a t h e m a t i c a l f o r m u l a c r e a t e d b y A N S E S * T h e r e a r e r a r e c a s e s i n w h i c h s o m e C U I L c a n n o t b e c a l c u l a t e d b e c a u s e t h e y a r e a s s i g n e d b y A N S E S w i t h o u t f o l l o w i n g t h e f o r m u l a t h a t t h e y t h e m s e l v e s c r e a t e d d e c a d e s a g o : / b u t a s I m e n t i o n e d t h e y a r e r a r e c a s e s s o s t i l l I s a w m y s e l f a t s o m e p o i n t i n n e e d o f a c o n v e r s i o n f u n c t i o n l i k e t h i s * I f t h e D N I h a s s e v e n d i g i t s , a z e r o w i l l b e a d d e d t o t h e n u m b e r t o r e a c h e i g h t d i g i t s , e x a m p l e : 1 2 3 4 5 6 7 w i l l b e c o n v e r t e d t o 0 1 2 3 4 5 6 7 # # U s e e x a m p l e ! [ ! [ N | S o l i d ] ( h t t p s : / / i . i b b . c o / 9 V b 1 j z h / d n i - C o n v e r t e r - T e s t . p n g ) ] ( h t t p s : / / i . i b b . c o / 9 V b 1 j z h / d n i - C o n v e r t e r - T e s t . p n g ) # # U s e s t e p s I t ' s v e r y s i m p l e , j u s t f o l l o w t h i s s t e p s ! : D 1 . R u n n p m i d n i - c o n v e r t e r i n a t e r m i n a l 2 . I m p o r t " d n i C o n v e r t e r " f u n c t i o n f r o m t h i s p a c k a g e 3 . G e t t h e D N I a n d g e n d e r o f t h e p e r s o n y o u w a n t t o g e t t h e i r C U I L 4 . U s e " d n i C o n v e r t e r " f u n c t i o n p a s s i n g t h e d a t a a l r e a d y m e n t i o n e d i n t h i s o r d e r a s p a r a m e t e r s , f i r s t D N I ( a s n u m b e r ) a n d s e c o n d t h e g e n d e r ( a s s t r i n g , ' m a l e ' o r ' f e m a l e ' ) # # F i n d a b u g ? I f y o u f o u n d a n i s s u e o r w o u l d l i k e t o s u b m i t a n i m p r o v e m e n t t o t h i s p r o j e c t , p l e a s e s u b m i t a n i s s u e u s i n g t h e i s s u e s t a b a b o v e . I f y o u w o u l d l i k e t o s u b m i t a P R w i t h a f i x , r e f e r e n c e t h e i s s u e y o u c r e a t e d ! # # # # # # # E S P A � O L # # C o n v i e r t e l a s u m a d e t u D N I a r g e n t i n o ( d o c u m e n t o n a c i o n a l d e i d e n t i d a d ) y g � n e r o a C U I L ( C � d i g o � n i c o d e I d e n t i f i c a c i � n L a b o r a l ) # E s t e p r o y e c t o a y u d a e n l a t e d i o s a t a r e a d e s a c a r e l C U I L d e u n a p e r s o n a c o n f u n c i o n e s m a t e m � t i c a s p r e d i s e � a d a s p a r a a p l i c a r a l D N I y o b t e n e r e l C U I L d e l a p e r s o n a * E l C � d i g o � n i c o d e I d e n t i f i c a c i � n L a b o r a l ( C U I L ) e s n e c e s a r i o a l i n i c i o d e u n a a c t i v i d a d l a b o r a l y t a m b i � n s e u t i l i z a p a r a c o b r a r l a s p r e s t a c i o n e s q u e b r i n d a l a A N S E S ( A d m i n i s t r a c i � n N a c i o n a l d e l S e g u r o S o c i a l ) y / o r e a l i z a r t r � m i t e s c o n o t r a s e n t i d a d e s q u e a s � l o r e q u i e r a n * C o n s i s t e e n l a c o m b i n a c i � n d e l D N I d e u n a p e r s o n a y d o s n u e v o s n � m e r o s a � a d i d o s a l a i z q u i e r d a d e l D N I y u n o n u e v o a l a d e r e c h a . E s t o s t r e s n u e v o s n � m e r o s s e c a l c u l a n c o n b a s e e n u n a f � r m u l a m a t e m � t i c a c r e a d a p o r A N S E S * H a y c a s o s r a r o s e n l o s q u e n o s e p u e d e n c a l c u l a r a l g u n o s C U I L p o r q u e s o n a s i g n a d o s p o r A N S E S s i n s e g u i r l a f � r m u l a q u e e l l o s m i s m o s c r e a r o n h a c e d � c a d a s : / p e r o c o m o m e n c i o n � s o n c a s o s r a r o s a s � q u e i g u a l m e v i e n a l g � n m o m e n t o n e c e s i t a n d o u n a f u n c i o n c o n v e r s o r a * S i e l D N I t i e n e s i e t e d � g i t o s , s e a � a d i r � u n c e r o a l n � m e r o h a s t a l l e g a r a l o s o c h o d � g i t o s , e j e m p l o : 1 2 3 4 5 6 7 s e c o n v e r t i r � e n 0 1 2 3 4 5 6 7 # # � E j e m p l o d e u s o ! [ ! [ N | S o l i d ] ( h t t p s : / / i . i b b . c o / 9 V b 1 j z h / d n i - C o n v e r t e r - T e s t . p n g ) ] ( h t t p s : / / i . i b b . c o / 9 V b 1 j z h / d n i - C o n v e r t e r - T e s t . p n g ) # # P a s o s p a r a s u u s o � E s m u y s i m p l e , s o l o s i g u e e s t o s p a s o s ! : D 1 . C o r r e r n p m i d n i - c o n v e r t e r e n u n a t e r m i n a l 2 . I m p o r t a r l a f u n c i o n " d n i C o n v e r t e r " d e s d e e s t e p a q u e t e 3 . C o n s i g u e e l D N I y s e x o d e l a p e r s o n a q u e q u i e r e s s a c a r s u C U I L 4 . U t i l i z a r l a f u n c i � n " d n i C o n v e r t e r " p a s a n d o l o s d a t o s y a m e n c i o n a d o s e n e s t e o r d e n c o m o p a r � m e t r o s , p r i m e r o D N I ( c o m o n � m e r o ) y s e g u n d o e l g � n e r o ( c o m o c a d e n a , ' m a l e ' o ' f e m a l e ' ) # # � E n c o n t r a s t e u n e r r o r ? S i e n c o n t r � u n p r o b l e m a o d e s e a e n v i a r u n a m e j o r a a e s t e p r o y e c t o , d e j e u n " i s s u e " ( p r o b l e m a ) u s a n d o l a p e s t a � a d e " i s s u e s " d e a r r i b a . � S i d e s e a e n v i a r u n P R c o n u n a c o r r e c c i � n , h a g a r e f e r e n c i a a l " i s s u e " q u e h a c r e a d o !

Readme

Keywords

Package Sidebar

Install

npm i dni-converter

Weekly Downloads

1

Version

1.0.1

License

ISC

Unpacked Size

10.3 kB

Total Files

3

Last publish

Collaborators

  • mateomax