Commit cc2c8677 authored by 18083's avatar 18083

经租报单改造

parent 3ab00003
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: WW
$Date: 2014-11-13 下午5:36:09
$Revision: 1.0
$Purpose:
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
SELECT t1.user_id,t1.user_name FROM sys_user t1 #WHERE_CLAUSE#
]]></bm:query-sql>
</bm:operation>
</bm:operations>
<bm:query-fields>
<bm:query-field name="user_id" queryExpression="t1.user_id=${@user_id}"/>
</bm:query-fields>
</bm:model>
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: weiwuzhen
$Date: 2016-5-5 下午3:45:05
$Revision: 1.0
$Purpose:
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
select *
from prj_project_bp_operat_lv p
where p.project_id=${@project_id}
and p.bp_category='RENTER'
]]></bm:query-sql>
</bm:operation>
</bm:operations>
</bm:model>
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: trd
$Date: 2023-11-1 下午04:17:01
$Revision: 1.0
$Purpose: 采购单报价信息
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[SELECT T1.* FROM (SELECT * FROM prj_quotation a) T1 #WHERE_CLAUSE#]]></bm:query-sql>
</bm:operation>
</bm:operations>
<bm:query-fields>
<bm:query-field name="document_id" queryExpression="t1.document_id=${@document_id} and t1.document_category=&apos;PROJECT&apos;"/>
</bm:query-fields>
</bm:model>
......@@ -16,6 +16,7 @@
<a:model-query defaultWhereClause="t1.company_id=${/session/@company_id}" fetchAll="true"
model="prj.PRJ500D.get_company_info" rootPath="company_info_path"/>
<a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/>
<a:model-query defaultWhereClause="t.user_id=${/session/@user_id}" model="hls.HLS214N.sys_division" rootPath="user_division"/>
</a:init-procedure>
<a:view>
<a:link id="prj_chance_create_link"
......@@ -25,6 +26,8 @@
<a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code"
modelaction="update"/>
<a:link id="prj500n_create_project_interface_link" model="prj.PRJ500N.ds_project_interface_query" modelaction="execute" />
<a:link id="prj_chance_operat_create_link"
url="${/request/@context_path}/modules/prj/PRJ500N/prj_project_create_operat.lview"/>
<script type="text/javascript"><![CDATA[
//确定
window['${/parameter/@layout_code}_user_button1_layout_dynamic_click'] = function () {
......@@ -40,12 +43,23 @@
debugger;
$L.showErrorMessage("提示", '租赁物为北京卡家的业务类型只能是售后回租!');
return false;
}
if(record.data.division=='95'&&record.data.business_type!='LEASEOPERAT'){
$L.showErrorMessage("提示", '租赁物为经租设备的业务类型只能是经营性租赁!');
return false;
}
if(record.data.division!='95'&&record.data.business_type=='LEASEOPERAT'){
$L.showErrorMessage("提示", '业务类型为经营性租赁只能选择经租设备!');
return false;
}
if ($(ds_id).validate()) {
var url;
if(record.data.is_constru_unit == 'Y' || '${/model/user_agent_description/record/@is_constru_unit}' == 'Y'){
record.set('function_code', 'PRJ500D_CONSTRU');
url = "prj_chance_constru_create_link";
}else if(record.data.division=='95'){
record.set('function_code', 'PRJ500D_OPERAT');
url = "prj_chance_operat_create_link";
}else{
record.set('function_code', 'PRJ500D');
url = "prj_chance_create_link";
......@@ -78,6 +92,17 @@
// head_record.set('invoice_agent_id_n', '${/model/prj_project_invoice_agent_id_dafault_value_path/record/@bp_id_n}');
head_record.set('invoice_agent_id', invoice_agent_id);
head_record.set('invoice_agent_id_n', invoice_agent_id_n);
//经营性租赁改造 18083 2023/8/24
if("${/model/user_division/record/@division}"==95){
head_record.set('business_type','LEASEOPERAT');
head_record.set('business_type_n','经营性租赁');
head_record.set('division','95');
head_record.set('division_n','经租设备');
head_record.getField('division').setReadOnly(true);
head_record.getField('division_n').setReadOnly(true);
head_record.set('bp_class','bp_class');
head_record.set('bp_class_n','法人');
}
if(!invoice_agent_id){
head_record.getField('invoice_agent_id_n').setReadOnly(false);
......
......@@ -9,6 +9,7 @@
trace="true">
<a:init-procedure>
<a:model-query model="cont.CON620.get_sys_role" rootPath="role_info"/>
<a:model-query defaultWhereClause="t1.user_id=${/session/@user_id}" model="prj.PRJ501N.get_user_info" rootPath="user_name_path"/>
</a:init-procedure>
<a:view>
<a:link id="prj_project_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code"
......@@ -17,6 +18,7 @@
url="${/request/@context_path}/modules/prj/PRJ501N/prj_project_create_tree_n.lview"/>
<a:link id="car_modify_link" url="${/request/@context_path}/modules/prj/PRJ501N/prj_project_maintain.lview"/>
<a:link id="car_modify_constru_link" url="${/request/@context_path}/modules/prj/PRJ501N/prj_project_maintain_constru.lview"/>
<a:link id="car_modify_operat_link" url="${/request/@context_path}/modules/prj/PRJ501N/prj_project_maintain_opreat.lview"/>
<a:link id="car_modify_dff_link"
url="${/request/@context_path}/modules/prj/PRJ501N/prj_project_maintain.lview"/>
<a:link id="car_modify_mananger_link"
......@@ -62,6 +64,9 @@
if(record.get('is_constru_unit') == 'Y'){
param['function_code'] = 'PRJ501_CONSTRU_WFL';
url = 'car_modify_constru_link';
}else if(record.get('division')=='95'){
param['function_code'] = 'PRJ501_OPERAT_WFL';
url = 'car_modify_operat_link';
}else{
param['function_code'] = 'PRJ501_WFL';
url = 'car_modify_link';
......@@ -81,6 +86,9 @@
if(record.get('is_constru_unit') == 'Y'){
param['function_code'] = 'PRJ500D_CONSTRU';
url = 'car_modify_constru_link';
}else if(record.get('division')=='95'){
param['function_code'] = 'PRJ500D_OPERAT';
url = 'car_modify_operat_link';
}else{
param['function_code'] = 'PRJ501D';
url = 'car_modify_link';
......@@ -172,6 +180,11 @@
window['${/parameter/@layout_code}_user_button3_layout_dynamic_click'] = function () {
var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'prj_project');
var project_id = $(ds_id).getSelected()[0].get('project_id');
var division = $(ds_id).getSelected()[0].get('division');
if (division=='95'){
Leaf.showMessage('提示', '经营性租赁不支持报价单打印!');
return;
}
//根据是否是代理店打印不同的文本
var templet_code='';
// if("${/model/role_info/record/@role_code}"!="0018"&&"${/model/role_info/record/@role_code}"!="0019") {
......@@ -186,6 +199,11 @@
window['${/parameter/@layout_code}_user_button4_layout_dynamic_click'] = function () {
var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'prj_project');
var project_id = $(ds_id).getSelected()[0].get('project_id');
var division = $(ds_id).getSelected()[0].get('division');
if (division=='95'){
Leaf.showMessage('提示', '经营性租赁不支持租金支付计划表打印!');
return;
}
//根据是否是代理店打印不同的文本
var templet_code='';
templet_code = 'PROJECT_QUOTATION_N';
......@@ -204,11 +222,19 @@
//上级 btn4 可见
if("${/model/role_info/record/@role_code}"=="0019") {
$('PROJECT_MODIFY_ENTRANCE_user_button4').hide();
if("${/model/user_name_path/record/@user_name}"=="ZLSY001"||"${/model/user_name_path/record/@user_name}"=="ZLSY002"){
$('PROJECT_MODIFY_ENTRANCE_user_button4').hide();
$('PROJECT_MODIFY_ENTRANCE_user_button3').hide();
}
}else if("${/model/role_info/record/@role_code}"=="0018"){
var t= document.getElementById('PROJECT_MODIFY_ENTRANCE_user_button3').style.display="none";
t.remove();
$('PROJECT_MODIFY_ENTRANCE_user_button3').hide();
if("${/model/user_name_path/record/@user_name}"=="ZLSY001"||"${/model/user_name_path/record/@user_name}"=="ZLSY002"){
$('PROJECT_MODIFY_ENTRANCE_user_button4').hide();
$('PROJECT_MODIFY_ENTRANCE_user_button3').hide();
}
}
})
function check_isload() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment