Proyectos de Subversion LeadersLinked - SPA

Rev

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

Rev 1188 Rev 1190
Línea 73... Línea 73...
73
 
73
 
74
        if (!success) {
74
        if (!success) {
75
          throw new Error(data)
75
          throw new Error(data)
Línea -... Línea 76...
-
 
76
        }
76
        }
77
 
77
 
78
        console.log(data)
78
        setEntities(data.current.items)
79
        setEntities(data.current.items)
79
        setPages(data.total.pages)
80
        setPages(data.total.pages)
80
      } catch (error) {
81
      } catch (error) {
Línea 87... Línea 88...
87
    searchEntities()
88
    searchEntities()
88
  }, [search, pathname])
89
  }, [search, pathname])
Línea 89... Línea 90...
89
 
90
 
90
  return (
91
  return (
91
    <>
92
    <>
92
      <Container as='main'>
-
 
93
        <Input
-
 
94
          icon={Search}
-
 
95
          onChange={(e) => onChangeKeyword(e.target.value)}
-
 
96
          defaultValue={keyword}
-
 
97
          placeholder={labels.search}
-
 
98
        />
-
 
99
 
-
 
100
        <Grid container spacing={2} mt={2}>
-
 
101
          <Grid item xs={12} md={4} display='flex' direction='column' gap={2}>
-
 
102
            <FiltersSidebar>
-
 
103
              <CategoryFilter
-
 
104
                currentCategory={category}
-
 
105
                onChange={onChangeCategory}
-
 
106
              />
-
 
107
 
-
 
108
              <LocationFilter onChange={onChangeAddress} />
-
 
109
            </FiltersSidebar>
-
 
110
          </Grid>
-
 
111
 
-
 
112
          <Grid item xs={12} md={8} display='flex' direction='column' gap={2}>
-
 
113
            <div className='posts-section'>
-
 
114
              {loading ? (
-
 
115
                <LoaderContainer>
-
 
116
                  <Spinner />
-
 
117
                </LoaderContainer>
-
 
118
              ) : (
-
 
119
                <>
-
 
120
                  <EntitiesList entities={entities} />
-
 
121
                  <PaginationComponent
-
 
122
                    pages={pages}
-
 
123
                    currentActivePage={currentPage}
-
 
124
                    onChangePage={onChangePage}
-
 
125
                    isRow
-
 
126
                  />
-
 
127
                </>
-
 
128
              )}
-
 
129
            </div>
-
 
130
          </Grid>
-
 
131
        </Grid>
-
 
132
      </Container>
93
      <Container as='main'></Container>
133
    </>
94
    </>
134
  )
95
  )
Línea 135... Línea 96...
135
}
96
}