Exemplo n.º 1
0
        public static void AddProperty(string city, string streetAddress, double purchasePrice, DateTime aquisitionDate, Features features, double rent = 0, bool moveInReady = false, string state = "Illinois", byte[] imageData = null)
        {
            Property property = new Property(city, streetAddress, rent, moveInReady, state, purchasePrice, aquisitionDate, features, imageData);

            PropertyList.Add(property);
            Occurence.AddNewOccurence("Aquired new property", streetAddress, aquisitionDate, property, Occurence.Statuses.Resolved, null);
        }
Exemplo n.º 2
0
        public void MoveOutOldTenants(string eventName, string reason, DateTime moveOutDate, bool evicted)
        {
            CurrentLease.MoveOutDate = moveOutDate;
            CurrentLease.Evicted     = evicted;

            Occurence.AddNewOccurence(eventName, reason, moveOutDate, this, Occurence.Statuses.Resolved, CurrentTenants.ToList());

            foreach (Tenant t in CurrentTenants)
            {
                t.CurrentLease = null;
            }

            CurrentLease = null;
        }
Exemplo n.º 3
0
        public void MoveInNewTenants(List <Tenant> tenants, DateTime startDate, int termLengthInMonths, double rent, double deposit, double petDeposit, byte[] imageData)
        {
            CurrentLease = new Lease(this, tenants, rent, deposit, petDeposit, startDate, termLengthInMonths, imageData);
            Lease.Leases.Add(CurrentLease);
            string[] tenantslist = new string[tenants.Count()];
            int      i           = 0;

            foreach (Tenant t in tenants)
            {
                t.CurrentLease   = CurrentLease;
                tenantslist[i++] = t.FirstName + " " + t.LastName;
            }

            Occurence.AddNewOccurence("New tenant move in", String.Join(", ", tenantslist), startDate, this, Occurence.Statuses.Resolved, tenants);
            Rent = rent;
        }