<?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://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:DataServices>
    <Schema Namespace="PerDayAllowanceService" xmlns="http://docs.oasis-open.org/odata/ns/edm">
      <EntityContainer Name="EntityContainer">
        <EntitySet Name="UserUIAccess" EntityType="PerDayAllowanceService.UserUIAccess"/>
        <EntitySet Name="Users" EntityType="PerDayAllowanceService.Users">
          <NavigationPropertyBinding Path="group" Target="Groups"/>
        </EntitySet>
        <EntitySet Name="PerDayAllowance" EntityType="PerDayAllowanceService.PerDayAllowance">
          <NavigationPropertyBinding Path="group" Target="Groups"/>
          <NavigationPropertyBinding Path="policy" Target="ExpensePolicy"/>
        </EntitySet>
        <EntitySet Name="Groups" EntityType="PerDayAllowanceService.Groups">
          <NavigationPropertyBinding Path="created_by" Target="Users"/>
          <NavigationPropertyBinding Path="updated_by" Target="Users"/>
        </EntitySet>
        <EntitySet Name="ExpensePolicy" EntityType="PerDayAllowanceService.ExpensePolicy">
          <NavigationPropertyBinding Path="group" Target="Groups"/>
          <NavigationPropertyBinding Path="created_by" Target="Users"/>
          <NavigationPropertyBinding Path="updated_by" Target="Users"/>
        </EntitySet>
        <EntitySet Name="Cities" EntityType="PerDayAllowanceService.Cities"/>
        <EntitySet Name="AllCities" EntityType="PerDayAllowanceService.AllCities"/>
        <ActionImport Name="saveorupdatePerDayAllowance" Action="PerDayAllowanceService.saveorupdatePerDayAllowance"/>
        <ActionImport Name="getPerDayAllowanceRate" Action="PerDayAllowanceService.getPerDayAllowanceRate"/>
      </EntityContainer>
      <EntityType Name="UserUIAccess">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="feature_name" Type="Edm.String" MaxLength="50"/>
        <Property Name="is_visible" Type="Edm.Boolean" DefaultValue="true"/>
      </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="PerDayAllowanceService.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="PerDayAllowance">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="PerDayAllowanceName" Type="Edm.String"/>
        <NavigationProperty Name="group" Type="PerDayAllowanceService.Groups">
          <ReferentialConstraint Property="group_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="group_ID" Type="Edm.Guid"/>
        <NavigationProperty Name="policy" Type="PerDayAllowanceService.ExpensePolicy">
          <ReferentialConstraint Property="policy_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="policy_ID" Type="Edm.Guid"/>
        <Property Name="details" Type="Edm.String"/>
        <Property Name="criteria" Type="Edm.String"/>
        <Property Name="sub_criteria" 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="PerDayAllowanceService.Users">
          <ReferentialConstraint Property="created_by_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="created_by_ID" Type="Edm.Guid"/>
        <NavigationProperty Name="updated_by" Type="PerDayAllowanceService.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="ExpensePolicy">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="policyName" Type="Edm.String" MaxLength="255" Nullable="false"/>
        <Property Name="expenseReportHeader_ID" Type="Edm.Guid"/>
        <Property Name="expenseWorkflow" Type="Edm.String" MaxLength="100"/>
        <Property Name="disableTravelAllowance" Type="Edm.Boolean" DefaultValue="false"/>
        <Property Name="disableFuelAllowance" Type="Edm.Boolean" DefaultValue="false"/>
        <NavigationProperty Name="group" Type="PerDayAllowanceService.Groups">
          <ReferentialConstraint Property="group_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="group_ID" Type="Edm.Guid"/>
        <Property Name="created_at" Type="Edm.DateTimeOffset" Precision="7"/>
        <Property Name="updated_at" Type="Edm.DateTimeOffset" Precision="7"/>
        <NavigationProperty Name="created_by" Type="PerDayAllowanceService.Users">
          <ReferentialConstraint Property="created_by_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="created_by_ID" Type="Edm.Guid"/>
        <NavigationProperty Name="updated_by" Type="PerDayAllowanceService.Users">
          <ReferentialConstraint Property="updated_by_ID" ReferencedProperty="ID"/>
        </NavigationProperty>
        <Property Name="updated_by_ID" Type="Edm.Guid"/>
        <Property Name="isActive" Type="Edm.Boolean" DefaultValue="true"/>
      </EntityType>
      <EntityType Name="Cities">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Int32" Nullable="false"/>
        <Property Name="city" Type="Edm.String" MaxLength="255"/>
        <Property Name="name" Type="Edm.String" MaxLength="255"/>
        <Property Name="countryCode" Type="Edm.String" MaxLength="10"/>
        <Property Name="country_ID" Type="Edm.Int32"/>
      </EntityType>
      <EntityType Name="AllCities">
        <Key>
          <PropertyRef Name="ID"/>
        </Key>
        <Property Name="ID" Type="Edm.Guid" Nullable="false"/>
        <Property Name="name" Type="Edm.String" MaxLength="255"/>
        <Property Name="countryCode" Type="Edm.String" MaxLength="255"/>
        <Property Name="country" Type="Edm.String" MaxLength="255"/>
      </EntityType>
      <ComplexType Name="return_PerDayAllowanceService_getPerDayAllowanceRate">
        <Property Name="included_days" Type="Edm.Int32"/>
        <Property Name="total_amount" Type="Edm.Decimal" Precision="10" Scale="2"/>
        <Property Name="currency_ID" Type="Edm.Guid"/>
        <Property Name="message" Type="Edm.String"/>
      </ComplexType>
      <Action Name="saveorupdatePerDayAllowance" IsBound="false">
        <Parameter Name="ID" Type="Edm.Guid"/>
        <Parameter Name="PerDayAllowanceName" Type="Edm.String"/>
        <Parameter Name="group" Type="Edm.Guid"/>
        <Parameter Name="policy" Type="Edm.Guid"/>
        <Parameter Name="criteria" Type="Edm.String"/>
        <Parameter Name="sub_criteria" Type="Edm.String"/>
        <Parameter Name="details" Type="Edm.String"/>
        <ReturnType Type="Edm.String"/>
      </Action>
      <Action Name="getPerDayAllowanceRate" IsBound="false">
        <Parameter Name="policy_ID" Type="Edm.Guid"/>
        <Parameter Name="group_ID" Type="Edm.Guid"/>
        <Parameter Name="location_ID" Type="Edm.String"/>
        <Parameter Name="arrival_datetime" Type="Edm.DateTimeOffset" Precision="7"/>
        <Parameter Name="departure_datetime" Type="Edm.DateTimeOffset" Precision="7"/>
        <ReturnType Type="PerDayAllowanceService.return_PerDayAllowanceService_getPerDayAllowanceRate"/>
      </Action>
      <Annotations Target="PerDayAllowanceService.UserUIAccess/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.Users/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.Users/created_at">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.Users/updated_at">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.PerDayAllowance/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.Groups/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.ExpensePolicy/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.ExpensePolicy/created_at">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.ExpensePolicy/updated_at">
        <Annotation Term="Core.Computed" Bool="true"/>
      </Annotations>
      <Annotations Target="PerDayAllowanceService.AllCities/ID">
        <Annotation Term="Core.ComputedDefaultValue" Bool="true"/>
      </Annotations>
    </Schema>
  </edmx:DataServices>
</edmx:Edmx>