mirror of
				https://github.com/firefly-iii/firefly-iii.git
				synced 2025-11-04 05:15:39 +00:00 
			
		
		
		
	Various code cleanup.
This commit is contained in:
		@@ -19,6 +19,8 @@ sed -i 's/# fr_FR.UTF-8 UTF-8/fr_FR.UTF-8 UTF-8/g' /etc/locale.gen
 | 
			
		||||
dpkg-reconfigure --frontend=noninteractive locales
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# actually add repository
 | 
			
		||||
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E9C74FEEA2098A6E
 | 
			
		||||
add-apt-repository "deb http://packages.dotdeb.org jessie all"
 | 
			
		||||
@@ -37,6 +39,10 @@ service mysql stop
 | 
			
		||||
systemctl disable nginx
 | 
			
		||||
systemctl disable php7.1-fpm
 | 
			
		||||
systemctl disable mysql
 | 
			
		||||
 | 
			
		||||
# make php.ini display errors:
 | 
			
		||||
sed -i 's/display_errors = Off/display_errors = On/g' /etc/php/7.1/fpm/php.ini
 | 
			
		||||
 | 
			
		||||
# patch /etc/php/7.1/fpm/pool.d/www.conf to not change uid/gid to www-data
 | 
			
		||||
sed --in-place='' \
 | 
			
		||||
       --expression='s/^listen.owner = www-data/;listen.owner = www-data/' \
 | 
			
		||||
@@ -72,3 +78,5 @@ cat <<EOF > /etc/mysql/conf.d/sandstorm.cnf
 | 
			
		||||
# Set the main data file to grow by 1MB at a time, rather than 8MB at a time.
 | 
			
		||||
innodb_autoextend_increment = 1
 | 
			
		||||
EOF
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -48,20 +48,20 @@ class StartFireflySession extends StartSession
 | 
			
		||||
//        return parent::handle($request, $next); // defer to the right stuff
 | 
			
		||||
//    }
 | 
			
		||||
 | 
			
		||||
//    /**
 | 
			
		||||
//     * Store the current URL for the request if necessary.
 | 
			
		||||
//     *
 | 
			
		||||
//     * @param  \Illuminate\Http\Request              $request
 | 
			
		||||
//     * @param  \Illuminate\Contracts\Session\Session $session
 | 
			
		||||
//     *
 | 
			
		||||
//     * @return void
 | 
			
		||||
//     */
 | 
			
		||||
//    protected function storeCurrentUrl(Request $request, $session)
 | 
			
		||||
//    {
 | 
			
		||||
//        $uri    = $request->fullUrl();
 | 
			
		||||
//        $strpos = strpos($uri, 'jscript');
 | 
			
		||||
//        if ($request->method() === 'GET' && $request->route() && !$request->ajax() && $strpos === false) {
 | 
			
		||||
//            $session->setPreviousUrl($uri);
 | 
			
		||||
//        }
 | 
			
		||||
//    }
 | 
			
		||||
    /**
 | 
			
		||||
     * Store the current URL for the request if necessary.
 | 
			
		||||
     *
 | 
			
		||||
     * @param  \Illuminate\Http\Request              $request
 | 
			
		||||
     * @param  \Illuminate\Contracts\Session\Session $session
 | 
			
		||||
     *
 | 
			
		||||
     * @return void
 | 
			
		||||
     */
 | 
			
		||||
    protected function storeCurrentUrl(Request $request, $session)
 | 
			
		||||
    {
 | 
			
		||||
        $uri    = $request->fullUrl();
 | 
			
		||||
        $strpos = strpos($uri, 'jscript');
 | 
			
		||||
        if ($request->method() === 'GET' && $request->route() && !$request->ajax() && $strpos === false) {
 | 
			
		||||
            $session->setPreviousUrl($uri);
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										3
									
								
								public/js/ff/firefly.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										3
									
								
								public/js/ff/firefly.js
									
									
									
									
										vendored
									
									
								
							@@ -65,7 +65,8 @@ $(function () {
 | 
			
		||||
            $.post(dateRangeMeta.uri, {
 | 
			
		||||
                start: start.format('YYYY-MM-DD'),
 | 
			
		||||
                end: end.format('YYYY-MM-DD'),
 | 
			
		||||
                label: label
 | 
			
		||||
                label: label,
 | 
			
		||||
                _token: token
 | 
			
		||||
            }).done(function () {
 | 
			
		||||
                window.location.reload(true);
 | 
			
		||||
            }).fail(function () {
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										22
									
								
								public/js/ff/index.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										22
									
								
								public/js/ff/index.js
									
									
									
									
										vendored
									
									
								
							@@ -102,26 +102,4 @@ function getBalanceBox() {
 | 
			
		||||
        $('#box-balance-in').html(data.income);
 | 
			
		||||
        $('#box-balance-out').html(data.expense);
 | 
			
		||||
    });
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
function getBoxAmounts() {
 | 
			
		||||
    "use strict";
 | 
			
		||||
    var boxes = ['in', 'out', 'bills-unpaid', 'bills-paid'];
 | 
			
		||||
    for (var x in boxes) {
 | 
			
		||||
        if (!boxes.hasOwnProperty(x)) {
 | 
			
		||||
            continue;
 | 
			
		||||
        }
 | 
			
		||||
        var box = boxes[x];
 | 
			
		||||
        $.getJSON('json/box/' + box).done(putData).fail(failData);
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
function putData(data) {
 | 
			
		||||
    "use strict";
 | 
			
		||||
    $('#box-' + data.box).html(data.amount);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
function failData() {
 | 
			
		||||
    "use strict";
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user