Skip to content

SJTU-UMJI-Tech/JI-Student-Web

Repository files navigation

JI-LIFE

Build Status

A website for ALL students in JI

Requirements

PHP >= v5.4
Composer >= v1.3.2
Nodejs >= v7.4.0
npm >= v4.0.5

The server is built under CodeIgniter 3 and the front-end is built by requirejs.

We strongly recommend you to develop or deploy this website with jetbrains PhpStorm IDE, which applies free education license to students. Our tutorials are mostly based on it.

Installation

Make sure you meet all of the requirements above and run the following script:

php composer.phar install
npm install
npm run compile:template
npm run compile:build

The script does these things:

  • Install PHP dependencies through composer
  • Install Node and Bower dependencies through node and bower
  • Compile the Handlebars templates
  • Build the whole front-end config file app.*.js

To start development, run

sudo npm run deploy:development

To start production, run

sudo npm run deploy:production

This script copy different files for different usages and then you can upload the whole project to the FTP server. You may change the content of files in deployment/development|production for certain purposes.

Remember to set the mode of folders js, css, node_modules, bower_modules to 755, and that of folder uploads to 777, or some functions won't work on Linux Server.

Edit 000-default.conf in etc/apache2/sites-enabled and change the DocumentRoot to your working directory, for example, "var/www/ipp". Then, add

<Directory /var/www/ipp>
    Options Indexes FollowSymLinks
    AllowOverride All
    Order allow,deny
    Allow from all
</Directory>

to the end of file.

Apache2 on Ubuntu doesn't have rewrite engine open, use the command to enable it.

sudo a2enmod rewrite
sudo service apache2 restart

Contribution

All students in JI are welcomed to contribute in this project. For development reference, see the WIKI.

Reference

  • babel Babel is a compiler for writing next generation JavaScript.
  • bootstrap The most popular HTML, CSS, and JavaScript framework for developing responsive, mobile first projects on the web.
  • bootstrap-touchspin A mobile and touch friendly input spinner component for Bootstrap 3.
  • bower A package manager for the web
  • Chart.js Simple HTML5 Charts using the tag
  • chosen Chosen is a library for making long, unwieldy select boxes more friendly.
  • clean-css Fast and efficient CSS optimizer for node.js and the Web
  • code-prettify An embeddable script that makes source-code snippets in HTML prettier.
  • CodeIgniter Open Source PHP Framework (originally from EllisLab)
  • console The Console component eases the creation of beautiful and testable command line interfaces.
  • cropper A simple jQuery image cropping plugin.
  • editor.md The open source embeddable online markdown editor (component).
  • flatpickr lightweight and powerful datetimepicker with no dependencies
  • flowchart.js Draws simple SVG flow chart diagrams from textual representation of the diagram
  • FontAwesome The iconic font and CSS toolkit
  • Footable jQuery plugin to make HTML tables responsive
  • Gritter A small growl-like notification plugin for jQuery
  • Handlebars Handlebars.js is an extension to the Mustache templating language created by Chris Wanstrath.
  • jQuery jQuery JavaScript Library
  • jQuery-slimScroll small jQuery plugin that transforms any div into a scrollable area with a nice scrollbar.
  • jquery-ui The official jQuery user interface library.
  • jquery.flowchart JQuery plugin that allows you to draw a flow chart.
  • js-sequence-diagrams Draws simple SVG sequence diagrams from textual representation of the diagram
  • katex Fast math typesetting for the web.
  • marked A markdown parser and compiler. Built for speed.
  • metismenu A jQuery menu plugin
  • oauth2-client Easy integration with OAuth 2.0 service providers.
  • pace Automatically add a progress bar to your site.
  • PHPExcel A pure PHP library for reading and writing spreadsheet files
  • qrcodejs Cross-browser QRCode generator for javascript
  • raphael JavaScript Vector Library
  • require-css A RequireJS CSS loader plugin to allow CSS requires and optimization
  • requirejs A file and module loader for JavaScript
  • select2 Select2 is a jQuery based replacement for select boxes. It supports searching, remote data sets, and infinite scrolling of results.
  • shelljs Portable Unix shell commands for Node.js
  • toastr Simple javascript toast notifications
  • UglifyJs JavaScript parser / mangler / compressor / beautifier library for NodeJS
  • underscore JavaScript's utility _ belt
  • xterm.js Full xterm terminal, in your browser
  • zend-permissions-acl Provides a lightweight and flexible access control list (ACL) implementation for privileges management.