All Downloads are FREE. Search and download functionalities are using the official Maven repository.

gitbucket.core.model.Activity.scala Maven / Gradle / Ivy

There is a newer version: 4.9.0
Show newest version
package gitbucket.core.model

trait ActivityComponent extends TemplateComponent { self: Profile =>
  import profile.simple._
  import self._

  lazy val Activities = TableQuery[Activities]

  class Activities(tag: Tag) extends Table[Activity](tag, "ACTIVITY") with BasicTemplate {
    val activityId = column[Int]("ACTIVITY_ID", O AutoInc)
    val activityUserName = column[String]("ACTIVITY_USER_NAME")
    val activityType = column[String]("ACTIVITY_TYPE")
    val message = column[String]("MESSAGE")
    val additionalInfo = column[String]("ADDITIONAL_INFO")
    val activityDate = column[java.util.Date]("ACTIVITY_DATE")
    def * = (userName, repositoryName, activityUserName, activityType, message, additionalInfo.?, activityDate, activityId) <> (Activity.tupled, Activity.unapply)
  }
}

case class Activity(
  userName: String,
  repositoryName: String,
  activityUserName: String,
  activityType: String,
  message: String,
  additionalInfo: Option[String],
  activityDate: java.util.Date,
  activityId: Int = 0
)




© 2015 - 2024 Weber Informatics LLC | Privacy Policy