Skip to content

Instantly share code, notes, and snippets.

@kurotanshi
Last active October 15, 2016 07:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kurotanshi/906db43f828a90a9f0477b6f065f361e to your computer and use it in GitHub Desktop.
Save kurotanshi/906db43f828a90a9f0477b6f065f361e to your computer and use it in GitHub Desktop.
<template>
<div id="app">
<div class="panel panel-default">
<div class="panel-heading">Task Table</div>
<table class="table">
<!-- 表頭 -->
<thead>
<tr>
<th class="number">#</th>
<th class="name">Task Name</th>
<th class="duration">Duration</th>
<th class="status">Status</th>
<th class="edit"></th>
</tr>
</thead>
<!-- 表頭 -->
<tbody>
<tr>
<th class="number" scope="row">1</th>
<td>
<div>Name</div>
<input type="text">
</td>
<td class="duration">
<div>123</div>
<input type="text">
</td>
<td class="status">
<div>Open</div>
<input type="checkbox">
</td>
<td class="edit">
<button class="btn btn-primary">編輯</button>
<button class="btn btn-danger">刪除</button>
</td>
</tr>
</tbody>
<!-- 新增用 -->
<tfoot>
<tr>
<th class="number" scope="row">新增</th>
<td>
<input type="text">
</td>
<td class="duration">
<input type="text">
</td>
<td class="status">
<div>Open?</div>
<input type="checkbox">
</td>
<td class="edit">
<button class="btn btn-success">加入</button>
<button class="btn btn-warning">重置</button>
</td>
</tr>
</tfoot>
<!-- 新增用 -->
</table>
</div>
</div>
</template>
<script>
export default {
data () {
return {
msg: 'Hello Vue!'
}
}
}
</script>
<style>
#app{
width: 980px; margin: 10px;
}
body {
font-family: Helvetica Neue, Arial, sans-serif;
font-size: 14px;
color: #444;
}
thead{
font-size: 16px; font-weight: 900;
}
</style>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>vue-wrokshop</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
</head>
<body>
<div id="app"></div>
<script src="dist/build.js"></script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment