質問編集履歴
6
修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -238,7 +238,7 @@
|
|
238
238
|
|
239
239
|
})
|
240
240
|
|
241
|
-
.
|
241
|
+
.fail(function(jqXHR, textStatus, errorThrown){
|
242
242
|
|
243
243
|
console.log(jqXHR);
|
244
244
|
|
5
更新
test
CHANGED
File without changes
|
test
CHANGED
@@ -94,7 +94,9 @@
|
|
94
94
|
|
95
95
|
```progressblade
|
96
96
|
|
97
|
+
|
98
|
+
|
97
|
-
@extends('layouts.app')
|
99
|
+
@extends('layouts.app')
|
98
100
|
|
99
101
|
@section('content')
|
100
102
|
|
@@ -120,15 +122,13 @@
|
|
120
122
|
|
121
123
|
<input type='hidden' name='user_id' value="{{ $user['id'] }}">
|
122
124
|
|
123
|
-
|
124
|
-
|
125
|
-
|
125
|
+
<div class="form-group row”>
|
126
126
|
|
127
127
|
<label for="memo">科目</label>
|
128
128
|
|
129
129
|
|
130
130
|
|
131
|
-
<select name='tagname' id=tagname type="select" class="form-control" >
|
131
|
+
<select name='tagname' id="tagname" type="select" class="form-control" >
|
132
132
|
|
133
133
|
@foreach($tags as $tag)
|
134
134
|
|
@@ -146,7 +146,7 @@
|
|
146
146
|
|
147
147
|
|
148
148
|
|
149
|
-
<select name='content' id=memo type="select" class="form-control" >
|
149
|
+
<select name='content' id="memo" type="select" class="form-control" >
|
150
150
|
|
151
151
|
@foreach($memos as $memo)
|
152
152
|
|
@@ -158,8 +158,6 @@
|
|
158
158
|
|
159
159
|
</select>
|
160
160
|
|
161
|
-
|
162
|
-
|
163
161
|
|
164
162
|
|
165
163
|
<div class="text-center">
|
@@ -176,18 +174,20 @@
|
|
176
174
|
|
177
175
|
</div>
|
178
176
|
|
179
|
-
|
180
|
-
|
181
177
|
@endsection
|
182
178
|
|
179
|
+
|
180
|
+
|
183
181
|
@push('scripts')
|
184
182
|
|
185
|
-
<script src="{{ asset('/js/progress.js') }}"></script>
|
183
|
+
<script src="{{ asset('/js/progress.js') }}" type="module"></script>
|
186
184
|
|
187
185
|
@endpush
|
188
186
|
|
189
187
|
|
190
188
|
|
189
|
+
|
190
|
+
|
191
191
|
```
|
192
192
|
|
193
193
|
```progressjs
|
@@ -238,11 +238,17 @@
|
|
238
238
|
|
239
239
|
})
|
240
240
|
|
241
|
-
|
241
|
+
.$fail(function(jqXHR, textStatus, errorThrown){
|
242
|
+
|
242
|
-
|
243
|
+
console.log(jqXHR);
|
244
|
+
|
243
|
-
|
245
|
+
console.log(textStatus);
|
246
|
+
|
244
|
-
|
247
|
+
console.log(errorThrown);
|
248
|
+
|
245
|
-
})
|
249
|
+
});
|
250
|
+
|
251
|
+
|
246
252
|
|
247
253
|
})
|
248
254
|
|
@@ -260,9 +266,7 @@
|
|
260
266
|
|
261
267
|
layoutsのapp.blade.php
|
262
268
|
|
263
|
-
|
264
|
-
|
265
|
-
|
269
|
+
<!doctype html>
|
266
270
|
|
267
271
|
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
|
268
272
|
|
@@ -286,9 +290,11 @@
|
|
286
290
|
|
287
291
|
<!-- Scripts -->
|
288
292
|
|
293
|
+
|
294
|
+
|
289
|
-
<script src="{{ '
|
295
|
+
<script src="{{ asset('js/app.js') }}" defer></script>
|
290
|
-
|
296
|
+
|
291
|
-
@yield('js')
|
297
|
+
@yield('js')
|
292
298
|
|
293
299
|
|
294
300
|
|
@@ -304,15 +310,31 @@
|
|
304
310
|
|
305
311
|
<!-- Styles -->
|
306
312
|
|
313
|
+
|
314
|
+
|
307
|
-
<link href="{{ '
|
315
|
+
<link href="{{ asset('css/app.css') }}" rel="stylesheet">
|
308
|
-
|
316
|
+
|
309
|
-
<link href="{{ '
|
317
|
+
<link href="{{ asset('css/utility.css') }}" rel="stylesheet">
|
318
|
+
|
319
|
+
@yield('css')
|
320
|
+
|
321
|
+
|
322
|
+
|
323
|
+
|
310
324
|
|
311
325
|
|
312
326
|
|
327
|
+
<script src="//code.jquery.com/jquery-1.12.1.min.js"></script>
|
328
|
+
|
329
|
+
{{-- <script src="{{ asset('js/progress.js') }}" defer></script> --}}
|
330
|
+
|
313
331
|
@stack('scripts')
|
314
332
|
|
315
|
-
|
333
|
+
|
334
|
+
|
335
|
+
|
336
|
+
|
337
|
+
|
316
338
|
|
317
339
|
</head>
|
318
340
|
|
@@ -498,6 +520,12 @@
|
|
498
520
|
|
499
521
|
</div>
|
500
522
|
|
523
|
+
|
524
|
+
|
525
|
+
|
526
|
+
|
527
|
+
|
528
|
+
|
501
529
|
</div>
|
502
530
|
|
503
531
|
</div>
|
@@ -538,6 +566,4 @@
|
|
538
566
|
|
539
567
|
```
|
540
568
|
|
541
|
-
![イメージ説明](9
|
569
|
+
![イメージ説明](38840a495221a0b8dfb4830a1da758ac.png)
|
542
|
-
|
543
|
-
![イメージ説明](6f6f814cc73add9d1c40d671aba3e040.png)
|
4
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -539,3 +539,5 @@
|
|
539
539
|
```
|
540
540
|
|
541
541
|
![イメージ説明](9371fe315e140c59ebd4c816a6cdc3aa.png)
|
542
|
+
|
543
|
+
![イメージ説明](6f6f814cc73add9d1c40d671aba3e040.png)
|
3
追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -92,4 +92,450 @@
|
|
92
92
|
|
93
93
|
### 補足情報
|
94
94
|
|
95
|
-
|
95
|
+
```progressblade
|
96
|
+
|
97
|
+
@extends('layouts.app')
|
98
|
+
|
99
|
+
@section('content')
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
<div class="row justify-content-center ml-0 mr-0 h-100">
|
106
|
+
|
107
|
+
<div class="card w-100">
|
108
|
+
|
109
|
+
<div class="card-header">進捗状況登録</div>
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
<div class="card-body">
|
114
|
+
|
115
|
+
<form method='POST' action="/store2">
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
@csrf
|
120
|
+
|
121
|
+
<input type='hidden' name='user_id' value="{{ $user['id'] }}">
|
122
|
+
|
123
|
+
|
124
|
+
|
125
|
+
<div class="form-group row”>
|
126
|
+
|
127
|
+
<label for="memo">科目</label>
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
<select name='tagname' id=tagname type="select" class="form-control" >
|
132
|
+
|
133
|
+
@foreach($tags as $tag)
|
134
|
+
|
135
|
+
<option value="{{ $tag['tagname']}}">{{ $tag['tagname']}}</option>
|
136
|
+
|
137
|
+
@endforeach
|
138
|
+
|
139
|
+
</select>
|
140
|
+
|
141
|
+
<div>
|
142
|
+
|
143
|
+
<div class="form-group row”>
|
144
|
+
|
145
|
+
<label for="memo">課題</label>
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
<select name='content' id=memo type="select" class="form-control" >
|
150
|
+
|
151
|
+
@foreach($memos as $memo)
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
<option value="{{ $memo['content']}}">{{ $memo['content']}}</option>
|
156
|
+
|
157
|
+
@endforeach
|
158
|
+
|
159
|
+
</select>
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
|
164
|
+
|
165
|
+
<div class="text-center">
|
166
|
+
|
167
|
+
<button type='submit' class="btn btn-danger btn-lg">登録する</button>
|
168
|
+
|
169
|
+
</div>
|
170
|
+
|
171
|
+
</form>
|
172
|
+
|
173
|
+
</div>
|
174
|
+
|
175
|
+
</div>
|
176
|
+
|
177
|
+
</div>
|
178
|
+
|
179
|
+
|
180
|
+
|
181
|
+
@endsection
|
182
|
+
|
183
|
+
@push('scripts')
|
184
|
+
|
185
|
+
<script src="{{ asset('/js/progress.js') }}"></script>
|
186
|
+
|
187
|
+
@endpush
|
188
|
+
|
189
|
+
|
190
|
+
|
191
|
+
```
|
192
|
+
|
193
|
+
```progressjs
|
194
|
+
|
195
|
+
$(function() {
|
196
|
+
|
197
|
+
// 「科目」のセレクトボックスが変更された場合
|
198
|
+
|
199
|
+
$('#tagname').on('change', function() {
|
200
|
+
|
201
|
+
// value属性の値を取得
|
202
|
+
|
203
|
+
let tag_name_val = $(this).val();
|
204
|
+
|
205
|
+
// tag_name_valをHomeControllerへ渡す
|
206
|
+
|
207
|
+
$.ajax({
|
208
|
+
|
209
|
+
headers: {
|
210
|
+
|
211
|
+
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
|
212
|
+
|
213
|
+
},
|
214
|
+
|
215
|
+
type: "POST",
|
216
|
+
|
217
|
+
url: "/addContent",
|
218
|
+
|
219
|
+
dataType: "JSON",
|
220
|
+
|
221
|
+
data: {
|
222
|
+
|
223
|
+
val: tag_name_val
|
224
|
+
|
225
|
+
}
|
226
|
+
|
227
|
+
})
|
228
|
+
|
229
|
+
.done(function(data) {
|
230
|
+
|
231
|
+
$.each(data['memos'], function(index, value) {
|
232
|
+
|
233
|
+
// コントローラ側で取得した課題のデータをセレクトボックスに追加する
|
234
|
+
|
235
|
+
$('#memo').append($('<option>').val(value.id).text(value.name));
|
236
|
+
|
237
|
+
})
|
238
|
+
|
239
|
+
})
|
240
|
+
|
241
|
+
.fail(function() {
|
242
|
+
|
243
|
+
// 失敗した際の処理を記述
|
244
|
+
|
245
|
+
})
|
246
|
+
|
247
|
+
})
|
248
|
+
|
249
|
+
})
|
250
|
+
|
251
|
+
|
252
|
+
|
253
|
+
|
254
|
+
|
255
|
+
|
256
|
+
|
257
|
+
```
|
258
|
+
|
259
|
+
```app
|
260
|
+
|
261
|
+
layoutsのapp.blade.php
|
262
|
+
|
263
|
+
|
264
|
+
|
265
|
+
<!doctype html>
|
266
|
+
|
267
|
+
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
|
268
|
+
|
269
|
+
<head>
|
270
|
+
|
271
|
+
<meta charset="utf-8">
|
272
|
+
|
273
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
274
|
+
|
275
|
+
<body bgcolor="black" text="white">
|
276
|
+
|
277
|
+
<!-- CSRF Token -->
|
278
|
+
|
279
|
+
<meta name="csrf-token" content="{{ csrf_token() }}">
|
280
|
+
|
281
|
+
|
282
|
+
|
283
|
+
<title>{{ config('app.name', 'SimpleNote') }}</title>
|
284
|
+
|
285
|
+
|
286
|
+
|
287
|
+
<!-- Scripts -->
|
288
|
+
|
289
|
+
<script src="{{ '/js/app.js' }}" defer></script>
|
290
|
+
|
291
|
+
@yield('js')
|
292
|
+
|
293
|
+
|
294
|
+
|
295
|
+
<!-- Fonts -->
|
296
|
+
|
297
|
+
<link rel="dns-prefetch" href="//fonts.gstatic.com">
|
298
|
+
|
299
|
+
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.1.0/css/all.css" integrity="sha384-lKuwvrZot6UHsBSfcMvOkWwlCMgc0TaWr+30HWe3a4ltaBwTZhyTEggF5tJv8tbt" crossorigin="anonymous">
|
300
|
+
|
301
|
+
<link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">
|
302
|
+
|
303
|
+
|
304
|
+
|
305
|
+
<!-- Styles -->
|
306
|
+
|
307
|
+
<link href="{{ '/css/app.css' }}" rel="stylesheet">
|
308
|
+
|
309
|
+
<link href="{{ '/css/utility.css' }}" rel="stylesheet">
|
310
|
+
|
311
|
+
|
312
|
+
|
313
|
+
@stack('scripts')
|
314
|
+
|
315
|
+
@yield('css')
|
316
|
+
|
317
|
+
</head>
|
318
|
+
|
319
|
+
<body>
|
320
|
+
|
321
|
+
<div id="app">
|
322
|
+
|
323
|
+
<nav class="navbar navbar-expand-md navbar-light bg-white shadow-sm">
|
324
|
+
|
325
|
+
<div class="container">
|
326
|
+
|
327
|
+
<a class="navbar-brand" href="{{ url('/') }}">
|
328
|
+
|
329
|
+
{{ config('app.name', 'Laravel') }}
|
330
|
+
|
331
|
+
</a>
|
332
|
+
|
333
|
+
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="{{ __('Toggle navigation') }}">
|
334
|
+
|
335
|
+
<span class="navbar-toggler-icon"></span>
|
336
|
+
|
337
|
+
</button>
|
338
|
+
|
339
|
+
|
340
|
+
|
341
|
+
<div class="collapse navbar-collapse" id="navbarSupportedContent">
|
342
|
+
|
343
|
+
<!-- Left Side Of Navbar -->
|
344
|
+
|
345
|
+
<ul class="navbar-nav mr-auto">
|
346
|
+
|
347
|
+
|
348
|
+
|
349
|
+
</ul>
|
350
|
+
|
351
|
+
|
352
|
+
|
353
|
+
<!-- Right Side Of Navbar -->
|
354
|
+
|
355
|
+
<ul class="navbar-nav ml-auto">
|
356
|
+
|
357
|
+
<!-- Authentication Links -->
|
358
|
+
|
359
|
+
@guest
|
360
|
+
|
361
|
+
<li class="nav-item">
|
362
|
+
|
363
|
+
<a class="nav-link" href="{{ route('login') }}">{{ __('Login') }}</a>
|
364
|
+
|
365
|
+
</li>
|
366
|
+
|
367
|
+
@if (Route::has('register'))
|
368
|
+
|
369
|
+
<li class="nav-item">
|
370
|
+
|
371
|
+
<a class="nav-link" href="{{ route('register') }}">{{ __('Register') }}</a>
|
372
|
+
|
373
|
+
</li>
|
374
|
+
|
375
|
+
@endif
|
376
|
+
|
377
|
+
@else
|
378
|
+
|
379
|
+
<li class="nav-item dropdown">
|
380
|
+
|
381
|
+
<a id="navbarDropdown" class="nav-link dropdown-toggle" href="#" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" v-pre>
|
382
|
+
|
383
|
+
{{ Auth::user()->name }} <span class="caret"></span>
|
384
|
+
|
385
|
+
</a>
|
386
|
+
|
387
|
+
|
388
|
+
|
389
|
+
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="navbarDropdown">
|
390
|
+
|
391
|
+
<a class="dropdown-item" href="{{ route('logout') }}"
|
392
|
+
|
393
|
+
onclick="event.preventDefault();
|
394
|
+
|
395
|
+
document.getElementById('logout-form').submit();">
|
396
|
+
|
397
|
+
{{ __('ログアウト') }}
|
398
|
+
|
399
|
+
</a>
|
400
|
+
|
401
|
+
|
402
|
+
|
403
|
+
<form id="logout-form" action="{{ route('logout') }}" method="POST" style="display: none;">
|
404
|
+
|
405
|
+
@csrf
|
406
|
+
|
407
|
+
</form>
|
408
|
+
|
409
|
+
</div>
|
410
|
+
|
411
|
+
</li>
|
412
|
+
|
413
|
+
@endguest
|
414
|
+
|
415
|
+
</ul>
|
416
|
+
|
417
|
+
</div>
|
418
|
+
|
419
|
+
</div>
|
420
|
+
|
421
|
+
</nav>
|
422
|
+
|
423
|
+
|
424
|
+
|
425
|
+
<main class="main">
|
426
|
+
|
427
|
+
@if(session('success'))
|
428
|
+
|
429
|
+
<div class="alert alert-success" role="alert">
|
430
|
+
|
431
|
+
{{ session('success') }}
|
432
|
+
|
433
|
+
</div>
|
434
|
+
|
435
|
+
@endif
|
436
|
+
|
437
|
+
|
438
|
+
|
439
|
+
<div class="card" style="width: 18rem;">
|
440
|
+
|
441
|
+
<ul class="list-group list-group-flush">
|
442
|
+
|
443
|
+
<li class="list-group-item">
|
444
|
+
|
445
|
+
<a href="{{ url('/mypage') }}"> マイページ </a>
|
446
|
+
|
447
|
+
</li>
|
448
|
+
|
449
|
+
<li class="list-group-item">
|
450
|
+
|
451
|
+
<a href="{{ url('/add') }}"> 科目登録 </a>
|
452
|
+
|
453
|
+
</li>
|
454
|
+
|
455
|
+
<li class="list-group-item">
|
456
|
+
|
457
|
+
<a href="{{ url('/create') }}"> 課題作成 </a></li>
|
458
|
+
|
459
|
+
<li class="list-group-item">
|
460
|
+
|
461
|
+
<a href="{{ url('/progress') }}"> 進捗状況登録 </a></li>
|
462
|
+
|
463
|
+
</ul>
|
464
|
+
|
465
|
+
</div>
|
466
|
+
|
467
|
+
</div>
|
468
|
+
|
469
|
+
<p></p>
|
470
|
+
|
471
|
+
<div class="card" style="width: 18rem;">
|
472
|
+
|
473
|
+
<div class="card w-100 ">
|
474
|
+
|
475
|
+
<div class="card-header">科目一覧</div>
|
476
|
+
|
477
|
+
<p></p>
|
478
|
+
|
479
|
+
<a href="{{ url('/kadai') }}"> 科目名(課題詳細) </a></li>
|
480
|
+
|
481
|
+
@foreach($tags as $tag)
|
482
|
+
|
483
|
+
|
484
|
+
|
485
|
+
<a href="/?tag={{ $tag['tagname'] }}" class='d-block'>{{ $tag['tagname'] }}</a>
|
486
|
+
|
487
|
+
@endforeach
|
488
|
+
|
489
|
+
|
490
|
+
|
491
|
+
<div class="card-body ">
|
492
|
+
|
493
|
+
</div>
|
494
|
+
|
495
|
+
</div>
|
496
|
+
|
497
|
+
</div>
|
498
|
+
|
499
|
+
</div>
|
500
|
+
|
501
|
+
</div>
|
502
|
+
|
503
|
+
</div>
|
504
|
+
|
505
|
+
</div> <!-- col-md-3 -->
|
506
|
+
|
507
|
+
|
508
|
+
|
509
|
+
<div style="position:absolute; top:80px; left:300px;'>
|
510
|
+
|
511
|
+
<div class="col-md-8">
|
512
|
+
|
513
|
+
|
514
|
+
|
515
|
+
@yield('content')
|
516
|
+
|
517
|
+
</div>
|
518
|
+
|
519
|
+
</div>
|
520
|
+
|
521
|
+
</div>
|
522
|
+
|
523
|
+
</div>
|
524
|
+
|
525
|
+
</div> <!-- row justify-content-center -->
|
526
|
+
|
527
|
+
</div>
|
528
|
+
|
529
|
+
</main>
|
530
|
+
|
531
|
+
</div>
|
532
|
+
|
533
|
+
@yield('footer')
|
534
|
+
|
535
|
+
</body>
|
536
|
+
|
537
|
+
</html>
|
538
|
+
|
539
|
+
```
|
540
|
+
|
541
|
+
![イメージ説明](9371fe315e140c59ebd4c816a6cdc3aa.png)
|
2
誤字
test
CHANGED
File without changes
|
test
CHANGED
@@ -22,7 +22,7 @@
|
|
22
22
|
|
23
23
|
|
24
24
|
|
25
|
-
```progres
|
25
|
+
```progress
|
26
26
|
|
27
27
|
<div class="form-group row”>
|
28
28
|
|
1
修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -93,5 +93,3 @@
|
|
93
93
|
### 補足情報
|
94
94
|
|
95
95
|
画像を載せさせていただきました。
|
96
|
-
|
97
|
-
詳しく、コードを教えていただけたら幸いです。
|