Skip to content

Commit

Permalink
Ref #215: add Select2 library
Browse files Browse the repository at this point in the history
  • Loading branch information
LucileDT committed Jul 11, 2020
1 parent fbf99c0 commit 15b5db4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ public/javascript/library/jQuery
public/javascript/library/DataTables
public/javascript/library/Chart.js
public/javascript/library/Moment
public/javascript/library/Select2
public/images/uploads/
###< local files ###

Expand Down
8 changes: 7 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,13 @@
"wget https://github.com/chartjs/Chart.js/releases/download/v2.9.3/Chart.min.js -O ./vendor/Chart.js/chart.min.js",
"wget https://github.com/chartjs/Chart.js/releases/download/v2.9.3/Chart.min.css -O ./vendor/Chart.js/chart.min.css",
"ln -sf ../../../../vendor/Chart.js/chart.min.js ./public/javascript/library/Chart.js/chart.min.js",
"ln -sf ../../../../vendor/Chart.js/chart.min.css ./public/javascript/library/Chart.js/chart.min.css"
"ln -sf ../../../../vendor/Chart.js/chart.min.css ./public/javascript/library/Chart.js/chart.min.css",
"wget https://github.com/select2/select2/archive/4.0.13.zip -O ./vendor/select2.zip",
"unzip -o vendor/select2.zip -d vendor/",
"rm -r vendor/Select2",
"mv vendor/select2-4.0.13 vendor/Select2",
"rm vendor/select2.zip",
"ln -sf ../../../vendor/Select2/dist ./public/javascript/library/Select2"
],
"post-update-cmd": [
"@auto-scripts"
Expand Down
2 changes: 2 additions & 0 deletions templates/Home/base.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
{% block global_css %}
<link rel="stylesheet" href="{{ asset('css/library/Bootstrap/bootstrap.min.css') }}">
<link rel="stylesheet" href="{{ asset('javascript/library/DataTables/datatables.min.css') }}">
<link rel="stylesheet" href="{{ asset('javascript/library/Select2/css/select2.min.css') }}">
<link rel="stylesheet" href="{{ asset('javascript/library/Chart.js/chart.min.css') }}">
<link rel="stylesheet" href="{{ asset('css/library/theme.min.css') }}">
<link rel="stylesheet" href="{{ asset('css/global.css') }}">
Expand All @@ -14,6 +15,7 @@
<script src="{{ asset('javascript/library/jQuery/jquery.min.js') }}"></script>
<script src="{{ asset('javascript/library/Moment/moment-with-locales.min.js') }}"></script>
<script src="{{ asset('javascript/library/DataTables/datatables.min.js') }}"></script>
<script src="{{ asset('javascript/library/Select2/js/select2.full.min.js') }}"></script>
<script src="{{ asset('javascript/library/Chart.js/chart.min.js') }}"></script>
<script src="{{ asset('javascript/library/Bootstrap/bootstrap.bundle.min.js') }}"></script>
<script src="{{ asset('javascript/global.js') }}"></script>
Expand Down

0 comments on commit 15b5db4

Please sign in to comment.