Skip to content

Commit

Permalink
work in progress, user interface, a couple of hard-coded formats, no …
Browse files Browse the repository at this point in the history
…effect on choosing. Bauble/bauble.classic#59.
  • Loading branch information
mfrasca committed Jan 27, 2016
1 parent 10fd1d1 commit ae6e6b4
Show file tree
Hide file tree
Showing 2 changed files with 66 additions and 6 deletions.
70 changes: 65 additions & 5 deletions bauble/plugins/garden/acc_editor.glade
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,26 @@
<interface>
<requires lib="gtk+" version="2.24"/>
<!-- interface-naming-policy project-wide -->
<object class="GtkListStore" id="acc_code_format_liststore">
<columns>
<!-- column-name gchararray1 -->
<column type="gchararray"/>
</columns>
<data>
<row>
<col id="0" translatable="yes">%Y.####</col>
</row>
<row>
<col id="0" translatable="yes">######</col>
</row>
<row>
<col id="0" translatable="yes">SD.#####</col>
</row>
<row>
<col id="0" translatable="yes">H.#####</col>
</row>
</data>
</object>
<object class="GtkDialog" id="accession_dialog">
<property name="can_focus">False</property>
<property name="title">Accession Editor</property>
Expand Down Expand Up @@ -557,7 +577,7 @@
<object class="GtkTable" id="table7">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="n_rows">2</property>
<property name="n_rows">3</property>
<property name="n_columns">2</property>
<property name="column_spacing">5</property>
<property name="row_spacing">3</property>
Expand All @@ -570,6 +590,8 @@
<property name="use_markup">True</property>
</object>
<packing>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"/>
</packing>
Expand All @@ -583,8 +605,8 @@
<property name="use_markup">True</property>
</object>
<packing>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
<property name="top_attach">2</property>
<property name="bottom_attach">3</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"/>
</packing>
Expand Down Expand Up @@ -627,6 +649,8 @@
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"/>
</packing>
Expand Down Expand Up @@ -669,8 +693,44 @@
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
<property name="top_attach">2</property>
<property name="bottom_attach">3</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="label59">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="label" translatable="yes">ID format</property>
</object>
<packing>
<property name="x_options">GTK_FILL</property>
<property name="y_options"/>
</packing>
</child>
<child>
<object class="GtkComboBoxEntry" id="acc_code_format_comboentry">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="model">acc_code_format_liststore</property>
<property name="text_column">0</property>
<child internal-child="entry">
<object class="GtkEntry" id="comboboxentry-entry10">
<property name="can_focus">False</property>
<property name="invisible_char">•</property>
<property name="primary_icon_activatable">False</property>
<property name="secondary_icon_activatable">False</property>
<property name="primary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">True</property>
</object>
</child>
</object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"/>
</packing>
</child>
</object>
Expand Down
2 changes: 1 addition & 1 deletion bauble/plugins/garden/accession.py
Original file line number Diff line number Diff line change
Expand Up @@ -1724,7 +1724,7 @@ def __init__(self, model, view):
self.current_source_box = None

if not model.code:
model.code = self.get_next_code()
model.code = model.get_next_code()
if self.model.species:
self._dirty = True

Expand Down

0 comments on commit ae6e6b4

Please sign in to comment.