Skip to content

Commit 86d1c0e

Browse files
CostaTassielli04rino-andriano
authored andcommitted
New: Added sample file CSV to Import School-Classes and Users
1 parent 2b1e1f9 commit 86d1c0e

4 files changed

Lines changed: 116 additions & 1 deletion

File tree

public/download/classi-sample.csv

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
id,site_id,year,course,section
2+

public/download/student-sample.csv

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
first_name,last_name,email,class_id,site_id

resources/views/pages/classes/import.blade.php

Lines changed: 57 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,58 @@
1-
@extends('layouts.app', ['title' => 'Importazione studenti'])
1+
<?php
2+
/**
3+
* File: /resources/views/pages/classes/import.blade.php
4+
* @package smartbreak
5+
* @author Costantino Tassielli <costantino.tassielli.inf@colamonicochiarulli.edu.it>
6+
* @copyright (c)2022 IISS Colamonico-Chiarulli Acquaviva delle Fonti (BA) Italy
7+
* Created Date: Saturday, December 3rd 2022, 10:35:48 am
8+
* -----
9+
* Last Modified: December 17th 2022 10:07:22 am
10+
* Modified By: Costantino Tassielli <costantino.tassielli.inf@colamonicochiarulli.edu.it>
11+
* -----
12+
* HISTORY:
13+
* Date By Comments
14+
* ---------- ------------- ----------------------------------
15+
* 2022-12-17 C. Tassielli Added sample file CSV
16+
* A. Liuzzi
17+
* 2021-05-18 R. Andriano Import CSV School-Classes & Students
18+
* -----
19+
* @license https://www.gnu.org/licenses/agpl-3.0.html AGPL 3.0
20+
* ------------------------------------------------------------------------------
21+
* SmartBreak is a School Bar food booking web application
22+
* developed during the PON course "The AppFactory" 2020-2021 with teachers
23+
* & students of "Informatica e Telecomunicazioni"
24+
* at IISS "C. Colamonico - N. Chiarulli" Acquaviva delle Fonti (BA)-Italy
25+
* Expert dr. Giovanni Ciriello <giovanni.ciriello.5@gmail.com>
26+
* ----------------------------------------------------------------------------
27+
* SmartBreak is free software; you can redistribute it and/or modify it under
28+
* the terms of the GNU Affero General Public License version 3 as published by
29+
* the Free Software Foundation
30+
*
31+
* SmartBreak is distributed in the hope that it will be useful, but WITHOUT
32+
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
33+
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
34+
* details.
35+
* You should have received a copy of the GNU Affero General Public License along
36+
* with this program; if not, see http://www.gnu.org/licenses or write to the Free
37+
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
38+
* 02110-1301 USA.
39+
*
40+
* The interactive user interfaces in original and modified versions
41+
* of this program must display Appropriate Legal Notices, as required under
42+
* Section 5 of the GNU Affero General Public License version 3.
43+
*
44+
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
45+
* these Appropriate Legal Notices must retain the display of the SmartBreak
46+
* logo and IISS "Colamonico-Chiarulli" copyright notice. If the display of the logo
47+
* is not reasonably feasible for technical reasons, the Appropriate Legal Notices
48+
* must display the words
49+
* "(C) IISS Colamonico-Chiarulli-https://colamonicochiarulli.edu.it - 2022".
50+
*
51+
* ------------------------------------------------------------------------------
52+
*/
53+
54+
?>
55+
@extends('layouts.app', ['title' => 'Importazione classi'])
256
@include('plugins.toastr')
357

458
@section('content')
@@ -13,6 +67,8 @@
1367
<form action="{{ route('classes.import-csv') }}" method="POST" enctype="multipart/form-data">
1468
@csrf
1569
<div class="form-group">
70+
<p>Il file csv delle classi deve avere i seguenti campi: id,site_id,year,course,section</p>
71+
<a href="{{asset('download/classi-sample.csv')}}" target="_blank" rel="nofollow noopener noreferrer" title="Download sample csv ">Scarica CSV classi di esempio</a>
1672
<div class="custom-file">
1773
<input type="file" class="custom-file-input" id="customFile" name="file" onchange="$('#upload-file-info').html(this.files[0].name)">
1874
<label class="custom-file-label" id="upload-file-info" for="customFile">Scegli il file</label>

resources/views/pages/users/import.blade.php

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,57 @@
1+
<?php
2+
/**
3+
* File: /resources/views/pages/users/import.blade.php
4+
* @package smartbreak
5+
* @author Costantino Tassielli <costantino.tassielli.inf@colamonicochiarulli.edu.it>
6+
* @copyright (c)2022 IISS Colamonico-Chiarulli Acquaviva delle Fonti (BA) Italy
7+
* Created Date: Saturday, December 3rd 2022, 10:34:17 am
8+
* -----
9+
* Last Modified: December 17th 2022 10:07:50 am
10+
* Modified By: Costantino Tassielli <costantino.tassielli.inf@colamonicochiarulli.edu.it>
11+
* -----
12+
* HISTORY:
13+
* Date By Comments
14+
* ---------- ------------- ----------------------------------
15+
* 2022-12-17 C. Tassielli Added sample file CSV
16+
* A. Liuzzi
17+
* 2021-05-18 R. Andriano Import CSV School-Classes & Students
18+
* -----
19+
* @license https://www.gnu.org/licenses/agpl-3.0.html AGPL 3.0
20+
* ------------------------------------------------------------------------------
21+
* SmartBreak is a School Bar food booking web application
22+
* developed during the PON course "The AppFactory" 2020-2021 with teachers
23+
* & students of "Informatica e Telecomunicazioni"
24+
* at IISS "C. Colamonico - N. Chiarulli" Acquaviva delle Fonti (BA)-Italy
25+
* Expert dr. Giovanni Ciriello <giovanni.ciriello.5@gmail.com>
26+
* ----------------------------------------------------------------------------
27+
* SmartBreak is free software; you can redistribute it and/or modify it under
28+
* the terms of the GNU Affero General Public License version 3 as published by
29+
* the Free Software Foundation
30+
*
31+
* SmartBreak is distributed in the hope that it will be useful, but WITHOUT
32+
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
33+
* FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
34+
* details.
35+
* You should have received a copy of the resources/views/pages/users/import.blade.phpGNU Affero General Public License along
36+
* with this program; if not, see http://www.gnu.org/licenses or write to the Free
37+
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
38+
* 02110-1301 USA.
39+
*
40+
* The interactive user interfaces in original and modified versions
41+
* of this program must display Appropriate Legal Notices, as required under
42+
* Section 5 of the GNU Affero General Public License version 3.
43+
*
44+
* In accordance with Section 7(b) of the GNU Affero General Public License version 3,
45+
* these Appropriate Legal Notices must retain the display of the SmartBreak
46+
* logo and IISS "Colamonico-Chiarulli" copyright notice. If the display of the logo
47+
* is not reasonably feasible for technical reasons, the Appropriate Legal Notices
48+
* must display the words
49+
* "(C) IISS Colamonico-Chiarulli-https://colamonicochiarulli.edu.it - 2022".
50+
*
51+
* ------------------------------------------------------------------------------
52+
*/
53+
54+
?>
155
@extends('layouts.app', ['title' => 'Importazione studenti'])
256

357
@section('content')
@@ -12,6 +66,8 @@
1266
<form action="{{ route('users.import-csv') }}" method="POST" enctype="multipart/form-data">
1367
@csrf
1468
<div class="form-group">
69+
<p>Il file csv degli studenti deve avere i seguenti campi:first_name,last_name,email,class_id,site_id</p>
70+
<a href="{{asset('download/student-sample.csv')}}" target="_blank" rel="nofollow noopener noreferrer" title="Download sample csv ">Scarica CSV studenti di esempio</a>
1571
<div class="custom-file">
1672
<input type="file" class="custom-file-input" id="customFile" name="file" onchange="$('#upload-file-info').html(this.files[0].name)">
1773
<label class="custom-file-label" id="upload-file-info" for="customFile">Scegli il file</label>

0 commit comments

Comments
 (0)