The reporting service is written to run reports on the j-guar system, record filters, and access filters. This service can be used to operate on the adaptation and system reports defined in j-guar.
Security
The reporting service uses j-guar user security. The username and password information of a j-guar user, which is valid and can be connected to the system (uninhibited, un-expired, etc.), must be defined in the SOAP messages sent to the Service. This service can only be used by j-guar users.
Service Access Address
To access this service, the address of the j-guar system is as follows:
http://<sunucu>:<port>/logo/services/ReportingWebService?wsdl
Example address: http://172.16.12.62:9080/logo/services/ReportingWebService?wsdl
Service Methods
All methods used in this service return a String in xml structure.
- getFilterList(RWSFilterParams filterParams, RWSBasicParams basicParams) : All system and adaptation reports defined in j-guar and the filters of the adaptations derived from these reports are the method of returning.
- saveFilter(RWSFilterParams filterParams, RWSBasicParams basicParams) :It is the method that performs the filtering operation on the database for all system and adaptation reports defined in j-guar.
- loadFilter(RWSFilterParams filterParams, RWSBasicParams basicParams) :It is the method that returns the filters defined in the database for all system and adaptation reports defined in j-guar.
- executeReport(RWSParams params, RWSBasicParams basicParams) :It is the method that runs all system and adaptation reports defined in j-guar.
- getStatus(long repID, RWSBasicParams basicParams) :For all system and adaptation reports defined in j-guar, the status of the report is the returning method.
- changeStatus(long repID, int newStatus, RWSBasicParams basicParams) :It is the method that changes the status of the report for all system and adaptation reports defined in j-guar.
Serviced Objects
RWSFilterParams
The RWSFilterParams object is used when processing the filter. Contains parameters:
- repName :The parameter is the name of the report. Ex: "MMRPItemsList".
- custName : The parameter that specifies the name of the adaptation made from the product of the report specified in the parameter repName.
- custLRef : Parameter indicating the logicalRef of the adaptation made from the product of the report specified in the parameter repName.
- filterName : The parameter is the name of the filter.
- descr : The parameter is the description of the filter.
- defaultValue : Parameter that indicates whether the filter is the default filter. If a default filter is desired, this value should be set to "1".
- filterData :The parameter to specify the content of the filter to be registered.
RWSBasicParams
The RWSBasicParams object contains the company, period and language information to be linked in j-guar. Contains parameters:
- firm : Specifies company information. It is the number of the institution to be used during the j-guar connection (login) before the operation is performed. This value should be the number of a valid institution. If it is not a valid institution number, the operation fails because j-guar connection (login) is not available.
- period : Specifies the period information. This is the number of the period to be used during j-guar connection (login) before the operation is performed. This value should be the number of a valid turn. If it is not a valid period number, the operation fails because j-guar connection (login) can not be provided.
- language : Specifies the language information: The default value is "ENUS". Example values: "TRT", "ENUS".
RWSParams
RWSParams is the object that contains the parameters of the report that you want to run. Contains parameters:
- m_ReportName : The parameter is the name of the report. Ex: "MMRPSlipList".
- m_ReportDescription :The parameter is the description of the report.
- m_CustomReportName : The parameter specifying the name of the adaptation made from the product of the report specified in the parameter m_ReportName.
- m_CustomReportLRef : The parameter indicating the logicalRef of the adaptation made from the product of the report specified in the parameter m_ReportName.
- m_OutputType : The parameter is the report output type. The output of the report is available as JRF, HTML, PDF, TXT, and XLS.
Valid values for this parameter are:
- To receive the report as JRF: 2;
- To retrieve the report as HTML: 3;
- To receive the report as PDF: 4;
- To receive the report as TXT: 5;
- To receive the report as XLS: 6.
- m_PixelPerInch : The parameter is the number of dots per nc. The default value is "96". It should be set according to the resolution of your screen. The code snippet for Java is Toolkit.getDefaultToolkit (). GetScreenResolution ()
- m_OutputOptions : The report output parameter is set to be specified. Bitwise is a working parameter. If more than one property is desired to be activated, the values of these properties must be passed through the OR operation. The default value is "4".
Valid values for this parameter are:
- Print margins: 1
- Bottom info down: 2
- Print region colors: 4
- Crop margins: 8
- m_DebugOptions :The parameter for which debugging options are specified. Bitwise is a working parameter. The default value is "14" type (Warning Messages, Error Messages, Other Messages).
Valid values for this parameter are
- Server Messages: 1
- Warning Messages: 2
- Error Messages: 4
- Other Messages: 8
- m_PageHeightInCM : Specifies the value of the page height in cm. The default value is "27.9".
- m_PrintFilters : It is a parameter that indicates whether report filters should be written to the first page before the report is written. The default value is "false".
- m_UserSettings : It is the parameter that specifies the opening template settings. The default value is "0".
Valid values for this parameter are:
- Standard Design: 0
- Default Design: 1
- Selected Design: 2
- m_FiltersValues : The parameter contains the values of the filter applied to the report. Must be sent in XML format. The content will be specified below.
- m_HiddenFilters :The implementation is a parameter that contains the id of the unwanted filters. Filters with the IDs contained here will not be considered when running the report. It is a parameter of type int [].
- m_SetValue : The value of the set variable that will be used in these tables if there is a set variable for database tables of readable objects.
- m_TextDelimeter: The value of the variable to be used in the parenthesis parameter.
Returning Methods XML Constructs
- getFilterList(RWSFilterParams filterParams, RWSBasicParams basicParams)
<?xml version="1.0" encoding="UTF-8"?>
<navi-filters>
<filter type="group-selection" caption="Malzeme (Sınıfı) Türü" id="1" />
<filter type="group-selection" caption="Malzeme (Sınıfı) Durumu" id="2" />
<filter type="string" caption="Malzeme (Sınıfı) Kodu" id="3" range="true" />
<filter type="string" caption="Malzeme (Sınıfı) Açıklaması" id="4" range="true" />
<filter type="string" caption="Malzeme (Sınıfı) Özel Kodu" id="5" range="true" />
<filter type="string" caption="Malzeme (Sınıfı) Yetki Kodu" id="8" range="true" />
<filter type="string" caption="Malzeme (Sınıfı) Grup Kodu" id="10018" range="true" />
<filter type="string" caption="Üst Malzeme Sınıfı Kodu" id="20" />
<filter type="group-selection" caption="Konfigüre Edilebilir" id="10" />
<filter type="string" caption="Birim Seti Kodu" id="22" range="true" />
<filter type="string" caption="Birim Seti Açıklaması" id="23" range="true" />
<filter type="group-selection" caption="ızleme Yöntemi" id="24" />
<filter type="group-selection" caption="Stok Yeri Takibi" id="31" />
<filter type="numeric" caption="Alış KDV Oranı (%)" id="25" />
<filter type="numeric" caption="Satış KDV Oranı (%)" id="34" />
<filter type="numeric" caption="İade KDV Oranı (%)" id="35" />
<filter type="group-selection" caption="Kullanım Yeri" id="36" />
<filter type="string" caption="Org. Birimler" id="33" range="true" />
<filter type="string" caption="OrgBirimGrupKodu" id="9" />
<filter type="list-selection" caption="Ambar_Bilgisi_Detayları" id="28" />
<filter type="string" caption="Ambar Kodu" id="29" range="true" />
<filter type="list-selection" caption="Takım_Bilesenleri" id="30" />
</navi-filters>
- loadFilter(RWSFilterParams filterParams, RWSBasicParams basicParams)
<?xml version="1.0" encoding="UTF-8"?>
<navi-filters>
<filter type="group-selection" caption="Malzeme (Sınıfı) Türü" id="1" value="4|10|" />
<filter type="string" caption="Malzeme (Sınıfı) Kodu" id="3" range="true" value="KOD1" />
<filter type="string" caption="Malzeme (Sınıfı) Açıklaması" id="4" range="true" value="DESC1|DESC1" />
<filter type="list-selection" caption="Ambar_Bilgisi_Detayları" id="28" value="1" />
<filter type="list-selection" caption="Takım_Bilesenleri" id="30" value="0" />
</navi-filters>
- executeReport(RWSParams params, RWSBasicParams basicParams)
<?xml version="1.0" encoding="UTF-8"?>
<report id="361" url="http://172.16.12.62:9080/UnityWebTier/ServerReports/mmrpitemslist_admin_19700101_020000.jrd />
- getStatus(long repID, RWSBasicParams basicParams)
<?xml version="1.0" encoding="UTF-8"?>
<report id="361" status="2" />
REPORT_IN_QUEUE = -1;
REPORT_IN_PROGRESS = 0;
REPORT_COMPLETED = 1;
REPORT_ABORTED = 2;
REPORT_IN_ARCHIVE_REQUEST = 3;
REPORT_IN_ARCHIVE_PROGRESS = 4
Parametrelere Verilecek XML Tanımları
- saveFilter(RWSFilterParams filterParams, RWSBasicParams basicParams) "RWSFilterParams" The "filterData" parameter of the object must be in the following XML structure.
<?xmlversion=\"1.0\" encoding=\"UTF-8\"?>
<navi-filters>
<filter type="1"id=\"1\" value=\"0|1|\" />
<filter type="2"id=\"4\" value=\"123\" />
<filter type="6"id=\"7\" value=\"2009-11-24 00:00:00|2009-12-06 23:59:59\"/>
<filter type="9"id=\"9\" value=\"5|9|12|20|\" />
<filter type="10"id=\"10\" value=\"1\" />
<filter type="10"id=\"11\" value=\"1|\" />
<filter type="2"id=\"66\" value=\"12\" />
</navi-filters>
Here are the values of the filter types as follows:
STRING_FILTER = 1
STRING_RANGE_FILTER = 2
NUMERIC_FILTER = 3
NUMERIC_RANGE_FILTER = 4
DATE_FILTER = 5
DATE_RANGE_FILTER = 6
TIME_FILTER = 7
TIME_RANGE_FILTER = 8
GROUPSEL_FILTER = 9
LISTSEL_FILTER = 10
- executeReport(RWSParams params, RWSBasicParams basicParams) "RWSParams " The object's "m_FiltersValues" parameter is the same as the "filterData" parameter of the "RWSFilterParams" object.
A structure.
String Returning Methods That Work Successfully
<?xml version="1.0" encoding="UTF-8"?>
<error message="Successful" id="100" />
Error Messages
Applies to all methods. If any parameter is invalid or an unexpected error occurs while processing, the methods return error messages with the following structure.
<?xml version="1.0" encoding="UTF-8"?>
<error message="Invalid Report Status" id="1016" />
Hata Mesajları Anlamları
id = 1000 - > It is a message containing errors from j-guar.
id = 1001 - > Occurs when the RWSParams object is null.
id = 1002 - > Occurs when the RWSFilterParams object is null
id = 1003 - > Occurs when the RWSBasicParams object is null.
id = 1004 - > Occurs when the report name is not specified.
id = 1005 - > Occurs when Company or Period information is not valid.
id = 1006 - > Occurs when the filter list is not found according to the given information.
id = 1007 - > Occurs when the adaptation filter is not found according to the given information. There is a point to note here. If "custName" is specified but "custLRef" is not specified, the filter database called "custName" is searched. If not, this error message is generated. The "custName" variable is not checked in any case where "custLRef" is specified.
id = 1008 - > Occurs when the requested filter is not found in the "loadFilter" method.
id = 1011 - > Occurs when an invalid value is set in the "m_OutputOptions" parameter in the object "RWSParams".
id = 1013 - > Occurs when a report with the repID specified in the "changeStatus" and "getStatus" methods is not found.
id = 1014 - > Occurs when the "oldStatus" specified in the "changeStatus" method is the same as the previous status of the report.
id = 1015 - > Occurs when the repID specified in the "changeStatus" and "getStatus" methods is invalid.
id = 1016 - > Occurs when the "newStatus" parameter specified in the "changeStatus" method is invalid.
Valid parameters for status:
STATUS_INVALID = -1 ,
STATUS_COMPLETED = 2 ,
STATUS_CANCELLED = 3 ,
id = 1017 - > Occurs if the filterName given in the "loadFilter" and "saveFilter" methods is invalid.
id = 1018 - > Occurs when the FilterData given in the "saveFilter" method is invalid.