feat: implement profile editing and password change
This commit is contained in:
@@ -3,6 +3,8 @@
|
||||
namespace App\Http\Controllers\Account;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Models\City;
|
||||
use App\Models\Province;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
|
||||
@@ -13,6 +15,15 @@ class ProfileController extends Controller
|
||||
{
|
||||
$title = 'پروفایل';
|
||||
$user = Auth::user();
|
||||
|
||||
return view('account.profile', compact('title', 'user'));
|
||||
}
|
||||
|
||||
public function getCities($provinceId)
|
||||
{
|
||||
$cities = City::where('province_id', $provinceId)->orderBy('name')->get(['id', 'name']);
|
||||
return response()->json($cities);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user