問題: Item ITM-xxxxxx is on hold for transactions.
解決方法: On you item, click the "default order settings, click sales order, check the whether the stopped tick is on.
問題: Item ITM-xxxxxx is on hold for transactions.
解決方法: On you item, click the "default order settings, click sales order, check the whether the stopped tick is on.
public static class MyTableEventHandler_XppPrePostArgs
{
const static str myFieldHasChangedArgName = 'myFieldHasChanged';
[PreHandlerFor(tableStr(MyTable), tableMethodStr(MyTable, update))]
public static void MyTable_Pre_update(XppPrePostArgs _args)
{
MyTable myTable = _args.getThis() as MyTable;
boolean myFieldHasChanged = myTable.MyField != myTable.orig().MyField;
<strong>_args.addArg(MyTableEventHandler_XppPrePostArgs::myFieldHasChangedArgName, myFieldHasChanged);</strong>
}
[PostHandlerFor(tableStr(MyTable), tableMethodStr(MyTable, update))]
public static void MyTable_Post_update(XppPrePostArgs _args)
{
MyTable myTable = _args.getThis() as MyTable;
<strong>boolean myFieldHasChanged = _args.getArg(MyTableEventHandler_XppPrePostArgs::myFieldHasChangedArgName);
</strong>
if (myFieldHasChanged)
{
myTable.doStuff();
}
}
}
public void createSalesLine()
{
public void setFinancialDimension()
{
public void exportCSV(str _filename)
{
str name;
Array Arr = new Array (Types::String);
int i= 1, j;
Int test;
TestTable TestTable;
;
// Create an Str array
// Write some elements in it
while select TestTable
{
Arr.value(i, TestTable.TestTables);//(i, i*2);
i++;
}
j = i;
for (i = 1; i<j; i++)
{
test= Arr.value(i);
while select TestTable where TestTable.TestTables == test
{
info(strfmt("%1", Arr.value(i)));
}
}
Return order:
Return order is the process in which customers return items that they have purchased.
Example:
Customer might return items if it is defective or if it was received incorrectly. You need to create a return order in ax before receiving items back from the customer.
Steps to create Return order in AX 2012:
1. First step is to find invoiced sales order against which return order is getting created.
.
/// <summary> | |
/// Hooks on Initialized event of the <c>EcoResProductVariantFlavorDisplayOrderView</c> form data source and adjusts data source query. | |
/// </summary> | |
/// <param name = "_sender">The data source object that triggers the event.</param> | |
/// <param name = "_e">Event arguments.</param> | |
[FormDataSourceEventHandler(formDataSourceStr(EcoResProductVariants, EcoResProductVariantFlavorDisplayOrderView), FormDataSourceEventType::Initialized)] | |
public void ecoResProductVariantFlavorDisplayOrderView_ValidatingWrite(FormDataSource _sender, FormDataSourceEventArgs _e) | |
{ | |
if (isConfigurationkeyEnabled(configurationKeyNum(Retail))) | |
{ | |
_sender.queryBuildDataSource().addLink(fieldNum(EcoResProductVariantFlavor, DistinctProductVariant), fieldNum(EcoResProductVariantFlavorDisplayOrderView, DistinctProductVariant)); | |
_sender.queryBuildDataSource().addLink(fieldNum(EcoResProductVariantFlavor, Flavor), fieldNum(EcoResProductVariantFlavorDisplayOrderView, Flavor)); | |
_sender.queryBuildDataSource().addOrderByField(fieldNum(EcoResProductVariantFlavorDisplayOrderView, RetailDisplayOrder)); | |
_sender.queryBuildDataSource().addOrderByField(fieldNum(EcoResProductVariantFlavorDisplayOrderView, Name)); | |
} | |
} | |
加range/link 到 新加的datasource [View] (extension) 內: | |
/// <summary> /// |
[ExtensionOf(formStr(DimensionValueDetails))]
final class DimensionValueDetails_extension
[DataSource]
class ABCView
public void lookup()
{
Name | Used how | Example |
dayRange | (dayRange(-1,2)) gives a query result of all records from yesterday until the day after tomorrow.
Note that it is unfortunately not possible to use decimals, only full days work. |
SQL : 可以用 curExt() :
where dataareaId = curExt() ;
smmParametersTable smmParameters;
QueryBuildDataSource qbds;
/// <summary>
///
// 輸入 : (1) 需要分拆的字元 , (2) 分折字元符號 , (3) 分折後退回指定字元
public static str strSplit(str _splitString,str _splitchar,int _pos)