1. Куча / Говнокод #9236

    +127

    1. 01
    2. 02
    3. 03
    4. 04
    5. 05
    6. 06
    7. 07
    8. 08
    9. 09
    10. 10
    11. 11
    12. 12
    13. 13
    14. 14
    15. 15
    16. 16
    17. 17
    18. 18
    19. 19
    20. 20
    21. 21
    22. 22
    23. 23
    24. 24
    25. 25
    26. 26
    27. 27
    28. 28
    29. 29
    30. 30
    31. 31
    32. 32
    33. 33
    34. 34
    35. 35
    36. 36
    37. 37
    38. 38
    39. 39
    40. 40
    41. 41
    42. 42
    43. 43
    44. 44
    45. 45
    46. 46
    resid := "ANeNaidenVidShortNameNA";
    defval := "(Не найден вид '(ShortNameNA)')";
    nenay:=@DbLookup("":"NoCache";"":"ResDB.nsf";"(Res)";lng+resid;2);
    nenay:=@If(@IsError(nenay);defval;nenay);
    
    key:=@Name([Abbreviate]; @UserName);
    
    serv:=@GetProfileField("CommonDBProfile"; "StructServer"; @ServerName);
    db:=@GetProfileField("CommonDBProfile"; "StructDB"; @ServerName);
    
    @If (serv="" | db=""; @Do(
    @Prompt([Ok];osh; vstr);
    @Return(vstr)
    ); "");
    
    StructServer1:=@DbLookup("":"NoCache"; serv:db; "(NAShortNamePost)"; key; "StructServer" ) ;
    StructDB1:=@DbLookup("":"NoCache"; serv:db; "(NAShortNamePost)"; key; "StructDB" ) ;
    
    @If(StructDB1 = ""; @Do(@Prompt([Ok]; vnim; vstr); @Return("")); @Success);
    a := @Trim(@PickList([Custom];StructServer1 :StructDB1; "(ShortNameNA)";sel; sel1; 5));
    @If(@IsError(a); @Do(@Prompt([Ok]; osh; nenay); @Return("")); @Success);
    @If(a = ""; @Do(@Prompt([Ok]; vnim; vneob); @Return("")); @Success);
    
    FIELD NamesAlias:=  @Middle(a; "$"; "#");
    FIELD IndDepart := @Explode(@Implode(@Trim(@Left(a;"*"));";");";");
    FIELD Depart := @Middle(a; "*"; "$");
    FIELD Empl :=  @Middle(a; "$"; "#");
    
    FIELD EmplNotesAdr:= @Explode(@Implode(@Trim(@Middle(a; "#"; "%"));";");";");
    FIELD Replacer := @Trim(@Middle(a; "%"; "?"));
    
    FIELD ReplacerNotesAdr := @Explode(@Implode(@Trim(@Middle(a; "?"; "+"));";");";");
    
    FIELD ServerName:=@Explode(@Implode(@Trim(@Right(a;"+"));";");";");
    REM {FIELD CtrlDate:=@Adjust(@Today;0;1;0;0;0;0 )};
    FIELD a3:=@Date(@Today);
    
    FIELD a6:=@Middle(a; "$"; "#")+"<< >> " ;
    
    FIELD IndDepart:=IndDepart ;
    FIELD Depart:=Depart;
    FIELD Replacer :=@Unique(Replacer );
    FIELD ReplacerNotesAdr:=@Unique(@Name([Abbreviate];  ReplacerNotesAdr));
    FIELD ServerName:=@Unique(@Name([Abbreviate];ServerName));
    @Command([RunAgent];"(CheckWall)");
    @Command([RefreshFrame];"Document")

    документооборот епта

    Запостил: d_dev, 27 Января 2012

    Комментарии (5) RSS

    Добавить комментарий