Skip to content

Instantly share code, notes, and snippets.

@alpavlove
Created November 7, 2014 11:06
Show Gist options
  • Save alpavlove/111009aee2fdc9f040da to your computer and use it in GitHub Desktop.
Save alpavlove/111009aee2fdc9f040da to your computer and use it in GitHub Desktop.
actionsByType = {
Client: {
participantId: scope.project.Client.Id,
onHideCallback: function () {
scope.project.Client = {
Id: popupScope.participant.Id,
TypeId: popupScope.participant.Type.Id,
TypeName: popupScope.participant.Type.Name,
Address: popupScope.participant.Address
};
if (popupScope.participant.Type.NameEn === 'company') {
scope.project.Client.Name = popupScope.participant.Organization;
} else if (popupScope.participant.Type.NameEn === 'individual') {
scope.project.Client.Name = popupScope.participant.LastName + ' ' + popupScope.participant.FirstName + ' ' + popupScope.participant.MiddleName;
}
}
},
VerifyingDepartment: {
participantId: scope.project.TaxAuditProject.VerifyingDepartmentId,
onHideCallback: function () {
scope.project.TaxAuditProject.VerifyingDepartment = popupScope.participant.Organization;
}
},
Inspector: {
participantId: scope.project.TaxAuditProject.InspectorId,
onHideCallback: function () {
scope.project.TaxAuditProject.InspectorSurname = popupScope.participant.LastName + ' ' + popupScope.participant.FirstName + ' ' + popupScope.participant.MiddleName;
}
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment