Merge branch 'backend' of https://github.com/nakazawakan/kikikanri into fe_fix
このコミットが含まれているのは:
コミット
0f819499cc
|
@ -32,6 +32,11 @@ npm run watch ( npm run dev )
|
|||
php artisan migrate:fresh --seed
|
||||
```
|
||||
|
||||
#### 6.ストレージのリンク
|
||||
```
|
||||
php artisan storage:link
|
||||
```
|
||||
|
||||
|
||||
|
||||
# 仕様書
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
APP_NAME=KIKIkan
|
||||
APP_NAME=KIKI
|
||||
APP_ENV=local
|
||||
APP_KEY=
|
||||
APP_DEBUG=true
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
APP_NAME=KIKIkan
|
||||
APP_NAME=KIKI
|
||||
APP_ENV=local
|
||||
APP_KEY=
|
||||
APP_DEBUG=true
|
||||
|
|
|
@ -5,6 +5,7 @@ namespace App\Http\Controllers\Api;
|
|||
use App\Http\Controllers\Controller;
|
||||
use Illuminate\Support\Facades\Validator;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
|
||||
use App\Models\Child;
|
||||
|
@ -99,10 +100,22 @@ class FatherRelationsController extends Controller {
|
|||
}
|
||||
|
||||
try {
|
||||
FatherRelation::where('father_id', session()->get('fathers')['id'])->where('child_id', $child_id)->delete();
|
||||
DB::beginTransaction();
|
||||
|
||||
$rel = FatherRelation::where('father_id', session()->get('fathers')['id'])->where('child_id', (int)$child_id);
|
||||
|
||||
foreach (Meeting::where('father_id', session()->get('fathers')['id'])->get() as $m) {
|
||||
$apr = MeetingApprovals::where('child_id', (int)$child_id)->where('meeting_id', $m->id);
|
||||
$apr->delete();
|
||||
}
|
||||
|
||||
$rel->delete();
|
||||
|
||||
DB::commit();
|
||||
} catch (\Throwable $e) {
|
||||
// 失敗
|
||||
Log::critical($e->getMessage());
|
||||
DB::rollback();
|
||||
return ['status_code' => 400, 'error_messages' => ['子の削除に失敗しました。']];
|
||||
}
|
||||
|
||||
|
|
|
@ -120,10 +120,9 @@ class MeetingsController extends Controller {
|
|||
$fnames[] = $fname;
|
||||
$image = base64_decode(substr($img, strpos($img, ',') + 1));
|
||||
Storage::disk('private')->put($fname, $image);
|
||||
$this->fiximg($filename);
|
||||
$this->fiximg($fname);
|
||||
|
||||
$imgname = '/files/'.$fname;
|
||||
|
||||
}
|
||||
else {
|
||||
$imgname = $img;
|
||||
|
@ -332,7 +331,7 @@ class MeetingsController extends Controller {
|
|||
$child_select = ['image'];
|
||||
|
||||
// 取得に成功
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->get())) {
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->orderBy('created_at', 'desc')->get())) {
|
||||
return ['status_code' => 400];
|
||||
}
|
||||
|
||||
|
@ -379,7 +378,7 @@ class MeetingsController extends Controller {
|
|||
$child_select = ['image'];
|
||||
|
||||
// 取得に成功
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->get())) {
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->orderBy('created_at', 'desc')->get())) {
|
||||
return ['status_code' => 400];
|
||||
}
|
||||
|
||||
|
@ -420,7 +419,7 @@ class MeetingsController extends Controller {
|
|||
$child_select = ['image'];
|
||||
|
||||
// 取得に成功
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('is_favorite', 1)->get())) {
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('is_favorite', 1)->orderBy('created_at', 'desc')->get())) {
|
||||
return ['status_code' => 400];
|
||||
}
|
||||
|
||||
|
@ -454,7 +453,7 @@ class MeetingsController extends Controller {
|
|||
$child_select = ['image'];
|
||||
|
||||
// 取得に成功
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('is_favorite', 0)->get())) {
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('is_favorite', 0)->orderBy('created_at', 'desc')->get())) {
|
||||
return ['status_code' => 400];
|
||||
}
|
||||
|
||||
|
@ -556,7 +555,7 @@ class MeetingsController extends Controller {
|
|||
$child_select = ['image'];
|
||||
|
||||
// 取得に成功
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('title', 'LIKE', '%'.$r->keyword.'%')->orWhere('text', 'LIKE', '%'.$r->keyword.'%')->get())) {
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('title', 'LIKE', '%'.$r->keyword.'%')->orWhere('text', 'LIKE', '%'.$r->keyword.'%')->orderBy('created_at', 'desc')->get())) {
|
||||
$list = [];
|
||||
}
|
||||
|
||||
|
@ -603,7 +602,7 @@ class MeetingsController extends Controller {
|
|||
$child_select = ['image'];
|
||||
|
||||
// 取得に成功
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('title', 'LIKE', '%'.$r->keyword.'%')->orWhere('text', 'LIKE', '%'.$r->keyword.'%')->get())) {
|
||||
if (null === ($list = Meeting::select($meeting_select)->where('father_id', (int)$r->father_id)->where('title', 'LIKE', '%'.$r->keyword.'%')->orWhere('text', 'LIKE', '%'.$r->keyword.'%')->orderBy('created_at', 'desc')->get())) {
|
||||
$list = [];
|
||||
}
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ class FathersRegistrationTemporaryMail extends Mailable {
|
|||
}
|
||||
|
||||
public function build () {
|
||||
return $this->subject('【KIKIkan】会員登録のご案内')->markdown('emails.fathers.registration.temporary', [
|
||||
return $this->subject('【KIKI】会員登録のご案内')->markdown('emails.fathers.registration.temporary', [
|
||||
'token' => $this->token
|
||||
]);
|
||||
}
|
||||
|
|
|
@ -12929,7 +12929,7 @@ categories: [project]
|
|||
@font-face {
|
||||
font-family: "iconfont";
|
||||
src: url(/fonts/iconfont.eot?9bd2f8e21fb68f3cb69f306c7a5a07d2);
|
||||
src: url(/fonts/iconfont.eot?9bd2f8e21fb68f3cb69f306c7a5a07d2) format("eot"), url(/fonts/iconfont.woff?72290a51f520574be856b3621acc29a1) format("woff"), url(/fonts/iconfont.ttf?e240ce427caf7549e576c77b39a1d3f1) format("truetype"), url(/fonts/iconfont.svg?9e48c54f8bbb472c1c286234fdd6636f) format("svg");
|
||||
src: url(/fonts/iconfont.eot?9bd2f8e21fb68f3cb69f306c7a5a07d2) format("eot"), url(/fonts/iconfont.woff?72290a51f520574be856b3621acc29a1) format("woff"), url(/fonts/iconfont.ttf?e240ce427caf7549e576c77b39a1d3f1) format("truetype"), url(/fonts/iconfont.svg?d812f238f7ec32f5cb5ebd322f320a02) format("svg");
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
|
|
ファイル差分が大きすぎるため省略します
差分を読み込み
|
@ -1,9 +1,9 @@
|
|||
@component('mail::message')
|
||||
# 【KIKIkan】会員登録のご案内
|
||||
# 【KIKI】会員登録のご案内
|
||||
|
||||
KIKIkanサービスの会員登録のご案内です。
|
||||
KIKIサービスの会員登録のご案内です。
|
||||
|
||||
KIKIkanシステムのご利用ありがとうございます。
|
||||
KIKIシステムのご利用ありがとうございます。
|
||||
|
||||
※本登録完了後にホーム画面もしくはブックマークに登録してください。<br />
|
||||
ログインする際に利用します。
|
||||
|
@ -22,7 +22,7 @@ URLの有効期限を過ぎると、再登録が必要になりますので、
|
|||
|
||||
■□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□□■
|
||||
|
||||
KIKIkan運営事務局<br />
|
||||
KIKI運営事務局<br />
|
||||
56@zotman.jp<br />
|
||||
{{ url('/') }}/
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<tr>
|
||||
<td class="header">
|
||||
<a href="{{ $url }}" style="display: inline-block;">
|
||||
<img src="{{ $url }}/assets/img/common/logo.png" class="logo" alt="KIKIkan">
|
||||
<img src="{{ $url }}/assets/img/common/logo.png" class="logo" alt="KIKI">
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
|
@ -12,8 +12,8 @@ services:
|
|||
- 443:443
|
||||
volumes:
|
||||
- ./backend:/work
|
||||
- /etc/letsencrypt/live/kikikan.xyz:/etc/letsencrypt/live/kikikan.xyz
|
||||
- /etc/letsencrypt/archive/kikikan.xyz:/etc/letsencrypt/archive/kikikan.xyz
|
||||
# - /etc/letsencrypt/live/kikikan.xyz:/etc/letsencrypt/live/kikikan.xyz
|
||||
# - /etc/letsencrypt/archive/kikikan.xyz:/etc/letsencrypt/archive/kikikan.xyz
|
||||
- ./infra/nginx/default.conf:/etc/nginx/conf.d/default.conf
|
||||
working_dir: /work
|
||||
|
||||
|
|
|
@ -1,18 +1,18 @@
|
|||
server {
|
||||
listen 80;
|
||||
listen 443 ssl;
|
||||
# listen 443 ssl;
|
||||
server_name kikikan.xyz;
|
||||
root /work/public;
|
||||
|
||||
# Redirect to HTTPS
|
||||
return 301 https://$host$request_uri;
|
||||
# return 301 https://$host$request_uri;
|
||||
|
||||
# SSL化
|
||||
ssl_certificate /etc/letsencrypt/live/kikikan.xyz/fullchain.pem;
|
||||
ssl_certificate_key /etc/letsencrypt/live/kikikan.xyz/privkey.pem;
|
||||
# ssl_certificate /etc/letsencrypt/live/kikikan.xyz/fullchain.pem;
|
||||
# ssl_certificate_key /etc/letsencrypt/live/kikikan.xyz/privkey.pem;
|
||||
|
||||
access_log /var/log/nginx/ssl-access.log;
|
||||
error_log /var/log/nginx/ssl-error.log;
|
||||
# access_log /var/log/nginx/ssl-access.log;
|
||||
# error_log /var/log/nginx/ssl-error.log;
|
||||
|
||||
add_header X-Frame-Options "SAMEORIGIN";
|
||||
add_header X-XSS-Protection "1; mode=block";
|
||||
|
|
新しいイシューから参照