Table of Contents

Class StBiz

Namespace
PHCBusinessLayer
Assembly
PHCBusinessLayer.dll
public class StBiz : BizObjectOfType<StVO>, IPnp, ISDKBiz, ISDKBaseBiz, ISDKContextAwareness, ITypedWS<StVO>
Inheritance
StBiz

Constructors

StBiz()

public StBiz()

StBiz(ContextVO)

public StBiz(ContextVO contextItem)

Parameters

Nome Tipo Descrição
contextItem ContextVO

Properties

entityDataManager

public StDataManager entityDataManager { get; }

Property Value

StDataManager

LotDtManager

public LotDataManager LotDtManager { get; }

Property Value

LotDataManager

SaDtManager

public SaDataManager SaDtManager { get; }

Property Value

SaDataManager

SalotDtManager

public SalotDataManager SalotDtManager { get; }

Property Value

SalotDataManager

flBizManager

public FlBiz flBizManager { get; }

Property Value

FlBiz

flDtManager

public FlDataManager flDtManager { get; }

Property Value

FlDataManager

slDtManager

public SlDataManager slDtManager { get; }

Property Value

SlDataManager

stfamiDtManager

public StfamiDataManager stfamiDtManager { get; }

Property Value

StfamiDataManager

stflDtManager

public StFlDataManager stflDtManager { get; }

Property Value

StFlDataManager

Methods

AfterSave(StVO)

public override List<MessageVO> AfterSave(StVO itemVO)

Parameters

Nome Tipo Descrição
itemVO StVO

Returns

List<MessageVO>

AvailableStock(string, int, string)

public decimal AvailableStock(string referencia, int armazem, string lote)

Parameters

Nome Tipo Descrição
referencia string
armazem int
lote string

Returns

decimal

CreateNewInstanceFromTypeWithSL<sourceTy>(GenericVO, List<GenericVO>)

public PHCResult CreateNewInstanceFromTypeWithSL<sourceTy>(GenericVO sourceEntity, List<GenericVO> sourceEntityList)

Parameters

Nome Tipo Descrição
sourceEntity GenericVO
sourceEntityList List<GenericVO>

Returns

PHCResult

Type Parameters

sourceTy

CreateNewInstanceFromType<sourceTy>(GenericVO)

public PHCResult CreateNewInstanceFromType<sourceTy>(GenericVO sourceEntity)

Parameters

Nome Tipo Descrição
sourceEntity GenericVO

Returns

PHCResult

Type Parameters

sourceTy

FeatureAvailable(StVO)

public override List<MessageVO> FeatureAvailable(StVO itemVO)

Parameters

Nome Tipo Descrição
itemVO StVO

Returns

List<MessageVO>

GetDataManager()

public override BizDataManagerOfType<StVO> GetDataManager()

Returns

BizDataManagerOfType<StVO>

GetQttRecCommand(string, int, bool, string)

We use this function to get the value of an article from receipt of goods (with the Ts.isToUseQttrec = true we can create an Bo for receipt of goods and with this we can create an invoice for a article even when we dont have stock)

public PHCCmdSql GetQttRecCommand(string @ref, int armazem, bool isLotes, string lot)

Parameters

Nome Tipo Descrição
ref string
armazem int
isLotes bool
lot string

Returns

PHCCmdSql

GetUpdTriggers(StVO)

public void GetUpdTriggers(StVO itemSt)

Parameters

Nome Tipo Descrição
itemSt StVO

MustValidateStock()

public static bool MustValidateStock()

Returns

bool

OnActionAvailable(ActionVO, ActionFilterVO, StVO)

protected override bool OnActionAvailable(ActionVO actionItem, ActionFilterVO filter, StVO recordItem)

Parameters

Nome Tipo Descrição
actionItem ActionVO
filter ActionFilterVO
recordItem StVO

Returns

bool

OnAdding(StVO, bool)

public override List<MessageVO> OnAdding(StVO itemVO, bool duplicating)

Parameters

Nome Tipo Descrição
itemVO StVO
duplicating bool

Returns

List<MessageVO>

OnDelete(StVO, bool)

public override List<MessageVO> OnDelete(StVO itemSt, bool runWarningRules)

Parameters

Nome Tipo Descrição
itemSt StVO
runWarningRules bool

Returns

List<MessageVO>

OnExecuteAction(ActionVO, ActionFilterVO, StVO)

protected override PHCResult OnExecuteAction(ActionVO actionItem, ActionFilterVO filter, StVO recordItem)

Parameters

Nome Tipo Descrição
actionItem ActionVO
filter ActionFilterVO
recordItem StVO

Returns

PHCResult

OnGetActions()

