Files
game/addons/game_base/views/asset_views.xml
T
李鹏宇 73d764938d feat: 前端 UI 精修 + 后端视图调整 + 资源预置
前端:
- world.html 游戏内聊天组件重构:表情选择器改固定方格+自适应列+去滚动条;
  输入框清空占位文字+隐藏滚动条;聊天面板整体高度缩短约 1/3;
  顶部用户区改为纯文字并点开个人信息弹窗(头像/头像框/性别/说明/称号/注册)
- chat.html 聊天输入框压扁(46→34px)
- codex.html 新增神话品质、天赋/技能书/书籍分类与预置数据
- rules.html 规则文档更新

后端(Odoo):
- game_base 附件改为看板视图(图片/名称/备注/大小)
- yt_world 玩家菜单直接指向 hr.employee
- game_base 员工表单隐藏原生联系人/组织架构页签
- chat 模型/接口/视图与规则数据扩充

资源:生成 4x4 资源精灵表(树木/石材/芦苇/宝箱)
2026-08-14 14:27:15 +08:00

102 lines
3.8 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<!-- ============ 附件(Odoo 原生 ir.attachment) ============ -->
<!-- ============ 附件(Odoo 原生 ir.attachment)看板视图 ============ -->
<record id="yusen_attachment_kanban_view" model="ir.ui.view">
<field name="name">yusen.attachment.kanban</field>
<field name="model">ir.attachment</field>
<field name="arch" type="xml">
<kanban>
<field name="name"/>
<field name="description"/>
<field name="file_size"/>
<field name="mimetype"/>
<templates>
<t t-name="kanban-box">
<div class="oe_kanban_global_click oe_kanban_card d-flex flex-column p-2" style="width:160px;">
<div class="o_kanban_image mb-2 text-center" style="height:100px;line-height:100px;background:rgba(0,0,0,.06);border-radius:6px;overflow:hidden;font-size:40px;">
<t t-if="record.mimetype.raw_value and 'image' in record.mimetype.raw_value">🖼️</t>
<t t-else="">📎</t>
</div>
<div class="oe_kanban_details text-center">
<strong class="o_kanban_record_title d-block text-truncate" title="%s"><field name="name"/></strong>
<div class="text-muted small text-truncate mt-1" style="min-height:1.2em;">
<t t-if="record.description.raw_value"><field name="description"/></t>
<t t-else="">—</t>
</div>
<div class="small mt-1" style="color:#6c757d;">
<t t-if="record.file_size.raw_value &gt;= 1048576">
<t t-esc="(record.file_size.raw_value / 1048576).toFixed(2)"/> MB
</t>
<t t-elif="record.file_size.raw_value &gt;= 1024">
<t t-esc="(record.file_size.raw_value / 1024).toFixed(1)"/> KB
</t>
<t t-else="">
<t t-esc="record.file_size.raw_value"/> B
</t>
</div>
</div>
</div>
</t>
</templates>
</kanban>
</field>
</record>
<record id="action_yusen_attachment" model="ir.actions.act_window">
<field name="name">附件</field>
<field name="res_model">ir.attachment</field>
<field name="view_mode">kanban,list,form</field>
<field name="context">{'search_default_filter_website': 0}</field>
</record>
<!-- ============ 素材管理(yusen.asset) ============ -->
<record id="action_yusen_asset" model="ir.actions.act_window">
<field name="name">素材管理</field>
<field name="res_model">yusen.asset</field>
<field name="view_mode">list,form</field>
</record>
<record id="yusen_asset_list_view" model="ir.ui.view">
<field name="name">yusen.asset.list</field>
<field name="model">yusen.asset</field>
<field name="arch" type="xml">
<list expand="1">
<field name="name"/>
<field name="category"/>
<field name="source"/>
<field name="tags"/>
<field name="file_name"/>
<field name="active" widget="boolean"/>
</list>
</field>
</record>
<record id="yusen_asset_form_view" model="ir.ui.view">
<field name="name">yusen.asset.form</field>
<field name="model">yusen.asset</field>
<field name="arch" type="xml">
<form>
<sheet>
<group>
<field name="name"/>
<field name="category"/>
<field name="active"/>
</group>
<group>
<field name="file" filename="file_name"/>
<field name="file_name"/>
<field name="source"/>
<field name="tags"/>
</group>
<group>
<field name="description"/>
</group>
</sheet>
</form>
</field>
</record>
</odoo>