作者 tangxvhui

更新

@@ -51,6 +51,7 @@ func init() { @@ -51,6 +51,7 @@ func init() {
51 &models.SummaryEvaluationValue{}, 51 &models.SummaryEvaluationValue{},
52 &models.Permission{}, 52 &models.Permission{},
53 &models.LogSms{}, 53 &models.LogSms{},
  54 + &models.MessagePersonal{},
54 } 55 }
55 for _, model := range tables { 56 for _, model := range tables {
56 err := DB.Model(model).CreateTable(&orm.CreateTableOptions{ 57 err := DB.Model(model).CreateTable(&orm.CreateTableOptions{
  1 +-- summary_evaluation_value表添加字段
  2 +ALTER TABLE public.summary_evaluation_value
  3 + ADD executor jsonb NULL;
  4 +
  5 +-- 初始化旧数据的summary_evaluation_value.executor
  6 +UPDATE
  7 + public.summary_evaluation_value
  8 +SET
  9 + executor = public.summary_evaluation.executor
  10 +FROM
  11 + public.summary_evaluation
  12 +WHERE
  13 + public.summary_evaluation_value.summary_evaluation_id = public.summary_evaluation.id;
  14 +