profile ava

This commit is contained in:
andrey 2021-08-16 17:32:31 +03:00
parent 9c948774e0
commit c8540c41b3
17 changed files with 17 additions and 0 deletions

View File

@ -17,6 +17,23 @@ class SqlController extends Controller
echo "script completed successfully\n";
}
public function actionAddAva()
{
$model = UserCard::find()->all();
foreach ($model as $item) {
if(!$item->photo){
if($item->gender === 1){
$item->photo = '/profileava/f' . random_int(1, 6) . '.png';
}
else {
$item->photo = '/profileava/m' . random_int(1, 10) . '.png';
}
$item->save();
}
}
echo "script completed successfully\n";
}
public function actionGenerateUser()
{
echo UserCard::generateUserForUserCard() . "\n";

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB