2
Laravel 내에서 Post 및 Model :: create 함수를 실행할 때 아래 오류로 반갑습니다. TaskQueue.php 오류 - Laravel 5 & Forge
FatalErrorException in TaskQueue.php line 13:
Interface 'GuzzleHttp\Promise\TaskQueueInterface' not found
이
내 로컬 컴퓨터에 완벽하게 잘 작동했지만 곧 웹 사이트 포지와 서버에 넣어으로이 오류를 표시하기 시작했다.서버가 Laravel과 함께 Queue 함수를 사용하려고하지만 내 코드가 이것을 사용하지 않는 것처럼 보입니다.
public function postCreateCustomer(){
$input = Request::all();
$customer = Customers::create([
'customer_name' => $input['customer_name'],
'customer_url' => $input['customer_url']
]);
$password = str_random(8);
$pass = Hash::make($password);
$user = User::create([
'name' => $input['name'],
'email' => $input['email'],
'password' => $pass,
'user_type' => 3,
'active_customer' => $customer->id,
]);
Access::create([
'user_id' => $user->id,
'customer_id' => $customer->id
]);
$the_content = '<p>Hello '.$input['name'].' ('.$input['customer_name'].'),</p>
<p>Thank you for creating an account. </p>
<p>Your login details are listed below;</p>
<p><strong>Username</strong>: '.$input['email'].'<p>
<p><strong>Password</strong>: '.$password.'<p>';
$contactEmail = $input['email'];
Mail::send('emails.default', ['the_content' => $the_content, 'the_heading' => 'Customer Account Created'], function ($message) use ($contactEmail) {
$message->subject("Customer Account Created");
$message->to($contactEmail);
});
Session::flash('success_message', 'The new customer has been created.');
return Redirect::to('/customers');
}
완벽하게 작동했습니다. 감사합니다. –
오, 오. 이것은 효과가 있지만, 왜? – markashworth
그 수업을 찾을 수 없기 때문에 저자의 부주의 한 실수 일 수 있습니다. –