0
0

给项目页面、飞行器页面

This commit is contained in:
xubing
2025-12-05 21:15:33 +08:00
parent 2c314b9b0b
commit 46c184b920
18 changed files with 498 additions and 57 deletions

View File

@@ -25,6 +25,7 @@ export class ProjectView extends BaseView {
</span>
</td>
<td>
${isConfigured ? `<button class="btn-upload" onclick="uploadProject('${project.id}', '${project.name}')" style="margin-right: 5px;">上传</button>` : ''}
<button class="btn-delete" onclick="deleteProject('${project.id}')">删除</button>
</td>
</tr>
@@ -213,7 +214,6 @@ export class ProjectView extends BaseView {
</tbody>
</table>
<!-- 项目云仓库 -->
<div class="config-section">
<h3 class="section-title">📚 项目云仓库</h3>
<div class="url-input-section">
@@ -289,6 +289,20 @@ export class ProjectView extends BaseView {
}
);
}
// 新增上传功能
function uploadProject(projectId, projectName) {
showConfirmDialog(
'上传项目仓库',
'确定将此项目目录(包括所有子文件夹和文件)上传到一个新的 Git 仓库分支吗?',
function() {
vscode.postMessage({
type: 'openRepoSelectForProjectUpload',
projectId: projectId
});
}
);
}
// 项目名称编辑功能
document.addEventListener('DOMContentLoaded', function() {
@@ -483,4 +497,4 @@ export class ProjectView extends BaseView {
</body>
</html>`;
}
}
}