- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 1,504 for USER (0.3 sec)
-
docs_src/sql_databases_peewee/sql_app/main.py
@app.post("/users/", response_model=schemas.User, dependencies=[Depends(get_db)]) def create_user(user: schemas.UserCreate): db_user = crud.get_user_by_email(email=user.email) if db_user: raise HTTPException(status_code=400, detail="Email already registered") return crud.create_user(user=user) @app.get("/users/", response_model=List[schemas.User], dependencies=[Depends(get_db)])
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Mar 26 19:09:53 UTC 2020 - 2.2K bytes - Viewed (0) -
tests/update_belongs_to_test.go
var user2 User DB.Preload("Company").Preload("Manager").Find(&user2, "id = ?", user.ID) CheckUser(t, user2, user) user.Company.Name += "new" user.Manager.Name += "new" if err := DB.Save(&user).Error; err != nil { t.Fatalf("errors happened when update: %v", err) } var user3 User DB.Preload("Company").Preload("Manager").Find(&user3, "id = ?", user.ID) CheckUser(t, user2, user3)
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Thu Jul 14 06:55:54 UTC 2022 - 1.6K bytes - Viewed (0) -
tests/scan_test.go
t.Errorf("Failed to run join query, got error: %v", err) } AssertEqual(t, person1, personDupField) user := User{ Name: "TestScanToEmbedded_1", Manager: &User{ Name: "TestScanToEmbedded_1_m1", Manager: &User{Name: "TestScanToEmbedded_1_m1_m1"}, }, } DB.Create(&user) type UserScan struct { ID uint Name string ManagerID *uint } var user2 UserScan
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/create_test.go
user.CreatedAt = curTime user.UpdatedAt = curTime DB.Save(&user) AssertEqual(t, user.CreatedAt, curTime) AssertEqual(t, user.UpdatedAt, curTime) var newUser User DB.First(&newUser, user.ID) AssertEqual(t, newUser.CreatedAt, curTime) AssertEqual(t, newUser.UpdatedAt, curTime) } func TestCreateWithNowFuncOverride(t *testing.T) {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Tue Mar 19 03:50:28 UTC 2024 - 26.4K bytes - Viewed (0) -
schema/schema_test.go
References: []Reference{{"ID", "Company", "CompanyID", "User", "", false}}, }, { Name: "Manager", Type: schema.BelongsTo, Schema: "User", FieldSchema: "User", References: []Reference{{"ID", "User", "ManagerID", "User", "", false}}, }, { Name: "Team", Type: schema.HasMany, Schema: "User", FieldSchema: "User", References: []Reference{{"ID", "User", "ManagerID", "User", "", true}}, }, {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Thu Jun 20 12:19:31 UTC 2024 - 13.3K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/app/web/base/login/FessLoginAssist.java
getSavedUserBean().ifPresent(user -> { if (user.hasRoles(fessConfig.getAuthenticationAdminRolesAsArray())) { return; } final Method executeMethod = resource.getExecuteMethod(); final Secured secured = executeMethod.getAnnotation(Secured.class); if (secured != null && user.hasRoles(secured.value())) { return;
Registered: Thu Oct 31 13:40:30 UTC 2024 - Last Modified: Thu Feb 22 01:53:18 UTC 2024 - 7.8K bytes - Viewed (0) -
tests/test_response_model_data_filter.py
@app.post("/users/", response_model=UserBase) async def create_user(user: UserCreate): return user @app.get("/pets/{pet_id}", response_model=PetOut) async def read_pet(pet_id: int): user = UserDB( email="******@****.***", hashed_password="secrethashed", ) pet = PetDB(name="Nibbler", owner=user) return pet @app.get("/pets/", response_model=List[PetOut])
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 1.7K bytes - Viewed (0) -
docs_src/security/tutorial005_an_py310.py
def authenticate_user(fake_db, username: str, password: str): user = get_user(fake_db, username) if not user: return False if not verify_password(password, user.hashed_password): return False return user def create_access_token(data: dict, expires_delta: timedelta | None = None): to_encode = data.copy() if expires_delta:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Mon May 20 17:37:28 UTC 2024 - 5.2K bytes - Viewed (0) -
docs_src/security/tutorial005_an_py39.py
def authenticate_user(fake_db, username: str, password: str): user = get_user(fake_db, username) if not user: return False if not verify_password(password, user.hashed_password): return False return user def create_access_token(data: dict, expires_delta: Union[timedelta, None] = None): to_encode = data.copy() if expires_delta:
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Mon May 20 17:37:28 UTC 2024 - 5.3K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/auth/chain/LdapChain.java
import org.codelibs.fess.es.user.exentity.User; import org.codelibs.fess.util.ComponentUtil; public class LdapChain implements AuthenticationChain { @Override public void update(final User user) { ComponentUtil.getLdapManager().insert(user); } @Override public void delete(final User user) { ComponentUtil.getLdapManager().delete(user); } @Override
Registered: Thu Oct 31 13:40:30 UTC 2024 - Last Modified: Thu Feb 22 01:37:57 UTC 2024 - 1.4K bytes - Viewed (0)