修改共建工具地址

This commit is contained in:
黄心宇 2026-01-07 17:10:31 +08:00
parent c33fa34be9
commit 9d5f554a3c
6 changed files with 37 additions and 18 deletions

View File

@ -63,6 +63,11 @@ const SoftwareFactoryResourceDetail= Loadable({
loading: Loading,
})
const SoftwareFactoryResourceDetailCommon= Loadable({
loader: () => import('./factory/resource/commonTools/detail/index'),
loading: Loading,
})
const SoftwareFactoryNews = Loadable({
@ -497,6 +502,15 @@ class App extends Component {
}>
</Route>
<Route
path={"/sf/resources/commontools/:id"}
render={
(props) => {
return (<SoftwareFactoryResourceDetailCommon {...this.props} {...props} {...this.state} />)
}
}>
</Route>
<Route
path={"/sf/resources"}
render={

View File

@ -276,7 +276,7 @@ const Resource = forwardRef(({ zoneId }, ref) => {
<div className="item-name" title={ item.name }>{item.name}</div>
<div className="item-desc" title={ item.summary }>{item.summary}</div>
<div className="item-btn">
<Link to={`/sf/resources/devtools/${item.id}`}><button className="shiny-button">查看</button></Link>
<Link to={`/sf/resources/commontools/${item.id}`}><button className="shiny-button">查看</button></Link>
<button onClick={() => { downloadFunc(`${httpUrl}/file/open/download/${item.fileIds}`) }}>下载</button>
</div>
</div>

View File

@ -45,10 +45,11 @@ function Index(props) {
extendData = JSON.parse(response.data.data.extendData)
}
document.title = response.data.data.name
if (extendData.content) {
setContent(Base64.decode(extendData.content))
}
setDetail({...response.data.data, ...extendData});
if (extendData.content) {
const base64content = Base64.decode(extendData.content)
setContent(base64content !== '<p><br></p>' ? base64content : '')
}
setDetail({ ...response.data.data, ...extendData });
}
}).catch(error => { })
}
@ -65,12 +66,12 @@ function Index(props) {
<div className="news-detail-header">
<Breadcrumb separator=">">
<Breadcrumb.Item href={`/sf`}>首页</Breadcrumb.Item>
<Breadcrumb.Item href={`/sf/resources/devtools`}>开发工具</Breadcrumb.Item>
<Breadcrumb.Item href={`/sf/resources/commontools`}>共建工具</Breadcrumb.Item>
<Breadcrumb.Item> <span className="breacrumb-name">{detail.name}</span> </Breadcrumb.Item>
</Breadcrumb>
<div className="header-content">
<h3>{detail.name}</h3>
<p title={ detail.summary }>{detail.summary}</p>
<p title={detail.summary}>{detail.summary}</p>
<div className="tools-info">
<div>
<span>{detail.downloadCount}</span>
@ -107,11 +108,12 @@ function Index(props) {
</div>
</div>
<div className="news-detail-content">
<div className="news-detail-content-wrapper">
{
content && <RenderHtml className="informations_detail imageLayerParent" value={content} url={props.history.location} />
}
</div>
{
content &&
<div className="news-detail-content-wrapper">
<RenderHtml className="informations_detail imageLayerParent" value={content} url={props.history.location} />
</div>
}
</div>
</div>
)

View File

@ -221,7 +221,7 @@
width: 1600px;
height: 100%;
margin: 52px auto;
margin-top: -100px;
margin-top: -130px;
position: relative;
z-index: 1;
@ -241,9 +241,12 @@
}
.news-detail-content-wrapper {
width: 1600px;
float: left;
padding-bottom: 60px;
background-image: url('../../../../images/factory/resource/detail-bg.png');
background-repeat: no-repeat;
background-size: 100% 100%;
padding: 30px;
border-radius: 16px;
margin-bottom: 60px;
}
.news-detail-content-others {

View File

@ -107,7 +107,7 @@ function Index(props) {
</div>
</div>
<div className="content-bottom-btn">
<Link to={`/sf/resources/devtools/${item.id}`}><button className="shiny-button">查看详情</button></Link>
<Link to={`/sf/resources/commontools/${item.id}`}><button className="shiny-button">查看详情</button></Link>
</div>
</ActionItem>
})

View File

@ -66,7 +66,7 @@ function Index(props) {
<div className="news-detail-header">
<Breadcrumb separator=">">
<Breadcrumb.Item href={`/sf`}>首页</Breadcrumb.Item>
<Breadcrumb.Item href={`/sf/resources/devtools`}>工具</Breadcrumb.Item>
<Breadcrumb.Item href={`/sf/resources/devtools`}>工具</Breadcrumb.Item>
<Breadcrumb.Item> <span className="breacrumb-name">{detail.name}</span> </Breadcrumb.Item>
</Breadcrumb>
<div className="header-content">