todod/src/task.cr

18 lines
250 B
Crystal
Raw Normal View History

2019-07-07 12:09:54 +02:00
require "uuid"
class Task
JSON.mapping({
id: String,
author: Int32,
title: String,
description: String,
column: String,
assigned_to: Int32?
})
def initialize(@title, @author, @description, @column)
@id = UUID.random.to_s
end
end