最新一次版本提交

This commit is contained in:
xuhuixiang
2026-01-06 16:16:49 +08:00
parent 08d67f0fed
commit 17b41fc9bf
5966 changed files with 219734 additions and 1598 deletions

View File

@@ -8,7 +8,7 @@ android {
buildToolsVersion "30.0.3"
defaultConfig {
applicationId "com.web.cergas"
applicationId "com.web.cergas36"
minSdkVersion 24
targetSdkVersion 31
versionCode rootProject.ext.versionCode

View File

@@ -1,21 +1,21 @@
{
"project_info": {
"project_number": "773432010162",
"project_id": "cergas999-c8b99",
"storage_bucket": "cergas999-c8b99.firebasestorage.app"
"project_number": "111534832614",
"project_id": "cergas36",
"storage_bucket": "cergas36.firebasestorage.app"
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:773432010162:android:7721474e224398963bb0ab",
"mobilesdk_app_id": "1:111534832614:android:62f8b7180ed63432757427",
"android_client_info": {
"package_name": "com.web.cergas"
"package_name": "com.web.cergas36"
}
},
"oauth_client": [],
"api_key": [
{
"current_key": "AIzaSyCysVxeDJd9W_ZFA_O5-ruQbSf2BHqhTUs"
"current_key": "AIzaSyBxKCY4RL1Zsz9Hvyi9EeRA5TLFDaV9CPE"
}
],
"services": {

View File

@@ -87,7 +87,7 @@
<!-- android:directBootAware="true" 为应用启用消息处理直接启动模式-->
<service
android:name=".MyFirebaseMessageingService"
android:exported="false">
android:exported="true">
<intent-filter>
<action android:name="com.google.firebase.MESSAGING_EVENT" />
</intent-filter>

View File

@@ -10,6 +10,7 @@ import androidx.annotation.NonNull;
import com.google.android.gms.tasks.OnCompleteListener;
import com.google.android.gms.tasks.Task;
import com.google.firebase.messaging.FirebaseMessaging;
import com.web.base.LogUtils;
import com.web.base.MainActivity;
public class MainActivity2 extends com.web.base.MainActivity2 {
@@ -20,8 +21,17 @@ public class MainActivity2 extends com.web.base.MainActivity2 {
saveInt(MainActivity2.this,"user_code",userId);
saveInt(MainActivity2.this,"version_code",getVersion());
MainActivity.saveString(this, "base_url","https://cergas.online/");
//网页的底部NavigationBar颜色
com.web.base.MainActivity.saveString(this, "style_color", "#7a4f2f");
//页面的大背景颜色
com.web.base.MainActivity.saveString(this, "windows_color", "#272727");
//任务栏的文字颜色 0 黑 1白 默认黑
saveInt(MainActivity2.this,"is_white",1);
super.onCreate(savedInstanceState);
//用于修改大背景渐变色 不设置 大背景就是 windows_color 的颜色
setBackDrawables(R.drawable.big_bg);
setImageView(true);
// showTopV1.setImageResource(R.mipmap.start_gifs);
//订阅主题
FirebaseMessaging.getInstance().subscribeToTopic("demo")
.addOnCompleteListener(new OnCompleteListener<Void>() {
@@ -31,7 +41,7 @@ public class MainActivity2 extends com.web.base.MainActivity2 {
if (!task.isSuccessful()) {
msg = "Subscribe failed";
}
LogUtils.i("结果:"+msg);
}
});
}

View File

@@ -83,14 +83,14 @@ public class MyFirebaseMessageingService extends FirebaseMessagingService {
channelwinway.enableVibration(true);
notificationManager.createNotificationChannel(channelwinway);
notificationBuilder = new NotificationCompat.Builder(this, channelwinway.getId())
.setSmallIcon(com.web.base.R.mipmap.ic_launcher)
.setSmallIcon(R.mipmap.app_logo)
.setContentTitle(messageInfo.getTitle())
.setContentText(messageInfo.getContent())
.setAutoCancel(true)
.setContentIntent(pendingIntent);
} else {
notificationBuilder = new NotificationCompat.Builder(this, getString(com.web.base.R.string.app_name))
.setSmallIcon(com.web.base.R.mipmap.ic_launcher)
.setSmallIcon(R.mipmap.app_logo)
.setContentTitle(messageInfo.getTitle())
.setContentText(messageInfo.getContent())
.setAutoCancel(true)
@@ -129,14 +129,14 @@ public class MyFirebaseMessageingService extends FirebaseMessagingService {
channelwinway.enableVibration(true);
notificationManager.createNotificationChannel(channelwinway);
notificationBuilder = new NotificationCompat.Builder(this, channelwinway.getId())
.setSmallIcon(com.web.base.R.mipmap.ic_launcher)
.setSmallIcon(R.mipmap.app_logo)
.setContentTitle(title)
.setContentText(body)
.setAutoCancel(true)
.setContentIntent(pendingIntent);
} else {
notificationBuilder = new NotificationCompat.Builder(this, getString(com.web.base.R.string.app_name))
.setSmallIcon(com.web.base.R.mipmap.ic_launcher)
.setSmallIcon(R.mipmap.app_logo)
.setContentTitle(title)
.setContentText(body)
.setAutoCancel(true)

View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:angle="270"
android:startColor="#272727"
android:endColor="#7a4f2f"/>
</shape>

View File

@@ -9,6 +9,7 @@
<color name="white">#FFFFFFFF</color>
<color name="jisuanqi">#EF4723</color>
<color name="notify_color">#FFFFFFFF</color>
<color name="main_color">#7a4f2f</color>
<color name="dialog_bg">#2C2C2E</color>
<color name="dialog_textcolor">#FFA722</color>

View File

@@ -64,7 +64,7 @@
<!-- <item name="android:windowBackground">@drawable/splah_bg</item>-->
<item name="android:windowBackground">@color/white</item>
<item name="android:navigationBarColor">@color/white</item>
<item name="android:navigationBarColor">@color/main_color</item>
<!-- <item name="android:windowBackground">@mipmap/big_bg</item>-->
<item name="android:forceDarkAllowed" tools:ignore="NewApi">false</item>
</style>