Skip to content

Instantly share code, notes, and snippets.

@B-uny
B-uny / Zapier: Create Quickbooks Estimate with Shipping
Created June 26, 2020 18:24
Zapier does not have a working integration to create an estimate in quickbooks with shipping. In order to solve this you can create a custom zap with this code.
var des = bundle.inputData.description;
var qty = bundle.inputData.qty;
var rate = bundle.inputData.rate;
var serv = bundle.inputData.service;
var servID = bundle.inputData.serviceID;
var shippingAmount = bundle.inputData.shipping;
var desFin = des.split(',');
var qtyFin = qty.split(',');
var rateFin = rate.split(',');
var servFin = serv.split(',');
@B-uny
B-uny / SQL Query with PHP Filter
Last active February 11, 2020 15:08
Useful for querying & filtering multiple tables in php. Note that you can run multi-query instead of individual calls (I prefer to separate my calls line by line).
<?php
//on ajax POST of user defined var
if(isset($_POST['msg'])){
//include the SQL configuration and request
include('configFiles.php');
//var sent with POST to be queried
$keywords = $_POST['keywords'];
//send queries
@B-uny
B-uny / Shopify Custom Checkout for Zapier Webhook
Last active September 5, 2019 19:37
The following still needs to be cleaned up but it works. Editing as I get the chance. This works to create a button that when clicked will send the user to a checkout page and send line_items and notes to the webhook. Legend as follows: "orderTag = note textarea; updatec=update input button; redirect-href= whatever your page is"
<!--progress bar edited From: https://www.w3schools.com/howto/howto_js_progressbar.asp-->
<!--Thank you html & countDown function from: https://www.jotform.com/help/89-Create-a-Custom-Thank-you-page-with-Auto-redirect-->
<!--redirect page-->
<!--create a new page and add this to the script area-->
<div style="text-align: center;">
<h1>Thank you!</h1>
<p> </p>
<p>Your request has been received and our team is reviewing. Need another estimate? Click Upload RFQ or Build RFQ Request on the tab above!</p>
<span id="timer"> </span>
<div id="myProgress" style="width: 100%; background-color: #ddd;">
@B-uny
B-uny / Shopify Customer Order History Search
Last active August 29, 2019 13:05
Adding a search bar to order history in flits (workaround with JQuery). Haven't tried it in the normal cart but it wouldn't be too hard to implement. I found nothing on the flits site or shopify that said you can't add code to code that an app installs, but if anyone finds out that is the case please contact this account and I will remake this f…
@B-uny
B-uny / Shopify Fillable Order Form
Last active January 14, 2020 04:33 — forked from carolineschnapp/gist:9122054
This order form contains input/text line-item sections (e.g. if you wanted an order form with custom engraving). A simple way to implement is to create a collection with duplicate Item names.
{% comment %}
Source: https://gist.github.com/carolineschnapp/9122054
If you are not on a collection page, do define which collection to use in the order form.
Use the following assign statement, replace 'your-collection-handle-here' with your collection handle.
{% assign collection = collections.your-collection-handle-here %}
Use the assign statement outside of this comment block at the top of your template.
Big thanks to this post for pointing me in the right direction: https://community.shopify.com/c/Shopify-Design/Order-Form-and-Line-Item-Properties/m-p/388892
{% endcomment %}