Пример #1
0
    public static WCFRetrieval Make(int retrievalID, int retrievedBy, string retrievedDate, string retrievalStatus)
    {
        WCFRetrieval r = new WCFRetrieval();

        r.RetrievalID     = retrievalID;
        r.RetrievedBy     = retrievedBy;
        r.RetrievedDate   = retrievedDate;
        r.RetrievalStatus = retrievalStatus;
        return(r);
    }
Пример #2
0
    /* get retrieval list */
    public List <WCFRetrieval> getDataSource()
    {
        List <RetrivalBO>   l = n.getDataSource();
        List <WCFRetrieval> m = new List <WCFRetrieval>();

        foreach (RetrivalBO b in l)
        {
            m.Add(WCFRetrieval.Make1(b.Bin, b.ItemName, b.Needed, b.Retrived));
        }
        return(m);
    }
Пример #3
0
    public static WCFRetrieval Make1(string bin, string itemName, int needed, int retrieved)
    {
        WCFRetrieval e = new WCFRetrieval();

        e.bin       = bin;
        e.itemName  = itemName;
        e.needed    = needed;
        e.retrieved = retrieved;

        return(e);
    }
Пример #4
0
    public List <WCFRetrieval> getAllRetrieval()
    {
        List <WCFRetrieval> wcfDisbList = new List <WCFRetrieval>();
        List <Retrieval>    retList     = retCon.DisplayRetrievalList();

        foreach (Retrieval r in retList)
        {
            wcfDisbList.Add(WCFRetrieval.Make(r.RetrievalID, (int)r.RetrievedBy, ((DateTime)r.RetrievedDate).ToLongDateString(), r.RetrievalStatus));
        }
        return(wcfDisbList);
    }
Пример #5
0
    public WCFRetrieval[] ListCollectedRetrievals()
    {
        List <WCFRetrieval> l = new List <WCFRetrieval>();

        foreach (Retrieval c in Data.ListCollectedRetrievals())
        {
            WCFRetrieval w = WCFRetrieval.Make(c.RetrievalID, c.RetrievalDate.HasValue ? c.RetrievalDate.Value.ToString("dd-MMM-yyyy") : null /*, ListRetrievalDetails(c.RetrievalID.ToString())*/);
            l.Add(w);
        }
        return(l.ToArray <WCFRetrieval>());
    }
Пример #6
0
    public WCFRetrieval GetLatestRetrieval(int sessionID)
    {
        WCFRetrieval result = null;

        if (AndroidAuthenticationController.IsValidSessionId(sessionID))
        {
            Retrieval latestRetrieval = AndroidController.GetLatestRetrieval();

            if (latestRetrieval != null)
            {
                result = new WCFRetrieval()
                {
                    RetrievalNo = latestRetrieval.RetrievalNo.ToString(),
                    Date        = String.Format("{0:dd/MM/yyyy}", latestRetrieval.Date)
                };
            }
        }
        return(result);
    }
Пример #7
0
 public void UpdateWCFRetrieval(WCFRetrieval b)
 {
     throw new NotImplementedException();
 }