Kevin Kok Khah Whey
2023-11-07 5ae534ab606e6f2ba5ea60914224d665b0447d5a
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
Quintiq file version 2.0
#parent: pl_Function_FCOV/btn_deleteOrder_FCOV
Response OnClick (
  S_DT_CustomOrder selection
) id:Response_pl_Function_FCOV_btn_deleteOrder_FCOV_OnClick
{
  #keys: '[414724.0.321284302]'
  CanBindMultiple: false
  DefinitionID => /pl_Function_FCOV/Responsedef_pl_Function_FCOV_btn_deleteOrder_FCOV_OnClick
  Precondition:
  [*
    return not isnull( selection) and selection.ParentID()<>"";
  *]
  QuillAction
  {
    Body:
    [*
      Num:=WebMessageBox::Question("确认删除?",true);
      if( Num=0)
      {
        OrderInfo:=select( MacroPlan,SalesDemand.astype( CustomerOrder ),obj,obj.ID()=selection.ParentID());
        SSI := select(MacroPlan,S_DT_SpliteStruct,obj,obj.ID() = selection.ID_SpliteStruct());
        if( not isnull( SSI))
        {
          SSI.Status(0);
        }
        S_FunctionClass::SM_OrderToSpliteOrder( MacroPlan,OrderInfo,"");
        if( not isnull( selection))
        {
          selection.Delete();
        }
      }
    *]
    GroupServerCalls: false
  }
}