Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

modify attachment for write and read

By
edgard pimentel rojas
on 11/17/13, 10:22 PM 725 views

I have a problem and is this:

I have a field attachment and I want to read for modify the text.

Any suggestions ?

code:

class contract_type(osv.osv):
     _inherit = 'hr.contract.type'

    _columns = {
        'attachment': fields.many2one('ir.attachment', 'Adjuntar'),
        'dni': fields.char('DNI'),
        'ruc': fields.char('Nro. Ruc'),
        'name_employee': fields.char('Nombre'),
        'address': fields.char('Direccion'),
        'job_position': fields.char('Cargo'),
        'salary': fields.char('Salario'),
        'start_date': fields.date('Fecha de Inicio'),
        'end_date': fields.date('Fecha Fin'),
    }

    _defaults = {
       'start_date': lambda *a: time.strftime('%Y-%m-%d'),
   }

contract_type()

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 11/17/13, 10:22 PM
Seen: 725 times
Last updated: 3/16/15, 8:10 AM