完善教育 #57
@@ -1,7 +1,7 @@
|
||||
// 关于页(yuthon.about.page)为只读展示页:
|
||||
// form 视图已设 edit="false",但教师组有该模型写权限时控制面板仍会渲染「编辑」按钮,
|
||||
// 这里用 CSS 精准隐藏该页面的编辑按钮(作用域限定 o_about_full_form,不影响其他表单)。
|
||||
.o_form_view.o_about_full_form .o_form_button_edit,
|
||||
.o_form_view.o_about_full_form button[data-hotkey="e"] {
|
||||
// 这里用 js_class + CSS 精准隐藏该视图控制面板里的编辑按钮,不影响其他表单。
|
||||
.o_view_controller.yuthon_about_form .o_control_panel .o_form_button_edit,
|
||||
.o_view_controller.yuthon_about_form .o_control_panel button[data-hotkey="e"] {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<field name="model">yuthon.about.page</field>
|
||||
<field name="arch" type="xml">
|
||||
<!-- create/edit 关掉:关于页内容由代码预置维护,页面右上角不再显示「创建/编辑」按钮 -->
|
||||
<form class="o_about_full_form" create="false" edit="false">
|
||||
<form class="o_about_full_form" create="false" edit="false" js_class="yuthon_about_form">
|
||||
<field name="content" widget="html" readonly="1" class="o_about_full"/>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
Reference in New Issue
Block a user