<s> from app import db <EOL> import datetime <EOL> class Todo ( db . Document ) : <EOL> content = db . StringField ( required = True , max_length = <NUM_LIT:20> ) <EOL> time = db . DateTimeField ( default = datetime . datetime . now ( ) ) <EOL> status = db . IntField ( default = <NUM_LIT:0> ) <EOL> def to_json ( self ) : <EOL> return { <EOL> '<STR_LIT:id>' : str ( self . id ) , <EOL> '<STR_LIT:content>' : self . content , <EOL> '<STR_LIT:time>' : self . time , <EOL> '<STR_LIT:status>' : self . status <EOL> } </s>
