获取项目信息1
This commit is contained in:
parent
1cf1f3d4f9
commit
26a1a38d56
|
@ -74,18 +74,18 @@
|
||||||
<div id="navbar-dropdown" class="w-full md:block md:w-auto">
|
<div id="navbar-dropdown" class="w-full md:block md:w-auto">
|
||||||
<ul class="flex flex-col font-medium p-4 md:p-0 mt-4 border border-gray-100 rounded-lg bg-gray-50 md:space-x-8 rtl:space-x-reverse md:flex-row md:mt-0 md:border-0 md:bg-white">
|
<ul class="flex flex-col font-medium p-4 md:p-0 mt-4 border border-gray-100 rounded-lg bg-gray-50 md:space-x-8 rtl:space-x-reverse md:flex-row md:mt-0 md:border-0 md:bg-white">
|
||||||
<li>
|
<li>
|
||||||
<a aria-current="page" class="block py-2 px-3 text-white bg-blue-700 rounded md:bg-transparent md:text-blue-500 md:p-0" href="/" onclick="changeColor('home')">
|
<a aria-current="page" id="home" class=" nav-link block py-2 px-3 text-white bg-blue-700 rounded md:bg-transparent md:text-blue-500 md:p-0" href="/" onclick="changeColor('home')">
|
||||||
首页
|
首页
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a class="block py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0" href="/Project" onclick="changeColor('projects')">
|
<a id="project" class=" nav-link block py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0" href="/Project" onclick="changeColor('projects')">
|
||||||
项目
|
项目
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li class="relative">
|
<li class="relative">
|
||||||
<button id="dropdownNavbarLink" class="flex items-center justify-between w-full py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0 md:w-auto" data-dropdown-toggle="dropdownNavbar" @click="toggleDropdown()">
|
<button id="about" class=" nav-link flex items-center justify-between w-full py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0 md:w-auto" data-dropdown-toggle="dropdownNavbar" @click="changeColor('about')">
|
||||||
关于
|
关于
|
||||||
<svg aria-hidden="true" class="w-2.5 h-2.5 ms-2.5" fill="none" viewBox="0 0 10 6" xmlns="http://www.w3.org/2000/svg">
|
<svg aria-hidden="true" class="w-2.5 h-2.5 ms-2.5" fill="none" viewBox="0 0 10 6" xmlns="http://www.w3.org/2000/svg">
|
||||||
<path d="m1 1 4 4 4-4" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"/>
|
<path d="m1 1 4 4 4-4" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"/>
|
||||||
|
@ -107,10 +107,10 @@
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a class="block py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0" href="#">团队</a>
|
<a id="team" class=" nav-link block py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0" href="#" @click="changeColor('team')">团队</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a class="block py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0" href="/New">新闻</a>
|
<a id="new" class=" nav-link block py-2 px-3 text-gray-900 rounded hover:bg-gray-100 md:hover:bg-transparent md:border-0 md:hover:text-blue-700 md:p-0" href="/New" @click="changeColor('new')">新闻</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -148,19 +148,30 @@ function toggleDropdown(){
|
||||||
isDropdownOpen.value = !isDropdownOpen.value;
|
isDropdownOpen.value = !isDropdownOpen.value;
|
||||||
|
|
||||||
}
|
}
|
||||||
function changeColor(item){
|
// function changeColor(item){
|
||||||
const homeLink = document.getElementById('homeLink');
|
// const homeLink = document.getElementById('homeLink');
|
||||||
const projectsLink = document.getElementById('projectsLink');
|
// const projectsLink = document.getElementById('projectsLink');
|
||||||
|
//
|
||||||
|
// homeLink.classList.remove('text-blue-500');
|
||||||
|
// projectsLink.classList.remove('text-blue-500');
|
||||||
|
//
|
||||||
|
// if (item === 'home') {
|
||||||
|
// homeLink.classList.add('text-blue-500');
|
||||||
|
// } else if (item === 'projects') {
|
||||||
|
// projectsLink.classList.add('text-blue-500');
|
||||||
|
// }
|
||||||
|
// // textColor.value = 'blue';
|
||||||
|
// }
|
||||||
|
|
||||||
homeLink.classList.remove('text-blue-500');
|
function changeColor(id) {
|
||||||
projectsLink.classList.remove('text-blue-500');
|
const links = document.getElementsByClassName('nav-link');
|
||||||
|
for (let i = 0; i < links.length; i++) {
|
||||||
if (item === 'home') {
|
if (links[i].id === id + '-link') {
|
||||||
homeLink.classList.add('text-blue-500');
|
links[i].classList.add('text-blue-500');
|
||||||
} else if (item === 'projects') {
|
} else {
|
||||||
projectsLink.classList.add('text-blue-500');
|
links[i].classList.remove('text-blue-500');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// textColor.value = 'blue';
|
|
||||||
}
|
}
|
||||||
// function backMain() {
|
// function backMain() {
|
||||||
// // 当按钮被点击时,将文字颜色改为蓝色
|
// // 当按钮被点击时,将文字颜色改为蓝色
|
||||||
|
@ -228,6 +239,9 @@ function JumpMyManage (){
|
||||||
function JumpPersonalInformation (){
|
function JumpPersonalInformation (){
|
||||||
router.push("/WorkLoad/PersonalInformation")
|
router.push("/WorkLoad/PersonalInformation")
|
||||||
}
|
}
|
||||||
|
function JumpMyResponsible(){
|
||||||
|
router.push("/WorkLoad/I_Responsible")
|
||||||
|
}
|
||||||
// function MyResponsible(){
|
// function MyResponsible(){
|
||||||
// router.push("")
|
// router.push("")
|
||||||
// }
|
// }
|
||||||
|
|
Loading…
Reference in New Issue
Block a user