Skip to content

Add Model methods: create(), update() and set() #49

@1st

Description

@1st

Helper methods are useful to make code more compact:

  1. Model.create() - creates a new object and saves it to DB. Returns a new instance
  2. model_instance.update() - sets new fields to the existing object and saves it to DB
  3. model_instance.set() - sets new fields to the existing object, without saving it to DB

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions