|  | @@ -24,15 +24,15 @@ | 
                                                    
                                                        |  |  |  block discarded – undo | 
                                                                                                                                                                                                                    
                                                            | 24 | 24 |          } | 
                                                                                                            
                                                            | 25 | 25 |          // https://segmentfault.com/q/1010000000672529/a-1020000000679702 | 
                                                                                                            
                                                            | 26 | 26 |          $this->createTable($this->tableName, [ | 
                                                                                                            
                                                            | 27 |  | -            'id' => $this->char(36)->notNull()->comment('Id'),//通知ID | 
                                                                                                            
                                                            | 28 |  | -            'verb' => $this->string(32),//执行了什么操作 | 
                                                                                                            
                                                            | 29 |  | -            'template' => $this->string(),//模板 | 
                                                                                                            
                                                            | 30 |  | -            'notifiable_id' => $this->unsignedInteger()->notNull()->comment('Entity'),//通知实体ID | 
                                                                                                            
                                                            | 31 |  | -            'notifiable_class' => $this->string()->notNull()->comment('Entity'),//通知实体类名 | 
                                                                                                            
                                                            | 32 |  | -            'data' => $this->text(),//通知数据 | 
                                                                                                            
                                                            | 33 |  | -            'read_at' => $this->unixTimestamp()->comment('Read At'),//阅读时间 | 
                                                                                                            
                                                            | 34 |  | -            'created_at' => $this->unixTimestamp()->notNull()->comment('Created At'),//创建时间 | 
                                                                                                            
                                                            | 35 |  | -            'updated_at' => $this->integer(10)->unsigned()->notNull()->comment('Updated At'),//更新时间 | 
                                                                                                            
                                                            |  | 27 | +            'id' => $this->char(36)->notNull()->comment('Id'), //通知ID | 
                                                                                                            
                                                            |  | 28 | +            'verb' => $this->string(32), //执行了什么操作 | 
                                                                                                            
                                                            |  | 29 | +            'template' => $this->string(), //模板 | 
                                                                                                            
                                                            |  | 30 | +            'notifiable_id' => $this->unsignedInteger()->notNull()->comment('Entity'), //通知实体ID | 
                                                                                                            
                                                            |  | 31 | +            'notifiable_class' => $this->string()->notNull()->comment('Entity'), //通知实体类名 | 
                                                                                                            
                                                            |  | 32 | +            'data' => $this->text(), //通知数据 | 
                                                                                                            
                                                            |  | 33 | +            'read_at' => $this->unixTimestamp()->comment('Read At'), //阅读时间 | 
                                                                                                            
                                                            |  | 34 | +            'created_at' => $this->unixTimestamp()->notNull()->comment('Created At'), //创建时间 | 
                                                                                                            
                                                            |  | 35 | +            'updated_at' => $this->integer(10)->unsigned()->notNull()->comment('Updated At'), //更新时间 | 
                                                                                                            
                                                            | 36 | 36 |          ], $tableOptions); | 
                                                                                                            
                                                            | 37 | 37 |          $this->addPrimaryKey('{{%notification_notifiable_pk}}', $this->tableName, 'id'); | 
                                                                                                            
                                                            | 38 | 38 |          $this->createIndex('notification_notifiable', $this->tableName, ['notifiable_id', 'notifiable_class']); |