﻿{"id":2598,"date":"2015-10-27T12:00:42","date_gmt":"2015-10-27T04:00:42","guid":{"rendered":"http:\/\/www.jointd.com\/?p=2598"},"modified":"2016-04-13T17:49:41","modified_gmt":"2016-04-13T09:49:41","slug":"%e5%8d%93%e5%bf%86%e7%bf%bb%e8%af%91%ef%bc%9a%e8%8b%b1%e4%b8%ad%e5%af%b9%e7%85%a7%ef%bc%9aodoo%e6%8a%a5%e8%a1%a8%e5%9f%ba%e7%a1%80","status":"publish","type":"post","link":"https:\/\/www.jointd.com\/?p=2598","title":{"rendered":"\u5353\u5fc6\u7ffb\u8bd1\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u57fa\u7840odoo\u62a5\u8868\u57fa\u7840"},"content":{"rendered":"<p><strong>\u539f\u6587\uff1a<\/strong><strong> <a href=\"http:\/\/odoo.guide\/odoo-report-design-basics\/\">Odoo report design basics<\/a><\/strong><\/p>\n<p>\u5353\u5fc6\u7ffb\u8bd1\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u57fa\u7840, \u00a0\u8f6c\u5e16\u70e6\u8bf7\u6ce8\u660e \u51fa\u5904\uff0c\u8c22\u8c22<\/p>\n<ol>\n<li>\n<h3><a title=\"\u8be6\u7ec6\u9605\u8bfb \u591a\u56fe\u7ffb\u8bd1\u52a0\u6574\u7406\u6d4b\u8bd5\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u5165\u95e8Step by Step,Odoo\u521b\u5efa\u4e00\u4efd\u62a5\u8868\u5230\u6253\u5370\u4e0b\u62c9\u83dc\u5355\u4e2d\" href=\"http:\/\/www.jointd.com\/?p=2579\" rel=\"bookmark\">\u591a\u56fe\u7ffb\u8bd1\u52a0\u6574\u7406\u6d4b\u8bd5\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u5165\u95e8Step by Step,Odoo\u521b\u5efa\u4e00\u4efd\u62a5\u8868\u5230\u6253\u5370\u4e0b\u62c9\u83dc\u5355\u4e2d<\/a><\/h3>\n<\/li>\n<li>\n<h3><a title=\"\u8be6\u7ec6\u9605\u8bfb \u5353\u5fc6\u7ffb\u8bd1\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u57fa\u7840\" href=\"http:\/\/www.jointd.com\/?p=2598\" rel=\"bookmark\">\u5353\u5fc6\u7ffb\u8bd1\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u57fa\u7840<\/a><\/h3>\n<\/li>\n<li>\n<h3><a title=\"\u8be6\u7ec6\u9605\u8bfb \u5353\u5fc6\u7ffb\u8bd1\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u8bbe\u8ba1\u8fdb\u9636\u7bc7\" href=\"http:\/\/www.jointd.com\/?p=2603\" rel=\"bookmark\">\u5353\u5fc6\u7ffb\u8bd1\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u8bbe\u8ba1\u8fdb\u9636\u7bc7<\/a><\/h3>\n<\/li>\n<li>\n<h3><a href=\"http:\/\/www.jointd.com\/?p=2974\" rel=\"bookmark\">\u5353\u5fc6\u7ffb\u8bd1\uff1a\u5199\u6a21\u5757\u8fdb\u884cOdoo Qweb\u62a5\u8868\u7684\u7ee7\u627f\u548c\u4fee\u6539<\/a><\/h3>\n<\/li>\n<\/ol>\n<p>Odoo helps to uniform reports by providing an overall layout structure of\u00a0<strong>individual rows\u00a0<\/strong>subdivided into\u00a0<strong>twelve columns<\/strong>.<\/p>\n<p>Odoo \u62a5\u8868\uff0c\u63d0\u4f9b\u4e00\u4e2a 12\u5217 \u7684 \u7ed3\u6784\u7ec6\u5206\uff1a<\/p>\n<p><a href=\"http:\/\/www.jointd.com\/?attachment_id=2599\" rel=\"attachment wp-att-2599\"><img loading=\"lazy\" decoding=\"async\" class=\"alignleft size-full wp-image-2599\" src=\"http:\/\/www.jointd.com\/wp-content\/uploads\/2015\/10\/qwebbase0.png\" alt=\"qwebbase0\" width=\"664\" height=\"333\" srcset=\"https:\/\/www.jointd.com\/wp-content\/uploads\/2015\/10\/qwebbase0.png 664w, https:\/\/www.jointd.com\/wp-content\/uploads\/2015\/10\/qwebbase0-150x75.png 150w, https:\/\/www.jointd.com\/wp-content\/uploads\/2015\/10\/qwebbase0-300x150.png 300w\" sizes=\"auto, (max-width: 664px) 100vw, 664px\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p><strong>A<\/strong><\/p>\n<p>Every sheet in Odoo has a top, bottom, left and right margin specified in millimeters\u00a0in\u00a0<strong>Settings &gt; Technical &gt; Reports &gt; Paper Formats<\/strong>.<\/p>\n<p>&nbsp;<\/p>\n<p>\u5728 \u8bbe\u7f6e- \u6280\u672f- \u62a5\u8868 -\u62a5\u8868\u683c\u5f0f \u4e2d \uff1a<\/p>\n<p>Odoo \u4e2d\u6240\u6709\u7684\u8868\u5355\u90fd\u6709 \u4ee5\u6beb\u7c73\u4e3a\u5355\u4f4d\u7684 \u4e0a\uff0c\u4e0b\uff0c\u5de6\u548c\u53f3\u8fb9\u8ddd<\/p>\n<p><strong>B<\/strong><\/p>\n<p>Odoo subdivides a\u00a0sheet into rows (CSS class \u201crow\u201d) with a top margin (CSS class \u201cmt\u201d) and a bottom margin (CSS class \u201cmb\u201d). \u00a0To\u00a0define\u00a0e.g. a row with 8px top margin and 32px bottom margin you need the following code:<\/p>\n<p>&nbsp;<\/p>\n<p>Odoo \u628a\u8868\u5355 \u7ec6\u5206\u4e3a \u884c \uff08CSS\u7c7b\u7684\u201c\u884c\u201d\uff09\u5728 \u4e0a\u8fb9\u8ddd\uff08CSS \u7c7b \u201cmt\u201d\uff09\u548c \u4e0b\u8fb9\u8ddd \uff08CSS\u7c7b\u201cmb\u201d\uff09\u3002<\/p>\n<p>\u8981\u5b9a\u4e49\u4e00\u4e2a\u7c7b\u4f3c 8px\uff08\u50cf\u7d20\uff09 \u7684\u4e0a\u8fb9\u8ddd\u53ca32px(\u50cf\u7d20\uff09\u7684\u4e0b\u8fb9\u8ddd\uff0c\u60a8\u9700\u8981\u4e0b\u5217\u4ee3\u7801\uff1a<\/p>\n<p>&nbsp;<\/p>\n<p>&lt;div class=&#8221;row mt8 mb32&#8243;&gt;Your new line!&lt;\/div&gt;<\/p>\n<p>Available margins are: mt0, mt4, mt8, mt16, mt32, mt48, mt64, mt92, mt128,\u00a0mb0, mb4, mb8, mb16, mb32, mb48, mb64, mb92, mb128<\/p>\n<p>&nbsp;<\/p>\n<p>\u53ef\u7528\u7684<em>\u4e0a\u4e0b<\/em>\u8fb9\u8ddd\u6709\uff1a\u00a0mt0, mt4, mt8, mt16, mt32, mt48, mt64, mt92, mt128,\u00a0mb0, mb4, mb8, mb16, mb32, mb48, mb64, mb92, mb128<\/p>\n<p><strong>C<\/strong><\/p>\n<p>Odoo subdivides each row into twelve columns. To specify a certain\u00a0position and width of a div container\u00a0there are two\u00a0CSS\u00a0class names to use\u00a0\u2013\u00a0for defining the width\u00a0\u201ccol-[screensize]-[column-factor]\u201d and for defining the position \u201ccol-[screensize]-[position-type]-[column-factor]\u201d.<\/p>\n<p>To define e.g. a centered div container of 50% width you need the following code:<\/p>\n<p>Odoo \u628a\u6bcf\u884c\u5206\u4e3a12\u5217\u3002\u60f3\u8981\u5b9a\u4e49 \u4f4d\u7f6e\u548c\u5bbd\u5ea6 \u9700\u8981\u4f7f\u7528 \u53e6\u59162\u4e2a CSS \u7c7b<\/p>\n<p>&#8211; \u5b9a\u4e49\u5bbd\u5ea6\u00a0\u201ccol-[screensize]-[column-factor]\u201d<\/p>\n<p>\u5b9a\u4e49 \u4f4d\u7f6e\u00a0\u201ccol-[screensize]-[position-type]-[column-factor]\u201d.<\/p>\n<p>\u8981\u5b9a\u4e49 \u4e00\u4e2a \u5c45\u4e2d \u7684 50%\u5bbd\u5ea6 \u60a8 \u9700\u8981\u4e0b\u9762\u7684\u4ee3\u7801\uff1a<\/p>\n<p>&lt;div class=&#8221;col-xs-6 col-xs-offset-3&#8243;&gt;Big centered container&lt;\/div&gt;<\/p>\n<p><strong>Explanation <\/strong><strong>\u8bf4\u660e\uff1a<\/strong><br \/>\ncol-xs-6\u00a0means a width of 6 columns. Because there is a total of 12 columns this is exactly the half of it \u2013 to say 50%<\/p>\n<p>col-xs-6\u00a0\u8868\u793a\u5bbd\u5ea6\u4e3a6\u5217\u3002\u7531\u4e8e\u603b\u5171\u670912\u5217\uff0c\u6240\u4ee56\u5217\u5c31\u662f50%\u5bbd\u5ea6\u3002<br \/>\ncol-xs-offset-3\u00a0means the container starts to display after a width of 3\u00a0columns. Because there is a total of 12 columns and the container itself is exactly\u00a06 columns wide\u00a0there are also 3 columns left on its\u00a0right side. Thats why the container is in the middle of the sheet.<\/p>\n<p>col-xs-offset-3\u00a0\u8868\u793a\u4ece\u7b2c3\u5217\u7684\u540e\u4e00\u5217\u5f00\u59cb \uff0c\u603b\u5217\u6570\u662f12\uff0c\u5bbd\u5ea6\u662f6\uff0c\u4ece\u7b2c3\u5217\u4e4b\u540e\u4e00\u5217\u5f00\u59cb\uff0c\u521a\u597d\u5c31\u662f\u5c45\u4e2d\u7684\u4f4d\u7f6e\u3002<\/p>\n<p><strong>Available screensizes <\/strong><strong>\u53ef\u7528\u7684<\/strong> <strong>\u5c4f\u5e55\u5c3a\u5bf8<\/strong><br \/>\nxs\u00a0(width smaller than 768px),\u00a0sm\u00a0(min-width: 768px),\u00a0md\u00a0(min-width: 992px),\u00a0lg\u00a0(min-width: 1200px)<\/p>\n<p>xs (\u5bbd\u5ea6\u5c0f\u4e8e 768\u50cf\u7d20\uff09\uff0csm(\u6700\u5c0f\u5bbd\u5ea6\uff1a768\u50cf\u7d20\uff09\uff0cmd (\u6700\u5c0f\u5bbd\u5ea6\uff1a992\u50cf\u7d20),lg (\u6700\u5c0f\u5bbd\u5ea6\uff1a1200\u50cf\u7d20\uff09<\/p>\n<p><strong>Available column-factors \u00a0<\/strong><strong>\u53ef\u7528\u7684<\/strong> <strong>\u5217<\/strong> <strong>\uff1a<\/strong><br \/>\n1,2,3,4,5,6,7,8,9,10,11,12<\/p>\n<p><strong>Available position-types <\/strong><strong>\u53ef\u7528\u7684\u4f4d\u7f6e\u7c7b\u578b\uff1a<\/strong><br \/>\noffset\u00a0(absolut horizontal position in a row),<\/p>\n<p>offset\u00a0( \u884c\u5185\u7684\u7edd\u5bf9\u6c34\u5e73\u4f4d\u7f6e\uff09\uff0c<br \/>\npull\u00a0(relative position, on the left\u00a0hand of the last div element),<\/p>\n<p>pull ( \u5de6\u8d77\u5230\u672b\u5c3e\u7684\u76f8\u5bf9\u4f4d\u7f6e\uff09\uff0c<br \/>\npush\u00a0(relative position, on the right hand of the last div element)<\/p>\n<p>push (\u53f3\u8d77\u5230\u672b\u5c3e\u7684\u76f8\u5bf9\u4f4d\u7f6e\uff09<\/p>\n<p>Example: to position a small container (only one column width) on the right side of\u00a0the big one (see example above) with two columns distance you need the following code:<\/p>\n<p>\u4f8b\uff1a \u5728\u53f3\u8fb9\u5927\u4e00\u70b9\u76842\u5217\u7684 \u533a\u5757 \u8fb9 \u5b9a\u4f4d1\u4e2a\uff08\u4ec51\u5217\u5bbd\u5ea6\uff09\u7684\u533a\u5757\uff08\u89c1\u6700\u4e0a\u65b9\u7684\u793a\u610f\u56fe\uff09 \u00a0 \u60a8\u9700\u8981\u4e0b\u9762\u7684\u4ee3\u7801 \uff1a<\/p>\n<p>&lt;div class=&#8221;col-xs-1 col-xs-push-2&#8243;&gt;Little container on the right&lt;\/div&gt;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>\u7ffb\u8bd1\u96be\u514d\u6709\u6240\u758f\u6f0f\uff0c\u671b\u8bf8\u4f4d\u6d77\u6db5\u3002\u8c22\u8c22\u5927\u5bb6\u3002<\/p>\n<p>&nbsp;<\/p>\n<p>Odoo\u62a5\u8868\u8bbe\u8ba1\u5165\u95e8\u53ef\u89c1\uff1a<a href=\"http:\/\/www.jointd.com\/?p=2579\">http:\/\/www.jointd.com\/?p=2579<\/a><\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u539f\u6587\uff1a Odoo report design basics \u5353\u5fc6\u7ffb\u8bd1\uff1a\u82f1\u4e2d\u5bf9\u7167\uff1aOdoo\u62a5\u8868\u57fa\u7840, \u00a0\u8f6c\u5e16\u70e6\u8bf7 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[139],"tags":[169,278,277,279],"class_list":{"0":"post-2598","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"hentry","6":"category-odoo-openerp","7":"tag-odoo","8":"tag-odoo-qweb","10":"tag-qweb"},"views":3154,"_links":{"self":[{"href":"https:\/\/www.jointd.com\/index.php?rest_route=\/wp\/v2\/posts\/2598","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.jointd.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.jointd.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.jointd.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.jointd.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2598"}],"version-history":[{"count":1,"href":"https:\/\/www.jointd.com\/index.php?rest_route=\/wp\/v2\/posts\/2598\/revisions"}],"predecessor-version":[{"id":2998,"href":"https:\/\/www.jointd.com\/index.php?rest_route=\/wp\/v2\/posts\/2598\/revisions\/2998"}],"wp:attachment":[{"href":"https:\/\/www.jointd.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2598"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.jointd.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2598"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.jointd.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2598"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}