コード例 #1
0
        //static int _firstYear = 2001;
        //public IssuesCollection GetAllIssues()
        //{
        //    IssuesCollection allIssues = new IssuesCollection();
        //    int years = DateTime.Now.AddYears(1).Year - _firstYear;
        //    for (int i = 0; i < years; i++)
        //    {
        //        allIssues.Add((_firstYear + i).ToString());
        //    }
        //    return allIssues;

        //}
        //public IssuesData GetIssuesByYear(string year)
        //{
        //    IssuesData issue = new IssuesData { Year = year, Issues = new MonthInfo() };
        //    Calendar c = new GregorianCalendar();
        //    CultureInfo ci = CultureInfo.CurrentCulture;

        //    int mnths = c.GetMonthsInYear(Int32.Parse(year));
        //    for (int j = 0; j < mnths; j++)
        //    {
        //        issue.Issues.Add(ci.DateTimeFormat.MonthNames[j]);
        //    }
        //    return issue;

        #region IPOSHardwareCtrlService Members

        public SlipData SampleSlip()
        {
            SlipData data = new SlipData();

            data.id       = "9876";
            data.type     = "ticket";
            data.datetime = DateTime.Now.ToString();

            contactInfo biz = new contactInfo();

            biz.name     = "J's Cleaners";
            biz.addr     = "205 S San Mateo Dr, San Mateo, CA 94401";
            biz.webaddr  = "http://jsdryclean.com";
            biz.phone    = "650.343.2060";
            data.bizInfo = biz;

            contactInfo customer = new contactInfo();

            customer.name  = "J's Cleaners";
            customer.phone = "650.343.2060";
            data.custInfo  = customer;

            LineItemsCollection items = new LineItemsCollection()
            {
                new LineItem {
                    quant = 1, desc = "dc coat", comment = "grey", itemPrice = 14.0F
                },
                new LineItem {
                    quant = 2, desc = "dc shirt", comment = "blue stripes, red silk", itemPrice = 6.0F
                }
            };

            data.items = items;

            return(data);
        }
コード例 #2
0
        public SlipData  PrintSlip(SlipData data)
        {
            //do pos stuff

            return(data);
        }