'use strict';
					
/* Services */

// Demonstrate how to register services
// In this case it is a simple value service.
//angular.module('mftApp.services', []).
  //value('version', '0.1');

//var Item = $resource( 'App/Details/:AppId', { AppId: '@id' } );

//var item = Item.get({ id: 1 }, function( data ) {
    //data.setAnothervalue = 'fake value';
    //data.$save();
//);

//Feeds Services
//var feedServices = angular.module('feedServices', ['ngResource']);

	mftApp.factory('Feed', ['$resource', function($resource) { 
		//var getFeed = $resource('JSON/feeds.json', {id:'@id', status:'@status', interface:'@interface'},
		var getFeed = $resource('http://dev.bigcompass.com\:2222/rest/AaronL/Feeds/:id', {id:'@id', status:'@status', interface:'@interface'}, 
		{ post: {method: 'POST'}, 
		get: {method: 'GET'}, 
		update: {method:'PUT'}, 
		query: {method:'GET', isArray:true, headers: {'Content-Type': 'application/json'}}});
		
		//Ajax Call
		$.ajax({
		    url: "http://dev.bigcompass.com:2222/rest/AaronL/Feeds/",
		    success: function(reports){

		        var global = reports;
				// Create x2js instance with default config
				var x2js = new X2JS();
				var xmlText = global;
				var jsonObj = x2js.xml_str2json( xmlText );
		        return global;
				return jsonObj;
				console.log(jsonObj);
				console.log(global);
				$scope.jsonString = findJSON;
				console.log($scope.jsonString);
		        }
		    });
		var x2js = new X2JS();
		var xmlText = getFeed;
		var jsonObj = x2js.xml_str2json( xmlText );
		return jsonObj;
	}]);

//Comment Services

//var commentServices = angular.module('commentServices', ['ngResource']);

  mftApp.factory('Comment', ['$resource', function($resource) {
    var getComment = $resource('JSON/comments.json', {id: '@id'}, 
		{ post: {method: 'POST'}, get: {method: 'GET'}, update: {method:'PUT'} });	
	return getComment;
  }]);







@@ -951,487 +951,8 @@
 all%0A
-%09%09$.ajax(%7B%0A%09%09    url: %22http://dev.bigcompass.com:2222/rest/AaronL/Feeds/%22,%0A%09%09    success: function(reports)%7B%0A%0A%09%09        var global = reports;%0A%09%09%09%09// Create x2js instance with default config%0A%09%09%09%09var x2js = new X2JS();%0A%09%09%09%09var xmlText = global;%0A%09%09%09%09var jsonObj = x2js.xml_str2json( xmlText );%0A%09%09        return global;%0A%09%09%09%09return jsonObj;%0A%09%09%09%09console.log(jsonObj);%0A%09%09%09%09console.log(global);%0A%09%09%09%09$scope.jsonString = findJSON;%0A%09%09%09%09console.log($scope.jsonString);%0A%09%09        %7D%0A%09%09    %7D);%0A
 %09%09va
@@ -972,16 +972,16 @@
 X2JS();%0A
+
 %09%09var xm
@@ -1045,22 +1045,25 @@
 xt );%0A%09%09
-return
+getFeed =
  jsonObj
@@ -1064,16 +1064,34 @@
 sonObj;%0A
+%09%09return getFeed;%0A
 %09%7D%5D);%0A%0A/

Convert XML to JSON