Proyectos de Subversion LeadersLinked - Backend

Rev

Rev 14365 | Rev 14367 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 14365 Rev 14366
Línea 80... Línea 80...
80
		section: sectionSelected.slug_section,
80
		section: sectionSelected.slug_section,
81
		question: questionSelected.slug_question,
81
		question: questionSelected.slug_question,
82
		option: optionSelected.slug_option
82
		option: optionSelected.slug_option
83
	}
83
	}
Línea -... Línea 84...
-
 
84
 
-
 
85
	const [text,setText] = useState('')
-
 
86
	const [description,setDescription] = useState('')
84
 
87
 
85
	// Section methods
88
	// Section methods
86
	const showSectionModal = (section = INITIAL_SECTION, type = 'add') => {
89
	const showSectionModal = (section = INITIAL_SECTION, type = 'add') => {
87
		setSectionSelected(section)
90
		setSectionSelected(section)
88
		setSectionType(type)
91
		setSectionType(type)
Línea 394... Línea 397...
394
					setStatus(data.data.status)
397
					setStatus(data.data.status)
Línea 395... Línea 398...
395
 
398
 
396
					setValue('name', data.data.name)
399
					setValue('name', data.data.name)
397
					setValue('description', data.data.description)
400
					setValue('description', data.data.description)
-
 
401
					setValue('text', data.data.description)
-
 
402
					setDescription(data.data.description)
398
					setValue('text', data.data.description)
403
					setText(data.data.text)
399
				})
404
				})
400
		}
405
		}
Línea 401... Línea 406...
401
	}, [actionLink])
406
	}, [actionLink])
Línea 410... Línea 415...
410
							<input type="text" name="name" className='form-control' ref={register({ required: true, maxLength: 50 })} />
415
							<input type="text" name="name" className='form-control' ref={register({ required: true, maxLength: 50 })} />
411
						</div>
416
						</div>
412
						<div className="form-group">
417
						<div className="form-group">
413
							<label htmlFor="form-description">Descripción</label>
418
							<label htmlFor="form-description">Descripción</label>
414
							<DescriptionInput
419
							<DescriptionInput
415
								defaultValue={watch('description') }
420
								defaultValue={description}
416
								name='description'
421
								name='description'
417
								onChange={setValue}
422
								onChange={setDescription}
418
							/>
423
							/>
419
						</div>
424
						</div>
420
						<div className="form-group">
425
						<div className="form-group">
421
							<label htmlFor="form-description">Texto</label>
426
							<label htmlFor="form-description">Texto</label>
422
							<DescriptionInput
427
							<DescriptionInput
423
								defaultValue={watch('text')}
428
								defaultValue={text}
424
								name='text'
429
								name='text'
425
								onChange={setValue}
430
								onChange={setText}
426
							/>
431
							/>
427
						</div>
432
						</div>
428
						<div className="form-group">
433
						<div className="form-group">
429
							<label htmlFor="form-status">Estatus</label>
434
							<label htmlFor="form-status">Estatus</label>
430
							<select name="form-status" className="form-control" onChange={(e) => setStatus(e.target.value)} value={status}>
435
							<select name="form-status" className="form-control" onChange={(e) => setStatus(e.target.value)} value={status}>