I have an app in Agile Central App SDK 2.1 that has been working fine iterating through a bunch or Projects to get Release details. I have just added a three new projects to it, 2 of them work and one of them causes an error:
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at
https://rally1.rallydev.com/slm/webservice/v2.0/Project/202236741040?fetch=ObjectID%2CName%2CState%2CWorkspace%2CSchemaVersion%2CWorkspaceConfiguration%2CDateFormat%2CDateTimeFormat%2CDragDropRankingEnabled%2CBuildandChangesetEnabled%2CTimeZone%2CWorkDays%2CIterationEstimateUnitName%2CReleaseEstimateUnitName%2CTaskUnitName%2CChildren.
(Reason: CORS header ‘Access-Control-Allow-Origin’ missing).
What is bizarre is that if I cut the exact URL out of that error message and paste that into a browser I get a proper result as expected, with no errors, warning and definitely no CORS issues.
If I change the ObjectID to another known good one I get exactly the same JSON payload except with different Project Name,. On other words, it works if I put the URL into the browser, but errors with the CORS error if called through 'Rally.data.wsapi.Store'.
I have tried to make this as simple an app as possible, but still does the same :(
Ext.create('Rally.data.wsapi.Store', {
model: 'release',
fetch: ['Name'],
autoLoad: true,
context: {
project: "/project/202236741040"
},
listeners: {
load: function(store, records) {
console.log(records);
}
},
scope: this
});