GoodERP
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

264 line
13KB

  1. <?xml version="1.0"?>
  2. <odoo>
  3. <data>
  4. <!--会计凭证菜单-->
  5. <menuitem id='voucher_home_menu' name='会计凭证' parent='finance_menu' sequence='5'/>
  6. <!--会计凭证搜索及过滤-->
  7. <record id="view_voucher_search_filter" model="ir.ui.view">
  8. <field name="name">凭证搜索</field>
  9. <field name="model">voucher</field>
  10. <field name="arch" type="xml">
  11. <search string="Search Voucher">
  12. <field name='name' filter_domain="[('name','ilike',self)]"/>
  13. <field name="brief" />
  14. <field name='date'/>
  15. <field name='period_id'/>
  16. <separator/>
  17. <filter string="本期"
  18. name="this_period"
  19. domain="[('date','&gt;=',(context_today()).strftime('%%Y-%%m-01')),
  20. ('date','&lt;=',(context_today()).strftime('%%Y-%%m-%%d'))]"/>
  21. <separator/>
  22. <filter name="draft" string="草稿" domain="[('state','=', 'draft')]"/>
  23. <group expand="0" string="分组">
  24. <filter name="by_period" string="会计期间" domain="[]" context="{'group_by':'period_id'}"/>
  25. </group>
  26. </search>
  27. </field>
  28. </record>
  29. <!--会计凭证view-->
  30. <record id="voucher_form" model="ir.ui.view">
  31. <field name="name">voucher.form</field>
  32. <field name="model">voucher</field>
  33. <field name="arch" type="xml">
  34. <form string="会计凭证">
  35. <header>
  36. <button name='voucher_done' invisible="state!='draft'" string="确认"
  37. type="object" class="oe_highlight"/>
  38. <button name='voucher_can_be_draft' invisible="state!='done'" string="撤销确认"
  39. type="object"/>
  40. <button name="action_cancel" invisible="state!='draft'" string="作废" type="object"/>
  41. <field name="state" widget="statusbar" readonly="1"/>
  42. </header>
  43. <sheet>
  44. <group>
  45. <group>
  46. <field name="document_word_id" widget='selection' readonly='1' />
  47. <field name="name" readonly='1'/>
  48. </group>
  49. <group>
  50. <field name="date" readonly="state!='draft'"/>
  51. <field name="period_id" options="{'no_open':True,'no_create':True}"/>
  52. <field name="att_count" readonly="state!='draft'"/>
  53. <field name="is_init" invisible="1" />
  54. </group>
  55. <field name="ref" groups='base.group_no_one'/>
  56. </group>
  57. <notebook>
  58. <page string="凭证明细" >
  59. <field name="line_ids" context="{'line_ids':line_ids}" readonly="state!='draft'">
  60. <list editable='bottom'>
  61. <field name='name' optional="show"/>
  62. <field name='account_id' options="{'no_create': True}"
  63. context="{'show_balance':False}"
  64. optional="show"/>
  65. <field name='partner_id' options="{'no_open': True, 'no_create': True}" optional="show"/>
  66. <field name='goods_id' options="{'no_open': True, 'no_create': True}" optional="show"/>
  67. <field name='goods_qty' optional="show"/>
  68. <field name='auxiliary_id' optional="show"/>
  69. <field name='currency_id' options="{'no_create': True}"
  70. optional="show"/>
  71. <field name='currency_amount' sum='外币合计'
  72. optional="show"/>
  73. <field name='rate_silent' digits="[12,6]"
  74. optional="show"/>
  75. <field name='debit' sum='借方合计' optional="show"/>
  76. <field name='credit' sum='贷方合计' optional="show"/>
  77. <field name='init_obj' invisible="1" optional="show"/>
  78. </list>
  79. </field>
  80. </page>
  81. </notebook>
  82. <group>
  83. <field name="amount_text"/>
  84. </group>
  85. </sheet>
  86. <chatter/>
  87. </form>
  88. </field>
  89. </record>
  90. <record id="voucher_list" model="ir.ui.view">
  91. <field name="name">voucher.list</field>
  92. <field name="model">voucher</field>
  93. <field name="arch" type="xml">
  94. <list string="会计凭证" decoration-info="state=='draft'" decoration-muted="state=='cancel'">
  95. <field name="period_id" optional="show"/>
  96. <field name="name" optional="show"/>
  97. <field name="date" optional="show"/>
  98. <field name="brief" />
  99. <field name="details" widget="html" optional="show"/>
  100. <field name="state" invisible="1" optional="show"/>
  101. <field name="is_init" invisible="1" optional="show"/>
  102. </list>
  103. </field>
  104. </record>
  105. <record id="voucher_action" model="ir.actions.act_window">
  106. <field name="name">会计凭证</field>
  107. <field name="res_model">voucher</field>
  108. <field name="type">ir.actions.act_window</field>
  109. <field name="view_mode">list,form</field>
  110. <field name="context">{'entry_manual': True, }</field>
  111. </record>
  112. <menuitem id='voucher_menu' action='voucher_action' parent='voucher_home_menu' sequence='10'/>
  113. <!--账簿菜单-->
  114. <menuitem id='voucher_books_menu' name='账簿' parent='finance_menu' sequence='10'/>
  115. <!--账簿搜索及过滤-->
  116. <record id="view_voucher_line_search_filter" model="ir.ui.view">
  117. <field name="name">凭证行搜索</field>
  118. <field name="model">voucher.line</field>
  119. <field name="arch" type="xml">
  120. <search string="Search Voucher Line">
  121. <field name='period_id'/>
  122. <field name='voucher_id'/>
  123. <field name='name' filter_domain="[('name','ilike',self)]"/>
  124. <field name='account_id'/>
  125. <field name='partner_id' options="{'no_open': True, 'no_create': True}"/>
  126. <field name='goods_id'/>
  127. <field name='auxiliary_id'/>
  128. <field name='date'/>
  129. <separator/>
  130. <filter string="本期"
  131. name="this_period"
  132. domain="[('voucher_id.date','&gt;=',(context_today()).strftime('%%Y-%%m-01')),
  133. ('voucher_id.date','&lt;=',(context_today()).strftime('%%Y-%%m-%%d'))]"/>
  134. <filter string="隐藏作废"
  135. name="not_cancel"
  136. domain="[('state','!=','cancel')]"/>
  137. <group expand="0" string="分组">
  138. <filter name="by_period" string="会计期间" domain="[]" context="{'group_by':'period_id'}"/>
  139. <filter name="by_account" string="会计科目" domain="[]" context="{'group_by':'account_id'}"/>
  140. </group>
  141. </search>
  142. </field>
  143. </record>
  144. <record id="voucher_line_list" model="ir.ui.view">
  145. <field name="name">voucher.line.list</field>
  146. <field name="model">voucher.line</field>
  147. <field name="arch" type="xml">
  148. <list string='分录查询' decoration-info="state=='draft'" decoration-muted="state=='cancel'" create="false" edit='false'>
  149. <field name='date' optional="show"/>
  150. <field name='period_id' optional="show"/>
  151. <field name='voucher_id' optional="show"/>
  152. <button name="view_document" type="object" string="查看凭证"
  153. icon="fa-search"/>
  154. <field name='name' optional="show"/>
  155. <field name='account_id' optional="show"/>
  156. <field name='debit' sum='借方合计' widget="bgcolor" color="success" optional="show"/>
  157. <field name='credit' sum='贷方合计' widget="bgcolor" color="primary" optional="show"/>
  158. <field name='partner_id' options="{'no_open': True, 'no_create': True}" optional="show"/>
  159. <field name='auxiliary_id' optional="show"/>
  160. <field name='goods_id' optional="show"/>
  161. <field name='goods_qty' sum='数量合计' optional="show"/>
  162. <field name='currency_id'
  163. optional="show"/>
  164. <field name='currency_amount' sum='外币合计'
  165. optional="show"/>
  166. <field name='rate_silent' digits="[12,6]"
  167. optional="show"/>
  168. <field name='state' optional="show"/>
  169. <field name='init_obj' invisible="1" optional="show"/>
  170. </list>
  171. </field>
  172. </record>
  173. <record id='voucher_line_graph' model='ir.ui.view'>
  174. <field name='name'>voucher.line.graph</field>
  175. <field name='model'>voucher.line</field>
  176. <field name='arch' type='xml'>
  177. <graph string='分录查询'>
  178. <field name='period_id' type='row'/>
  179. <field name='debit' type='measure'/>
  180. </graph>
  181. </field>
  182. </record>
  183. <record id='voucher_line_pivot' model='ir.ui.view'>
  184. <field name='name'>voucher.line.pivot</field>
  185. <field name='model'>voucher.line</field>
  186. <field name='arch' type='xml'>
  187. <pivot string='分录查询'>
  188. <field name='period_id' type='row'/>
  189. <field name='debit' type='measure'/>
  190. <field name='credit' type='measure'/>
  191. <field name='currency_amount' type='measure'/>
  192. </pivot>
  193. </field>
  194. </record>
  195. <record id="voucher_line_action" model="ir.actions.act_window">
  196. <field name="name">分录查询</field>
  197. <field name="res_model">voucher.line</field>
  198. <field name="type">ir.actions.act_window</field>
  199. <field name="view_mode">list,graph,pivot</field>
  200. </record>
  201. <menuitem id='voucher_line_menu' action='voucher_line_action' parent='voucher_books_menu' sequence='10' />
  202. <record id="chang_voucher_name_list" model="ir.ui.view">
  203. <field name="name">change.voucher.name.list</field>
  204. <field name="model">change.voucher.name</field>
  205. <field name="arch" type="xml">
  206. <list string='凭证变更记录' create='0'>
  207. <field name="period_id" optional="show"/>
  208. <field name="before_voucher_name" optional="show"/>
  209. <field name="after_voucher_name" optional="show"/>
  210. <field name="write_date" string="变更日期" optional="show"/>
  211. </list>
  212. </field>
  213. </record>
  214. <record id="chang_voucher_name_action" model="ir.actions.act_window">
  215. <field name="name">凭证变更记录</field>
  216. <field name="res_model">change.voucher.name</field>
  217. <field name="type">ir.actions.act_window</field>
  218. <field name="view_mode">list</field>
  219. </record>
  220. <menuitem id='chang_voucher_name_menu_finance' name="月末凭证变更记录"
  221. groups='base.group_no_one'
  222. action='chang_voucher_name_action' parent='finance.checkout_menu' sequence='90'/>
  223. <record id='dupont_graph' model='ir.ui.view'>
  224. <field name='name'>dupont.graph</field>
  225. <field name='model'>dupont</field>
  226. <field name='arch' type='xml'>
  227. <graph string='杜邦分析'>
  228. <field name='period_id' type='row'/>
  229. <field name='kpi' type='col'/>
  230. <field name='val' type='measure'/>
  231. </graph>
  232. </field>
  233. </record>
  234. <record id="dupont_action" model="ir.actions.act_window">
  235. <field name="name">杜邦分析</field>
  236. <field name="res_model">dupont</field>
  237. <field name="type">ir.actions.act_window</field>
  238. <field name="view_mode">pivot,graph</field>
  239. </record>
  240. <menuitem id='dupont_menu_finance' name="杜邦分析"
  241. action='dupont_action' parent='finance.checkout_menu' sequence='100'/>
  242. </data>
  243. </odoo>
上海开阖软件有限公司 沪ICP备12045867号-1