Add ValueType
This commit is contained in:
parent
71926cfd4b
commit
4cb5bf962b
@ -35,6 +35,8 @@ pub enum PrimaryKey {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl PrimaryKeyTrait for PrimaryKey {
|
impl PrimaryKeyTrait for PrimaryKey {
|
||||||
|
type ValueType = i32;
|
||||||
|
|
||||||
fn auto_increment() -> bool {
|
fn auto_increment() -> bool {
|
||||||
true
|
true
|
||||||
}
|
}
|
||||||
|
@ -24,5 +24,10 @@
|
|||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<p><a href="/new">Add Post</a></p>
|
<div class="twelve columns">
|
||||||
|
<a href="/new">
|
||||||
|
<input type="button" value="add post" />
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
{% endblock content %}
|
{% endblock content %}
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<h4>New Post</h4>
|
<h4>New Post</h4>
|
||||||
<form action="/" method="post">
|
<form action="/" method="post">
|
||||||
<div class="ten columns">
|
<div class="twelve columns">
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="enter title"
|
placeholder="enter title"
|
||||||
@ -22,8 +22,16 @@
|
|||||||
class="u-full-width"
|
class="u-full-width"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div class="two columns">
|
<div class="twelve columns">
|
||||||
<input type="submit" value="add post" />
|
<div class="two columns">
|
||||||
|
<a href="/">
|
||||||
|
<input type="button" value="cancel" />
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div class="eight columns"></div>
|
||||||
|
<div class="two columns">
|
||||||
|
<input type="submit" value="save post" />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user