protected override List<ActionVO> OnGetActions()

Returns

List<ActionVO>

OnSave(StVO, bool)

public override List<MessageVO> OnSave(StVO itemVO, bool runWarningRules)

Parameters

Nome Tipo Descrição
itemVO StVO
runWarningRules bool

Returns

List<MessageVO>

OnSaveError(List<MessageVO>)

public override void OnSaveError(List<MessageVO> mensagens)

Parameters

Nome Tipo Descrição
mensagens List<MessageVO>

OnValidEditLoopFields(ref Dictionary<string, FieldStructure>, PHCCmdSql)

Valid fieldCollection list

protected override List<MessageVO> OnValidEditLoopFields(ref Dictionary<string, FieldStructure> fieldCollection, PHCCmdSql tsql)

Parameters

Nome Tipo Descrição
fieldCollection Dictionary<string, FieldStructure>

Is a ignore case dictionary to facilitate the manipulation of this list

tsql PHCCmdSql

Returns

List<MessageVO>

SyncOnChange(StVO, List<EntityChangeOperation>)

public override List<MessageVO> SyncOnChange(StVO masterVO, List<EntityChangeOperation> changedItems)

Parameters

Nome Tipo Descrição
masterVO StVO
changedItems List<EntityChangeOperation>

Returns

List<MessageVO>

UpdateRef(ScVO)

public List<MessageVO> UpdateRef(ScVO itemSC)

Parameters

Nome Tipo Descrição
itemSC ScVO

Returns

List<MessageVO>

UseLot()

public static bool UseLot()

Returns

bool

UseSerialNumber()

public static bool UseSerialNumber()

Returns

bool

actualizarDadosFlVO(StVO)

public List<MessageVO> actualizarDadosFlVO(StVO itemSt)

Parameters

Nome Tipo Descrição
itemSt StVO

Returns

List<MessageVO>

actualizarDadosStcbVO(StVO)

public void actualizarDadosStcbVO(StVO itemSt)

Parameters

Nome Tipo Descrição
itemSt StVO

addDataTable(DataTable, ref List<ValorVO>, bool)

public PHCResult addDataTable(DataTable mData, ref List<Utilitarios.ValorVO> msgResult, bool @virtual)

Parameters

Nome Tipo Descrição
mData DataTable
msgResult List<Utilitarios.ValorVO>
virtual bool

Returns

PHCResult

existStUsingSerialnumber()

public bool existStUsingSerialnumber()

Returns

bool

getPrecoCustoParaVendas(string, string, DateTime, string, CostPriceTypes, bool)

public decimal getPrecoCustoParaVendas(string reference, string lote, DateTime data, string time, CostPriceTypes tipoCusto, bool stnsTabelPrice = false)

Parameters

Nome Tipo Descrição
reference string
lote string
data DateTime
time string
tipoCusto CostPriceTypes
stnsTabelPrice bool

Returns

decimal

getPrecoVenda(StVO, SalePriceEnum)

public StBiz.PrecoVendaInfo getPrecoVenda(StVO itemSt, SalePriceEnum tipoPreco)

Parameters

Nome Tipo Descrição
itemSt StVO
tipoPreco SalePriceEnum

Returns

StBiz.PrecoVendaInfo

getRefForPOS(string)

public PHCResult getRefForPOS(string @ref)

Parameters

Nome Tipo Descrição
ref string

Returns

PHCResult

getRefList(QueryVO)

public PHCResult getRefList(QueryVO query)

Parameters

Nome Tipo Descrição
query QueryVO

Returns

PHCResult

getStocksFromStores(string)

public PHCResult getStocksFromStores(string @ref)

Parameters

Nome Tipo Descrição
ref string

Returns

PHCResult

getTriggers(StVO)

public override void getTriggers(StVO itemVO)

Parameters

Nome Tipo Descrição
itemVO StVO

usaCompostos()

public static bool usaCompostos()

Returns

bool

validaErrors(StVO)

public List<MessageVO> validaErrors(StVO itemSt)

Parameters

Nome Tipo Descrição
itemSt StVO

Returns

List<MessageVO>

validaReferencia(string, string)

public StVO validaReferencia(string value, string flStamp = "")

Parameters

Nome Tipo Descrição
value string
flStamp string

Returns

StVO

validaWarnings(StVO)

public List<MessageVO> validaWarnings(StVO itemSt)

Parameters

Nome Tipo Descrição
itemSt StVO

Returns

List<MessageVO>

validateRefBySupplier(string, string)

public StVO validateRefBySupplier(string flstamp, string value)

Parameters

Nome Tipo Descrição
flstamp string
value string

Returns

StVO