move date into doc, add index