using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

/// <summary>
/// Summary description for Class_xtblTamiratBaz
/// </summary>
public class Class_xtblTamiratBaz
{
    private Decimal Dec_TamirID = 0;
    private String Str_InfoCar = String.Empty;
    private String Str_Note = String.Empty;

    public Class_xtblTamiratBaz(Decimal _TamirID)
    {
        this.Dec_TamirID = _TamirID;
    }

    public String UDF_ReternInfoCar()
    {
        LSCTamiratDataContext db = new LSCTamiratDataContext();
        var Query = from Row in db.xtblTamiratBazs 
                    where Row.TamirID == Dec_TamirID 
                    select new
                    {
                        Row.TamirID ,
                        Row.PelakAndCarName 

                    };
        foreach (var Row in Query)
        {
            Str_InfoCar = Row.PelakAndCarName;

        }
        return Str_InfoCar;
    }

    public String UDF_ReternNote()
    {
        LSCTamiratDataContext db = new LSCTamiratDataContext();
        var Query = from Row in db.xtblTamiratBazs
                    where Row.TamirID == Dec_TamirID
                    select new
                    {
                        Row.TamirID,
                        Row.TamirNote 

                    };
        foreach (var Row in Query)
        {
            Str_Note = Row.TamirNote;

        }
        return Str_Note;
    }

    public String Str_InformationOfCars
    {
        get
        {
            return Str_InfoCar;
        }
    }

    public String Str_InformatinNote
    {
        get
        {
            return Str_Note;
        }
    }

}