-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
executable file
·112 lines (110 loc) · 5.64 KB
/
Copy pathindex.html
File metadata and controls
executable file
·112 lines (110 loc) · 5.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Brand Management</title>
<script src="lib/vue2-6.10.js"></script>
<link rel="stylesheet" href="style/bootstrap.min.css">
<link rel="stylesheet" href="style/style.css">
</head>
<body>
<div id="app" class="container">
<div class="jumbotron">
<h2 class="display-4" v-fontsize="100">VueJs Application</h2>
<p class="lead">What's included in this app?</p>
<hr class="my-4">
<div class="list-group">
<a href="resource.html" class="list-group-item list-group-item-action">1. How to send ajax request?</a>
<a href="datalist.html" class="list-group-item list-group-item-action">2. How to send request to RESTFul data?</a>
<a href="animation.html" class="list-group-item list-group-item-action">3. How to create animation?</a>
<a href="animation2.html" class="list-group-item list-group-item-action">4. How to use third-party (animate.css) animation?</a>
<a href="animation3.html" class="list-group-item list-group-item-action">5. How to implement in JS hooks?</a>
<a href="animation4.html" class="list-group-item list-group-item-action">6. How to add animation to add list?</a>
<a href="componets.html" class="list-group-item list-group-item-action">7. How to create components in Vue?</a>
<a href="router.html" class="list-group-item list-group-item-action">8. How to use frontend router in Vue?</a>
<a href="events-binding.html" class="list-group-item list-group-item-action">9. How to bind events to DOM in Vue?</a>
</div>
</div>
<div class="card text-dark bg-primary">
<div class="card">
<!--Private Directives-->
<div class="card-header text-primary" v-fontweight="900">
Add Brand
</div>
<div class="card-body">
<form class="form-inline">
<div class="form-group">
<label for="id">ID</label>
<input type="text" id="id" class="form-control" v-model="id">
<label for="namd">Name</label>
<!-- <input type="text" id="name" class="form-control" v-model="name" @keyup.f2="add"> -->
<input type="text" id="name" class="form-control" v-model="name" @keyup.enter="add">
<input type="button" name="" id="id" class="form-control btn btn-primary" value="Add" @click="add">
<!-- All Vue Directives must be started with v-. -->
<input type="text" placeholder="Search" class="form-control" id="search" v-model="keywords" v-focus v-color="'green'">
</div>
</form>
</div>
<table class="table ">
<thead>
<tr>
<th>id</th>
<th>Name</th>
<th>Ctime</th>
<th>Operation</th>
</tr>
</thead>
<tbody>
<tr v-for="item in search(keywords)" :key="item.id">
<td scope="row">{{item.id}}</td>
<td>{{item.name}}</td>
<td>{{item.ctime | dateFormat('') }}</td>
<td>
<a href="#" class="badge badge-primay">Edit</a>
<a href="#" class="badge badge-danger" @click.prevent="del(item.id)">Delete</a>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<hr class="my-4">
<div class="container">
<div id="app2">
<cmt-box v-on:func="loadComments"></cmt-box>
<div class="card">
<ul class="list-group list-group-flush" style="background-color:darkturquoise;">
<li class="list-group-item" v-for="val in datalist" :key="val.id">
{{val.content}} by <span class="badge badge-pill badge-primary">{{val.user}}</span>
</li>
</ul>
</div>
</div>
</div>
<div class="row">
<div class="footer"></div>
</div>
<!--Component Template-->
<template id="tmplcomment">
<div class="card">
<div class="card-body">
<h4 class="card-title">Users' Comments: </h4>
<p class="card-text">Leave your comments...</p>
<div class="form-group">
<label for="commentuser">Name: </label>
<input type="text" name="commentuser" id="commentuser" class="form-control" placeholder="Your Name..." aria-describedby="helpId" v-model="user">
<div class="form-group">
<label for="commentarea">Comment:</label>
<textarea class="form-control" name="" id="commentarea" rows="3" placeholder="Your comment..." v-model="content"></textarea>
</div>
<button type="button" class="btn btn-primary" @click="postcomment">Submit</button>
</div>
</div>
</div>
</template>
<script src="script/myScript.js"></script>
</body>
</html>