A simple file sharing site with an easy to use API and online panel.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
469B

  1. const angular = require('angular');
  2. angular.module('StatSvc', []).service('StatService', ['$http', function($http) {
  3. this.getWeek = async () => {
  4. const res = await $http({
  5. method: 'GET',
  6. url: '/api/stats/week'
  7. });
  8. return res.data;
  9. };
  10. this.getAll = async () => {
  11. const res = await $http({
  12. method: 'GET',
  13. url: '/api/stats/all'
  14. });
  15. return res.data;
  16. }
  17. }]);