|
@@ -17,6 +17,7 @@ import tabLeftArr, { routerSon } from './data'
|
|
|
import MyPopconfirm from '@/components/MyPopconfirm'
|
|
import MyPopconfirm from '@/components/MyPopconfirm'
|
|
|
import store from '@/store'
|
|
import store from '@/store'
|
|
|
import SpinLodingSon from '@/components/SpinLodingSon'
|
|
import SpinLodingSon from '@/components/SpinLodingSon'
|
|
|
|
|
+import { DownOutlined, RightOutlined } from '@ant-design/icons'
|
|
|
|
|
|
|
|
function Layout() {
|
|
function Layout() {
|
|
|
const [loding, setLoding] = useState(false)
|
|
const [loding, setLoding] = useState(false)
|
|
@@ -57,7 +58,7 @@ function Layout() {
|
|
|
const dom = document.querySelector('.layoutLeftMain') as HTMLDivElement
|
|
const dom = document.querySelector('.layoutLeftMain') as HTMLDivElement
|
|
|
if (dom) {
|
|
if (dom) {
|
|
|
dom.scrollTo({
|
|
dom.scrollTo({
|
|
|
- top: sroolRef.current.offsetTop - 400,
|
|
|
|
|
|
|
+ top: sroolRef.current.offsetTop - 350,
|
|
|
behavior: 'smooth'
|
|
behavior: 'smooth'
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|
|
@@ -233,7 +234,7 @@ function Layout() {
|
|
|
{/* 左边 */}
|
|
{/* 左边 */}
|
|
|
<div className='layoutLeft'>
|
|
<div className='layoutLeft'>
|
|
|
<div className='layoutLeftTop'>
|
|
<div className='layoutLeftTop'>
|
|
|
- <img src={require('@/assets/img/layLogo.png')} alt='' />
|
|
|
|
|
|
|
+ <img className='logo' src={require('@/assets/img/logo.png')} alt='' />
|
|
|
</div>
|
|
</div>
|
|
|
{/* 左边主体 */}
|
|
{/* 左边主体 */}
|
|
|
<div className='layoutLeftMain mySorrl'>
|
|
<div className='layoutLeftMain mySorrl'>
|
|
@@ -243,16 +244,38 @@ function Layout() {
|
|
|
key={v.id}
|
|
key={v.id}
|
|
|
hidden={!v.son.length || (v.son.length === 1 && v.son[0].name === '藏品详情')}
|
|
hidden={!v.son.length || (v.son.length === 1 && v.son[0].name === '藏品详情')}
|
|
|
>
|
|
>
|
|
|
- <div className='layoutLRowBoxTxt'>{v.name}</div>
|
|
|
|
|
|
|
+ <div
|
|
|
|
|
+ className={classNames('layoutLRowBoxTxt', v.show ? 'layoutLRowBoxTxtShow' : '')}
|
|
|
|
|
+ onClick={() => {
|
|
|
|
|
+ setList(
|
|
|
|
|
+ list.map(c => ({
|
|
|
|
|
+ ...c,
|
|
|
|
|
+ show: c.id === v.id ? !c.show : c.show
|
|
|
|
|
+ }))
|
|
|
|
|
+ )
|
|
|
|
|
+ }}
|
|
|
|
|
+ >
|
|
|
|
|
+ {v.name}
|
|
|
|
|
+ <span className={classNames(v.show ? 'layoutLRowBoxTxtIcon' : '')}>
|
|
|
|
|
+ <DownOutlined />
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </div>
|
|
|
{v.son.map(v2 => (
|
|
{v.son.map(v2 => (
|
|
|
<div
|
|
<div
|
|
|
key={v2.id}
|
|
key={v2.id}
|
|
|
hidden={v2.id >= 9901}
|
|
hidden={v2.id >= 9901}
|
|
|
- className={classNames('layoutLRowBoxRow', pathAcFu(v2.path) ? 'active' : '')}
|
|
|
|
|
|
|
+ className={classNames(
|
|
|
|
|
+ 'layoutLRowBoxRow',
|
|
|
|
|
+ pathAcFu(v2.path) ? 'active' : '',
|
|
|
|
|
+ v.show ? '' : 'layoutLRowBoxRowHide'
|
|
|
|
|
+ )}
|
|
|
ref={pathAcFu(v2.path) ? sroolRef : null}
|
|
ref={pathAcFu(v2.path) ? sroolRef : null}
|
|
|
onClick={() => pathCutFu(v2)}
|
|
onClick={() => pathCutFu(v2)}
|
|
|
>
|
|
>
|
|
|
{v2.name}
|
|
{v2.name}
|
|
|
|
|
+ <span>
|
|
|
|
|
+ <RightOutlined />
|
|
|
|
|
+ </span>
|
|
|
</div>
|
|
</div>
|
|
|
))}
|
|
))}
|
|
|
</div>
|
|
</div>
|