This is an overview of the logic implemented in Import.php
for external review.
Returns data from previous year's Revised Budget for all forms.
| var gulp = require("gulp"), | |
| sftp = require("gulp-sftp"), | |
| path = require("path"), | |
| changed = require("gulp-changed"), | |
| rename = require("gulp-rename"), | |
| tap = require("gulp-tap"), | |
| notify = require("gulp-notify"), | |
| remoteBaseDir = "/base/dir/on/server", | |
| watchedFilesToUpload = ["css/**/*.css", "js/**/*.js"]; |
| // Make sure user has card on file. | |
| if (empty($user['cclastfour'])) { | |
| $config['vars']['nocard'] = true; | |
| $config['vars']['error'] = 'You do not have any payment methods on file'; | |
| return $config; | |
| } | |
| $payment = localAPI('capturepayment', ['invoiceid' => $invoice_id], 'admin'); | |
| if ($payment['result'] === 'success') { | |
| $config['vars']['payment']['success'] = sprintf('Payment succeeded'); |
| "use strict"; | |
| /** | |
| * @description A simple formatter for <input type="checkbox"> fields. | |
| * @usage <input type="checkbox" ng-model="myCheckbox" boolean> | |
| */ | |
| angular.module("clls").directive("boolean", function() { | |
| return { | |
| require: "ngModel", | |
| link: function(scope, element, attrs, ngModel) { |
| /** | |
| * @description A simple check to ensure a number is not zero. Sets the "zero" validation accordingly. | |
| * @usage <input ng-model="myModel" not-zero> | |
| */ | |
| angular.module("app").directive("notZero", function() { | |
| var linkFunc = function(scope, element, attrs, ngModel) { | |
| var zeroValidator = function(value) { | |
| var num = parseFloat(value); |
| <!DOCTYPE html> | |
| <html ng-app="testApp"> | |
| <head> | |
| <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.3.15/angular.min.js"></script> | |
| <meta charset="utf-8"> | |
| <title>JS Bin</title> | |
| <style> | |
| .container { | |
| position: fixed; | |
| bottom: 0; |
| angular.module('chargeback', ['ui.router', 'upload', 'ngAnimate']) | |
| // Lots of code before the directive... | |
| .directive('test', ['$filter', function($filter){ | |
| // This should handle and input and return 0 or a valid float. | |
| function toFloat(val){ | |
| var f = parseFloat(val || 0) | |
| return isFinite(f) ? f : 0; | |
| } |
| // This file is correct version, but is not built dev_appserver because of a | |
| // bug in the SDK. | |
| // +build !appengine | |
| package broker | |
| import ( | |
| "encoding/json" | |
| "errors" |
I hereby claim:
To claim this, I am signing this object:
| package main | |
| import ( | |
| "fmt" | |
| "crypto/md5" | |
| ) | |
| func GetMD5Hash(s string) string { | |
| return fmt.Sprintf("%x", md5.Sum([]byte(s))) | |
| } |