This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
textView.setText(getItem(position)); | |
// textView.setPadding(15,0,0,0); | |
textView.setCompoundDrawablePadding(20); | |
textView.setCompoundDrawablesRelativeWithIntrinsicBounds(R.drawable.mapa, 0,0,0); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package apps.com.py.jesuitas; | |
import android.Manifest; | |
import android.content.Context; | |
import android.content.pm.PackageManager; | |
import android.support.v4.app.ActivityCompat; | |
import android.telephony.TelephonyManager; | |
import android.util.Log; | |
import com.iamhabib.easy_preference.EasyPreference; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Add project specific ProGuard rules here. | |
# By default, the flags in this file are appended to flags specified | |
# in C:\Users\user\AppData\Local\Android\Sdk/tools/proguard/proguard-android.txt | |
# You can edit the include path and order by changing the proguardFiles | |
# directive in build.gradle. | |
# | |
# For more details, see | |
# http://developer.android.com/guide/developing/tools/proguard.html | |
# Add any project specific keep options here: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% extends 'master.html' %} | |
{% block body %} | |
<div id="app"> | |
<aside style="position: fixed; left: 1em; top: 8em;"> | |
<zonatag class="item-zona" v-for="item in zonas" :nombre="item.zona_nombre" :activo="item.activo"></zonatag> | |
</aside> | |
<supertag class="item-vehiculo" v-for="item in lista" :chofer="item.chofer" :vehiculo="item.vehiculo"></supertag> | |
</div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<div class="columns"> | |
<div class="column is-half is-offset-one-quarter task-list"> | |
<div class="box"> | |
<h2 class="title">My tasks</h2> | |
<hr> | |
<div class="field has-addons"> | |
<div class="control is-expanded"> | |
<input class="input" type="text" placeholder="New task" v-model="task.body"> | |
</div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Lista(View): | |
def dispatch_request(self): | |
datos = g.data.select_many('select first 100 * from PAGOS ') | |
return jsonify([dict(data) for data in datos]) | |
app.add_url_rule('/test/a', view_func=Lista.as_view('show_list')) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from dotenv import * | |
from sqlalchemy import * | |
from sqlalchemy.sql import text as txt | |
from sqlalchemy.pool import NullPool | |
from PIL import Image | |
import io | |
import os | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- seleccionando items de una tabla contra una lista subselect (firebird). | |
select p.categoria, t.sub_categoria,0 monto | |
from pagos p, (select distinct pp.sub_categoria from pagos pp) t | |
group by 1,2 | |
-- dataset -- | |
-- categoria: 7,8,9 | |
-- sub categoria: a,b,c,d,e |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def procesar_archivo(filename): | |
"""Procesar un csv para importar a la tabla""" | |
import pandas | |
dateparser = lambda x: pandas.datetime.strptime(x, '%d/%m/%Y') | |
df = pandas.read_csv(filename, delimiter=";", decimal=".", parse_dates=['fecha'], date_parser=dateparser ) | |
print df | |
df.to_sql('diario', con=g.data.getEngine(), if_exists='append', index=False) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python2.7 | |
# -*- coding: utf-8 -*- | |
# | |
# Sending a SMS with Python and pyserial via an USB 3G Modem on pfSense/FreeBSD | |
# tested with: Huawei Technologies Co., Ltd. E620 USB Modem | |
# and a Telekom SIM card | |
import serial | |
from curses import ascii | |
import time |