Initialization & improvement stage 1

Re-generate entity bean & slightly combine, improve code