raydelpq/whatsapp-api
Composer 安装命令:
composer require raydelpq/whatsapp-api
包简介
Gestionas grupos y usuarios de whatsapp conjunto con la libreria whatsapp-web.js
README 文档
README
Gestionar agencias de taxis desde whatsapp
Install
composer require raydelpq/whatsapp-api
Public Vendor
php artisan vendor:publish --tag=whatsappapi
Ejecutar Migracion
php artisan migrate
Agragar al Model Taxista
public function whatsapps(){ return $this->belongsToMany(\Raydelpq\WhatsappApi\Models\Whatsapp::class); }
Dentro del Modelo agregar los jobs en las funciones
addSaldo
\Raydelpq\WhatsappApi\Jobs\ApiWhastappAdd::dispatch($this);
delSaldo
\Raydelpq\WhatsappApi\Jobs\ApiWhastappDel::dispatch($this);
Dentro de App\Http\Livewire\Taxista\AgregarFonfo
El el metodo procesar antes de los eventos
\Raydelpq\WhatsappApi\Jobs\ApiWhatsappFondo::dispatch($this->taxista);
Provider
Raydelpq\WhatsappApi\WhatsappApiServiceProvider::class
Jobs
Raydelpq\WhatsappApi\Jobs\ApiWhastappAdd Raydelpq\WhatsappApi\Jobs\ApiWhastappDel Raydelpq\WhatsappApi\Jobs\ApiWhastappFondo
Componente de Livewire
@if( Auth::user()->hasRole('Administrador') && config("whatsappapi.API_WA") == true ) <button :class=" tab == 0 ? 'bg-slate-300 dark:bg-slate-800' : 'bg-slate-900' " class="text-white px-4 py-2 -mr-1.5 border-l border-slate-900 dark:border-white rounded-tr border-t" x-on:click="tab=0;">Whatsapp</button> @endif
@if( Auth::user()->hasRole('Administrador') && config("whatsappapi.API_WA") == true ) <div x-show="tab == 0" class="p-4 bg-slate-300 dark:bg-slate-800 rounded-b rounded-tr w-full"> <livewire:taxista.whatsapp :taxista='$taxista'> </div> @endif
@if( Auth::user()->hasRole('Administrador') && config("whatsappapi.API_WA") == true ) <livewire:link> @endif
Mostrar QR
Limpiar cache de Rutas
php artisan route:cache
Ruta
https://mi.domain.com/getqr
Expulsar a todos los taxistas
php artisan out:taxista
统计信息
- 总下载量: 46
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-10-26