diff --git a/app/build.gradle b/app/build.gradle index fc16bbe..0645ae4 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -4,7 +4,7 @@ android { compileSdkVersion 29 buildToolsVersion "29.0.2" defaultConfig { - applicationId "com.finogeeks.mop.demo" + applicationId "com.finogeeks.finclip.demo" minSdkVersion 19 targetSdkVersion 29 versionCode 1 @@ -13,9 +13,9 @@ android { multiDexEnabled true - buildConfigField "String", "APP_KEY", "\"22LyZEib0gLTQdU3MUauAVUHSFDdTToYDWCqr0AgPGwA\"" + buildConfigField "String", "APP_KEY", "\"22LyZEib0gLTQdU3MUauATBwgfnTCJjdr7FCnywmAEM=\"" // App Secret - buildConfigField "String", "APP_SECRET", "\"8c5c3c26420b7e66\"" + buildConfigField "String", "APP_SECRET", "\"bdfd76cae24d4313\"" // API服务地址 buildConfigField "String", "API_URL", "\"https://mp.finogeeks.com\"" // API服务前缀 diff --git a/app/src/main/java/com/finogeeks/mop/demo/MainActivity.java b/app/src/main/java/com/finogeeks/mop/demo/MainActivity.java index 10a56a5..7b04ffc 100644 --- a/app/src/main/java/com/finogeeks/mop/demo/MainActivity.java +++ b/app/src/main/java/com/finogeeks/mop/demo/MainActivity.java @@ -1,6 +1,7 @@ package com.finogeeks.mop.demo; import android.os.Bundle; +import android.view.View; import android.widget.Button; import androidx.appcompat.app.AppCompatActivity; @@ -20,17 +21,20 @@ public class MainActivity extends AppCompatActivity { Toolbar toolbar = findViewById(R.id.toolbar); setSupportActionBar(toolbar); - Button canvasButton = findViewById(R.id.btnCanvas); Button demoButton = findViewById(R.id.btnDemo); - Button profileButton = findViewById(R.id.btnProfile); - canvasButton.setOnClickListener(v -> { - Map startParams = new HashMap<>(); - startParams.put("path", "/pages/index/index"); - FinAppClient.INSTANCE.getAppletApiManager().startApplet(MainActivity.this, "5ea03fa563cb900001d73863", startParams); + demoButton.setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + FinAppClient.INSTANCE.getAppletApiManager().startApplet(MainActivity.this, "5fa214a29a6a7900019b5cc1"); + } }); - demoButton.setOnClickListener(v -> FinAppClient.INSTANCE.getAppletApiManager().startApplet(MainActivity.this, "5ea0401463cb900001d73865")); - - profileButton.setOnClickListener(v -> FinAppClient.INSTANCE.getAppletApiManager().startApplet(MainActivity.this, "5ea0412663cb900001d73867")); + Button profileButton = findViewById(R.id.btnProfile); + profileButton.setOnClickListener(new View.OnClickListener() { + @Override + public void onClick(View v) { + FinAppClient.INSTANCE.getAppletApiManager().startApplet(MainActivity.this, "5fa215459a6a7900019b5cc3"); + } + }); } } \ No newline at end of file diff --git a/app/src/main/java/com/finogeeks/mop/demo/MopApplication.java b/app/src/main/java/com/finogeeks/mop/demo/MopApplication.java index b94b0ac..82a3465 100644 --- a/app/src/main/java/com/finogeeks/mop/demo/MopApplication.java +++ b/app/src/main/java/com/finogeeks/mop/demo/MopApplication.java @@ -25,12 +25,11 @@ public class MopApplication extends MultiDexApplication { FinAppConfig.UIConfig uiConfig = new FinAppConfig.UIConfig(); uiConfig.setHideNavigationBarCloseButton(true); FinAppConfig config = new FinAppConfig.Builder() - .setAppKey(BuildConfig.APP_KEY) - .setAppSecret(BuildConfig.APP_SECRET) + .setSdkKey(BuildConfig.APP_KEY) + .setSdkSecret(BuildConfig.APP_SECRET) .setApiUrl(BuildConfig.API_URL) .setApiPrefix(BuildConfig.API_PREFIX) .setDebugMode(BuildConfig.DEBUG) - .setGlideWithJWT(false) .setUiConfig(uiConfig) .setEncryptionType(FinAppConfig.ENCRYPTION_TYPE_SM) .build(); diff --git a/app/src/main/res/layout/content_main.xml b/app/src/main/res/layout/content_main.xml index f13da32..241487d 100644 --- a/app/src/main/res/layout/content_main.xml +++ b/app/src/main/res/layout/content_main.xml @@ -8,43 +8,25 @@ tools:context=".MainActivity" tools:showIn="@layout/activity_main"> -