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.
		
		
		
		
		
			
		
			
				
					
					
						
							269 lines
						
					
					
						
							14 KiB
						
					
					
				
			
		
		
		
			
			
			
		
		
	
	
							269 lines
						
					
					
						
							14 KiB
						
					
					
				| <?xml version="1.0" encoding="utf-8" ?> | |
| <odoo> | |
|     <!-- Salon order view tree--> | |
|     <record id="salon_order_view_tree" model="ir.ui.view"> | |
|         <field name="name">salon.order.view.tree</field> | |
|         <field name="model">salon.order</field> | |
|         <field name="arch" type="xml"> | |
|             <list> | |
|                 <field name="name"/> | |
|                 <field name="chair_id"/> | |
|                 <field name="start_time"/> | |
|                 <field name="end_time"/> | |
|                 <field name="currency_id" column_invisible="1"/> | |
|                 <field name="time_taken_total" widget="float_time"/> | |
|                 <field name="price_subtotal" widget="monetary"/> | |
|                 <field name="stage_id"/> | |
|             </list> | |
|         </field> | |
|     </record> | |
|     <!-- Salon order view kanban--> | |
|     <record id="salon_order_view_kanban" model="ir.ui.view"> | |
|         <field name="name">salon.order.view.kanban</field> | |
|         <field name="model">salon.order</field> | |
|         <field name="arch" type="xml"> | |
|             <kanban default_group_by="stage_id" | |
|                     class="o_kanban_small_column" quick_create="false" | |
|                     on_create="quick_create"> | |
|                 <field name="color"/> | |
|                 <field name="stage_id"/> | |
|                 <field name="currency_id" invisible="1"/> | |
|                 <templates> | |
|                     <t t-name="kanban-box"> | |
|                         <div t-attf-class="#{kanban_color(record.color.raw_value)} oe_kanban_global_click"> | |
|                             <div class="o_dropdown_kanban dropdown"> | |
|                                 <a role="button" | |
|                                    class="dropdown-toggle o-no-caret btn" | |
|                                    data-toggle="dropdown" href="#" | |
|                                    aria-label="Dropdown menu" | |
|                                    title="Dropdown menu"> | |
|                                     <span class="fa fa-ellipsis-v"/> | |
|                                 </a> | |
|                                 <div class="dropdown-menu" role="menu"> | |
|                                     <t t-if="widget.editable"> | |
|                                         <a role="menuitem" type="edit" | |
|                                            class="dropdown-item">Edit... | |
|                                         </a> | |
|                                     </t> | |
|                                     <t t-if="widget.deletable"> | |
|                                         <a role="menuitem" type="delete" | |
|                                            class="dropdown-item">Delete | |
|                                         </a> | |
|                                     </t> | |
|                                     <ul class="oe_kanban_colorpicker" | |
|                                         data-field="color"/> | |
|                                 </div> | |
|                             </div> | |
|                             <div class="oe_kanban_content"> | |
|                                 <div> | |
|                                     <strong> | |
|                                         <field name="name"/> | |
|                                     </strong> | |
|                                 </div> | |
|                                 <div class="text-muted"> | |
|                                     <a>Customer :</a> | |
|                                     <field name="customer_name"/> | |
|                                     <div style="float: right;"> | |
|                                         <a>Chair :</a> | |
|                                         <field name="chair_id"/> | |
|                                     </div> | |
|                                 </div> | |
|                                 <div class="text-muted"> | |
|                                     <a>Amount :</a> | |
|                                     <field name="price_subtotal" | |
|                                            widget="monetary"/> | |
|                                 </div> | |
|                                 <div class="text-muted"> | |
|                                     <a>Total time taken :</a> | |
|                                     <field name="time_taken_total" | |
|                                            widget="float_time"/> | |
|                                 </div> | |
|                                 <div class="text-muted"> | |
|                                     <a>Date :</a> | |
|                                     <field name="date"/> | |
|                                 </div> | |
|                             </div> | |
|                             <div class="oe_clear"/> | |
|                         </div> | |
|                     </t> | |
|                 </templates> | |
|             </kanban> | |
|         </field> | |
|     </record> | |
|     <!-- Salon order view form--> | |
|     <record id="salon_order_view_form" model="ir.ui.view"> | |
|         <field name="name">salon.order.view.form</field> | |
|         <field name="model">salon.order</field> | |
|         <field name="arch" type="xml"> | |
|             <form> | |
|                 <header> | |
|                     <button name="action_validate" | |
|                             invisible="stage_id != 1 or validation_controller == True" | |
|                             string="Validate" type="object" | |
|                             class="oe_highlight"/> | |
|                     <button name="action_confirm" | |
|                             invisible="stage_id != 1 or validation_controller != True" | |
|                             string="Confirm" type="object" | |
|                             class="oe_highlight"/> | |
|                     <button name="action_create_invoice" | |
|                             invisible="stage_id != 2" | |
|                             string="Create Invoice" type="object" | |
|                             class="oe_highlight"/> | |
|                     <button name="action_cancel" string="Cancel" | |
|                             invisible="stage_id not in [1,2]" | |
|                             type="object"/> | |
|                     <button name="action_close" | |
|                             invisible="stage_id != [1,2]" string="Close" | |
|                             type="object"/> | |
|                     <field name="stage_id" widget="statusbar" | |
|                            domain="[('id','in',[1,2,4])]"/> | |
|                 </header> | |
|                 <sheet> | |
|                     <div class="oe_button_box" name="button_box"> | |
|                         <button name="action_view_invoice_salon" | |
|                                 type="object" class="oe_stat_button" | |
|                                 icon="fa-pencil-square-o" | |
|                                 invisible="stage_id not in [3,4]"> | |
|                             <field name="count" widget="statinfo" | |
|                                    string="Invoice"/> | |
|                         </button> | |
|                     </div> | |
|                     <group> | |
|                         <group> | |
|                             <field name="partner_id" | |
|                                    domain="[('partner_salon','=',True)]" | |
|                                    readonly="stage_id != 1"/> | |
|                             <field name="customer_name" | |
|                                    readonly="stage_id != 1"/> | |
|                             <field name="chair_id" | |
|                                    domain="[('active_booking_chairs','!=',True)]" | |
|                                    readonly="stage_id != 1" | |
|                                    options="{'no_create': True}"/> | |
|                             <field name="currency_id" invisible="1"/> | |
|                         </group> | |
|                         <group> | |
|                             <field name="booking_identifier" invisible="1"/> | |
|                             <field name="date" readonly="stage_id != 1"/> | |
|                             <field name="start_time" | |
|                                    readonly="stage_id != 1" | |
|                                    invisible="stage_id != 1 or booking_identifier != True"/> | |
|                             <field name="end_time" readonly="stage_id != 1" | |
|                                    invisible="stage_id != 1 or booking_identifier != True"/> | |
|                             <field name="inv_stage_identifier" | |
|                                    invisible="1"/> | |
|                             <field name="time_taken_total" invisible="1"/> | |
|                             <field name="validation_controller" | |
|                                    invisible="1"/> | |
|                         </group> | |
|                     </group> | |
|                     <notebook> | |
|                         <page string="Order Lines"> | |
|                             <field name="order_line_ids" mode="list,kanban" | |
|                                    readonly="stage_id != 1"> | |
|                                 <form string="Salon Order Lines"> | |
|                                     <group> | |
|                                         <group> | |
|                                             <field name="service_id"/> | |
|                                             <field name="time_taken"/> | |
|                                             <field name="currency_id" | |
|                                                    invisible="1"/> | |
|                                             <field name="price" | |
|                                                    widget="monetary"/> | |
|                                         </group> | |
|                                     </group> | |
|                                 </form> | |
|                                 <list string="Salon Order Lines" | |
|                                       editable="bottom"> | |
|                                     <field name="service_id"/> | |
|                                     <field name="time_taken" | |
|                                            widget="float_time"/> | |
|                                     <field name="currency_id" | |
|                                            column_invisible="1"/> | |
|                                     <field name="price" widget="monetary"/> | |
|                                     <field name="price_subtotal" | |
|                                            widget="monetary"/> | |
|                                 </list> | |
|                                 <kanban class="o_kanban_mobile"> | |
|                                     <field name="service_id"/> | |
|                                     <field name="time_taken"/> | |
|                                     <field name="price_subtotal" | |
|                                            widget="monetary"/> | |
|                                     <templates> | |
|                                         <t t-name="kanban-box"> | |
|                                             <div t-attf-class="oe_kanban_card oe_kanban_global_click"> | |
|                                                 <div class="row"> | |
|                                                     <div class="col-xs-12"> | |
|                                                         <strong> | |
|                                                             <span> | |
|                                                                 <t t-esc="record.service_id.value"/> | |
|                                                             </span> | |
|                                                         </strong> | |
|                                                     </div> | |
|                                                 </div> | |
|                                                 <div class="row"> | |
|                                                     <div class="col-xs-4 text-muted"> | |
|                                                         <span class="pull-right text-right"> | |
|                                                             <t t-esc="record.time_taken.value"/> | |
|                                                         </span> | |
|                                                     </div> | |
|                                                 </div> | |
|                                                 <div class="row"> | |
|                                                     <div class="col-xs-4 text-muted"> | |
|                                                         <span class="pull-right text-right"> | |
|                                                             <t t-esc="record.price_subtotal.value"/> | |
|                                                         </span> | |
|                                                     </div> | |
|                                                 </div> | |
|                                             </div> | |
|                                         </t> | |
|                                     </templates> | |
|                                 </kanban> | |
|                             </field> | |
|                             <group class="oe_subtotal_footer oe_right" | |
|                                    colspan="2" name="salon_total"> | |
|                                 <div class="oe_subtotal_footer_separator oe_inline o_td_label"> | |
|                                     <label for="price_subtotal"/> | |
|                                     <button name="action_update_total" | |
|                                             string="(update)" type="object" | |
|                                             class="oe_edit_only oe_link"/> | |
|                                 </div> | |
|                                 <field name="price_subtotal" nolabel="1" | |
|                                        class="oe_subtotal_footer_separator" | |
|                                        widget="monetary"/> | |
|                             </group> | |
|                             <field name="note" class="oe_inline" | |
|                                    placeholder="Setup default terms and conditions in your company settings."/> | |
|                             <div class="oe_clear"/> | |
|                         </page> | |
|                     </notebook> | |
|                 </sheet> | |
|             </form> | |
|         </field> | |
|     </record> | |
|     <!-- Salon order action--> | |
|     <record id="salon_order_action" model="ir.actions.act_window"> | |
|         <field name="name">Salon Orders</field> | |
|         <field name="res_model">salon.order</field> | |
|         <field name="view_mode">kanban,list,form</field> | |
|         <field name="help" type="html"> | |
|             <p class="o_view_nocontent_smiling_face"> | |
|                 No data yet! | |
|             </p> | |
|             <p>Create order to manage salon orders.</p> | |
|         </field> | |
|     </record> | |
|     <!-- Salon active orders dashboard action --> | |
|     <record id="salon_active_orders_dashboard_action" | |
|             model="ir.actions.act_window"> | |
|         <field name="name">Salon Orders</field> | |
|         <field name="res_model">salon.order</field> | |
|         <field name="view_mode">kanban,list,form</field> | |
|         <field name="help" type="html"> | |
|             <p class="o_view_nocontent_smiling_face"> | |
|                 No Booking! | |
|             </p> | |
|             <p>Currently no booking for this chair</p> | |
|         </field> | |
|         <field name="domain">[('chair_id', '=', active_id)]</field> | |
|     </record> | |
| </odoo>
 | |
| 
 |