liukai 2 rokov pred
rodič
commit
e482395efb

+ 1 - 0
app/build.gradle

@@ -17,4 +17,5 @@ dependencies {
     implementation project(':cpt_main')
     implementation project(':cpt_parttime')
     implementation project(':cpt_ewallet')
+    implementation project(':cpt_rewards')
 }

+ 1 - 0
cpt_rewards/.gitignore

@@ -0,0 +1 @@
+/build

+ 5 - 0
cpt_rewards/build.gradle

@@ -0,0 +1,5 @@
+apply from: "../module_default_config.gradle"
+
+dependencies {
+
+}

+ 21 - 0
cpt_rewards/proguard-rules.pro

@@ -0,0 +1,21 @@
+# Add project specific ProGuard rules here.
+# You can control the set of applied configuration files using the
+# proguardFiles setting in build.gradle.
+#
+# For more details, see
+#   http://developer.android.com/guide/developing/tools/proguard.html
+
+# If your project uses WebView with JS, uncomment the following
+# and specify the fully qualified class name to the JavaScript interface
+# class:
+#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
+#   public *;
+#}
+
+# Uncomment this to preserve the line number information for
+# debugging stack traces.
+#-keepattributes SourceFile,LineNumberTable
+
+# If you keep the line number information, uncomment this to
+# hide the original source file name.
+#-renamesourcefileattribute SourceFile

+ 26 - 0
cpt_rewards/src/androidTest/java/com/hongyegroup/cpt_main/ExampleInstrumentedTest.java

@@ -0,0 +1,26 @@
+package com.hongyegroup.cpt_main;
+
+import android.content.Context;
+
+import androidx.test.platform.app.InstrumentationRegistry;
+import androidx.test.ext.junit.runners.AndroidJUnit4;
+
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import static org.junit.Assert.*;
+
+/**
+ * Instrumented test, which will execute on an Android device.
+ *
+ * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
+ */
+@RunWith(AndroidJUnit4.class)
+public class ExampleInstrumentedTest {
+    @Test
+    public void useAppContext() {
+        // Context of the app under test.
+        Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
+        assertEquals("com.hongyegroup.cpt_parttime", appContext.getPackageName());
+    }
+}

+ 11 - 0
cpt_rewards/src/main/AndroidManifest.xml

@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.hongyegroup.cpt_profile">
+
+    <application android:allowBackup="true">
+
+
+
+    </application>
+
+</manifest>

+ 20 - 0
cpt_rewards/src/main/java/com/hongyegroup/cpt_rewards/router/RewardsComponentServiceImpl.kt

@@ -0,0 +1,20 @@
+package com.hongyegroup.cpt_rewards.router
+
+import android.content.Context
+import com.alibaba.android.arouter.facade.annotation.Route
+import com.guadou.cs_router.ARouterPath
+import com.guadou.cs_router.rewards.IRewardsComponentServer
+
+@Route(path = ARouterPath.PATH_SERVICE_REWARDS, name = "Rewards模块路由服务")
+class RewardsComponentServiceImpl : IRewardsComponentServer {
+
+    override fun startRewardsMainPage() {
+    }
+
+    override fun startRewardsDailyPage() {
+    }
+
+    override fun init(context: Context?) {
+    }
+
+}

+ 17 - 0
cpt_rewards/src/test/java/com/hongyegroup/cpt_main/ExampleUnitTest.java

@@ -0,0 +1,17 @@
+package com.hongyegroup.cpt_main;
+
+import org.junit.Test;
+
+import static org.junit.Assert.*;
+
+/**
+ * Example local unit test, which will execute on the development machine (host).
+ *
+ * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
+ */
+public class ExampleUnitTest {
+    @Test
+    public void addition_isCorrect() {
+        assertEquals(4, 2 + 2);
+    }
+}

+ 3 - 0
cs_router/src/main/java/com/guadou/cs_router/ARouterPath.java

@@ -27,6 +27,9 @@ public class ARouterPath {
     //EWallet模块路由服务Path
     public static final String PATH_SERVICE_WALLET = "/wallet/path/service";
 
+    //Rewards模块路由服务Path
+    public static final String PATH_SERVICE_REWARDS = "/rewards/path/service";
+
     //Service模块路由服务Path
     public static final String PATH_SERVICE_SERVER = "/service/path/service";
 

+ 3 - 0
cs_router/src/main/java/com/guadou/cs_router/YYRouterService.kt

@@ -6,6 +6,7 @@ import com.guadou.cs_router.auth.IAuthComponentServer
 import com.guadou.cs_router.ewallet.IEWalletComponentServer
 import com.guadou.cs_router.main.IMainComponentServer
 import com.guadou.cs_router.parttime.IParttimeComponentServer
+import com.guadou.cs_router.rewards.IRewardsComponentServer
 import com.guadou.cs_router.service.IServiceComponentServer
 
 
@@ -21,6 +22,8 @@ object YYRouterService {
 
     var eWalletComponentServer: IEWalletComponentServer? = ARouter.getInstance().navigation(IEWalletComponentServer::class.java)
 
+    var rewardsComponentServer: IRewardsComponentServer? = ARouter.getInstance().navigation(IRewardsComponentServer::class.java)
+
     var serviceComponentServer: IServiceComponentServer? = ARouter.getInstance().navigation(IServiceComponentServer::class.java)
 
 }

+ 11 - 0
cs_router/src/main/java/com/guadou/cs_router/rewards/IRewardsComponentServer.kt

@@ -0,0 +1,11 @@
+package com.guadou.cs_router.rewards
+
+import com.alibaba.android.arouter.facade.template.IProvider
+
+interface IRewardsComponentServer : IProvider {
+
+    fun startRewardsMainPage()
+
+    fun startRewardsDailyPage()
+
+}

+ 1 - 0
settings.gradle

@@ -25,6 +25,7 @@ include ':app',
         ':cpt_main',
         ':cpt_parttime',
         ':cpt_ewallet',
+        ':cpt_rewards',
 
         ':lib_xpopup',