浏览代码

Broke apart the resource path in preparation of dynamic realms and guilds.

bmallred 13 年之前
父节点
当前提交
9adbf06694
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      armory.js

+ 2 - 2
armory.js

1
angular.module('WowArmory', ['ngResource']);
1
angular.module('WowArmory', ['ngResource']);
2
2
3
function ArmoryController($scope, $resource) {
3
function ArmoryController($scope, $resource) {
4
    $scope.armory = $resource('//us.battle.net/api/wow/guild/hellscream/:action', 
5
        { action: 'alkaline', fields: 'members', jsonp: 'angular.callbacks._0' }, 
4
    $scope.armory = $resource('//:server/api/wow/guild/:realm/:guild', 
5
        { server: 'us.battle.net', realm: 'alkaline', guild: 'alkaline', fields: 'members', jsonp: 'angular.callbacks._0' }, 
6
        { query: { method: 'JSONP' }});
6
        { query: { method: 'JSONP' }});
7
7
8
    $scope.Guild = $scope.armory.get();
8
    $scope.Guild = $scope.armory.get();