Change invoker uri and remove headers

feature/appm-store/pbac
Jayasanka 5 years ago
parent 519cb16393
commit f3a4abb190

@ -8,7 +8,7 @@
"hostname": "localhost",
"httpsPort": "9443",
"invoker": {
"uri": "/ui-request-handler/invoke",
"uri": "/publisher-ui-request-handler/invoke",
"publisher": "/application-mgt-publisher/v1.0",
"store": "/application-mgt-store/v1.0",
"admin" : ""

@ -30,13 +30,9 @@ class DetailedRating extends React.Component{
}
getData = (type, uuid)=>{
console.log();
return axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.store+"/reviews/"+uuid+"/"+type+"-rating",
{
headers: { 'X-Platform': config.serverConfig.platform }
}).then(res => {
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/admin/reviews/"+uuid+"/"+type+"-rating",
).then(res => {
if (res.status === 200) {
let detailedRating = res.data.data;
this.setState({

@ -108,9 +108,7 @@ class AppsTable extends React.Component {
axios.post(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/applications",
data,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
let apps = [];

@ -31,7 +31,7 @@ class Reviews extends React.Component {
const {uuid, type} = this.props;
axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.store+"/reviews/"+type+"/"+uuid,
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/admin/reviews/"+type+"/"+uuid,
{
headers: {'X-Platform': config.serverConfig.platform}
}).then(res => {

@ -22,9 +22,7 @@ class ManageCategories extends React.Component {
componentDidMount() {
axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/applications/categories",
{
headers: { 'X-Platform': config.serverConfig.platform }
}).then(res => {
).then(res => {
if (res.status === 200) {
let categories = JSON.parse(res.data.data);
this.setState({
@ -59,9 +57,7 @@ class ManageCategories extends React.Component {
});
axios.delete(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/admin/applications/categories/"+id,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
notification["success"]({
@ -202,9 +198,7 @@ class ManageCategories extends React.Component {
axios.post(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/admin/applications/categories",
data,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
notification["success"]({
@ -267,9 +261,7 @@ class ManageCategories extends React.Component {
axios.put(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/admin/applications/categories/rename?from="+currentlyEditingId+"&to="+editingValue,
{},
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
notification["success"]({

@ -22,9 +22,7 @@ class ManageTags extends React.Component {
componentDidMount() {
axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/applications/tags",
{
headers: { 'X-Platform': config.serverConfig.platform }
}).then(res => {
).then(res => {
if (res.status === 200) {
let tags = JSON.parse(res.data.data);
this.setState({
@ -202,9 +200,7 @@ class ManageTags extends React.Component {
axios.post(config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/applications/tags",
data,
{
headers: { 'X-Platform': config.serverConfig.platform }
}).then(res => {
).then(res => {
if (res.status === 200) {
notification["success"]({
message: "Done!",
@ -266,9 +262,7 @@ class ManageTags extends React.Component {
axios.put(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.publisher+"/applications/tags/rename?from="+currentlyEditingId+"&to="+editingValue,
{},
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
notification["success"]({

@ -9,13 +9,13 @@
"httpsPort": "9443",
"invokerUri": "/ui-request-handler/invoke/application-mgt-store/v1.0",
"invoker": {
"uri": "/ui-request-handler/invoke",
"uri": "/store-ui-request-handler/invoke",
"publisher": "/application-mgt-publisher/v1.0",
"store": "/application-mgt-store/v1.0",
"admin" : "",
"deviceMgt" : "/device-mgt/v1.0"
},
"loginUri": "/ui-request-handler/login",
"loginUri": "/store-ui-request-handler/login",
"platform": "store"
},
"defaultPlatformIcons": {

@ -43,9 +43,7 @@ class AppList extends React.Component {
axios.post(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri + config.serverConfig.invoker.store+"/applications/",
payload,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
//todo remove this property check after backend improvement

@ -33,9 +33,7 @@ class DetailedRating extends React.Component{
return axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.store+"/reviews/"+uuid+"/"+type+"-rating",
{
headers: { 'X-Platform': config.serverConfig.platform }
}).then(res => {
).then(res => {
if (res.status === 200) {
let detailedRating = res.data.data;
this.setState({

@ -140,9 +140,7 @@ class DeviceInstall extends React.Component {
//send request to the invoker
axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri + config.serverConfig.invoker.deviceMgt+"devices?" + encodedExtraParams,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
const pagination = {...this.state.pagination};

@ -29,9 +29,7 @@ class GroupInstall extends React.Component {
axios.post(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri + config.serverConfig.invoker.deviceMgt+"/groups?name=" + value,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
if (fetchId !== this.lastFetchId) {

@ -29,9 +29,7 @@ class RoleInstall extends React.Component {
axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri + config.serverConfig.invoker.deviceMgt+"/roles?filter=" + value,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
if (fetchId !== this.lastFetchId) {

@ -31,9 +31,7 @@ class UserInstall extends React.Component {
//send request to the invoker
axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri + config.serverConfig.invoker.deviceMgt+"/users/search?username=" + value,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
if (fetchId !== this.lastFetchId) {

@ -57,9 +57,7 @@ class AddReview extends React.Component {
axios.post(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri +config.serverConfig.invoker.store+"/reviews/"+uuid,
payload,
{
headers: { 'X-Platform': config.serverConfig.platform }
}).then(res => {
).then(res => {
if (res.status === 201) {
this.setState({
loading: false,

@ -39,9 +39,7 @@ class Release extends React.Component {
//send request to the invoker
axios.get(
config.serverConfig.protocol + "://"+config.serverConfig.hostname + ':' + config.serverConfig.httpsPort + config.serverConfig.invoker.uri + config.serverConfig.invoker.store+"/applications/"+uuid,
{
headers: { 'X-Platform': config.serverConfig.platform }
}
).then(res => {
if (res.status === 200) {
let app = res.data.data;

Loading…
Cancel
Save