Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 6248 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 6248 Rev 6249
Línea 41... Línea 41...
41
      </Box>
41
      </Box>
42
    </Drawer>
42
    </Drawer>
43
  )
43
  )
44
}
44
}
Línea 45... Línea 45...
45
 
45
 
46
const Item = ({ Icon, title, url, childs = [], ajax }) => {
46
const Item = ({ Icon, title, url, childs = [], ajaxRequest }) => {
47
  const handleAjaxRequest = async () => {
47
  const handleAjaxRequest = async () => {
48
    try {
48
    try {
49
      const { data } = await axios.get(url)
49
      const { data } = await axios.get(url)
50
      if (data.success) {
50
      if (data.success) {
Línea 62... Línea 62...
62
          href={`/${url}`}
62
          href={`/${url}`}
63
          display="flex"
63
          display="flex"
64
          gap=".5rem"
64
          gap=".5rem"
65
          paddingLeft="1rem"
65
          paddingLeft="1rem"
66
          onClick={(e) => {
66
          onClick={(e) => {
67
            if (ajax) {
67
            if (ajaxRequest) {
68
              e.preventDefault()
68
              e.preventDefault()
69
              handleAjaxRequest()
69
              handleAjaxRequest()
70
            }
70
            }
71
          }}
71
          }}
72
        >
72
        >