This commit is contained in:
30404 2024-07-07 17:06:24 +08:00
commit 822a02f88f
4 changed files with 68 additions and 76 deletions

View File

@ -8,30 +8,23 @@
float: right; float: right;
background-color: #f7f8fa; background-color: #f7f8fa;
} }
.link-box{
margin-top: 30px;
}
.title-link{ .title-link{
position: absolute;
top: 30px;
left: -110px;
font-size: 18px; font-size: 18px;
} }
.title-link th{
padding-left: 190px;
}
.link-table{ .link-table{
margin-top: 50px; position: relative;
position: absolute;
top: 40px;
left: 22px;
} }
.link-table td{ .link-table td{
padding-left: 45px; padding: 0 26.2px;
font-size: 17px; font-size: 17px;
border-bottom: 1px solid #8a9991; border-bottom: 1px solid #8a9991;
/* border-top: 1px solid #8a9991; */
line-height: 40px; line-height: 40px;
padding-top: 10px; padding-top: 10px;
padding-bottom: 10px; padding-bottom: 10px;
text-align: center;
} }
.link-table input{ .link-table input{
height: 20px; height: 20px;

View File

@ -60,30 +60,32 @@ function StudentLink(){
} }
return( return(
<div className='body-right-studentlink'> <div className='body-right-studentlink'>
{TestLink&&<table> <div className='link-box'>
<thead> {TestLink&&<table>
<tr className='title-link'> <thead>
<th>学生</th> <tr className='title-link'>
<th>链接1</th> <th>学生</th>
<th>链接2</th> <th>链接1</th>
<th>链接3</th> <th>链接2</th>
<th>分数</th> <th>链接3</th>
<th>建议</th> <th>分数</th>
</tr> <th>建议</th>
</thead> </tr>
<tbody> </thead>
{Object.keys(TestLink).map((key)=>( <tbody>
<tr key={key} className='link-table'> {Object.keys(TestLink).map((key)=>(
<td>{key}</td> <tr key={key} className='link-table'>
<td><Link to={TestLink[key][6]} target="_blank">{TestLink[key][6]}</Link></td> <td>{key}</td>
<td><Link to={TestLink[key][7]} target="_blank">{TestLink[key][7]}</Link></td> <td><Link to={TestLink[key][6]} target="_blank">{TestLink[key][6]}</Link></td>
<td><Link to={TestLink[key][8]} target="_blank">{TestLink[key][8]}</Link></td> <td><Link to={TestLink[key][7]} target="_blank">{TestLink[key][7]}</Link></td>
<td><input type="text" onChange={handleInputChange} name={TestLink[key][0]}/></td> <td><Link to={TestLink[key][8]} target="_blank">{TestLink[key][8]}</Link></td>
<td><input type="text" onChange={handleInputChange2} name={TestLink[key][0]} /></td> <td><input type="text" onChange={handleInputChange} name={TestLink[key][0]}/></td>
</tr> <td><input type="text" onChange={handleInputChange2} name={TestLink[key][0]} /></td>
))} </tr>
</tbody> ))}
</table>} </tbody>
</table>}
</div>
<button onClick={submit} className='submit'>确定</button> <button onClick={submit} className='submit'>确定</button>
</div> </div>
) )

View File

@ -20,30 +20,35 @@
top: 60px; top: 60px;
background-image: linear-gradient(120deg,#ffffff,rgb(181, 181, 181),#fff); background-image: linear-gradient(120deg,#ffffff,rgb(181, 181, 181),#fff);
} }
.ul1-trainmanage{ .ul-trainmanage{
width: 650px; /* width: 650px; */
height: 200px; height: 200px;
position: absolute; position: absolute;
top: 50px; top: 50px;
left: 10px; left: 10px;
width: 95%; /* 占满其父元素的宽度 */
display: flex;
flex-wrap: wrap; /* 允许换行 */
padding-left: 20px; /* 移除默认的内边距 */
list-style-type: none; /* 移除列表项的默认标记 */
} }
.ul2-trainmanage{ .ul-trainmanage li{
width: 650px; width: calc(50% - 20px); /* 每个li占据其父元素宽度的一半减去外边距 */
height: 200px;
position: absolute;
top: 50px;
left: 700px;
}
.train-list-trainmanage li{
width: 650px;
height: 70px; height: 70px;
list-style-type: none; list-style-type: none;
margin-top: 10px;
border-radius: 10px; border-radius: 10px;
background-color: #ffffff; background-color: #ffffff;
box-shadow: 2px 2px 2px #d8d9d9; box-shadow: 2px 2px 2px #d8d9d9;
cursor: pointer; cursor: pointer;
margin: 10px; /* 外边距 */
box-sizing: border-box; /* 边框计算在宽度内 */
display: flex; /* 使用Flexbox布局 */
align-items: center; /* 垂直居中 */
padding: 0 15px; /* 内边距 */
position: relative;
} }
.train-list-trainmanage span { .train-list-trainmanage span {
font-size: 20px; font-size: 20px;
} }
@ -51,6 +56,14 @@
font-size: 15px; font-size: 15px;
margin-left: 460px; margin-left: 460px;
margin-top: -40px; margin-top: -40px;
flex-shrink: 0; /* span不缩小 */
white-space: nowrap;
flex-grow: 1; /* p标签占据剩余空间 */
margin: 0; /* 移除默认外边距 */
padding-left: 410px;
text-align: right; /* 右对齐文本 */
overflow-wrap: break-word; /* 允许长单词换行 */
word-break: break-all; /* 允许在任意字符处断行 */
} }
.train-list-trainmanage li::before { .train-list-trainmanage li::before {
content: "▶"; content: "▶";
@ -62,6 +75,10 @@
display: inline-block; display: inline-block;
} }
.sendtestpage{ .sendtestpage{
padding: 10px 30px; padding: 10px 30px;
font-size: 20px; font-size: 20px;

View File

@ -28,33 +28,13 @@ function TrainManage(){
<p>已批改的试卷</p> <p>已批改的试卷</p>
<div className='line'></div> <div className='line'></div>
{Data&&<div className='train-list-trainmanage'> {Data&&<div className='train-list-trainmanage'>
<ul className='ul1-trainmanage'> <ul className="ul-trainmanage">
<li> {['111', '222', '333', '444'].map(num => (
<span>111</span> <li key={num}>
<p>关闭时间2024-11-5</p> <span>{num}</span>
</li> <p>关闭时间{`2024-11-${num === '111' ? '11' : 'XX'}`}</p>
<li> </li>
<span>333</span> ))}
<p>关闭时间2024-11-5</p>
</li>
<li>
<span>333</span>
<p>关闭时间2024-11-5</p>
</li>
<li>
<span>333</span>
<p>关闭时间2024-11-5</p>
</li>
</ul>
<ul className='ul2-trainmanage'>
<li>
<span>222</span>
<p>关闭时间2024-11-5</p>
</li>
<li>
<span>444</span>
<p>关闭时间2024-11-5</p>
</li>
</ul> </ul>
<Link to='/teacher/trainmanage/TrainPods' className='ManagePods' >管理实训</Link> <Link to='/teacher/trainmanage/TrainPods' className='ManagePods' >管理实训</Link>
<Link to='/teacher/SendTrain' className='sendtestpage'>发布实训</Link> <Link to='/teacher/SendTrain' className='sendtestpage'>发布实训</Link>