presentations/highlight-js/test/detect/isbl/default.txt

27 lines
1.1 KiB
Text
Raw Permalink Normal View History

2018-12-07 08:48:05 -06:00
 // Описание констант
ADD_EQUAL_NUMBER_TEMPLATE = "%s.%s = %s"
EMPLOYEES_REFERENCE = "РАБ"
/*********************************************
* Получить список кодов или ИД работников, *
* соответствующих текущему пользователю *
*********************************************/
Employees: IReference.РАБ = CreateReference(EMPLOYEES_REFERENCE;
ArrayOf("Пользователь"; SYSREQ_STATE); MyFunction(FALSE; MyParam * 0.05))
Employees.Events.DisableAll
EmployeesTableName = Employees.TableName
EmployeesUserWhereID = Employees.AddWhere(Format(ADD_EQUAL_NUMBER_TEMPLATE;
ArrayOf(EmployeesTableName; Employees.Requisites("Пользователь").SQLFieldName;
EDocuments.CurrentUser.ID)))
Employees.Open()
Result = CreateStringList()
foreach Employee in Employees
if IsResultCode
Result.Add(Employee.SYSREQ_CODE)
else
Result.Add(Employee.SYSREQ_ID)
endif
endforeach
Employees.Close()
Employees.DelWhere(EmployeesUserWhereID)
Employees.Events.EnableAll
Employees = nil