Esempio n. 1
0
        private void InitViewBag(QuotationComplex info)
        {
            // 倉庫
            ViewBag.WareHouseList =
                new SelectList(this._GlobalService.GetWarehouseList(), "Key", "Value", info?.Quotation.WarehouseID);

            // 公司
            ViewBag.CompanyList =
                new SelectList(this._GlobalService.GetCustomerList(), "Value", "Display", info?.Quotation?.CustomerID);

            // 運送方式
            ViewBag.ShippingModeList =
                new SelectList(this._GlobalService.GetShippingModeList(), "Key", "Value", null);

            // 審核結果
            ViewBag.ResultTypeList =
                new SelectList(ResultType.GetAll(), "value", "Text", info?.Quotation.Result);

            // 報價人
            //ViewBag.UserList =
            //   new SelectList(this._GlobalService.GetUserList(), "Value", "Display", info?.Quotation.QuotePerson);
            ViewBag.UserList =
                new SelectList(this._GlobalService.GetUserList(), "Value", "Display", info?.Quotation.QuotePerson);


            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Quotation.Activate);
        }
Esempio n. 2
0
        private void InitViewBag(BankDeposit info)
        {
            ViewBag.BankAccountList =
                new SelectList(this._GlobalService.GetBankAccountList(), "Value", "Text", null);

            HashSet <MyTextValue> sort = new HashSet <MyTextValue>();

            sort.Add(new MyTextValue {
                Text = "票據號碼", Value = "CheckNum", Disabled = false
            });
            sort.Add(new MyTextValue {
                Text = "收(開)票日期", Value = "DealDate", Disabled = false
            });
            sort.Add(new MyTextValue {
                Text = "到期日期", Value = "ExpiryDate", Disabled = false
            });

            ViewBag.SortList = new SelectList(sort, "Value", "Text", null);


            ViewBag.DepositSummaryList =
                new SelectList(this._GlobalService.GetDepositSummaryList(), "Text", "Text", null);

            ViewBag.CheckStatusList =
                new SelectList(this._GlobalService.GetCheckStatusList(), "Value", "Text", null);

            ViewBag.DealItemList =
                new SelectList(this._GlobalService.GetDealItemList(), "Value", "Text", null);

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Activate);
        }
Esempio n. 3
0
        private void InitViewBag(Receipt info)
        {
            ViewBag.BankAccountList =
                new SelectList(this._GlobalService.GetBankAccountList(), "Value", "Text", info?.BankAccountID);

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Activate);
        }
Esempio n. 4
0
        private void InitViewBag(CompanyViewModel info)
        {
            ViewBag.CompanyKindList =
                new SelectList(CompanyType.GetAll(), "Value", "Text", info?.CompanyKindID);

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Activate);
        }
Esempio n. 5
0
        private void InitViewBag(Code info)
        {
            ViewBag.CodeTypeList =
                new SelectList(CodeType.GetAll(), "value", "Text", info?.CodeType);

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Activate);
        }
Esempio n. 6
0
        private void InitViewBag(InquiryComplex info)
        {
            ViewBag.Token = _SingletonTokenService.GetToken();

            // 幣別
            ViewBag.CurrencyKindList =
                new SelectList(this._GlobalService.GetCurrencyKindList(), "Key", "Value", info?.Inquiry.CurrencyID);

            // 公司
            ViewBag.CompanyList =
                new SelectList(this._GlobalService.GetSupplierList(), "Value", "Display", info?.Inquiry?.CompanyID);

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Inquiry.Activate);
        }
Esempio n. 7
0
        private void InitViewBag(PurchaseComplex info)
        {
            // 倉庫
            ViewBag.CurrencyKindList =
                new SelectList(this._GlobalService.GetCurrencyKindList(), "Key", "Value", info?.Purchase.CurrencyID);

            // 倉庫
            ViewBag.WareHouseList =
                new SelectList(this._GlobalService.GetWarehouseList(), "Key", "Value", info?.Purchase.WarehouseID);

            // 公司供應商廠商名稱
            ViewBag.CompanyList =
                new SelectList(this._GlobalService.GetSupplierList(), "Value", "Display", info?.Purchase?.SupplierID);


            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Purchase.Activate);
        }
Esempio n. 8
0
        private void InitViewBag(News info)
        {
            var newsTypeList = this._GlobalService.GetNewsTypeList();

            ViewBag.NewsTypeList =
                new SelectList(newsTypeList, "Value", "Text",
                               info?.NewsTypeID as object,
                               newsTypeList.Where(x => x.Disabled == true).Select(x => x.Value));


            var departmentList = this._GlobalService.GetDepartmentList();

            ViewBag.DepartmentList =
                new SelectList(departmentList, "Value", "Text",
                               info?.DepartmentID as object,
                               departmentList.Where(x => x.Disabled == true).Select(x => x.Value).ToList());

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.SetTop);
        }
Esempio n. 9
0
        private void InitViewBag(SalesComplex info)
        {
            // 倉庫
            ViewBag.WareHouseList =
                new SelectList(this._GlobalService.GetWarehouseList(), "Key", "Value", info?.Sales.WarehouseID);

            // 公司
            ViewBag.CompanyList =
                new SelectList(this._GlobalService.GetCustomerList(), "Value", "Display", info?.Sales?.CustomerID);

            // 運送方式
            ViewBag.ShippingModeList =
                new SelectList(this._GlobalService.GetShippingModeList(), "Key", "Value", null);

            ViewBag.MultiWareHouseList =
                new SelectList(this._GlobalService.GetWarehouseList(), "Key", "Value", null);

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Sales.Activate);
        }
Esempio n. 10
0
        private void InitViewBag(User info)
        {
            // 職稱
            var titleList = this._GlobalService.GetTitleList();

            ViewBag.TitleList =
                new SelectList(titleList, "Value", "Text",
                               info?.TitleID as object,
                               titleList.Where(x => x.Disabled == true).Select(x => x.Value));
            // 權限
            var quotationLevelList = this._GlobalService.GetQuotationLevelList();

            ViewBag.QuotationLevelList =
                new SelectList(quotationLevelList, "Value", "Text",
                               info?.QuotationLevelID as object,
                               quotationLevelList.Where(x => x.Disabled == true).Select(x => x.Value));

            // 權限
            ViewBag.PermissionList =
                new SelectList(Permission.GetAll(), "value", "Text", info?.PermissionID);

            var departmentList = this._GlobalService.GetDepartmentList();

            ViewBag.DepartmentList =
                new SelectList(departmentList, "Value", "Text",
                               info?.DepartmentID as object,
                               departmentList.Where(x => x.Disabled == true).Select(x => x.Value).ToList());

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Activate);


            var userList = this._GlobalService.GetUserList()
                           .Where(x => x.Value != info?.UserID);

            ViewBag.UserList =
                new SelectList(userList, "Value", "Text",
                               info?.SupervisorID as object,
                               userList.Where(x => x.Disabled == true).Select(x => x.Value));
        }
Esempio n. 11
0
        private void InitViewBag(Product info)
        {
            // 單位
            var unitList = this._GlobalService.GetUnitKindList();

            ViewBag.UnitKindList =
                new SelectList(unitList, "Value", "Text",
                               info?.UnitID as object,
                               unitList.Where(x => x.Disabled == true).Select(x => x.Value).ToList());

            // 產品類別
            var productKindList = this._GlobalService.GetProductKindList();

            ViewBag.ProductKindList =
                new SelectList(productKindList, "Value", "Text",
                               info?.KindID as object,
                               productKindList.Where(x => x.Disabled == true).Select(x => x.Value).ToList());

            // 品牌 此處只顯示品牌代碼
            var brandList = this._GlobalService.GetBrandList();

            ViewBag.BrandList =
                new SelectList(brandList, "Value", "Value",
                               info?.BrandID as object,
                               brandList.Where(x => x.Disabled == true).Select(x => x.Value).ToList());

            // 公司
            ViewBag.CompanyList =
                new SelectList(this._GlobalService.GetSupplierList(), "Value", "Display", info?.SupplierID);

            //// 產品名
            //ViewBag.ProductsNameList =
            //  new SelectList(this._GlobalService.GetProductList(), "Value", "Display", info?.SupplierID);

            ViewBag.YseNoList =
                new SelectList(YesNo.GetAll(), "value", "Text", info?.Activate);
        }
Esempio n. 12
0
 private void InitViewBag(Brand info)
 {
     ViewBag.YseNoList =
         new SelectList(YesNo.GetAll(), "value", "Text", info?.Activate);
 }