public void executePrivate(int startRow, int maxRows) { this.cmSP_LISTA_IZNOSA_RADNIKASelect2 = this.connDefault.GetCommand("S_PLACA_IZNOSI_PO_ZAPOSLENIKU", true); this.cmSP_LISTA_IZNOSA_RADNIKASelect2.IDbCommand.CommandType = CommandType.StoredProcedure; this.cmSP_LISTA_IZNOSA_RADNIKASelect2.IDbCommand.Parameters.Clear(); this.cmSP_LISTA_IZNOSA_RADNIKASelect2.IDbCommand.Parameters.Add(this.dsDefault.GetDbParameter("@IDOBRACUN", this.AV8IDOBRAC)); this.cmSP_LISTA_IZNOSA_RADNIKASelect2.IDbCommand.Parameters.Add(this.dsDefault.GetDbParameter("@MJESECOBRACUNA", this.AV9MJESECO)); this.cmSP_LISTA_IZNOSA_RADNIKASelect2.IDbCommand.Parameters.Add(this.dsDefault.GetDbParameter("@GODINAOBRACUNA", this.AV10GODINA)); this.cmSP_LISTA_IZNOSA_RADNIKASelect2.IDbCommand.Parameters.Add(this.dsDefault.GetDbParameter("@SORT", this.AV11SORT)); this.cmSP_LISTA_IZNOSA_RADNIKASelect2.ErrorMask |= ErrorMask.Lock; this.SP_LISTA_IZNOSA_RADNIKASelect2 = this.cmSP_LISTA_IZNOSA_RADNIKASelect2.FetchData(); while (this.cmSP_LISTA_IZNOSA_RADNIKASelect2.HasMoreRows && (startRow > 0)) { startRow--; this.cmSP_LISTA_IZNOSA_RADNIKASelect2.HasMoreRows = this.SP_LISTA_IZNOSA_RADNIKASelect2.Read(); } int num = 0; while (this.cmSP_LISTA_IZNOSA_RADNIKASelect2.HasMoreRows && (num != maxRows)) { this.rowSP_LISTA_IZNOSA_RADNIKA["IDRADNIK"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["IDRADNIK"]); this.rowSP_LISTA_IZNOSA_RADNIKA["PREZIME"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["PREZIME"]); this.rowSP_LISTA_IZNOSA_RADNIKA["IME"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["IME"]); this.rowSP_LISTA_IZNOSA_RADNIKA["satibruto"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["SATIBRUTO"]); this.rowSP_LISTA_IZNOSA_RADNIKA["ukupnobruto"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["UKUPNOBRUTO"]); this.rowSP_LISTA_IZNOSA_RADNIKA["KOEFICIJENT"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["KOEFICIJENT"]); this.rowSP_LISTA_IZNOSA_RADNIKA["ukupnodoprinosi"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["UKUPNODOPRINOSI"]); this.rowSP_LISTA_IZNOSA_RADNIKA["ukupnoporeziprirez"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["ukupnoporeziprirez"]); this.rowSP_LISTA_IZNOSA_RADNIKA["netoplaca"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["NETOPLACA"]); this.rowSP_LISTA_IZNOSA_RADNIKA["ukupnonetonaknade"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["UKUPNONETONAKNADE"]); this.rowSP_LISTA_IZNOSA_RADNIKA["netoprimanja"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["NETOPRIMANJA"]); this.rowSP_LISTA_IZNOSA_RADNIKA["ukupnoobustave"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["UKUPNOOBUSTAVE"]); this.rowSP_LISTA_IZNOSA_RADNIKA["UKUPNOZAISPLATU"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["UKUPNOZAISPLATU"]); this.rowSP_LISTA_IZNOSA_RADNIKA["ukupnoolaksice"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["UKUPNOOLAKSICE"]); this.rowSP_LISTA_IZNOSA_RADNIKA["UKUPNODOPRINOSINA"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["UKUPNODOPRINOSINA"]); this.rowSP_LISTA_IZNOSA_RADNIKA["POREZKRIZNI"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["porezkrizni"]); this.rowSP_LISTA_IZNOSA_RADNIKA["netoplacamanjekrizni"] = RuntimeHelpers.GetObjectValue(this.SP_LISTA_IZNOSA_RADNIKASelect2["netoplacamanjekrizni"]); this.AddRowSp_lista_iznosa_radnika(); num++; this.rowSP_LISTA_IZNOSA_RADNIKA = this.SP_LISTA_IZNOSA_RADNIKASet.SP_LISTA_IZNOSA_RADNIKA.NewSP_LISTA_IZNOSA_RADNIKARow(); this.cmSP_LISTA_IZNOSA_RADNIKASelect2.HasMoreRows = this.SP_LISTA_IZNOSA_RADNIKASelect2.Read(); } this.SP_LISTA_IZNOSA_RADNIKASelect2.Close(); this.Cleanup(); }
public virtual int FillPage(SP_LISTA_IZNOSA_RADNIKADataSet dataSet, string iDOBRACUN, string mJESECOBRACUNA, string gODINAOBRACUNA, int sORT, int startRow, int maxRows) { this.Initialize(); this.connDefault = this.dsDefault.GetReadWriteConnection(this.daCurrentTransaction); this.SP_LISTA_IZNOSA_RADNIKASet = dataSet; this.rowSP_LISTA_IZNOSA_RADNIKA = this.SP_LISTA_IZNOSA_RADNIKASet.SP_LISTA_IZNOSA_RADNIKA.NewSP_LISTA_IZNOSA_RADNIKARow(); this.SetFillParameters(iDOBRACUN, mJESECOBRACUNA, gODINAOBRACUNA, sORT); this.AV8IDOBRAC = iDOBRACUN; this.AV9MJESECO = mJESECOBRACUNA; this.AV10GODINA = gODINAOBRACUNA; this.AV11SORT = sORT; try { this.executePrivate(startRow, maxRows); } finally { this.Cleanup(); } return(0); }