Skip to content

Commit

Permalink
build: v3.0.0-alpha
Browse files Browse the repository at this point in the history
  • Loading branch information
jevantang committed Mar 23, 2024
1 parent 3a54a8a commit 9f3e023
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 8 deletions.
6 changes: 3 additions & 3 deletions app/Helpers/AppHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@

class AppHelper
{
const VERSION = '2.21.4';
const VERSION_MD5 = 'aca1584a748aa60c88f0516d9325da01';
const VERSION_MD5_16BIT = '748aa60c88f0516d';
const VERSION = '3.0.0-alpha';
const VERSION_MD5 = '27c5d1414033d6d54692c0bf45ec33ce';
const VERSION_MD5_16BIT = '4033d6d54692c0bf';

// fresns test helper
public static function fresnsTestHelper(): mixed
Expand Down
12 changes: 9 additions & 3 deletions app/Utilities/AppUtility.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public static function newVersion(): array
];

try {
$versionInfoUrl = $baseUrl.'/v2/22/version.json';
$versionInfoUrl = $baseUrl.'/v3/version-1.json';
$client = new \GuzzleHttp\Client($options);
$response = $client->request('GET', $versionInfoUrl);
$versionInfo = json_decode($response->getBody(), true);
Expand Down Expand Up @@ -116,7 +116,7 @@ public static function fresnsNews(): array
];

try {
$newUrl = $baseUrl.'/v2/news.json';
$newUrl = $baseUrl.'/v3/news.json';
$client = new \GuzzleHttp\Client($options);
$response = $client->request('GET', $newUrl);
$news = json_decode($response->getBody(), true);
Expand Down Expand Up @@ -321,13 +321,16 @@ public static function getMarketHeaders(): array
'site_name',
'site_desc',
'site_copyright_name',
'language_status',
'language_menus',
'default_language',
]);

$isHttps = request()->getScheme() === 'https';

$siteName = base64_encode(json_encode($appConfig['site_name']));
$siteDesc = base64_encode(json_encode($appConfig['site_desc']));
$languageMenus = base64_encode(json_encode($appConfig['language_menus']));

return [
'X-Fresns-Panel-Lang-Tag' => App::getLocale(),
Expand All @@ -343,7 +346,10 @@ public static function getMarketHeaders(): array
'X-Fresns-Site-Name' => $siteName,
'X-Fresns-Site-Desc' => $siteDesc,
'X-Fresns-Site-Copyright-Name' => base64_encode($appConfig['site_copyright_name']),
'X-Fresns-Site-Language' => $appConfig['default_language'],
'X-Fresns-Site-Timezone' => config('app.timezone'),
'X-Fresns-Site-Language-Status' => $appConfig['language_status'],
'X-Fresns-Site-Language-Menus' => $languageMenus,
'X-Fresns-Site-Language-Default' => $appConfig['default_language'],
];
}
}
2 changes: 1 addition & 1 deletion fresns.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Fresns",
"version": "2.21.4",
"version": "3.0.0-alpha",
"license": "Apache-2.0",
"homepage": "https://fresns.org",
"plugins": {}
Expand Down
2 changes: 1 addition & 1 deletion public/status.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Fresns",
"version": "2.21.4",
"version": "3.0.0-alpha",
"activate": true,
"deactivateDescribe": {
"default": ""
Expand Down

0 comments on commit 9f3e023

Please sign in to comment.