Proyectos de Subversion LeadersLinked - SPA

Rev

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

Rev 42 Rev 334
Línea 47... Línea 47...
47
const DailyPulse = ({ dailyPulseUrl = "" }) => {
47
const DailyPulse = ({ dailyPulseUrl = "" }) => {
48
  const [emojisHowAreYouFeel, setEmojisHowAreYouFeel] = useState([]);
48
  const [emojisHowAreYouFeel, setEmojisHowAreYouFeel] = useState([]);
49
  const [emojisClimateOnYourOrganization, setEmojisClimateOnYourOrganization] =
49
  const [emojisClimateOnYourOrganization, setEmojisClimateOnYourOrganization] =
50
    useState([]);
50
    useState([]);
Línea 51... Línea 51...
51
 
51
 
52
  const getData = (url) => {
52
  const getData = (url = "") => {
53
    axios
53
    axios
54
      .get(url)
54
      .get(url)
55
      .then((response) => {
55
      .then((response) => {
Línea 76... Línea 76...
76
    <StyledDailyPulseContainer>
76
    <StyledDailyPulseContainer>
77
      <h3>Pulso Diario</h3>
77
      <h3>Pulso Diario</h3>
78
      <DailyPulse.List
78
      <DailyPulse.List
79
        options={emojisHowAreYouFeel}
79
        options={emojisHowAreYouFeel}
80
        title="¿Como te sientes hoy?"
80
        title="¿Como te sientes hoy?"
81
        onComplete={getData}
81
        onComplete={() => getData(dailyPulseUrl)}
82
      />
82
      />
83
      <DailyPulse.List
83
      <DailyPulse.List
84
        options={emojisClimateOnYourOrganization}
84
        options={emojisClimateOnYourOrganization}
85
        title="¿Como esta el clima en la organización?"
85
        title="¿Como esta el clima en la organización?"
86
        onComplete={getData}
86
        onComplete={() => getData(dailyPulseUrl)}
87
      />
87
      />
88
    </StyledDailyPulseContainer>
88
    </StyledDailyPulseContainer>
89
  );
89
  );
90
};
90
};
Línea 108... Línea 108...
108
                : "Ha ocurrido un error",
108
                : "Ha ocurrido un error",
109
          })
109
          })
110
        );
110
        );
111
      }
111
      }
Línea 112... Línea 112...
112
 
112
 
113
      return onComplete();
113
      onComplete();
114
    });
114
    });
Línea 115... Línea 115...
115
  };
115
  };
116
 
116