022 even more interlinks
This commit is contained in:
+1
-1
@@ -99,7 +99,7 @@
|
|||||||
|
|
||||||
|
|
||||||
<cfset request.RECORDS_PER_PAGE=500/>
|
<cfset request.RECORDS_PER_PAGE=500/>
|
||||||
<cfset request.APP_VERSION="0.00.021"/>
|
<cfset request.APP_VERSION="0.00.022"/>
|
||||||
<cfset request.STAND=getStand()/>
|
<cfset request.STAND=getStand()/>
|
||||||
|
|
||||||
<cflock scope="application" type="readonly" timeout=3>
|
<cflock scope="application" type="readonly" timeout=3>
|
||||||
|
|||||||
+6
-2
@@ -85,7 +85,11 @@
|
|||||||
|
|
||||||
<div class="tr">
|
<div class="tr">
|
||||||
<div class="th">Контрагент</div>
|
<div class="th">Контрагент</div>
|
||||||
<div class="td">#qDecoration.contragent# #qDecoration.wz# [#d.company_uid#] </div>
|
<div class="td">
|
||||||
|
<a href="contragent.cfm?__id=#d.company_uid#&#tr.fwx#">
|
||||||
|
#qDecoration.contragent# #qDecoration.wz# [#d.company_uid#]
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="tr">
|
<div class="tr">
|
||||||
@@ -127,7 +131,7 @@
|
|||||||
from elma.additional_agreements a
|
from elma.additional_agreements a
|
||||||
left outer join elma.deals d on (a.deal_uid=d.__id)
|
left outer join elma.deals d on (a.deal_uid=d.__id)
|
||||||
left outer join s on (d.__status_status=s.status_id)
|
left outer join s on (d.__status_status=s.status_id)
|
||||||
where a.contract_uid=<cfqueryparam cfsqltype="cf_sql_other" value="#d.__id#"/>
|
where a.contract_uid=<cfqueryparam cfsqltype="cf_sql_other" value="#d.__id#" null=#!isValid('guid',d.__id)#/>
|
||||||
order by 1
|
order by 1
|
||||||
</cfquery>
|
</cfquery>
|
||||||
|
|
||||||
|
|||||||
+227
-44
@@ -122,56 +122,239 @@
|
|||||||
|
|
||||||
</cfoutput>
|
</cfoutput>
|
||||||
сюда добавить сделок, договоров и т.д.
|
сюда добавить сделок, договоров и т.д.
|
||||||
<!---
|
|
||||||
<layout:page section="extension" closeForm="Yes"/>
|
<layout:page section="extension" closeForm="Yes"/>
|
||||||
|
|
||||||
<cfif d.contragent_id GT 0>
|
<cfif len(d.__id)>
|
||||||
<cfquery name="qContract">
|
|
||||||
select
|
|
||||||
d.contract_id
|
|
||||||
,d.contract
|
|
||||||
,d.dt_contract
|
|
||||||
,(select count(*) from specification s where s.contract_id=d.contract_id) as spec_cnt
|
|
||||||
from contract d
|
|
||||||
where d.contragent_id=<cfqueryparam cfsqltype="cf_sql_integer" value="#d.contragent_id#"/>
|
|
||||||
order by 1
|
|
||||||
</cfquery>
|
|
||||||
|
|
||||||
<cfoutput>
|
<cfquery name="qContract">
|
||||||
<h4>Договоры (#qContract.recordCount#)</h4>
|
select
|
||||||
|
<d:field_set titleMapOut="titleMap" lengthOut="fieldCount">
|
||||||
|
<d:field title="ID" cfSqlType="CF_SQL_OTHER">d.__id</d:field>
|
||||||
|
<d:field title="Внут.номер">d.agreement_id</d:field>
|
||||||
|
<d:field title="Договор">d.__name</d:field>
|
||||||
|
<d:field title="company_uid">d.company_uid</d:field>
|
||||||
|
<d:field title="Дата договора">d.date_of_aggrement</d:field>
|
||||||
|
<d:field title="Дата окончания">d.date_end_aggrement</d:field>
|
||||||
|
<d:field title="Тип договора">d.type_of_agreement</d:field>
|
||||||
|
<d:field title="__index">d.__index</d:field>
|
||||||
|
</d:field_set>
|
||||||
|
from elma.aggrements d
|
||||||
|
where d.company_uid=<cfqueryparam cfsqltype="cf_sql_other" value="#d.__id#" null=#!isValid('guid',d.__id)#/>
|
||||||
|
</cfquery>
|
||||||
|
|
||||||
|
<cfoutput>
|
||||||
|
<h4>Договоры (#qContract.recordCount#)</h4>
|
||||||
|
</cfoutput>
|
||||||
|
|
||||||
|
<table class="worktable">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>__id</th>
|
||||||
|
<th>Номер</th>
|
||||||
|
<th>Внут. номер</th>
|
||||||
|
<th>Дата</th>
|
||||||
|
<th>Дата оконч.</th>
|
||||||
|
<th>Тип договора</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<cfoutput query="qContract">
|
||||||
|
<tr>
|
||||||
|
<td><a href="contract.cfm?__id=#__id#&#tr.fwx#">#__id#</a></td>
|
||||||
|
<td>#__name#</td>
|
||||||
|
<td>#agreement_id#</td>
|
||||||
|
<td>#dateFormat(date_of_aggrement,"YYYY-MM-DD")#</td>
|
||||||
|
<td>#dateFormat(date_end_aggrement,"YYYY-MM-DD")#</td>
|
||||||
|
<td class="c">#type_of_agreement#</td>
|
||||||
|
</tr>
|
||||||
</cfoutput>
|
</cfoutput>
|
||||||
|
</table>
|
||||||
|
|
||||||
<table class="worktable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th><c:link_add canWrite=#pageInfo.writePermitted()# entity="contract" id="#contragent_id#" extra="contragent_id=#d.contragent_id#" fwx=#tr.fwx#/></th>
|
|
||||||
<th>Номер договора</th>
|
|
||||||
<th>Дата договора</th>
|
|
||||||
<th>Спецификаций</th>
|
|
||||||
<th></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<cfoutput query="qContract">
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<c:link_view_edit canWrite=#pageInfo.writePermitted()# entity="contract" id=#contract_id# fwx=#tr.fwx#/>
|
|
||||||
</td>
|
|
||||||
<td>#contract#</td>
|
|
||||||
<td class="c">
|
|
||||||
#dateFormat(dt_contract,'YYYY-MM-DD')#
|
|
||||||
</td>
|
|
||||||
<td class="c">
|
|
||||||
<cfif spec_cnt GT 0>#spec_cnt#</cfif>
|
|
||||||
|
|
||||||
</td>
|
<cfquery name="qAdditionalAgreement">
|
||||||
<td class="c">
|
with
|
||||||
<c:link_del canWrite=#pageInfo.writePermitted()# entity="contract" id=#contract_id# fwx=#tr.fwx#/>
|
s(status, status_id, probability_pc) as (VALUES
|
||||||
</td>
|
('Закрыта неуспешно',7,0),('Закрыта успешно',6,100),('Договор подписан',5,100),('Договор на подписании',15,90),('Договор на согласовании',12,70),
|
||||||
</tr>
|
('Тестирование',8,50),('Отправлено ТКП',10,20),('Внутреннее согласование',37,10),('Проработка решения',4,10),('Сбор потребностей',1,0)
|
||||||
</cfoutput>
|
),
|
||||||
</table>
|
component as (select siv.deal as deal_uids, siv.type, (siv.cnt*(100-COALESCE(siv.discount,0))/100*p.price*p.cnt*(100-COALESCE(p.discount,0))) as param_cost
|
||||||
</cfif> --->
|
from elma.deals_services siv
|
||||||
|
join elma.service_parametrs p on (p.__id = ANY(siv.params))
|
||||||
|
)
|
||||||
|
select
|
||||||
|
a.__id::text
|
||||||
|
,a.__name as additional_agreement
|
||||||
|
,a.contract_uid::text
|
||||||
|
,a.is_actual
|
||||||
|
,a.last_aa
|
||||||
|
,a.deal_uid::text
|
||||||
|
,c.__name as contract
|
||||||
|
,c.agreement_id
|
||||||
|
,c.date_of_aggrement
|
||||||
|
,d.__id as deal_uid
|
||||||
|
,d.__name as deal
|
||||||
|
,d.__status_status
|
||||||
|
,s.status
|
||||||
|
,s.probability_pc
|
||||||
|
,u.__name as owner
|
||||||
|
,(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (1)
|
||||||
|
) as install
|
||||||
|
,(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (2)
|
||||||
|
) as periodical
|
||||||
|
,(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (3)
|
||||||
|
) as metered
|
||||||
|
from elma.additional_agreements a
|
||||||
|
join elma.aggrements c on (a.contract_uid=c.__id)
|
||||||
|
join elma.deals d on (a.deal_uid=d.__id)
|
||||||
|
left outer join s on (d.__status_status=s.status_id)
|
||||||
|
left outer join elma.comp_users_ext u on (d._owner=c.__id)
|
||||||
|
where c.company_uid=<cfqueryparam cfsqltype="cf_sql_other" value=#d.__id# null=#!isValid("guid",d.__id)#/>
|
||||||
|
</cfquery>
|
||||||
|
|
||||||
<!--- <cfdump var=#this.datasources#/> --->
|
|
||||||
|
|
||||||
|
<cfoutput>
|
||||||
|
<h4>Доп. соглашения (#qAdditionalAgreement.recordCount#)</h4>
|
||||||
|
</cfoutput>
|
||||||
|
|
||||||
|
<table class="worktable">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>__id</th>
|
||||||
|
<th>Доп. соглашение</th>
|
||||||
|
<th>Внут. н-р дог.</th>
|
||||||
|
<th>Дата договора</th>
|
||||||
|
<th>Сделка</th>
|
||||||
|
<th>Статус сделки</th>
|
||||||
|
<th>Вер-ть %</th>
|
||||||
|
<th>Ответственный</th>
|
||||||
|
<th>Инсталл</th>
|
||||||
|
<th>Ежемес</th>
|
||||||
|
<th>Тариф.</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<cfoutput query="qAdditionalAgreement">
|
||||||
|
<tr>
|
||||||
|
<td><a href="additional_agreement.cfm?__id=#__id#&#tr.fwx#">#__id#</a></td>
|
||||||
|
<td>#additional_agreement#</td>
|
||||||
|
<td><a href="contract.cfm?__id=#contract_uid#&#tr.fwx#">#agreement_id#</a></td>
|
||||||
|
<td>#dateFormat(date_of_aggrement,"YYYY-MM-DD")#</td>
|
||||||
|
<td><a href="deal.cfm?__id=#deal_uid#&#tr.fwx#">#deal#</a></td>
|
||||||
|
<td>#status#</td>
|
||||||
|
<td>#probability_pc#</td>
|
||||||
|
<td>#owner#</td>
|
||||||
|
<td class="r">#nFmt(install)#</td>
|
||||||
|
<td class="r">#nFmt(periodical)#</td>
|
||||||
|
<td class="r">#nFmt(metered)#</td>
|
||||||
|
</tr>
|
||||||
|
</cfoutput>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
<!--- ----------------------------------------------------------------- --->
|
||||||
|
<!--- ----------------------------------------------------------------- --->
|
||||||
|
<!--- ----------------------------------------------------------------- --->
|
||||||
|
|
||||||
|
<cfquery name="qDeal">
|
||||||
|
with
|
||||||
|
status(status, status_id, probability_pc) as (VALUES
|
||||||
|
('Закрыта неуспешно',7,0),('Закрыта успешно',6,100),('Договор подписан',5,100),('Договор на подписании',15,90),('Договор на согласовании',12,70),
|
||||||
|
('Тестирование',8,50),('Отправлено ТКП',10,20),('Внутреннее согласование',37,10),('Проработка решения',4,10),('Сбор потребностей',1,0)
|
||||||
|
),
|
||||||
|
component as (select siv.deal as deal_uids, siv.type, (siv.cnt*(100-COALESCE(siv.discount,0))/100*p.price*p.cnt*(100-COALESCE(p.discount,0))) as param_cost
|
||||||
|
from elma.deals_services siv
|
||||||
|
join elma.service_parametrs p on (p.__id = ANY(siv.params))
|
||||||
|
)
|
||||||
|
select
|
||||||
|
<d:field_set titleMapOut="titleMap" lengthOut="fieldCount">
|
||||||
|
<d:field title="ID" cfSqlType="CF_SQL_OTHER">d.__id</d:field>
|
||||||
|
<d:field title="index" cfSqlType="CF_SQL_INTEGER">d.__index</d:field>
|
||||||
|
<d:field title="Название">d.__name</d:field>
|
||||||
|
<d:field title="company_uid">d._companies</d:field>
|
||||||
|
<d:field title="Создана">d."__createdAt" as __createdAt</d:field><!--- *** косяк d:field, если взять в кавычки имя поля, оно не попадает в массив полей --->
|
||||||
|
<d:field title="Контрагент">k.__name as contragent</d:field>
|
||||||
|
<d:field title="Контрагент">k.__id as contragent_uid</d:field>
|
||||||
|
<d:field title="WZ">k.id_klienta as wz</d:field>
|
||||||
|
<d:field title="status_id">d.__status_status</d:field>
|
||||||
|
<d:field title="Статус">s.status</d:field>
|
||||||
|
<d:field title="Вероятность%">s.probability_pc</d:field>
|
||||||
|
<d:field title="Ответственный">c.__name as owner</d:field>
|
||||||
|
<d:field title="Допник">a.__name as additional_agreement</d:field>
|
||||||
|
<d:field title="Допник">a.__id as additional_agreement_uid</d:field>
|
||||||
|
<d:field title="Договор">g.__name as contract</d:field>
|
||||||
|
<d:field title="Договор">g.__id as contract_uid</d:field>
|
||||||
|
<d:field title="Договор">g.date_of_aggrement</d:field>
|
||||||
|
<d:field title="Договор">g.agreement_id</d:field>
|
||||||
|
<d:field title="Дата дог.">g.date_of_aggrement as dt_contract</d:field>
|
||||||
|
<d:field>(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (1)
|
||||||
|
) as install
|
||||||
|
</d:field>
|
||||||
|
<d:field>(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (2)
|
||||||
|
) as periodical
|
||||||
|
</d:field>
|
||||||
|
<d:field>(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (3)
|
||||||
|
) as metered
|
||||||
|
</d:field>
|
||||||
|
</d:field_set>
|
||||||
|
from elma.deals d
|
||||||
|
left outer join elma.companies k on (d._companies=k.__id)
|
||||||
|
left outer join status s on (d.__status_status=s.status_id)
|
||||||
|
left outer join elma.comp_users_ext c on (d._owner=c.__id)
|
||||||
|
left outer join elma.additional_agreements a on (d.__id=a.deal_uid)
|
||||||
|
left outer join elma.aggrements g on (a.contract_uid = g.__id)
|
||||||
|
where d._companies=<cfqueryparam cfsqltype="cf_sql_other" value="#d.__id#" null=#!isValid('guid',d.__id)#/>
|
||||||
|
</cfquery>
|
||||||
|
|
||||||
|
<cfoutput>
|
||||||
|
<h4>Сделки (#qDeal.recordCount#)</h4>
|
||||||
|
</cfoutput>
|
||||||
|
|
||||||
|
<table class="worktable">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>__id</th>
|
||||||
|
<th>__index</th>
|
||||||
|
<th>Сделка</th>
|
||||||
|
<th>Статус сделки</th>
|
||||||
|
<th>Вер-ть %</th>
|
||||||
|
<th>Ответственный</th>
|
||||||
|
<th>Допник</th>
|
||||||
|
<th>Договор</th>
|
||||||
|
<th>Внут. н-р дог.</th>
|
||||||
|
<th>Дата договора</th>
|
||||||
|
<th>Инсталл</th>
|
||||||
|
<th>Ежемес</th>
|
||||||
|
<th>Тариф.</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<cfoutput query="qDeal">
|
||||||
|
<tr>
|
||||||
|
<td><a href="deal.cfm?__id=#__id#&#tr.fwx#">#__id#</a></td>
|
||||||
|
<td>#__index#</td>
|
||||||
|
<td><a href="deal.cfm?__id=#__id#&#tr.fwx#">#__name#</a></td>
|
||||||
|
<td>#status#</td>
|
||||||
|
<td>#probability_pc#</td>
|
||||||
|
<td>#owner#</td>
|
||||||
|
<td>#additional_agreement#</td>
|
||||||
|
<td>#contract#</td>
|
||||||
|
<td><a href="contract.cfm?__id=#contract_uid#&#tr.fwx#">#agreement_id#</a></td>
|
||||||
|
<td>#dateFormat(date_of_aggrement,"YYYY-MM-DD")#</td>
|
||||||
|
<td class="r">#nFmt(install)#</td>
|
||||||
|
<td class="r">#nFmt(periodical)#</td>
|
||||||
|
<td class="r">#nFmt(metered)#</td>
|
||||||
|
</tr>
|
||||||
|
</cfoutput>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
</cfif>
|
||||||
<layout:page section="footer"/>
|
<layout:page section="footer"/>
|
||||||
@@ -126,8 +126,8 @@
|
|||||||
<div class="th">Контрагент</div>
|
<div class="th">Контрагент</div>
|
||||||
<div class="td"><!--- <a href="contract.cfm?__id=#d.contract_uid#&#tr.fwx#"><b>#qDecoration.contract#</b> #dateFormat(qDecoration.date_of_aggrement,'DD.MM.YYYY')#
|
<div class="td"><!--- <a href="contract.cfm?__id=#d.contract_uid#&#tr.fwx#"><b>#qDecoration.contract#</b> #dateFormat(qDecoration.date_of_aggrement,'DD.MM.YYYY')#
|
||||||
[#d.contract_uid#]</a> --->
|
[#d.contract_uid#]</a> --->
|
||||||
#qDecoration.contragent# #qDecoration.wz#
|
<a href="contragent.cfm?__id=#d._companies#&#tr.fwx#"> #qDecoration.contragent# #qDecoration.wz#
|
||||||
index:#qDecoration.contragent_index#
|
index:#qDecoration.contragent_index#</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
+26
-2
@@ -18,11 +18,15 @@
|
|||||||
<!--- <cfset pageInfo.settings.filter=#filter#/> --->
|
<!--- <cfset pageInfo.settings.filter=#filter#/> --->
|
||||||
|
|
||||||
<cftry>
|
<cftry>
|
||||||
<cfquery name="qRead" datasource="#request.DS#">
|
<cfquery name="qRead">
|
||||||
with
|
with
|
||||||
status(status, status_id, probability_pc) as (VALUES
|
status(status, status_id, probability_pc) as (VALUES
|
||||||
('Закрыта неуспешно',7,0),('Закрыта успешно',6,100),('Договор подписан',5,100),('Договор на подписании',15,90),('Договор на согласовании',12,70),
|
('Закрыта неуспешно',7,0),('Закрыта успешно',6,100),('Договор подписан',5,100),('Договор на подписании',15,90),('Договор на согласовании',12,70),
|
||||||
('Тестирование',8,50),('Отправлено ТКП',10,20),('Внутреннее согласование',37,10),('Проработка решения',4,10),('Сбор потребностей',1,0)
|
('Тестирование',8,50),('Отправлено ТКП',10,20),('Внутреннее согласование',37,10),('Проработка решения',4,10),('Сбор потребностей',1,0)
|
||||||
|
),
|
||||||
|
component as (select siv.deal as deal_uids, siv.type, (siv.cnt*(100-COALESCE(siv.discount,0))/100*p.price*p.cnt*(100-COALESCE(p.discount,0))) as param_cost
|
||||||
|
from elma.deals_services siv
|
||||||
|
join elma.service_parametrs p on (p.__id = ANY(siv.params))
|
||||||
)
|
)
|
||||||
select
|
select
|
||||||
<d:field_set titleMapOut="titleMap" lengthOut="fieldCount">
|
<d:field_set titleMapOut="titleMap" lengthOut="fieldCount">
|
||||||
@@ -36,13 +40,28 @@
|
|||||||
<d:field title="WZ">k.id_klienta as wz</d:field>
|
<d:field title="WZ">k.id_klienta as wz</d:field>
|
||||||
<d:field title="status_id">d.__status_status</d:field>
|
<d:field title="status_id">d.__status_status</d:field>
|
||||||
<d:field title="Статус">s.status</d:field>
|
<d:field title="Статус">s.status</d:field>
|
||||||
<d:field title="Вероятность%">s.probability_pc</d:field>
|
<d:field title="Вер-ть %">s.probability_pc</d:field>
|
||||||
<d:field title="Ответственный">c.__name as owner</d:field>
|
<d:field title="Ответственный">c.__name as owner</d:field>
|
||||||
<d:field title="Допник">a.__name as additional_agreement</d:field>
|
<d:field title="Допник">a.__name as additional_agreement</d:field>
|
||||||
<d:field title="Допник">a.__id as additional_agreement_uid</d:field>
|
<d:field title="Допник">a.__id as additional_agreement_uid</d:field>
|
||||||
<d:field title="Договор">g.__name as contract</d:field>
|
<d:field title="Договор">g.__name as contract</d:field>
|
||||||
<d:field title="Договор">g.__id as contract_uid</d:field>
|
<d:field title="Договор">g.__id as contract_uid</d:field>
|
||||||
<d:field title="Дата дог.">g.date_of_aggrement as dt_contract</d:field>
|
<d:field title="Дата дог.">g.date_of_aggrement as dt_contract</d:field>
|
||||||
|
<!--- <d:field>(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (1)
|
||||||
|
) as install
|
||||||
|
</d:field>
|
||||||
|
<d:field>(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (2)
|
||||||
|
) as periodical
|
||||||
|
</d:field>
|
||||||
|
<d:field>(select sum(param_cost)
|
||||||
|
from component
|
||||||
|
where d.__id = ANY(component.deal_uids) AND component.type IN (3)
|
||||||
|
) as metered
|
||||||
|
</d:field> --->
|
||||||
</d:field_set>
|
</d:field_set>
|
||||||
from elma.deals d
|
from elma.deals d
|
||||||
left outer join elma.companies k on (d._companies=k.__id)
|
left outer join elma.companies k on (d._companies=k.__id)
|
||||||
@@ -52,6 +71,8 @@
|
|||||||
left outer join elma.aggrements g on (a.contract_uid = g.__id)
|
left outer join elma.aggrements g on (a.contract_uid = g.__id)
|
||||||
where 1=1 <m:filter_build filter=#pageInfo.settings.filter#/>
|
where 1=1 <m:filter_build filter=#pageInfo.settings.filter#/>
|
||||||
order by <m:order_build sortArray=#pageInfo.settings.sort.sortArray# fieldCount=#fieldCount#/>
|
order by <m:order_build sortArray=#pageInfo.settings.sort.sortArray# fieldCount=#fieldCount#/>
|
||||||
|
limit #pageInfo.recordsPerPage#
|
||||||
|
offset #pageInfo.nStart#
|
||||||
</cfquery>
|
</cfquery>
|
||||||
|
|
||||||
|
|
||||||
@@ -148,6 +169,9 @@ select count(*) as cnt from elma.deals d where 1=1
|
|||||||
<c:column width="5%" field="f_additional_agreement"><c:td class="l"/></c:column>
|
<c:column width="5%" field="f_additional_agreement"><c:td class="l"/></c:column>
|
||||||
<c:column width="5%" field="f_contract"><c:td class="l"/></c:column>
|
<c:column width="5%" field="f_contract"><c:td class="l"/></c:column>
|
||||||
<c:column width="5%" field="dt_contract" formatter=#function(dt){return dateformat(dt,"YYYY-MM-DD");}#><c:td class="c"/></c:column>
|
<c:column width="5%" field="dt_contract" formatter=#function(dt){return dateformat(dt,"YYYY-MM-DD");}#><c:td class="c"/></c:column>
|
||||||
|
<!--- <c:column width="5%" field="install" formatter=#nFmt#><c:td class="c"/></c:column>
|
||||||
|
<c:column width="5%" field="periodical" formatter=#nFmt#><c:td class="c"/></c:column>
|
||||||
|
<c:column width="5%" field="metered" formatter=#nFmt#><c:td class="c"/></c:column> --->
|
||||||
|
|
||||||
</c:table>
|
</c:table>
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -231,8 +231,8 @@
|
|||||||
,d.__index
|
,d.__index
|
||||||
,d.__status_status
|
,d.__status_status
|
||||||
,c.id_klienta as wz
|
,c.id_klienta as wz
|
||||||
, s.status
|
,s.status
|
||||||
, s.probability_pc
|
,s.probability_pc
|
||||||
from elma.deals_services siv
|
from elma.deals_services siv
|
||||||
join elma.deals d on (d.__id = ANY(siv.deal))
|
join elma.deals d on (d.__id = ANY(siv.deal))
|
||||||
left outer join elma.companies c on (d._companies=c.__id)
|
left outer join elma.companies c on (d._companies=c.__id)
|
||||||
|
|||||||
Reference in New Issue
Block a user