|
|
|
@ -55,7 +55,7 @@ class AppDetailsDrawer extends React.Component {
|
|
|
|
|
super(props);
|
|
|
|
|
this.state = {
|
|
|
|
|
loading: false,
|
|
|
|
|
name: null,
|
|
|
|
|
name: "",
|
|
|
|
|
description: null,
|
|
|
|
|
globalCategories: [],
|
|
|
|
|
globalTags: [],
|
|
|
|
@ -406,6 +406,36 @@ class AppDetailsDrawer extends React.Component {
|
|
|
|
|
if (app == null) {
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
let avatar = null;
|
|
|
|
|
|
|
|
|
|
if (app.applicationReleases.length === 0) {
|
|
|
|
|
const avatarLetter = name.charAt(0).toUpperCase();
|
|
|
|
|
avatar = (
|
|
|
|
|
<Avatar shape="square"
|
|
|
|
|
size={100}
|
|
|
|
|
style={{
|
|
|
|
|
marginBottom: 10,
|
|
|
|
|
borderRadius: "28%",
|
|
|
|
|
backgroundColor: pSBC(0.50, config.theme.primaryColor)
|
|
|
|
|
}}>
|
|
|
|
|
{avatarLetter}
|
|
|
|
|
</Avatar>
|
|
|
|
|
);
|
|
|
|
|
} else {
|
|
|
|
|
avatar = (
|
|
|
|
|
<img
|
|
|
|
|
style={{
|
|
|
|
|
marginBottom: 10,
|
|
|
|
|
width: 100,
|
|
|
|
|
borderRadius: "28%",
|
|
|
|
|
border: "1px solid #ddd"
|
|
|
|
|
}}
|
|
|
|
|
src={app.applicationReleases[0].iconPath}
|
|
|
|
|
/>
|
|
|
|
|
)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<div>
|
|
|
|
|
<Drawer
|
|
|
|
@ -417,15 +447,7 @@ class AppDetailsDrawer extends React.Component {
|
|
|
|
|
>
|
|
|
|
|
<Spin spinning={loading} delay={500}>
|
|
|
|
|
<div style={{textAlign: "center"}}>
|
|
|
|
|
<img
|
|
|
|
|
style={{
|
|
|
|
|
marginBottom: 10,
|
|
|
|
|
width: 100,
|
|
|
|
|
borderRadius: "28%",
|
|
|
|
|
border: "1px solid #ddd"
|
|
|
|
|
}}
|
|
|
|
|
src={app.applicationReleases[0].iconPath}
|
|
|
|
|
/>
|
|
|
|
|
{avatar}
|
|
|
|
|
<Title editable={{onChange: this.handleNameSave}} level={2}>{name}</Title>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
@ -436,8 +458,8 @@ class AppDetailsDrawer extends React.Component {
|
|
|
|
|
{(app.type === "ENTERPRISE") && (
|
|
|
|
|
<Link to={`/publisher/apps/${app.id}/add-release`}><Button htmlType="button" size="small">Add
|
|
|
|
|
new release</Button></Link>)}
|
|
|
|
|
<br/>
|
|
|
|
|
<List
|
|
|
|
|
style={{paddingTop: 16}}
|
|
|
|
|
grid={{gutter: 16, column: 2}}
|
|
|
|
|
dataSource={app.applicationReleases}
|
|
|
|
|
renderItem={release => (
|
|
|
|
@ -596,8 +618,8 @@ class AppDetailsDrawer extends React.Component {
|
|
|
|
|
)}
|
|
|
|
|
|
|
|
|
|
<Divider dashed={true}/>
|
|
|
|
|
|
|
|
|
|
<DetailedRating type="app" uuid={app.applicationReleases[0].uuid}/>
|
|
|
|
|
{app.applicationReleases.length > 0 && (
|
|
|
|
|
<DetailedRating type="app" uuid={app.applicationReleases[0].uuid}/>)}
|
|
|
|
|
</Spin>
|
|
|
|
|
</Drawer>
|
|
|
|
|
</div>
|
|
|
|
|