mirror of
				https://github.com/Telecominfraproject/wlan-cloud-ui.git
				synced 2025-10-31 02:37:54 +00:00 
			
		
		
		
	Upgraded to Apollo Client 3.
This commit is contained in:
		| @@ -1,6 +1,5 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useQuery, useMutation } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation, gql } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
|  | ||||
| import { Accounts as AccountsPage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|   | ||||
| @@ -1,7 +1,6 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import { AddProfile as AddProfilePage } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useMutation, useQuery } from '@apollo/react-hooks'; | ||||
| import { useMutation, useQuery, gql } from '@apollo/client'; | ||||
| import { notification } from 'antd'; | ||||
|  | ||||
| import UserContext from 'contexts/UserContext'; | ||||
|   | ||||
| @@ -1,6 +1,5 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useQuery } from '@apollo/react-hooks'; | ||||
| import { useQuery, gql } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import { Alarms as AlarmsPage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|  | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| import React, { useContext, useEffect, useMemo, useState, useRef } from 'react'; | ||||
| import { Alert } from 'antd'; | ||||
| import moment from 'moment'; | ||||
| import { useQuery } from '@apollo/react-hooks'; | ||||
| import { useQuery } from '@apollo/client'; | ||||
| import { Dashboard as DashboardPage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
| import UserContext from 'contexts/UserContext'; | ||||
| import { FILTER_SYSTEM_EVENTS, GET_ALL_STATUS } from 'graphql/queries'; | ||||
|   | ||||
| @@ -1,6 +1,5 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useMutation, useQuery } from '@apollo/react-hooks'; | ||||
| import { useMutation, useQuery, gql } from '@apollo/client'; | ||||
| import { notification, Alert } from 'antd'; | ||||
| import { EditAccount as EditAccountPage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,5 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useMutation, useApolloClient } from '@apollo/react-hooks'; | ||||
| import { useMutation, useApolloClient, gql } from '@apollo/client'; | ||||
| import { useHistory } from 'react-router-dom'; | ||||
| import { notification } from 'antd'; | ||||
|  | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import PropTypes from 'prop-types'; | ||||
| import { useLocation } from 'react-router-dom'; | ||||
| import { useApolloClient, useQuery } from '@apollo/react-hooks'; | ||||
| import { useApolloClient, useQuery } from '@apollo/client'; | ||||
| import { AppLayout as Layout } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|  | ||||
| import { GET_ALARM_COUNT } from 'graphql/queries'; | ||||
|   | ||||
| @@ -1,8 +1,7 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import PropTypes from 'prop-types'; | ||||
| import { useParams } from 'react-router-dom'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useQuery, useMutation } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation, gql } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import moment from 'moment'; | ||||
| import { | ||||
|   | ||||
| @@ -1,7 +1,7 @@ | ||||
| import React, { useEffect, useContext } from 'react'; | ||||
| import PropTypes from 'prop-types'; | ||||
| import moment from 'moment'; | ||||
| import { useLazyQuery } from '@apollo/react-hooks'; | ||||
| import { useLazyQuery } from '@apollo/client'; | ||||
| import { notification } from 'antd'; | ||||
| import { floor, padStart } from 'lodash'; | ||||
| import { NetworkTableContainer } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|   | ||||
| @@ -2,7 +2,7 @@ import React, { useContext, useMemo } from 'react'; | ||||
| import PropTypes from 'prop-types'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import { useParams } from 'react-router-dom'; | ||||
| import { useQuery, useMutation } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation } from '@apollo/client'; | ||||
| import { BulkEditAccessPoints, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|  | ||||
| import { FILTER_EQUIPMENT_BULK_EDIT_APS } from 'graphql/queries'; | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import { useParams } from 'react-router-dom'; | ||||
| import { useQuery } from '@apollo/react-hooks'; | ||||
| import { useQuery } from '@apollo/client'; | ||||
| import moment from 'moment'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import { | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| import React, { useEffect, useContext } from 'react'; | ||||
| import PropTypes from 'prop-types'; | ||||
| import { useLazyQuery } from '@apollo/react-hooks'; | ||||
| import { useLazyQuery } from '@apollo/client'; | ||||
| import { notification } from 'antd'; | ||||
|  | ||||
| import { NetworkTableContainer } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|   | ||||
| @@ -1,6 +1,6 @@ | ||||
| import React, { useMemo, useContext, useState } from 'react'; | ||||
| import { Switch, Route, useRouteMatch, Redirect } from 'react-router-dom'; | ||||
| import { useQuery, useMutation, useLazyQuery } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation, useLazyQuery } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import _ from 'lodash'; | ||||
| import { Network as NetworkPage, PopoverMenu, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|   | ||||
| @@ -1,7 +1,6 @@ | ||||
| import React, { useState, useContext } from 'react'; | ||||
| import { useParams, Redirect } from 'react-router-dom'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useQuery, useMutation } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation, gql } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import { ProfileDetails as ProfileDetailsPage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|  | ||||
|   | ||||
| @@ -1,6 +1,5 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useQuery, useMutation } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation, gql } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import { Profile as ProfilePage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|  | ||||
|   | ||||
| @@ -1,5 +1,5 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import { useQuery, useMutation } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import { AutoProvision as AutoProvisionPage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
|  | ||||
|   | ||||
| @@ -1,5 +1,5 @@ | ||||
| import React, { useContext } from 'react'; | ||||
| import { useQuery, useMutation } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation } from '@apollo/client'; | ||||
| import { Alert, notification } from 'antd'; | ||||
| import { BlockedList as BlockedListPage, Loading } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
| import { GET_BLOCKED_CLIENTS } from 'graphql/queries'; | ||||
|   | ||||
| @@ -1,5 +1,5 @@ | ||||
| import React from 'react'; | ||||
| import { useQuery, useMutation, useLazyQuery } from '@apollo/react-hooks'; | ||||
| import { useQuery, useMutation, useLazyQuery } from '@apollo/client'; | ||||
| import { notification } from 'antd'; | ||||
| import { | ||||
|   GET_ALL_FIRMWARE, | ||||
|   | ||||
| @@ -1,6 +1,5 @@ | ||||
| import React from 'react'; | ||||
| import gql from 'graphql-tag'; | ||||
| import { useMutation, useLazyQuery } from '@apollo/react-hooks'; | ||||
| import { useMutation, useLazyQuery, gql } from '@apollo/client'; | ||||
| import { notification } from 'antd'; | ||||
| import { Manufacturer as ManufacturerPage } from '@tip-wlan/wlan-cloud-ui-library'; | ||||
| import { OUI_UPLOAD } from 'graphql/mutations'; | ||||
|   | ||||
| @@ -1,4 +1,4 @@ | ||||
| import gql from 'graphql-tag'; | ||||
| import { gql } from '@apollo/client'; | ||||
|  | ||||
| export const REFRESH_TOKEN = gql` | ||||
|   mutation UpdateToken($refreshToken: String!) { | ||||
|   | ||||
| @@ -1,4 +1,4 @@ | ||||
| import gql from 'graphql-tag'; | ||||
| import { gql } from '@apollo/client'; | ||||
|  | ||||
| export const GET_ALL_LOCATIONS = gql` | ||||
|   query GetAllLocations($customerId: ID!) { | ||||
|   | ||||
| @@ -1,12 +1,10 @@ | ||||
| import React from 'react'; | ||||
| import ReactDOM from 'react-dom'; | ||||
| import { Router } from 'react-router-dom'; | ||||
| import { ApolloClient } from 'apollo-client'; | ||||
| import { InMemoryCache } from 'apollo-cache-inmemory'; | ||||
| import { onError } from 'apollo-link-error'; | ||||
| import { ApolloClient, ApolloProvider, ApolloLink, Observable } from '@apollo/client'; | ||||
| import { InMemoryCache } from '@apollo/client/cache'; | ||||
| import { onError } from '@apollo/client/link/error'; | ||||
| import { createUploadLink } from 'apollo-upload-client'; | ||||
| import { ApolloLink, Observable } from 'apollo-link'; | ||||
| import { ApolloProvider } from '@apollo/react-hooks'; | ||||
|  | ||||
| import 'styles/antd.less'; | ||||
| import 'styles/index.scss'; | ||||
|   | ||||
							
								
								
									
										5643
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										5643
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							| @@ -18,19 +18,12 @@ | ||||
|   "license": "MIT", | ||||
|   "dependencies": { | ||||
|     "@ant-design/icons": "^4.2.1", | ||||
|     "@apollo/react-hoc": "^3.1.4", | ||||
|     "@apollo/react-hooks": "^3.1.3", | ||||
|     "@apollo/client": "^3.1.3", | ||||
|     "@tip-wlan/wlan-cloud-ui-library": "^0.3.0", | ||||
|     "antd": "^4.5.2", | ||||
|     "apollo-cache-inmemory": "^1.6.6", | ||||
|     "apollo-client": "^2.6.10", | ||||
|     "apollo-link": "^1.2.14", | ||||
|     "apollo-link-error": "^1.1.13", | ||||
|     "apollo-link-http": "^1.5.17", | ||||
|     "apollo-upload-client": "^13.0.0", | ||||
|     "clean-webpack-plugin": "^3.0.0", | ||||
|     "graphql": "^14.6.0", | ||||
|     "graphql-tag": "^2.10.3", | ||||
|     "highcharts": "^8.1.1", | ||||
|     "highcharts-react-official": "^3.0.0", | ||||
|     "history": "^4.10.1", | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Hassan Azmi
					Hassan Azmi