李帅

1.微调一下接口,打印参数

......@@ -69,8 +69,7 @@ class PickPoetryVerseController extends AdminController
// 设置字段宽度
$form->width(8, 3);
$form->radio('plant')->addElementClass('plant')
$form->radio('terminal')->addElementClass('terminal')
->options([1 => 'Android', 2 => 'IOS'])->default(2);
$form->text('title')->addElementClass('title');
......@@ -86,7 +85,7 @@ class PickPoetryVerseController extends AdminController
$form->radio('user_type', '目标人群')->options([1 => '所有人', 2 => '指定用户'])->default(1)
->when(2, function (Form\BlockForm $form) {
$form->text('user_id');
$form->text('user_id')->placeholder("多个用户用逗号,分开");
});
});
......
......@@ -32,4 +32,4 @@ Admin::asset()->alias('@css', '/asset/css');
Column::extend('gallery', Gallery::class); //grid列扩展 - 多图浏览
Map::requireAssets(); // 引入地图资源
//Map::requireAssets(); // 引入地图资源
......
......@@ -75,7 +75,13 @@ class SendVerificationMessage implements ShouldQueue
$context = stream_context_create($options);
$result_json = file_get_contents($api, FILE_TEXT, $context);
$result = json_decode($result_json,true);
if ($result['result'] == false){
Log::channel('daily')->debug($result_json);
// 用开发模板发送。
Mail::to($this->email)->send(new SendVerifyCode($code));
}
}
}
......
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class Push extends Model
{
use HasFactory;
}
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreatePushesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('pushes', function (Blueprint $table) {
$table->id();
$table->string('title')->comment('标题');
$table->unsignedTinyInteger('terminal')->comment('1=Android,2=IOS');
$table->unsignedTinyInteger('push_type')->comment('1=立即,2=定时');
$table->timestamp('push_time')->comment('推送时间');
$table->string('action_type')->comment('动作类型');
$table->unsignedTinyInteger('user_type')->comment('目标人群1=所有人,2=指定用户');
$table->string('user_id')->comment('用户id');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('pushes');
}
}
......@@ -73,7 +73,7 @@
<div class="box-card">
<div class="phone-content">
<div class="text">会员页</div>
<img src="{{asset('storage/image/mobile-head.png')}}" alt="" width="338" height="80">
<img src="{{asset('storage/images/mobile-head.png')}}" alt="" width="338" height="80">
<div style="min-height: 625px;">
<img width="338" height="625" class="bg_img" src="{{asset('storage/images/a5fe2ba2bd71b543cbf4c6fb3968ab64.png')}}">
</div>
......
......@@ -62,7 +62,7 @@
<div class="box-card">
<div class="phone-content">
<div class="text">模板</div>
<img src="{{asset('storage/image/mobile-head.png')}}" alt="" width="360" height="80">
<img src="{{asset('storage/images/mobile-head.png')}}" alt="" width="360" height="80">
<div class="bg-box">
<img width="360" height="625" class="bg_img" style="display: none">
<video width="360" height="625" id="bg_video" style="display: none"></video>
......
......@@ -50,7 +50,7 @@
<hr>
<div class="box-card">
<div class="phone-content">
<img src="{{asset('storage/image/ios1-2.png')}}" alt="" width="358" height="625" id="bg_img">
<img src="{{asset('storage/images/ios1-2.png')}}" alt="" width="358" height="625" id="bg_img">
<div class="notification-app-name"> 一言-临境 </div>
<div class="notification-title"> Demo 标题 </div>
<div class="notification-detail"> 开发者249d42a097c1944e进行了广播推送,这是一条广播 </div>
......@@ -62,14 +62,14 @@
var asset = "{{asset('/storage/')}}";
$(document).off('click', '.sync').on('click', '.sync', function () {
let plant = parseInt($('.plant:checked').val());
if (plant === 1) {
$('#bg_img').attr('src', asset + '/image/android-2.png');
let terminal = parseInt($('.terminal:checked').val());
if (terminal === 1) {
$('#bg_img').attr('src', asset + '/images/android-2.png');
$('.notification-app-name').css('top','244px').css('left','80px');
$('.notification-title').css('top','264px').css('left','57px');
$('.notification-detail').css('top','287px').css('left','57px');
}else{
$('#bg_img').attr('src', asset + '/image/ios1-2.png');
$('#bg_img').attr('src', asset + '/images/ios1-2.png');
$('.notification-app-name').css('top','222px').css('left','92px');
$('.notification-title').css('top','242px').css('left','67px');
$('.notification-detail').css('top','265px').css('left','67px');
......
<body>
<h5>Set up your account verify code</h5>
<p>your code: {{$code}}</p>
<p>The code will expire in 30 minutes.</p>
<div style="width:700px;margin:0 auto;border-bottom:1px solid #ccc; border-top:1px solid #ccc; padding:30px">
<div style="line-height:1.5;font-size:14px;margin-bottom:25px;color:#4d4d4d;">
<p style="margin-bottom:15px;">尊敬的用户:您好!(Dear User)</p>
<p style="margin-bottom:15px;">
您正在进行注册账号操作,请在验证码输入框中输入:(You are registering an account, please enter in the verification code input box: )
<span style="color:#000b16;font-size: 24px">{{$code}}</span>,以完成操作。(,to complete the operation.)
</p>
<p>验证码有效期为30分钟(The code will expire in 30 minutes.)</p>
</div>
<div style="padding:10px 10px 0;margin-bottom:20px;line-height:1.3em;font-size:12px;">
<p>此为系统邮件,请勿回复(This is a system email, please do not reply.)<br>
请保管好您的邮箱,避免账号被他人盗用(Please take good care of your email to prevent your account from being stolen by others.)
</p>
<p>Parlando Network Technology Team</p>
</div>
</div>
</body>
\ No newline at end of file
......