<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx Version="4.0" xmlns:edmx="http://docs.oasis-open.org/odata/ns/edmx">
  <edmx:Reference Uri="https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Capabilities.V1.xml">
    <edmx:Include Alias="Capabilities" Namespace="Org.OData.Capabilities.V1"/>
  </edmx:Reference>
  <edmx:Reference Uri="https://sap.github.io/odata-vocabularies/vocabularies/Common.xml">
    <edmx:Include Alias="Common" Namespace="com.sap.vocabularies.Common.v1"/>
  </edmx:Reference>
  <edmx:Reference Uri="https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Core.V1.xml">
    <edmx:Include Alias="Core" Namespace="Org.OData.Core.V1"/>
  </edmx:Reference>
  <edmx:Reference Uri="https://sap.github.io/odata-vocabularies/vocabularies/UI.xml">
    <edmx:Include Alias="UI" Namespace="com.sap.vocabularies.UI.v1"/>
  </edmx:Reference>
  <edmx:DataServices>
    <Schema Namespace="ManageAccessService" xmlns="http://docs.oasis-open.org/odata/ns/edm">
      <EntityContainer Name="EntityContainer">
        <EntitySet Name="BusinessObjects" EntityType="ManageAccessService.BusinessObjects"/>
        <EntitySet Name="AccessRoles" EntityType="ManageAccessService.AccessRoles">
          <NavigationPropertyBinding Path="businessObject" Target="BusinessObjects"/>
        </EntitySet>
        <EntitySet Name="UserAccessMappings" EntityType="ManageAccessService.UserAccessMappings">
          <NavigationPropertyBinding Path="user" Target="Users"/>
          <NavigationPropertyBinding Path="role" Target="AccessRoles"/>
          <NavigationPropertyBinding Path="businessObject" Target="BusinessObjects"/>
          <NavigationPropertyBinding Path="group" Target="Groups"/>
          <NavigationPropertyBinding Path="assignedBy" Target="Users"/>
        </EntitySet>
        <EntitySet Name="RolePermissions" EntityType="ManageAccessService.RolePermissions">
          <NavigationPropertyBinding Path="role" Target="AccessRoles"/>
        </EntitySet>
        <EntitySet Name="Users" EntityType="ManageAccessService.Users">
          <NavigationPropertyBinding Path="group" Target="Groups"/>
        </EntitySet>
        <EntitySet Name="Groups" EntityType="ManageAccessService.Groups">
          <NavigationPropertyBinding Path="created_by" Target="Users"/>
          <NavigationPropertyBinding Path="updated_by" Target="Users"/>
        </EntitySet>
        <EntitySet Name="AdminChangeLog" EntityType="ManageAccessService.AdminChangeLog"/>
        <ActionImport Name="searchUsers" Action="ManageAccessService.searchUsers" EntitySet="Users"/>
        <ActionImport Name="getUserAccess" Action="ManageAccessService.getUserAccess"/>
        <ActionImport Name="assignRoles" Action="ManageAccessService.assignRoles"/>
        <ActionImport Name="removeRoles" Action="ManageAccessService.removeRoles"/>
        <ActionImport Name="saveUserAccess" Action="ManageAccessService.saveUserAccess"/>
        <ActionImport Name="getRolesByBusinessObject" Action="ManageAccessService.getRolesByBusinessObject" EntitySet="AccessRoles"/>
        <ActionImport Name="seedBusinessObjectsAndRoles" Action="ManageAccessService.seedBusinessObjectsAndRoles"/>
      </EntityContainer>
      <EntityType Name="BusinessObjects">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="code" Type="Edm.String" MaxLength="50" Nullable="false"/>
        <Property Name="name" Type="Edm.String" MaxLength="100" Nullable="false"/>
        <Property Name="description" Type="Edm.String" MaxLength="255"/>
        <Property Name="isActive" Type="Edm.Boolean" DefaultValue="true"/>
        <Property Name="createdAt" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="updatedAt" Type="Edm.DateTimeOffset" Precision="7"/>
      </EntityType>
      <EntityType Name="AccessRoles">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="roleCode" Type="Edm.String" MaxLength="100" Nullable="false"/>
        <Property Name="roleName" Type="Edm.String" MaxLength="150" Nullable="false"/>
        <Property Name="description" Type="Edm.String" MaxLength="500"/>
        <NavigationProperty Name="businessObject" Type="ManageAccessService.BusinessObjects" Nullable="false">
          <ReferentialConstraint Property="businessObject_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="businessObject_ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="permissions" Type="Edm.String"/>
        <Property Name="isActive" Type="Edm.Boolean" DefaultValue="true"/>
        <Property Name="createdAt" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="updatedAt" Type="Edm.DateTimeOffset" Precision="7"/>
      </EntityType>
      <EntityType Name="UserAccessMappings">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <NavigationProperty Name="user" Type="ManageAccessService.Users" Nullable="false">
          <ReferentialConstraint Property="user_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="user_ID" Type="Edm.Guid" Nullable="false"/>
        <NavigationProperty Name="role" Type="ManageAccessService.AccessRoles" Nullable="false">
          <ReferentialConstraint Property="role_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="role_ID" Type="Edm.Guid" Nullable="false"/>
        <NavigationProperty Name="businessObject" Type="ManageAccessService.BusinessObjects" Nullable="false">
          <ReferentialConstraint Property="businessObject_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="businessObject_ID" Type="Edm.Guid" Nullable="false"/>
        <NavigationProperty Name="group" Type="ManageAccessService.Groups">
          <ReferentialConstraint Property="group_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="group_ID" Type="Edm.Guid"/>
        <NavigationProperty Name="assignedBy" Type="ManageAccessService.Users">
          <ReferentialConstraint Property="assignedBy_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="assignedBy_ID" Type="Edm.Guid"/>
        <Property Name="assignedAt" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="isActive" Type="Edm.Boolean" DefaultValue="true"/>
      </EntityType>
      <EntityType Name="RolePermissions">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <NavigationProperty Name="role" Type="ManageAccessService.AccessRoles" Nullable="false">
          <ReferentialConstraint Property="role_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="role_ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="module" Type="Edm.String" MaxLength="100"/>
        <Property Name="action" Type="Edm.String" MaxLength="50"/>
        <Property Name="createdAt" Type="Edm.DateTimeOffset" Precision="7"/>
      </EntityType>
      <EntityType Name="Users">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="username" Type="Edm.String" MaxLength="100" Nullable="false"/>
        <Property Name="password" Type="Edm.String" MaxLength="100" Nullable="false"/>
        <Property Name="role" Type="Edm.String" MaxLength="50" Nullable="false"/>
        <Property Name="firstName" Type="Edm.String" MaxLength="32" Nullable="false"/>
        <NavigationProperty Name="group" Type="ManageAccessService.Groups">
          <ReferentialConstraint Property="group_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="group_ID" Type="Edm.Guid"/>
        <Property Name="customFields" Type="Edm.String"/>
        <Property Name="created_at" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="updated_at" Type="Edm.DateTimeOffset" Precision="7"/>
      </EntityType>
      <EntityType Name="Groups">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="name" Type="Edm.String" MaxLength="100"/>
        <Property Name="employeeForm_ID" Type="Edm.Guid"/>
        <Property Name="is_active" Type="Edm.Boolean"/>
        <Property Name="created_at" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="updated_at" Type="Edm.DateTimeOffset" Precision="7"/>
        <NavigationProperty Name="created_by" Type="ManageAccessService.Users">
          <ReferentialConstraint Property="created_by_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="created_by_ID" Type="Edm.Guid"/>
        <NavigationProperty Name="updated_by" Type="ManageAccessService.Users">
          <ReferentialConstraint Property="updated_by_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="updated_by_ID" Type="Edm.Guid"/>
        <Property Name="requestPolicies" Type="Collection(Edm.Guid)" Nullable="false"/>
        <Property Name="expensePolicies" Type="Collection(Edm.Guid)" Nullable="false"/>
        <Property Name="cashAdvanceForm_ID" Type="Edm.Guid"/>
      </EntityType>
      <EntityType Name="AdminChangeLog">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="createdAt" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="createdBy" Type="Edm.String" MaxLength="255"/>
        <Property Name="modifiedAt" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="modifiedBy" Type="Edm.String" MaxLength="100"/>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="action" Type="Edm.String" MaxLength="50"/>
        <Property Name="entityName" Type="Edm.String" MaxLength="100"/>
        <Property Name="recordId" Type="Edm.Guid"/>
        <Property Name="configType" Type="Edm.String" MaxLength="100"/>
        <Property Name="module" Type="Edm.String" MaxLength="100"/>
        <Property Name="description" Type="Edm.String" MaxLength="500"/>
        <Property Name="changeCategory" Type="Edm.String" MaxLength="100"/>
        <Property Name="modifiedRole" Type="Edm.String" MaxLength="100"/>
        <Property Name="beforeData" Type="Edm.String"/>
        <Property Name="afterData" Type="Edm.String"/>
        <Property Name="correlationId" Type="Edm.Guid"/>
      </EntityType>
      <ComplexType Name="return_ManageAccessService_getUserAccess">
        <Property Name="businessObject" Type="ManageAccessService.return_ManageAccessService_getUserAccess_businessObject"/>
        <Property Name="roles" Type="Collection(ManageAccessService.return_ManageAccessService_getUserAccess_roles)" Nullable="false"/>
      </ComplexType>
      <ComplexType Name="return_ManageAccessService_getUserAccess_businessObject">
        <Property Name="ID" Type="Edm.Guid"/>
        <Property Name="code" Type="Edm.String"/>
        <Property Name="name" Type="Edm.String"/>
      </ComplexType>
      <ComplexType Name="return_ManageAccessService_getUserAccess_roles">
        <Property Name="mappingId" Type="Edm.Guid"/>
        <Property Name="roleId" Type="Edm.Guid"/>
        <Property Name="roleCode" Type="Edm.String"/>
        <Property Name="roleName" Type="Edm.String"/>
        <Property Name="assignedAt" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="assignedBy" Type="Edm.String"/>
        <Property Name="isActive" Type="Edm.Boolean"/>
      </ComplexType>
      <ComplexType Name="ap_ManageAccessService_assignRoles_roles">
        <Property Name="roleId" Type="Edm.Guid"/>
        <Property Name="businessObjectId" Type="Edm.Guid"/>
        <Property Name="groupId" Type="Edm.Guid"/>
      </ComplexType>
      <ComplexType Name="ap_ManageAccessService_saveUserAccess_roles">
        <Property Name="roleId" Type="Edm.Guid"/>
        <Property Name="businessObjectId" Type="Edm.Guid"/>
        <Property Name="groupId" Type="Edm.Guid"/>
      </ComplexType>
      <Action Name="searchUsers" IsBound="false">
        <Parameter Name="searchBy" Type="Edm.String"/>
        <Parameter Name="searchText" Type="Edm.String"/>
        <Parameter Name="groupId" Type="Edm.Guid"/>
        <ReturnType Type="Collection(ManageAccessService.Users)"/>
      </Action>
      <Action Name="getUserAccess" IsBound="false">
        <Parameter Name="userId" Type="Edm.Guid"/>
        <ReturnType Type="Collection(ManageAccessService.return_ManageAccessService_getUserAccess)" Nullable="false"/>
      </Action>
      <Action Name="assignRoles" IsBound="false">
        <Parameter Name="userId" Type="Edm.Guid"/>
        <Parameter Name="roles" Type="Collection(ManageAccessService.ap_ManageAccessService_assignRoles_roles)" Nullable="false"/>
        <ReturnType Type="Edm.String"/>
      </Action>
      <Action Name="removeRoles" IsBound="false">
        <Parameter Name="mappingIds" Type="Collection(Edm.Guid)" Nullable="false"/>
        <ReturnType Type="Edm.String"/>
      </Action>
      <Action Name="saveUserAccess" IsBound="false">
        <Parameter Name="userId" Type="Edm.Guid"/>
        <Parameter Name="roles" Type="Collection(ManageAccessService.ap_ManageAccessService_saveUserAccess_roles)" Nullable="false"/>
        <ReturnType Type="Edm.String"/>
      </Action>
      <Action Name="getRolesByBusinessObject" IsBound="false">
        <Parameter Name="businessObjectId" Type="Edm.Guid"/>
        <ReturnType Type="Collection(ManageAccessService.AccessRoles)"/>
      </Action>
      <Action Name="seedBusinessObjectsAndRoles" IsBound="false">
        <ReturnType Type="Edm.String"/>
      </Action>
      <Annotations Target="ManageAccessService.BusinessObjects/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.BusinessObjects/createdAt">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.BusinessObjects/updatedAt">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.AccessRoles/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.AccessRoles/createdAt">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.AccessRoles/updatedAt">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.UserAccessMappings/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.UserAccessMappings/assignedAt">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.RolePermissions/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.RolePermissions/createdAt">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.EntityContainer/Users">
        <Annotation Term="Capabilities.DeleteRestrictions">
          <Record Type="Capabilities.DeleteRestrictionsType">
            <PropertyValue Property="Deletable" Bool="false"/>
          </Record>
        </Annotation>
        <Annotation Term="Capabilities.InsertRestrictions">
          <Record Type="Capabilities.InsertRestrictionsType">
            <PropertyValue Property="Insertable" Bool="false"/>
          </Record>
        </Annotation>
        <Annotation Term="Capabilities.UpdateRestrictions">
          <Record Type="Capabilities.UpdateRestrictionsType">
            <PropertyValue Property="Updatable" Bool="false"/>
          </Record>
        </Annotation>
      </Annotations>
      <Annotations Target="ManageAccessService.Users/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.Users/created_at">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.Users/updated_at">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.EntityContainer/Groups">
        <Annotation Term="Capabilities.DeleteRestrictions">
          <Record Type="Capabilities.DeleteRestrictionsType">
            <PropertyValue Property="Deletable" Bool="false"/>
          </Record>
        </Annotation>
        <Annotation Term="Capabilities.InsertRestrictions">
          <Record Type="Capabilities.InsertRestrictionsType">
            <PropertyValue Property="Insertable" Bool="false"/>
          </Record>
        </Annotation>
        <Annotation Term="Capabilities.UpdateRestrictions">
          <Record Type="Capabilities.UpdateRestrictionsType">
            <PropertyValue Property="Updatable" Bool="false"/>
          </Record>
        </Annotation>
      </Annotations>
      <Annotations Target="ManageAccessService.Groups/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="ManageAccessService.AdminChangeLog/createdAt">
        <Annotation Term="UI.HiddenFilter" Bool="true"/>
        <Annotation Term="Core.Immutable" Bool="true"/>
        <Annotation Term="Core.Computed" Bool="true"/>
        <Annotation Term="Common.Label" String="Created On"/>
      </Annotations>
      <Annotations Target="ManageAccessService.AdminChangeLog/createdBy">
        <Annotation Term="UI.HiddenFilter" Bool="true"/>
        <Annotation Term="Core.Immutable" Bool="true"/>
        <Annotation Term="Core.Computed" Bool="true"/>
        <Annotation Term="Core.Description" String="User's unique ID"/>
        <Annotation Term="Common.Label" String="Created By"/>
      </Annotations>
      <Annotations Target="ManageAccessService.AdminChangeLog/modifiedAt">
        <Annotation Term="UI.HiddenFilter" Bool="true"/>
        <Annotation Term="Core.Computed" Bool="true"/>
        <Annotation Term="Common.Label" String="Changed On"/>
      </Annotations>
      <Annotations Target="ManageAccessService.AdminChangeLog/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
    </Schema>
  </edmx:DataServices>
</edmx:Edmx>