← Back to team overview

openerp-india team mailing list archive

[Bug 1076895] [NEW] Binary Field "Filters" property is not working in Web Client

 

Public bug reported:

Binary Field File Filters Property is not working in Web Client, it
shows all the files.

# Class
class etl_process(osv.osv_memory):
    """ ETL Process """

    _name = "etl.process"
    _description = "ETL Process"
    _inherit = "ir.wizard.screen"

    _columns = {
        'file': fields.binary('File', required=True, filters='*.txt,*.TXT', help=''),
        'filename': fields.char('File Name', size=256, required=False, help=''),
    }
etl_process()


<!-- View -->
<record id="view_etl_process" model="ir.ui.view">
    <field name="name">ETL Process</field>
    <field name="model">etl.process</field>
    <field name="type">form</field>
    <field name="arch" type="xml">
        <form string="ETL Process">
            <group colspan="4" col="4">
                <separator string="Select Data File" colspan="4"/>
				<field name="file" filename="filename" colspan="4"/>
				<field name="filename" colspan="4" invisible="1"/>
            </group>
            <group colspan="8" col="8">
                <separator string="" colspan="8"/>
                <label colspan="6" width="220"/>
                    <button special="cancel" string="_Close" icon="gtk-cancel"/>
                    <button name="start_etl_process" string="_Start" type="object" icon="gtk-ok"/>
            </group>
        </form>
    </field>
</record>

** Affects: openobject-server
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Server.
https://bugs.launchpad.net/bugs/1076895

Title:
  Binary Field "Filters" property is  not working in Web Client

Status in OpenERP Server:
  New

Bug description:
  Binary Field File Filters Property is not working in Web Client, it
  shows all the files.

  # Class
  class etl_process(osv.osv_memory):
      """ ETL Process """

      _name = "etl.process"
      _description = "ETL Process"
      _inherit = "ir.wizard.screen"

      _columns = {
          'file': fields.binary('File', required=True, filters='*.txt,*.TXT', help=''),
          'filename': fields.char('File Name', size=256, required=False, help=''),
      }
  etl_process()

  
  <!-- View -->
  <record id="view_etl_process" model="ir.ui.view">
      <field name="name">ETL Process</field>
      <field name="model">etl.process</field>
      <field name="type">form</field>
      <field name="arch" type="xml">
          <form string="ETL Process">
              <group colspan="4" col="4">
                  <separator string="Select Data File" colspan="4"/>
  				<field name="file" filename="filename" colspan="4"/>
  				<field name="filename" colspan="4" invisible="1"/>
              </group>
              <group colspan="8" col="8">
                  <separator string="" colspan="8"/>
                  <label colspan="6" width="220"/>
                      <button special="cancel" string="_Close" icon="gtk-cancel"/>
                      <button name="start_etl_process" string="_Start" type="object" icon="gtk-ok"/>
              </group>
          </form>
      </field>
  </record>

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/1076895/+subscriptions


Follow ups

References