protected MAsset(MIFixedAsset ifa){
  this(ifa.getCtx(),0,ifa.get_TrxName());
  setAD_Org_ID(ifa.getAD_Org_ID());
  setIsOwned(true);
  setIsInPosession(true);
  String inventoryNo=ifa.getInventoryNo();
  if (inventoryNo != null) {
    inventoryNo=inventoryNo.trim();
    setInventoryNo(inventoryNo);
    setValue(inventoryNo);
  }
  setA_Asset_CreateDate(ifa.getAssetServiceDate());
  MProduct product=ifa.getProduct();
  if (product != null) {
    setM_Product_ID(product.getM_Product_ID());
    setA_Asset_Group_ID(ifa.getA_Asset_Group_ID());
    MAttributeSetInstance asi=MAttributeSetInstance.create(getCtx(),product,get_TrxName());
    setM_AttributeSetInstance_ID(asi.getM_AttributeSetInstance_ID());
  }
  setDateAcct(ifa.getDateAcct());
  setName(ifa.getName());
  setDescription(ifa.getDescription());
}

protected MAsset ( MIFixedAsset ifa ) { this ( ifa . getCtx ( ) , 0 , ifa . get_TrxName ( ) ) ; setAD_Org_ID ( ifa . getAD_Org_ID ( ) ) ; setIsOwned ( true ) ; setIsInPosession ( true ) ; String inventoryNo = ifa . getInventoryNo ( ) ; if ( inventoryNo != null ) { inventoryNo = inventoryNo . trim ( ) ; setInventoryNo ( inventoryNo ) ; setValue ( inventoryNo ) ; } setA_Asset_CreateDate ( ifa . getAssetServiceDate ( ) ) ; MProduct product = ifa . getProduct ( ) ; if ( product != null ) { setM_Product_ID ( product . getM_Product_ID ( ) ) ; setA_Asset_Group_ID ( ifa . getA_Asset_Group_ID ( ) ) ; MAttributeSetInstance asi = MAttributeSetInstance . create ( getCtx ( ) , product , get_TrxName ( ) ) ; setM_AttributeSetInstance_ID ( asi . getM_AttributeSetInstance_ID ( ) ) ; } setDateAcct ( ifa . getDateAcct ( ) ) ; setName ( ifa . getName ( ) ) ; setDescription ( ifa . getDescription ( ) ) ; }
construct from mifixedasset ( import )
