importing.js 421 B

123456789101112131415161718
  1. import App from '../base'
  2. App.controller(
  3. 'ImportingController',
  4. function ($interval, $scope, $timeout, $window) {
  5. $interval(function () {
  6. $scope.state.load_progress += 5
  7. if ($scope.state.load_progress > 100) {
  8. $scope.state.load_progress = 20
  9. }
  10. }, 500)
  11. $timeout(function () {
  12. $window.location.reload()
  13. }, 5000)
  14. $scope.state = {
  15. load_progress: 20,
  16. }
  17. }
  18. )