Advertisement
ignatov

Untitled

Sep 17th, 2021
1,672
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  componentDidMount() {
  2.     fetch(
  3.       "http://vhcala4hci:50000/sap/opu/odata/SAP/ZREACT_APP_SRV/employeeSet?$format=json"
  4.     )
  5.       .then((res) => res.json())
  6.       .then(
  7.         (result) => {
  8.           this.setState({
  9.             results: result.d.results,
  10.             isLoaded: true,
  11.           });
  12.         },
  13.         (error) => {
  14.           this.setState({
  15.             isLoaded: false,
  16.             error,
  17.           });
  18.         }
  19.       );
  20.   }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement