[IMP] changed barcode start page url to /stock/barcode
As a convention we use the module name as first fragment of the url
This commit is contained in:
@@ -8,9 +8,9 @@ _logger = logging.getLogger(__name__)
|
||||
|
||||
class BarcodeController(http.Controller):
|
||||
|
||||
@http.route(['/barcode/web/'], type='http', auth='user')
|
||||
@http.route(['/stock/barcode/'], type='http', auth='user')
|
||||
def a(self, debug=False, **k):
|
||||
if not request.session.uid:
|
||||
return http.local_redirect('/web/login?redirect=/barcode/web')
|
||||
return http.local_redirect('/web/login?redirect=/stock/barcode/')
|
||||
|
||||
return request.render('stock.barcode_index')
|
||||
|
||||
@@ -1070,7 +1070,7 @@ class stock_picking(osv.osv):
|
||||
|
||||
@api.cr_uid_ids_context
|
||||
def open_barcode_interface(self, cr, uid, picking_ids, context=None):
|
||||
final_url="/barcode/web/#action=stock.ui&picking_id="+str(picking_ids[0])
|
||||
final_url="/stock/barcode/#action=stock.ui&picking_id="+str(picking_ids[0])
|
||||
return {'type': 'ir.actions.act_url', 'url':final_url, 'target': 'self',}
|
||||
|
||||
@api.cr_uid_ids_context
|
||||
@@ -4038,7 +4038,7 @@ class stock_picking_type(osv.osv):
|
||||
_order = 'sequence'
|
||||
|
||||
def open_barcode_interface(self, cr, uid, ids, context=None):
|
||||
final_url = "/barcode/web/#action=stock.ui&picking_type_id=" + str(ids[0]) if len(ids) else '0'
|
||||
final_url = "/stock/barcode/#action=stock.ui&picking_type_id=" + str(ids[0]) if len(ids) else '0'
|
||||
return {'type': 'ir.actions.act_url', 'url': final_url, 'target': 'self'}
|
||||
|
||||
def _get_tristate_values(self, cr, uid, ids, field_name, arg, context=None):
|
||||
|
||||
Reference in New Issue
Block a user