EUNO.NEWS EUNO.NEWS
  • All (20580)
  • AI (3121)
  • DevOps (916)
  • Software (10669)
  • IT (5826)
  • Education (48)
  • Notice
  • All (20580)
    • AI (3121)
    • DevOps (916)
    • Software (10669)
    • IT (5826)
    • Education (48)
  • Notice
  • All (20580)
  • AI (3121)
  • DevOps (916)
  • Software (10669)
  • IT (5826)
  • Education (48)
  • Notice
Sources Tags Search
한국어 English 中文
  • 2周前 · software

    为什么 Laravel 不能猜测你的 Factory 关系

    Laravel factories 让测试变得轻而易举,尤其是在模型之间存在关联时。然而,当一个模型对同一目标模型有多个关联时,...

    #laravel #php #eloquent #model-factories #testing #relationships #unit-testing
  • 1个月前 · software

    在 Laravel Eloquent 中使用自定义时间戳列

    如果需要自定义 created_at 和 updated_at 的列名,可以在数据库层面进行设置。/ 运行迁移。/ public function up: void {...}

    #Laravel #Eloquent #PHP #custom timestamps #database migrations #created_at #updated_at
  • 1个月前 · software

    两个被忽视的 Laravel 功能:`fresh()` 和属性可见性

    使用 Laravel 的 fresh 方法重新加载模型可以让您从数据库中重新加载单个模型或整个集合,确保您正在使用最新的…

    #Laravel #Eloquent #fresh() #attribute visibility #PHP #model serialization #ORM
  • 1个月前 · software

    💡 两个不太为人知的 Laravel 技巧:numerify 与 invisible

    在 Eloquent 工厂中使用 numerify 方法。Faker 的 numerify 方法可以让你用随机数字替换字符。php public function definition: array { return 'p...

    #Laravel #Eloquent #Faker #numerify #invisible #PHP #database migrations #hidden columns
EUNO.NEWS
RSS GitHub © 2026