Guest User

Untitled

a guest
Oct 25th, 2018
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.21 KB | None | 0 0
  1. {
  2. "name": "AppRestWS",
  3. "integrations": {
  4. "cordova": {}
  5. },
  6. "type": "ionic-angular",
  7. "proxies": [{
  8. "path": "/ws",
  9. "proxyUrl": "http://LicencesSoftware:83"
  10. }]
  11. }
  12.  
  13. Http Failure during parsing http://localhost:8080/ws/service/conect
  14.  
  15. http://LicensesSoftware:83/service/conect
  16.  
  17. import { HttpClient } from '@angular/common/http';
  18. import { Injectable } from '@angular/core';
  19. import { AlertController, Platform } from "ionic-angular";
  20. import 'rxjs/add/operator/map';
  21. import { HttpHeaders } from '@angular/common/http';
  22. import { Storage } from '@ionic/storage';
  23.  
  24. @Injectable()
  25. export class ServiceRestProvider {
  26.  
  27. constructor(public http: HttpClient,private alertCtrl: AlertController,
  28. private platform: Platform, private storage: Storage) {
  29. }
  30.  
  31. LoginApp(cod: string, user: string) {
  32. const body = JSON.stringify({
  33. Cod: cod,
  34. User: user
  35. });
  36.  
  37. const headers = new HttpHeaders().set('Access-Control-Allow-Origin', '*')
  38. .set('Access-Control-Allow-Methods', 'POST, GET, OPTIONS, PUT')
  39. .set('Accept', 'application/json')
  40. .set('Content-Type', 'application/json; charset=utf-8');
  41. return this.http.post('ws/service/conect', body, { headers: headers })
  42. .map((resp: any) => {
  43. console.log(resp);
  44. }, err => {
  45. console.log(err);
  46. }
  47. );
  48. }
  49. }
  50.  
  51. I/App: WARNING: Back Button Default Behavior will be overridden. The backbutton event will be fired!
  52. D/CordovaWebViewImpl: onPageFinished(http://localhost:8080/)
  53. D/SERVER: Handling local request: http://localhost:8080/assets/icon/favicon.ico
  54. D/SystemWebChromeClient: http://localhost:8080/build/main.js: Line 583 : null
  55. I/chromium: [INFO:CONSOLE(583)] "null", source: http://localhost:8080/build/main.js (583)
  56. D/libc: [NET] dns_sku:0
  57. D/libc: [NET] android_getaddrinfo_proxy get netid:0
  58. D/libc: [NET] android_getaddrinfo_proxy-, success
  59. D/SystemWebChromeClient: http://localhost:8080/: Line 0 : Access to XMLHttpRequest at 'http://LicensesSoftware:83/ws/conect' from origin 'http://localhost:8080' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.
  60. I/chromium: [INFO:CONSOLE(0)] "Access to XMLHttpRequest at 'http://LicensesSoftware:83/ws/conect' from origin 'http://localhost:8080' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.", source: http://localhost:8080/ (0)
  61. D/SystemWebChromeClient: http://localhost:8080/build/main.js: Line 713 : [object Object]
  62. I/chromium: [INFO:CONSOLE(713)] "[object Object]", source: http://localhost:8080/build/main.js (713)
  63. I/zygote64: Do partial code cache collection, code=60KB, data=53KB
  64. I/zygote64: After code cache collection, code=60KB, data=53KB
  65. Increasing code cache capacity to 256KB
  66. I/zygote64: Compiler allocated 7MB to compile void android.view.ViewRootImpl.performTraversals()
  67. Application terminated.
  68.  
  69. <?xml version='1.0' encoding='utf-8'?>
  70. <widget id="io.ionic.starter" version="0.0.1" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
  71. <name>ProyectoTi</name>
  72. <description>An awesome Ionic/Cordova app.</description>
  73. <author email="hi@ionicframework" href="http://ionicframework.com/">Ionic Framework Team</author>
  74. <content src="index.html" />
  75. <access origin="*" />
  76. <allow-intent href="http://*/*" />
  77. <allow-intent href="https://*/*" />
  78. <allow-intent href="tel:*" />
  79. <allow-intent href="sms:*" />
  80. <allow-intent href="mailto:*" />
  81. <allow-intent href="geo:*" />
  82. <preference name="ScrollEnabled" value="false" />
  83. <preference name="android-minSdkVersion" value="19" />
  84. <preference name="android-targetSdkVersion" value="19" />
  85. <preference name="BackupWebStorage" value="none" />
  86. <preference name="SplashMaintainAspectRatio" value="true" />
  87. <preference name="FadeSplashScreenDuration" value="300" />
  88. <preference name="SplashShowOnlyFirstTime" value="false" />
  89. <preference name="SplashScreen" value="none" />
  90. <preference name="SplashScreenDelay" value="3000" />
  91. <platform name="android">
  92. <allow-intent href="market:*" />
  93. <icon density="ldpi" src="resources/android/icon/drawable-ldpi-icon.png" />
  94. <icon density="mdpi" src="resources/android/icon/drawable-mdpi-icon.png" />
  95. <icon density="hdpi" src="resources/android/icon/drawable-hdpi-icon.png" />
  96. <icon density="xhdpi" src="resources/android/icon/drawable-xhdpi-icon.png" />
  97. <icon density="xxhdpi" src="resources/android/icon/drawable-xxhdpi-icon.png" />
  98. <icon density="xxxhdpi" src="resources/android/icon/drawable-xxxhdpi-icon.png" />
  99. <splash density="land-ldpi" src="resources/android/splash/drawable-land-ldpi-screen.png" />
  100. <splash density="land-mdpi" src="resources/android/splash/drawable-land-mdpi-screen.png" />
  101. <splash density="land-hdpi" src="resources/android/splash/drawable-land-hdpi-screen.png" />
  102. <splash density="land-xhdpi" src="resources/android/splash/drawable-land-xhdpi-screen.png" />
  103. <splash density="land-xxhdpi" src="resources/android/splash/drawable-land-xxhdpi-screen.png" />
  104. <splash density="land-xxxhdpi" src="resources/android/splash/drawable-land-xxxhdpi-screen.png" />
  105. <splash density="port-ldpi" src="resources/android/splash/drawable-port-ldpi-screen.png" />
  106. <splash density="port-mdpi" src="resources/android/splash/drawable-port-mdpi-screen.png" />
  107. <splash density="port-hdpi" src="resources/android/splash/drawable-port-hdpi-screen.png" />
  108. <splash density="port-xhdpi" src="resources/android/splash/drawable-port-xhdpi-screen.png" />
  109. <splash density="port-xxhdpi" src="resources/android/splash/drawable-port-xxhdpi-screen.png" />
  110. <splash density="port-xxxhdpi" src="resources/android/splash/drawable-port-xxxhdpi-screen.png" />
  111. </platform>
  112. <platform name="ios">
  113. <allow-intent href="itms:*" />
  114. <allow-intent href="itms-apps:*" />
  115. <icon height="57" src="resources/ios/icon/icon.png" width="57" />
  116. <icon height="114" src="resources/ios/icon/icon@2x.png" width="114" />
  117. <icon height="40" src="resources/ios/icon/icon-40.png" width="40" />
  118. <icon height="80" src="resources/ios/icon/icon-40@2x.png" width="80" />
  119. <icon height="120" src="resources/ios/icon/icon-40@3x.png" width="120" />
  120. <icon height="50" src="resources/ios/icon/icon-50.png" width="50" />
  121. <icon height="100" src="resources/ios/icon/icon-50@2x.png" width="100" />
  122. <icon height="60" src="resources/ios/icon/icon-60.png" width="60" />
  123. <icon height="120" src="resources/ios/icon/icon-60@2x.png" width="120" />
  124. <icon height="180" src="resources/ios/icon/icon-60@3x.png" width="180" />
  125. <icon height="72" src="resources/ios/icon/icon-72.png" width="72" />
  126. <icon height="144" src="resources/ios/icon/icon-72@2x.png" width="144" />
  127. <icon height="76" src="resources/ios/icon/icon-76.png" width="76" />
  128. <icon height="152" src="resources/ios/icon/icon-76@2x.png" width="152" />
  129. <icon height="167" src="resources/ios/icon/icon-83.5@2x.png" width="167" />
  130. <icon height="29" src="resources/ios/icon/icon-small.png" width="29" />
  131. <icon height="58" src="resources/ios/icon/icon-small@2x.png" width="58" />
  132. <icon height="87" src="resources/ios/icon/icon-small@3x.png" width="87" />
  133. <icon height="1024" src="resources/ios/icon/icon-1024.png" width="1024" />
  134. <splash height="1136" src="resources/ios/splash/Default-568h@2x~iphone.png" width="640" />
  135. <splash height="1334" src="resources/ios/splash/Default-667h.png" width="750" />
  136. <splash height="2208" src="resources/ios/splash/Default-736h.png" width="1242" />
  137. <splash height="1242" src="resources/ios/splash/Default-Landscape-736h.png" width="2208" />
  138. <splash height="1536" src="resources/ios/splash/Default-Landscape@2x~ipad.png" width="2048" />
  139. <splash height="2048" src="resources/ios/splash/Default-Landscape@~ipadpro.png" width="2732" />
  140. <splash height="768" src="resources/ios/splash/Default-Landscape~ipad.png" width="1024" />
  141. <splash height="2048" src="resources/ios/splash/Default-Portrait@2x~ipad.png" width="1536" />
  142. <splash height="2732" src="resources/ios/splash/Default-Portrait@~ipadpro.png" width="2048" />
  143. <splash height="1024" src="resources/ios/splash/Default-Portrait~ipad.png" width="768" />
  144. <splash height="960" src="resources/ios/splash/Default@2x~iphone.png" width="640" />
  145. <splash height="480" src="resources/ios/splash/Default~iphone.png" width="320" />
  146. <splash height="2732" src="resources/ios/splash/Default@2x~universal~anyany.png" width="2732" />
  147. </platform>
  148. <plugin name="cordova-plugin-whitelist" spec="1.3.3" />
  149. <plugin name="cordova-plugin-statusbar" spec="2.4.2" />
  150. <plugin name="cordova-plugin-device" spec="2.0.2" />
  151. <plugin name="cordova-plugin-ionic-webview" spec="^2.0.0" />
  152. <plugin name="cordova-plugin-ionic-keyboard" spec="^2.0.5" />
  153. <plugin name="cordova-plugin-splashscreen" spec="5.0.2" />
  154. <engine name="android" spec="7.1.1" />
  155. </widget>
Add Comment
Please, Sign In to add comment