Skip to content

Instantly share code, notes, and snippets.

#!/bin/sh
# replace odoo8 per odoo version
# Start/stop odoo8
PIDFILE=/var/run/odoo8.pid
. /lib/lsb/init-functions
NAME=odoo8
# id user odoo8git
@dperaltab
dperaltab / script.sh
Created August 22, 2016 15:36
Change password users postgresql
# su - postgres
$ psql
postgres=# \password user_to_change_password
Enter new password:
Enter it again:
#!/usr/bin/python
from suds.client import Client
from suds.wsse import *
import requests
import base64
import logging
logging.basicConfig(level=logging.INFO)
logging.getLogger('suds.client').setLevel(logging.DEBUG)
#logging.getLogger('suds.wsdl').setLevel(logging.DEBUG)
SUBMODULOS GIT (comandos básicos)
$ git submodule add [email protected]:djperalta/cook_list.git aaa/bbb/ccc
$ git status
$ cat .gitmodules
$ git submodule init (inicializa submodulo)
<?xml version="1.0"?>
<document filename="index.pdf">
<template pageSize="(22.5cm, 20.2cm)" title="Test" author="YarosLab" allowSplitting="5">
<pageTemplate id="main">
<pageGraphics>
<setFont name="Helvetica" size="32.0"/>
<drawString x="6cm" y="18cm">Ficha Del Alumno</drawString>
</pageGraphics>
<frame id="first" x1="1cm" y1="0cm" width="20cm" height="18cm"/>
# -*- coding: utf-8 -*-
import time
from report import report_sxw
class report_alumno(report_sxw.rml_parse):
def __init__(self, cr, uid, name, context):
super(report_alumno, self).__init__(cr, uid, name, context=context)
{
"name" : "Alumno",
"version" : "0.1",
"author" : "yaroslab",
"website" : "http://yaroslab.com/",
"category" : "Generic Modules/Others",
"depends" : ["base"],
"description" : "Registro alumno",
"init_xml" : [
"alumno_view.xml",
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<!-- descripcion:
id: se define un id para el reporte
model: nombre del modelo
name: nombre del reporte
rml: la dirección del archivo rml
string: nombre descriptivo del reporte
.
.
.
def accion_planificada(self, cr, uid, param):
print "=" * 20
print "Estamos en accion_planificada"
print "=" * 20
print "Aquí toda la lógica de la programación."
print "param", param
.
.
.
_columns = {
.
.
.
}
_defaults = {