Skip to content

Commit

Permalink
Plugin (#1069)
Browse files Browse the repository at this point in the history
  • Loading branch information
matthew2564 authored Mar 9, 2023
1 parent b7d8d39 commit 0ba6819
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 3 deletions.
2 changes: 1 addition & 1 deletion config.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<widget id="uk.gov.dvsa.drivingexaminerservices" version="4.7.2.4" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<widget id="uk.gov.dvsa.drivingexaminerservices" version="4.7.2.5" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>DES</name>
<description>An application for DVSA driving examiners to conduct driving tests digitally</description>
<content src="index.html" />
Expand Down
4 changes: 2 additions & 2 deletions ios/App/App/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>4.7.2.4</string>
<string>4.7.2.5</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
Expand All @@ -30,7 +30,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>4.7.2.4</string>
<string>4.7.2.5</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>NSCameraUsageDescription</key>
Expand Down
1 change: 1 addition & 0 deletions ios/App/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ install! 'cocoapods', :disable_input_output_paths => true
def capacitor_pods
pod 'Capacitor', :path => '../../node_modules/@capacitor/ios'
pod 'CapacitorCordova', :path => '../../node_modules/@capacitor/ios'
pod 'CapacitorCommunityMdmAppconfig', :path => '../../node_modules/@capacitor-community/mdm-appconfig'
pod 'CapacitorSplashScreen', :path => '../../node_modules/@capacitor/splash-screen'
pod 'CapacitorStatusBar', :path => '../../node_modules/@capacitor/status-bar'
pod 'CapawesomeCapacitorManagedConfigurations', :path => '../../node_modules/@capawesome/capacitor-managed-configurations'
Expand Down
15 changes: 15 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@
"@awesome-cordova-plugins/network": "^6.2.0",
"@awesome-cordova-plugins/screen-orientation": "^6.2.0",
"@awesome-cordova-plugins/secure-storage": "^6.2.0",
"@capacitor-community/mdm-appconfig": "^4.0.5",
"@capacitor/cli": "^4.4.0",
"@capacitor/core": "^4.4.0",
"@capacitor/ios": "^4.4.0",
Expand Down
9 changes: 9 additions & 0 deletions src/app/providers/app-config/app-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { map, timeout } from 'rxjs/operators';
import { isEmpty, merge } from 'lodash';
import { ValidatorResult, ValidationError } from 'jsonschema';
import { IsDebug } from '@awesome-cordova-plugins/is-debug/ngx';
import { AppConfig as MDMAppConfig } from '@capacitor-community/mdm-appconfig';
import { GetResult, ManagedConfigurations } from '@capawesome/capacitor-managed-configurations';
import { Subscription } from 'rxjs';

Expand Down Expand Up @@ -125,6 +126,14 @@ export class AppConfigProvider {

public loadManagedConfig = async (): Promise<void> => {
this.logInfo('start loadManagedConfig');
const val = await MDMAppConfig
.getValue({ key: 'configUrl' })
.catch((error) => {
alert(`MDMAppConfig getValue: ${error}`);
return error;
});
this.logInfo(`new plugin configUrl: ${val}`);

const newEnvFile = {
production: false,
isRemote: true,
Expand Down

0 comments on commit 0ba6819

Please sign in to comment.