- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 1,366 for user (0.04 sec)
-
compat/maven-toolchain-builder/src/test/resources/org/apache/maven/toolchain/user.xml
under the License. --> <toolchains> <toolchain> <type>basic</type> <configuration> <user>true</user> </configuration> </toolchain> <toolchain> <type>rare</type> <configuration> <user>true</user> </configuration> </toolchain>
Registered: Sun Nov 03 03:35:11 UTC 2024 - Last Modified: Fri Oct 25 12:31:46 UTC 2024 - 1K bytes - Viewed (0) -
docs/zh/docs/tutorial/security/get-current-user.md
## 获取用户 `get_current_user` 使用创建的(伪)工具函数,该函数接收 `str` 类型的令牌,并返回 Pydantic 的 `User` 模型: ```Python hl_lines="19-22 26-27" {!../../docs_src/security/tutorial002.py!} ``` ## 注入当前用户 在*路径操作* 的 `Depends` 中使用 `get_current_user`: ```Python hl_lines="31" {!../../docs_src/security/tutorial002.py!} ``` 注意,此处把 `current_user` 的类型声明为 Pydantic 的 `User` 模型。 这有助于在函数内部使用代码补全和类型检查。 /// tip | "提示"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 3.5K bytes - Viewed (0) -
docs/en/docs/tutorial/security/get-current-user.md
/// tip Prefer to use the `Annotated` version if possible. /// ```Python hl_lines="10" {!> ../../docs_src/security/tutorial001.py!} ``` //// But that is still not that useful. Let's make it give us the current user. ## Create a user model First, let's create a Pydantic user model. The same way we use Pydantic to declare bodies, we can use it anywhere else:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 7.4K bytes - Viewed (0) -
docs/em/docs/tutorial/security/get-current-user.md
``` //// 👀 👈 👥 📣 🆎 `current_user` Pydantic 🏷 `User`. 👉 🔜 ℹ 🇺🇲 🔘 🔢 ⏮️ 🌐 🛠️ & 🆎 ✅. /// tip 👆 5️⃣📆 💭 👈 📨 💪 📣 ⏮️ Pydantic 🏷. 📥 **FastAPI** 🏆 🚫 🤚 😨 ↩️ 👆 ⚙️ `Depends`. /// /// check 🌌 👉 🔗 ⚙️ 🏗 ✔ 👥 ✔️ 🎏 🔗 (🎏 "☑") 👈 🌐 📨 `User` 🏷. 👥 🚫 🚫 ✔️ 🕴 1️⃣ 🔗 👈 💪 📨 👈 🆎 💽. /// ## 🎏 🏷
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 4.3K bytes - Viewed (0) -
docs/de/docs/tutorial/security/get-current-user.md
``` //// ## Den Benutzer holen `get_current_user` wird eine von uns erstellte (gefakte) Hilfsfunktion verwenden, welche einen Token vom Typ `str` entgegennimmt und unser Pydantic-`User`-Modell zurückgibt: //// tab | Python 3.10+ ```Python hl_lines="19-22 26-27" {!> ../../docs_src/security/tutorial002_an_py310.py!} ``` //// //// tab | Python 3.9+
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 8.3K bytes - Viewed (0) -
docs/ko/docs/tutorial/security/get-current-user.md
``` //// Pydantic 모델인 `User`로 `current_user`의 타입을 선언하는 것을 알아야 합니다. 이것은 모든 완료 및 타입 검사를 통해 함수 내부에서 우리를 도울 것입니다. /// tip | "팁" 요청 본문도 Pydantic 모델로 선언된다는 것을 기억할 것입니다. 여기서 **FastAPI**는 `Depends`를 사용하고 있기 때문에 혼동되지 않습니다. /// /// check | "확인" 이 의존성 시스템이 설계된 방식은 모두 `User` 모델을 반환하는 다양한 의존성(다른 "의존적인")을 가질 수 있도록 합니다.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 5.6K bytes - Viewed (0) -
docs/ja/docs/tutorial/security/get-current-user.md
`get_current_user` は作成した(偽物の)ユーティリティ関数を使って、 `str` としてトークンを受け取り、先ほどのPydanticの `User` モデルを返却します: ```Python hl_lines="19-22 26-27" {!../../docs_src/security/tutorial002.py!} ``` ## 現在のユーザーの注入 ですので、 `get_current_user` に対して同様に *path operation* の中で `Depends` を利用できます。 ```Python hl_lines="31" {!../../docs_src/security/tutorial002.py!} ``` Pydanticモデルの `User` として、 `current_user` の型を宣言することに注意してください。
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 5.6K bytes - Viewed (0) -
tests/scan_test.go
if err := DB.Table("users").Select("id, name, age").Where("id = ?", user3.ID).Scan(&resInt2).Error; err != nil { t.Fatalf("Failed to query with pointer of value, got error %v", err) } else if resInt2.(*User).ID != user3.ID || resInt2.(*User).Name != user3.Name || resInt2.(*User).Age != user3.Age { t.Fatalf("Scan into struct should work, got %#v, should %#v", resInt2, user3) } var resInt3 interface{} resInt3 = []User{}
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 10:57:36 UTC 2024 - 10.9K bytes - Viewed (0) -
tests/transaction_test.go
if err := tx.First(&User{}, "name = ?", user.Name).Error; err != nil { t.Fatalf("Should find saved record") } if err := tx.SavePoint("save_point1").Error; err != nil { t.Fatalf("Failed to save point, got error %v", err) } user1 := *GetUser("transaction-save-point-1", Config{}) tx.Create(&user1) if err := tx.First(&User{}, "name = ?", user1.Name).Error; err != nil {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Sat Sep 14 12:58:29 UTC 2024 - 12.9K bytes - Viewed (0) -
tests/joins_test.go
var user3 User DB.Model(&User{}).Joins("NamedPet").Joins("Account").First(&user3, user.ID) if user3.NamedPet != nil || user2.Account.ID != 0 { t.Fatalf("joins NamedPet and Account should not empty:%v", user2) } } func TestInnerJoins(t *testing.T) { user := *GetUser("inner-joins-1", Config{Company: true, Manager: true, Account: true, NamedPet: false}) DB.Create(&user) var user2 User
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Jun 17 03:58:13 UTC 2024 - 15K bytes - Viewed (0)