Skip to content

Instantly share code, notes, and snippets.

@23maverick23
23maverick23 / javascript_resources.md
Created June 3, 2014 16:07 — forked from jookyboi/javascript_resources.md
Here are a set of libraries, plugins and guides which may be useful to your Javascript coding.

Libraries

  • jQuery - The de-facto library for the modern age. It makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers.
  • Backbone - Backbone.js gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.
  • AngularJS - Conventions based MVC framework for HTML5 apps.
  • Underscore - Underscore is a utility-belt library for JavaScript that provides a lot of the functional programming support that you would expect in Prototype.js (or Ruby), but without extending any of the built-in JavaScript objects.
  • lawnchair - Key/value store adapter for indexdb, localStorage
@23maverick23
23maverick23 / python_resources.md
Created June 3, 2014 16:07 — forked from jookyboi/python_resources.md
Python-related modules and guides.

Packages

  • lxml - Pythonic binding for the C libraries libxml2 and libxslt.
  • boto - Python interface to Amazon Web Services
  • Django - Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.
  • Fabric - Library and command-line tool for streamlining the use of SSH for application deployment or systems administration task.
  • PyMongo - Tools for working with MongoDB, and is the recommended way to work with MongoDB from Python.
  • Celery - Task queue to distribute work across threads or machines.
  • pytz - pytz brings the Olson tz database into Python. This library allows accurate and cross platform timezone calculations using Python 2.4 or higher.

Guides

@23maverick23
23maverick23 / dash_tiles_v1.01.js
Created June 13, 2014 15:45
NS: SuiteScript updates for dash tiles
/**
* Copyright NetSuite, Inc. 2013 All rights reserved.
* The following code is a demo prototype. Due to time constraints of a demo,
* the code may contain bugs, may not accurately reflect user requirements
* and may not be the best approach. Actual implementation should not reuse
* this code without due verification.
*
* (Module description here. Whole header length should not exceed
* 100 characters in width. Use another line if needed.)
*
@23maverick23
23maverick23 / markdown_snippets_ace_editor.md
Last active August 29, 2015 14:02
Markdown: snippets for Ace editor
# Markdown

# Includes octopress (http://octopress.org/) snippets

snippet [
	[${1:text}](http://${2:address} "${3:title}")
snippet [*
	[${1:link}](${2:`@*`} "${3:title}")${4}
@23maverick23
23maverick23 / timesheet_flow_example.md
Created June 25, 2014 02:46
NS: example timesheet approval flow

Example Timesheet Approval

s=>start: Enter
e=>end: Exit
o=>operation: Open
p=>operation: Pending Approval
cond=>condition: PM Approved
r=>operation: Rejected
@23maverick23
23maverick23 / srp_advanced_mapping_06232014.nsoa.xml
Last active August 29, 2015 14:03
NSOA: Default advanced mappings 06232014
<PULL>
<EMPLOYEE_TO_USER>
OA_FIELDS nickname,email,role_id,job_code_id,primary_filter_set,line_manager_id
OA_FIELDS_INITIAL_ONLY nickname,email,role_id,job_code_id,primary_filter_set
role_id '2'
job_code_id '2'
primary_filter_set '2'
line_manager_id lookup=supervisor:lookup_table=user:lookup_by=netsuite_user_id:lookup_return=id
</EMPLOYEE_TO_USER>
@23maverick23
23maverick23 / yaml_frontmatter_check.py
Created July 5, 2014 15:09
Python: check YAML frontmatter
import re
with open(f_path, 'rU') as f:
yaml_break = 0
for line in f:
if line == '---\n':
yaml_break += 1
m = re.match("published:", line)
if m and m.group():
# published flag found...
@23maverick23
23maverick23 / checkProjectExpiration.js
Created July 11, 2014 22:42
NSOA: Check project expiration on booking save
/**
* If the booking end date is greater than the
* project expiration date, prevent saving the
* booking and throw a form error.
*/
function checkProjectExpiration(type) {
try {
var fldCustProj = NSOA.form.getValue('customer_project'),
fldEndDate = NSOA.form.getValue('enddate'),
@23maverick23
23maverick23 / createNewResourceRequestHeader.js
Created July 22, 2014 13:44
NSOA: Create new resource request header
function createNewResourceRequestHeader(type) {
try {
var newProjRec = NSOA.form.getNewRecord();
if (newProjRec && newProjRec.prj_staffing_plan__c == '1') {
var myself = NSOA.wsapi.whoami();
var resReqRec = new NSOA.record.oaResourceRequest();
resReqRec.number = newProjRec.prj_autoid__c;
resReqRec.ownerid = (myself && myself.id) ? myself.id : '2';
resReqRec.customerid = newProjRec.customerid;
@23maverick23
23maverick23 / setProjectStageWAR.js
Created July 22, 2014 13:48
NSOA: Set project stage when issue risk type changes
// Set project stage to WAR when Risk type = Cost risk
function setProjectStageWAR(type) {
var fld_category = "issue_stage_id",
fld_risk_type = "RiskType__c",
fld_risk_approval = "RiskApproval__c",
fld_stage = "project_stageid",
fld_iss_project_id = "project_id",
constant_risk = "1",
constant_risk_type = "Cost risk",