[MERGE] forward port branch saas-11 up to 65a67ce

This commit is contained in:
Christophe Simonis
2016-07-30 13:04:39 +02:00
4 changed files with 19 additions and 7 deletions
+5 -5
View File
@@ -175,11 +175,11 @@ class Inventory(models.Model):
@api.multi
def action_start(self):
for inventory in self.filtered(lambda inventory: not inventory.line_ids and inventory.filter != 'partial'):
self.write({
'line_ids': [(0, 0, line_values) for line_values in inventory._get_inventory_lines_values()],
'state': 'confirm', 'date': fields.Datetime.now()
})
for inventory in self.filtered(lambda x: not x.line_ids):
vals = {'state': 'confirm', 'date': fields.Datetime.now()}
if inventory.filter != 'partial':
vals.update({'line_ids': [(0, 0, line_values) for line_values in inventory._get_inventory_lines_values()]})
inventory.write(vals)
return True
prepare_inventory = action_start
+2 -1
View File
@@ -424,7 +424,8 @@ class Picking(models.Model):
@api.multi
def unlink(self):
self.mapped('move_lines').action_cancel().unlink()
self.mapped('move_lines').action_cancel()
self.mapped('move_lines').unlink() # Checks if moves are not done
return super(Picking, self).unlink()
# Actions
@@ -8,6 +8,10 @@ html, body {
display: none !important;
}
.editor_enable .css_editable_mode_hidden {
display: none !important;
}
/* ----- Editor (for public user, like forum) ----- */
.note-toolbar {
margin-left: 0 !important;
+8 -1
View File
@@ -501,6 +501,13 @@
<span itemprop="price" style="display:none;" t-esc="product.price"/>
<span itemprop="priceCurrency" style="display:none;" t-esc="website.currency_id.name"/>
</h4>
<h4 class="css_non_editable_mode_hidden">
<span t-field="product.lst_price"
t-field-options='{
"widget": "monetary",
"display_currency": "product.currency_id"
}'/>
</h4>
<h4 class="hidden oe_not_available bg-warning">Product not available</h4>
</div>
</template>
@@ -1549,4 +1556,4 @@
</t>
</xpath>
</template>
</odoo>
</odoo>