This repository was archived by the owner on Aug 22, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +0
-22
lines changed
resources/views/partials/layouts
src/Plugins/Users/Http/Controllers Expand file tree Collapse file tree 2 files changed +0
-22
lines changed Original file line number Diff line number Diff line change 4747 </li >
4848 <li class =" divider" ></li >
4949 <li ><a href =" {{ url (' /' ) } }" target =" _blank" >{{ __ (' Preview website' ) } } </a ></li >
50- @if ($profile -> isSuperUser () )
51- <li ><a href =" {{ route (' shopper.users.impersonate' ) } }" target =" _blank" >{{ __ (' Impersonate user' ) } } </a ></li >
52- @endif
5350 <li ><a href =" {{ route (' shopper.settings.translate.index' ) } }" >{{ __ (' Backend Preferences' ) } } </a ></li >
5451 <li class =" divider" ></li >
5552 <li >
Original file line number Diff line number Diff line change @@ -180,25 +180,6 @@ public function addresses(int $id)
180180 return $ user ->addresses ;
181181 }
182182
183- /**
184- * Impersonate user
185- *
186- * @return \Illuminate\Http\RedirectResponse
187- */
188- public function impersonate ()
189- {
190- $ user = $ this ->repository ->getModel ()->first ();
191-
192- if ($ user ) {
193- Auth::login ($ user );
194-
195- return redirect (url ('/ ' ))->with ('status ' , __ ("Impersonate as {$ user ->name }" ));
196- } else {
197- return redirect ()->route ('shopper.users.index ' )
198- ->with ('warning ' , __ ('There is no user you can impersonate ' ));
199- }
200- }
201-
202183 /**
203184 * @param int $id
204185 * @return \Illuminate\Database\Eloquent\Collection
You can’t perform that action at this time.
0 commit comments