Have JSON/Hal representers for your modules
lib/hal/hal.ex
:
defmodule APIWeb.Hal.Assignment
resource | category | country_code | direction | prefixes | resolutions | type | price | |
---|---|---|---|---|---|---|---|---|
CALL | tollfree | US | inbound | answered,missed,voicemail | 0.012 | |||
CALL | local | US | inbound | answered,missed,voicemail | 0.012 | |||
CALL | US | inbound | answered,missed,voicemail | 0.012 | ||||
CALL | tollfree | AE | inbound | answered,missed,voicemail | 0.67 | |||
CALL | tollfree | AR | inbound | answered,missed,voicemail | 0.7 | |||
CALL | local | AR | inbound | answered,missed,voicemail | 0.04 | |||
CALL | local | AT | inbound | answered,missed,voicemail | 0.02 | |||
CALL | tollfree | AT | inbound | answered,missed,voicemail | 0.59 | |||
CALL | national | AT | inbound | answered,missed,voicemail | 0.04 |
#!/usr/bin/env sh | |
docker rm $(docker ps -a | awk '{print $1}') | |
docker rmi $(docker images | awk '{print $3}') |
#!/usr/bin/env node | |
const fs = require('fs') | |
const usage = () => { | |
console.log('Usage: unload <aws-arn> <sql-statement-filepath> <name-of-file-in-s3>') | |
} | |
if (process.argv.length < 5 || process.argv[2] == '-h') { | |
usage() |
(defn wrap-options | |
[app] | |
(fn [request] | |
(if (= (request :request-method) :options) | |
(into request {:status 204}) | |
(app request)))) | |
(defn add-header | |
[r name value] | |
(assoc-in r [:headers name] value)) |
country_code | type | price | |
---|---|---|---|
AR | tollfree | $0.70 | |
AR | local | $0.04 | |
AT | local | $0.02 | |
AT | national | $0.04 | |
AU | tollfree | $0.12 | |
AU | local | $0.04 | |
BA | national | $0.20 | |
BB | local | $0.10 | |
BE | local | $0.02 |
I hereby claim:
To claim this, I am signing this object:
<?php | |
if ( !function_exists( 'get_pagination' ) ) : | |
/** | |
* Return the pagination for the current (or instead, given) WP_Query or WP_Query_Users | |
* object returned by paginate_links() function. | |
* | |
* @since 3.5.5 | |
* @uses paginate_links() | |
* @uses $wp_query |
<?php | |
function change_post_menu_label() { | |
global $menu, $submenu; | |
$menu[5][0] = __( 'News' ); | |
$submenu['edit.php'][5][0] = __( 'News' ); | |
$submenu['edit.php'][10][0] = __( 'Add News' ); | |
} | |
add_action( 'admin_menu', 'change_post_menu_label' ); |
<?php | |
$query = url_encode( array_implode( '=', '&', $array ) ); | |
echo '<input '.array_implode( '=”', '” ', $array ).' />'; | |
?> |