Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 10 of 16 for Barz (0.03 seconds)

  1. docs/ko/docs/tutorial/body-updates.md

    `PUT`은 기존 데이터를 **대체**해야 하는 데이터를 받는 데 사용합니다.
    
    ### 대체 시 주의사항 { #warning-about-replacing }
    
    즉, `PUT`으로 항목 `bar`를 업데이트하면서 다음과 같은 body를 보낸다면:
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    이미 저장된 속성 `"tax": 20.2`가 포함되어 있지 않기 때문에, 입력 모델은 `"tax": 10.5`라는 기본값을 사용하게 됩니다.
    
    그리고 데이터는 그 “새로운” `tax` 값 `10.5`로 저장됩니다.
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 14:06:26 GMT 2026
    - 4.8K bytes
    - Click Count (0)
  2. docs/zh-hant/docs/tutorial/body-updates.md

    {* ../../docs_src/body_updates/tutorial001_py310.py hl[28:33] *}
    
    `PUT` 用於接收應該取代現有資料的資料。
    
    ### 關於取代的警告 { #warning-about-replacing }
    
    這表示,如果你想用 `PUT` 並在 body 中包含以下內容來更新項目 `bar`:
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    由於這裡沒有包含已儲存的屬性 `"tax": 20.2`,輸入的模型會採用預設值 `"tax": 10.5`。
    
    最終資料會以這個「新的」 `tax` 值 `10.5` 被儲存。
    
    ## 使用 `PATCH` 進行部分更新 { #partial-updates-with-patch }
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:05:38 GMT 2026
    - 3.7K bytes
    - Click Count (0)
  3. docs/en/docs/tutorial/body-updates.md

    ### Warning about replacing { #warning-about-replacing }
    
    That means that if you want to update the item `bar` using `PUT` with a body containing:
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    because it doesn't include the already stored attribute `"tax": 20.2`, the input model would take the default value of `"tax": 10.5`.
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 05 18:13:19 GMT 2026
    - 4K bytes
    - Click Count (0)
  4. docs/zh/docs/tutorial/body-updates.md

    {* ../../docs_src/body_updates/tutorial001_py310.py hl[28:33] *}
    
    `PUT` 用于接收替换现有数据的数据。
    
    ### 关于替换的警告 { #warning-about-replacing }
    
    用 `PUT` 把数据项 `bar` 更新为以下请求体时:
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    因为其中未包含已存储的属性 `"tax": 20.2`,输入模型会取 `"tax": 10.5` 的默认值。
    
    因此,保存的数据会带有这个“新的” `tax` 值 `10.5`。
    
    ## 用 `PATCH` 进行部分更新 { #partial-updates-with-patch }
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 3.7K bytes
    - Click Count (0)
  5. docs/ja/docs/tutorial/body-updates.md

    `PUT`は、既存のデータを置き換えるべきデータを受け取るために使用されます。
    
    ### 置換についての注意 { #warning-about-replacing }
    
    つまり、`PUT`を使用して以下のボディで項目`bar`を更新したい場合は:
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    すでに格納されている属性`"tax": 20.2`を含まないため、入力モデルは`"tax": 10.5`のデフォルト値を取ります。
    
    そして、データはその「新しい」`10.5`の`tax`と共に保存されます。
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 14:07:17 GMT 2026
    - 5.2K bytes
    - Click Count (0)
  6. tests/test_tutorial/test_body_updates/test_tutorial001.py

            "tax": 10.5,
            "tags": [],
        }
    
    
    def test_put(client: TestClient):
        response = client.put(
            "/items/bar", json={"name": "Barz", "price": 3, "description": None}
        )
        assert response.json() == {
            "name": "Barz",
            "description": None,
            "price": 3,
            "tax": 10.5,
            "tags": [],
        }
    
    
    def test_openapi_schema(client: TestClient):
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Feb 12 13:19:43 GMT 2026
    - 7.3K bytes
    - Click Count (0)
  7. tests/test_tutorial/test_body_updates/test_tutorial002.py

            "tax": 10.5,
            "tags": ["tag1", "tag2"],
        }
    
    
    def test_patch_name(client: TestClient):
        response = client.patch(
            "/items/bar",
            json={"name": "Barz"},
        )
        assert response.json() == {
            "name": "Barz",
            "description": "The bartenders",
            "price": 62,
            "tax": 20.2,
            "tags": [],
        }
    
    
    def test_openapi_schema(client: TestClient):
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Feb 12 13:19:43 GMT 2026
    - 7.8K bytes
    - Click Count (0)
  8. docs/tr/docs/tutorial/body-updates.md

    ### Değiştirerek güncelleme uyarısı { #warning-about-replacing }
    
    Bu, `bar` öğesini `PUT` ile, body içinde şu verilerle güncellemek isterseniz:
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    zaten kayıtlı olan `"tax": 20.2` alanını içermediği için, input model `"tax": 10.5` varsayılan değerini kullanacaktır.
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 07:53:17 GMT 2026
    - 4.5K bytes
    - Click Count (0)
  9. docs/fr/docs/tutorial/body-updates.md

    ### Avertissement concernant le remplacement { #warning-about-replacing }
    
    Cela signifie que si vous souhaitez mettre à jour l’élément `bar` avec `PUT` et un corps contenant :
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    comme il n’inclut pas l’attribut déjà enregistré « tax »: 20.2, le modèle d’entrée prendrait la valeur par défaut « tax »: 10.5.
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 19 18:37:13 GMT 2026
    - 4.9K bytes
    - Click Count (0)
  10. docs/de/docs/tutorial/body-updates.md

    ### Warnung bezüglich des Ersetzens { #warning-about-replacing }
    
    Das bedeutet, dass, wenn Sie den Artikel `bar` aktualisieren wollen, mittels `PUT` und folgendem Body:
    
    ```Python
    {
        "name": "Barz",
        "price": 3,
        "description": None,
    }
    ```
    
    weil das bereits gespeicherte Attribut `"tax": 20.2` nicht enthalten ist, das Eingabemodell den Defaultwert `"tax": 10.5` erhalten würde.
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 19 17:58:09 GMT 2026
    - 5K bytes
    - Click Count (0)
Back to Top