<?xml version="1.0" encoding="UTF-8"?>
<!--
    $Author: ZLF 
    $Date: 2014-11-4 下午3:50:14  
    $Revision: 1.0  
    $Purpose: 
-->
<a:screen xmlns:a="http://www.leaf-framework.org/application">
    <a:init-procedure><![CDATA[
		
	]]></a:init-procedure>
    <a:view>
        <a:link id="con_lease_import_link" url="${/request/@context_path}/modules/cont/CON508/con_contract_lease_import.lview"/>
        <script type="text/javascript"><![CDATA[
			function con508_reset() {
			    $('con_document_history_query_ds').reset();
			}
			
			function con508_query() {
			    $('con_contract_lease_item_result_ds').query();
			}
			function con508_import() {
        	    var win =new Leaf.Window({
        	        url:$('con_lease_import_link').getUrl(),
        	        title: '合同租赁物导入',
                    id: 'con_lease_import_window',        	        
        	        fullScreen:true
        	    });
        	     win.on('close', function() {
        	         $('con_contract_lease_item_result_ds').query();
                });
        	}
		]]></script>
        <a:screen-include screen="modules/cont/CON500/con_contract_authority_list_validate.lview?document_category=LEASE_ITEM&amp;function_code=CON508&amp;"/>
        <a:dataSets>
            <a:dataSet id="vehicle_storage_placeDS" lookupCode="VEHICLE_STORAGE_PLACE"/>
            <a:dataSet id="vis_majorDS" lookupCode="VIS_MAJOR"/>
            <a:dataSet id="con_document_history_query_ds">
                <a:fields>
                    <a:field name="invoice_agent_id_n" lovGridHeight="350" lovHeight="500" lovService="basic.hls_bp_agent_for_lov" lovWidth="500" title="经销商名称">
                        <a:mapping>
                            <a:map from="bp_id" to="invoice_agent_id"/>
                            <a:map from="bp_name" to="invoice_agent_id_n"/>
                        </a:mapping>
                    </a:field>
                </a:fields>
            </a:dataSet>
            <a:dataSet id="con_contract_lease_item_result_ds" autoPageSize="true" autoQuery="true" model="cont.CON508.con_contract_lease_item_lv" queryDataSet="con_document_history_query_ds">
                <a:events>
                    <a:event name="query" handler="aut_authority_list_validate_query"/>
                </a:events>
            </a:dataSet>
        </a:dataSets>
        <a:screenBody>
            <a:screenTopToolbar>
                <a:screenTitle/>
                <a:gridButton click="con508_query" text="查询"/>
                <a:gridButton click="con508_reset" text="重置"/>
                <a:gridButton click="con508_import" text="导入"/>
            </a:screenTopToolbar>
        </a:screenBody>
        <a:form column="1" title="查询条件">
            <a:hBox>
                <a:lov name="invoice_agent_id_n" bindTarget="con_document_history_query_ds" prompt="经销商名称"/>
                <a:textField name="contract_number" bindTarget="con_document_history_query_ds" prompt="批次编码"/>
                <a:textField name="item_frame_number" bindTarget="con_document_history_query_ds" prompt="车架号"/>
                <a:datePicker name="treasury_date_from" bindTarget="con_document_history_query_ds" prompt="查库日期从"/>
                <a:datePicker name="treasury_date_to" bindTarget="con_document_history_query_ds" prompt="查库日期到"/>
            </a:hBox>
        </a:form>
        <a:grid id="con_contract_lease_item_grid" bindTarget="con_contract_lease_item_result_ds" marginHeight="200" marginWidth="30" navBar="true">
            <!-- <a:columns>
                <a:column name="lease_item_seq" prompt="序号" width="50"/>
                <a:column name="treasury_date" prompt="查库日期" renderer="Leaf.formatDate" width="120"/>
                <a:column name="invoice_agent_id_n" prompt="经销商名称" width="200"/>
                <a:column name="lease_start_date" prompt="融资日期" renderer="Leaf.formatDate" width="120"/>
                <a:column name="vehicle_storage_place_n" editor="combox_edit" prompt="车辆存放地点" width="120"/>
                <a:column name="item_frame_number" prompt="车架号" width="150"/>
                <a:column name="vehicle_check" prompt="车辆已查" width="100"/>
                <a:column name="license_flag" editor="grid_ckb" prompt="车证已查" width="60"/>
                <a:column name="key_flag" editor="grid_ckb" prompt="钥匙已查" width="60"/>
                <a:column name="mention_flag" editor="grid_ckb" prompt="未提" width="60"/>
                <a:column name="onway_flag" editor="grid_ckb" prompt="在途" width="60"/>
                <a:column name="invoice_date" prompt="发票日期" renderer="Leaf.formatDate" width="100"/>
                <a:column name="invoice_num" prompt="发票号码" width="200"/>
                <a:column name="vehicle_license_flag" editor="grid_ckb" prompt="车辆或车证未正常查到" width="150"/>
                <a:column name="damage_flag" editor="grid_ckb" prompt="损坏" width="60"/>
                <a:column name="display_vehicles" prompt="展示车辆" width="150"/>
                <a:column name="vis_major_n" editor="combox_edit" prompt="不可抗力" width="200"/>
                <a:column name="mortgage_third_flag" editor="grid_ckb" prompt="抵押给第三方" width="150"/>
                <a:column name="vehicle_others" prompt="其他" width="250"/>
            </a:columns> -->
            <a:columns>
                <a:column name="contract_number" prompt="批次编码" width="200"/>
                <a:column name="lease_item_seq" prompt="序号" width="50"/>
                <a:column name="treasury_date" prompt="查库日期" renderer="Leaf.formatDate" width="120"/>
                <a:column name="invoice_agent_id_n" prompt="经销商名称" width="200"/>
                <a:column name="lease_start_date" prompt="融资日期" renderer="Leaf.formatDate" width="120"/>
                <a:column name="vehicle_storage_place_n" prompt="车辆存放地点" width="120"/>
                <a:column name="item_frame_number" prompt="车架号" width="150"/>
                <a:column name="vehicle_check" prompt="车辆已查" width="100"/>
                <a:column name="license_flag_n" prompt="车证已查" width="60"/>
                <a:column name="key_flag_n" prompt="钥匙已查" width="60"/>
                <a:column name="mention_flag_n" prompt="未提" width="60"/>
                <a:column name="onway_flag_n" prompt="在途" width="60"/>
                <a:column name="invoice_date" prompt="发票日期" renderer="Leaf.formatDate" width="100"/>
                <a:column name="invoice_num" prompt="发票号码" width="200"/>
                <a:column name="vehicle_license_flag_n" prompt="车辆或车证未正常查到" width="150"/>
                <a:column name="damage_flag_n" prompt="损坏" width="60"/>
                <a:column name="display_vehicles" prompt="展示车辆" width="150"/>
                <a:column name="vis_major_n" prompt="不可抗力" width="200"/>
                <a:column name="mortgage_third_flag_n" prompt="抵押给第三方" width="150"/>
                <a:column name="vehicle_others" prompt="其他" width="250"/>
            </a:columns>
            <!--  <a:editors>
                <a:textField id="grid_tf"/>
                <a:lov id="lov_edit"/>
                <a:comboBox id="combox_edit"/>
                <a:checkBox id="grid_ckb"/>
                <a:datePicker id="dateDs_picker"/>
            </a:editors> -->
        </a:grid>
    </a:view>
</a:screen>
