issue #82 Fixed index and code generator for new state DRAFT