Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4f80cae

Browse files
authored
Merge pull requestlowcoder-org#741 from lowcoder-org/dev
Differentiate App URL Locations
2 parents92f3786 +617365e commit4f80cae

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

‎client/packages/lowcoder/src/constants/routesURL.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ export const PERMISSION_SETTING_DETAIL = `${PERMISSION_SETTING}/:groupId`;
2020
exportconstORGANIZATION_SETTING_DETAIL=`${ORGANIZATION_SETTING}/:orgId`;
2121

2222
exportconstALL_APPLICATIONS_URL="/apps";
23+
exportconstAPPLICATION_MARKETPLACE_URL=`https://app.lowcoder.cloud/apps`;
2324
exportconstMODULE_APPLICATIONS_URL="/apps/module";
2425
exportconstMARKETPLACE_URL=`/marketplace`;
2526
exportconstDATASOURCE_URL=`/datasource`;
@@ -48,6 +49,9 @@ export const MARKETPLACE_TYPE_URL = `${MARKETPLACE_URL}/:marketplaceType`;
4849
exportconstAPPLICATION_VIEW_URL=(appId:string,viewMode:AppViewMode)=>
4950
`${ALL_APPLICATIONS_URL}/${appId}/${viewMode}`;
5051

52+
exportconstAPPLICATION_MARKETPLACE_VIEW_URL=(appId:string,viewMode:AppViewMode)=>
53+
`${APPLICATION_MARKETPLACE_URL}/${appId}/${viewMode}`;
54+
5155
exportconstMARKETPLACE_URL_BY_TYPE=(type:MarketplaceType)=>
5256
`${MARKETPLACE_URL}/${type}`;
5357

‎client/packages/lowcoder/src/pages/ApplicationV2/MarketplaceResCard.tsx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -164,12 +164,8 @@ export function MarketplaceResCard(props: { res: HomeRes; }) {
164164
)}
165165
<CardInfo
166166
onClick={(e)=>{
167-
if(checkIsMobile(window.innerWidth)){
168-
history.push(APPLICATION_VIEW_URL(res.id,"view"));
169-
return;
170-
}
171167
if(res.isMarketplace){
172-
handleMarketplaceAppViewClick(res.id);
168+
handleMarketplaceAppViewClick(res.id,res.isLocalMarketplace);
173169
return;
174170
}
175171
}}
@@ -185,7 +181,7 @@ export function MarketplaceResCard(props: { res: HomeRes; }) {
185181
}
186182
</CardInfo>
187183
<OperationWrapper>
188-
<ExecButtononClick={()=>handleMarketplaceAppViewClick(res.id)}>
184+
<ExecButtononClick={()=>handleMarketplaceAppViewClick(res.id,res.isLocalMarketplace)}>
189185
{trans("view")}
190186
</ExecButton>
191187
</OperationWrapper>

‎client/packages/lowcoder/src/util/homeResUtils.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
NavDocIcon,
88
}from"lowcoder-design";
99
import{HomeResTypeEnum}from"../types/homeRes";
10-
import{APPLICATION_VIEW_URL,buildFolderUrl}from"../constants/routesURL";
10+
import{APPLICATION_VIEW_URL,APPLICATION_MARKETPLACE_VIEW_URL,buildFolderUrl}from"../constants/routesURL";
1111
importhistoryfrom"./history";
1212
import{trans}from"../i18n";
1313
import{FunctionComponent}from"react";
@@ -58,6 +58,6 @@ export const handleAppEditClick = (e: any, id: string): void => {
5858

5959
exportconsthandleAppViewClick=(id:string)=>window.open(APPLICATION_VIEW_URL(id,"view"));
6060

61-
exportconsthandleMarketplaceAppViewClick=(id:string)=>window.open(APPLICATION_VIEW_URL(id,"view_marketplace"));
61+
exportconsthandleMarketplaceAppViewClick=(id:string,isLocalMarketplace?:boolean)=>isLocalMarketplace==true ?window.open(APPLICATION_VIEW_URL(id,"view_marketplace")) :window.open(APPLICATION_MARKETPLACE_VIEW_URL(id,"view_marketplace"));
6262

6363
exportconsthandleFolderViewClick=(id:string)=>history.push(buildFolderUrl(id));

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp