Commit 9b6d3a25 authored by ppatro's avatar ppatro

Issue tracker point no 13


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@92270 ce508802-f39f-4f6c-b175-0d175dae99d5
parent b6fac49a
......@@ -2937,19 +2937,20 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC
" FROM REPL_ORD_DET R,REPL_ORD_HDR H,WAVE_TASK_DET W,LOCATION L,WAVE_TASK WH" +
" WHERE W.WAVE_ID = WH.WAVE_ID AND R.REPL_ORDER = H.REPL_ORDER AND" +
" R.REPL_ORDER = W.REF_ID AND W.STATUS = 'N' AND H.ORDER_TYPE NOT IN ('E','Q') " +
" AND FN_VALID_REPL(H.REPL_ORDER) = 'Y' AND R.LOC_CODE = L.LOC_CODE AND L.INV_STAT = ?) ORDER BY LOC_CODE";
" AND FN_VALID_REPL(H.REPL_ORDER) = 'Y' AND R.LOC_CODE = L.LOC_CODE AND L.INV_STAT = ? AND FN_CHECK_REPL_ORD_USER(H.REPL_ORDER,?) = 1) ORDER BY LOC_CODE";
}
else if("active_repl_iss".equalsIgnoreCase(objNameChk))
{
sql = " SELECT REPL_ORDER,LOC_CODE FROM (SELECT DISTINCT R.REPL_ORDER ,L.LOC_CODE FROM REPL_ORD_DET R,REPL_ORD_HDR H," +
" WAVE_TASK_DET W,LOCATION L ,WAVE_TASK WH WHERE W.WAVE_ID = WH.WAVE_ID AND R.REPL_ORDER = H.REPL_ORDER " +
" AND R.REPL_ORDER = W.REF_ID AND W.STATUS = 'N' AND H.ORDER_TYPE IN ('E','Q','T') " +
" AND FN_VALID_REPL(H.REPL_ORDER) = 'Y' AND R.LOC_CODE = L.LOC_CODE AND L.INV_STAT = ?) ORDER BY LOC_CODE ";
" AND FN_VALID_REPL(H.REPL_ORDER) = 'Y' AND R.LOC_CODE = L.LOC_CODE AND L.INV_STAT = ? AND FN_CHECK_REPL_ORD_USER(H.REPL_ORDER,?) = 1) ORDER BY LOC_CODE ";
}
System.out.println("CURRENT SQL["+sql+"]");
pstmt = conn.prepareStatement( sql );
pstmt.setString( 1, replOrderChkInv );
pstmt.setString( 2, loginCode );
rs = pstmt.executeQuery();
if( rs.next() )
{
......@@ -2970,7 +2971,7 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC
System.out.println("RETURNING MESSAGES AND REMOVE THE KEY FOR THAT USER["+loginCode+"]");
USER_DEFINED_VALUE_MAP.remove(loginCode);
//Changed By Pragyan To send the Fatal Error.
//return itmDBAccessEJB.getErrorString("","RECONEXIST","","",conn);
return itmDBAccessEJB.getErrorString("","RECONEXIST","","",conn);
}
valueXmlString.append( "<repl_order><![CDATA[" ).append( checkNull( replOrderChk )).append( "]]></repl_order>\r\n" );
}
......@@ -2989,6 +2990,7 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC
siteDescr = rs.getString("DESCR");
}
valueXmlString.append( "<descr><![CDATA[" ).append( checkNull( siteDescr )).append( "]]></descr>\r\n" );
valueXmlString.append( "<chg_user><![CDATA[" ).append( checkNull( loginCode )).append( "]]></chg_user>\r\n" );
valueXmlString.append( "<site_code><![CDATA[" ).append( checkNull( siteCode )).append( "]]></site_code>\r\n" );
if(rs != null )
{
......
......@@ -39,7 +39,7 @@
<color>536870912</color>
</Footer>
<Detail>
<height>40</height>
<height>38</height>
<color>536870912</color>
</Detail>
<TableDefinition>
......@@ -49,7 +49,19 @@
<name>repl_order</name>
<dbname>repl_iss_hdr.repl_order</dbname>
</table_column>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;repl_iss_hdr&quot; ) COLUMN(NAME=&quot;repl_iss_hdr.repl_order&quot;)) </retrieve>
<table_column>
<type size="10">char</type>
<updatewhereclause>yes</updatewhereclause>
<name>emp_code__aprv</name>
<dbname>repl_iss_hdr.emp_code__aprv</dbname>
</table_column>
<table_column>
<type size="10">char</type>
<updatewhereclause>yes</updatewhereclause>
<name>chg_user</name>
<dbname>repl_iss_hdr.chg_user</dbname>
</table_column>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;repl_iss_hdr&quot; ) COLUMN(NAME=&quot;repl_iss_hdr.repl_order&quot;) COLUMN(NAME=&quot;repl_iss_hdr.emp_code__aprv&quot;) COLUMN(NAME=&quot;repl_iss_hdr.chg_user&quot;)) </retrieve>
</TableDefinition>
<TextObject>
<band>Detail</band>
......@@ -118,6 +130,64 @@
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>2</id>
<alignment>0</alignment>
<tabsequence>32766</tabsequence>
<border>0</border>
<color>33554432</color>
<x>225</x>
<y>1</y>
<height>16</height>
<width>176</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>emp_code__aprv</name>
<visible>0</visible>
<font>
<face>Times</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>3</id>
<alignment>0</alignment>
<tabsequence>32766</tabsequence>
<border>0</border>
<color>33554432</color>
<x>402</x>
<y>1</y>
<height>16</height>
<width>50</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_user</name>
<visible>0</visible>
<font>
<face>Times</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<HtmlTable>
<border>1</border>
</HtmlTable>
......
......@@ -39,7 +39,7 @@
<color>536870912</color>
</Footer>
<Detail>
<height>40</height>
<height>38</height>
<color>536870912</color>
</Detail>
<TableDefinition>
......@@ -49,7 +49,19 @@
<name>repl_order</name>
<dbname>repl_iss_hdr.repl_order</dbname>
</table_column>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;repl_iss_hdr&quot; ) COLUMN(NAME=&quot;repl_iss_hdr.repl_order&quot;)) </retrieve>
<table_column>
<type size="10">char</type>
<updatewhereclause>yes</updatewhereclause>
<name>emp_code__aprv</name>
<dbname>repl_iss_hdr.emp_code__aprv</dbname>
</table_column>
<table_column>
<type size="10">char</type>
<updatewhereclause>yes</updatewhereclause>
<name>chg_user</name>
<dbname>repl_iss_hdr.chg_user</dbname>
</table_column>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;repl_iss_hdr&quot; ) COLUMN(NAME=&quot;repl_iss_hdr.repl_order&quot;) COLUMN(NAME=&quot;repl_iss_hdr.emp_code__aprv&quot;) COLUMN(NAME=&quot;repl_iss_hdr.chg_user&quot;)) </retrieve>
</TableDefinition>
<TextObject>
<band>Detail</band>
......@@ -118,6 +130,64 @@
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>2</id>
<alignment>0</alignment>
<tabsequence>32766</tabsequence>
<border>0</border>
<color>33554432</color>
<x>225</x>
<y>1</y>
<height>16</height>
<width>176</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>emp_code__aprv</name>
<visible>0</visible>
<font>
<face>Times</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>3</id>
<alignment>0</alignment>
<tabsequence>32766</tabsequence>
<border>0</border>
<color>33554432</color>
<x>402</x>
<y>1</y>
<height>16</height>
<width>50</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_user</name>
<visible>0</visible>
<font>
<face>Times</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<HtmlTable>
<border>1</border>
</HtmlTable>
......
......@@ -36469,5 +36469,44 @@ INSERT INTO MESSAGES (
commit;
------ 04-12-12
CREATE OR REPLACE FUNCTION FN_CHECK_REPL_ORD_USER(REPL_ORDER_IN IN CHAR, USER_IN IN CHAR)
RETURN NUMBER is FLAG NUMBER;
CNT NUMBER;
CNT1 NUMBER;
CNT2 NUMBER;
BEGIN
BEGIN
SELECT count(*) INTO CNT FROM REPL_ISS_HDR WHERE REPL_ORDER = REPL_ORDER_IN AND CHG_USER = USER_IN;
IF( CNT > 0) THEN
select count(*) into CNT1 from WAVE_TASK_DET where REF_ID = REPL_ORDER_IN AND STATUS <>'Y';
if( CNT1 > 0) THEN
FLAG := 1;
ELSE
FLAG := 0;
END IF ;
ELSE
SELECT count(*) INTO CNT2 FROM REPL_ISS_HDR WHERE REPL_ORDER = REPL_ORDER_IN AND CONFIRMED ='N';
IF( CNT2 > 0) THEN
FLAG := 0;
ELSE
FLAG := 1;
END IF ;
END IF;
EXCEPTION
WHEN NO_DATA_FOUND THEN
FLAG := 2;
END;
RETURN FLAG;
END;
/
UPDATE POPHELP
SET SQL_INPUT=':1.repl_order,:1.chg_user' ,SQL_STR = 'SELECT REPL_ORDER,LOC_CODE FROM (SELECT DISTINCT R.REPL_ORDER ,L.LOC_CODE FROM REPL_ORD_DET R,REPL_ORD_HDR H,WAVE_TASK_DET W,LOCATION L ,WAVE_TASK WH WHERE W.WAVE_ID = WH.WAVE_ID AND R.REPL_ORDER = H.REPL_ORDER AND R.REPL_ORDER = W.REF_ID AND W.STATUS = ''N'' AND H.ORDER_TYPE NOT IN (''E'',''Q'') AND FN_VALID_REPL (H.REPL_ORDER) = ''Y'' AND R.LOC_CODE = L.LOC_CODE AND L.INV_STAT = ''?'' AND FN_CHECK_REPL_ORD_USER(H.REPL_ORDER,''?'') = 1) ORDER BY LOC_CODE'
WHERE MOD_NAME = 'W_REPL_ISS' AND FIELD_NAME = 'REPL_ORDER';
UPDATE POPHELP
SET SQL_INPUT=':1.repl_order,:1.chg_user' ,SQL_STR = 'SELECT REPL_ORDER,LOC_CODE FROM (SELECT DISTINCT R.REPL_ORDER ,L.LOC_CODE FROM REPL_ORD_DET R,REPL_ORD_HDR H,WAVE_TASK_DET W,LOCATION L ,WAVE_TASK WH WHERE W.WAVE_ID = WH.WAVE_ID AND R.REPL_ORDER = H.REPL_ORDER AND R.REPL_ORDER = W.REF_ID AND W.STATUS = ''N'' AND H.ORDER_TYPE IN (''E'',''Q'',''T'') AND FN_VALID_REPL (H.REPL_ORDER) = ''Y'' AND R.LOC_CODE = L.LOC_CODE AND L.INV_STAT = ''?'' AND FN_CHECK_REPL_ORD_USER(H.REPL_ORDER,''?'') = 1) ORDER BY LOC_CODE'
WHERE MOD_NAME = 'W_ACTIVE_REPL_ISS' AND FIELD_NAME = 'REPL_ORDER';
COMMIT;
......@@ -7,7 +7,7 @@ detail(height=40 color="536870912" )
table(column=(type=char(10) updatewhereclause=yes name=repl_order dbname="repl_iss_hdr.repl_order" )
retrieve="PBSELECT( VERSION(400) TABLE(NAME=~"repl_iss_hdr~" ) COLUMN(NAME=~"repl_iss_hdr.repl_order~")) " )
text(band=detail alignment="1" text="Replenishment Order:" border="0" color="33554432" x="0" y="1" height="15" width="131" html.valueishtml="0" name=repl_order_t visible="1" font.face="Times" font.height="-10" font.weight="400" font.family="0" font.pitch="2" font.charset="0" background.mode="1" background.color="536870912" )
column(band=detail id=1 alignment="0" tabsequence=10 border="5" color="33554432" x="136" y="1" height="16" width="88" format="[general]" html.valueishtml="0" name=repl_order tag="Replenishment oder ID" visible="1" edit.limit=10 edit.case=any edit.focusrectangle=no edit.autoselect=yes edit.autohscroll=yes edit.imemode=0 font.face="Times" font.height="-10" font.weight="400" font.family="2" font.pitch="2" font.charset="0" background.mode="2" background.color="16777215" )
column(band=detail id=1 alignment="0" tabsequence=32766 border="5" color="33554432" x="136" y="1" height="16" width="88" format="[general]" html.valueishtml="0" name=repl_order tag="Replenishment oder ID" visible="1" edit.limit=10 edit.case=any edit.focusrectangle=no edit.autoselect=yes edit.autohscroll=yes edit.imemode=0 font.face="Times" font.height="-10" font.weight="400" font.family="2" font.pitch="2" font.charset="0" background.mode="2" background.color="16777215" )
htmltable(border="1" )
htmlgen(clientevents="1" clientvalidation="1" clientcomputedfields="1" clientformatting="0" clientscriptable="0" generatejavascript="1" encodeselflinkargs="1" netscapelayers="0" )
export.xml(headgroups="1" includewhitespace="0" metadatatype=0 savemetadata=0 )
......
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