[FIX] stock: fixed error 'cannot import name html_template'
bzr revid: qdp-launchpad@openerp.com-20140508100856-jbitae0fzsdt7v78
This commit is contained in:
parent
ce7a7f570a
commit
a029fb22d0
|
@ -1,14 +1,10 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
import logging
|
||||
import simplejson
|
||||
import os
|
||||
import openerp
|
||||
import time
|
||||
import random
|
||||
|
||||
from openerp import http
|
||||
from openerp.http import request
|
||||
from openerp.addons.web.controllers.main import manifest_list, module_boot, html_template
|
||||
from openerp.addons.web.controllers.main import module_boot
|
||||
|
||||
_logger = logging.getLogger(__name__)
|
||||
|
||||
|
@ -27,7 +23,7 @@ html_template = """<!DOCTYPE html>
|
|||
<link rel="shortcut icon" sizes="80x51" href="/stock/static/src/img/scan.png">
|
||||
<link rel="shortcut icon" href="/web/static/src/img/favicon.ico" type="image/x-icon"/>
|
||||
<link rel="stylesheet" href="/stock/static/src/css/barcode.css" />
|
||||
<link rel="stylesheet" href="/web/static/lib/bootstrap/css/bootstrap.css" />
|
||||
<link rel="stylesheet" href="/web/static/lib/bootstrap/css/bootstrap.css" />
|
||||
<link rel="stylesheet" href="/web/static/lib/jquery.ui/css/smoothness/jquery-ui-1.9.1.custom.css" />
|
||||
<link rel="stylesheet" href="/web/static/lib/fontawesome/css/font-awesome.css" />
|
||||
<script type="text/javascript" src="/web/js/web.assets_backend"></script>
|
||||
|
@ -54,14 +50,7 @@ class BarcodeController(http.Controller):
|
|||
if not request.session.uid:
|
||||
return http.local_redirect('/web/login?redirect=/barcode/web')
|
||||
|
||||
js_list = manifest_list('js',db=request.db, debug=debug)
|
||||
css_list = manifest_list('css',db=request.db, debug=debug)
|
||||
|
||||
js = "\n".join('<script type="text/javascript" src="%s"></script>' % i for i in js_list)
|
||||
#css = "\n".join('<link rel="stylesheet" href="%s">' % i for i in css_list)
|
||||
r = html_template % {
|
||||
'js': js,
|
||||
# 'css': css,
|
||||
'modules': simplejson.dumps(module_boot(request.db)),
|
||||
'init': """
|
||||
var wc = new s.web.WebClient();
|
||||
|
|
Loading…
Reference in New Issue