Beispiel #1
0
        protected override void Export()
        {
            if (this.GridListSelectedCodes.Count == 0)
            {
                return;
            }

            DSErp _DS = new DSErp();

            this.IsBusy = true;
            var _ID = UReportID.ExcelFileName;
            var p   = _DS.GetV_Ware_Stocks_Base_LensForExportQuery(USysInfo.DBCode, USysInfo.LgIndex, _ID, this.GridListSelectedCodes);

            _DS.Load(p, geted =>
            {
                this.IsBusy = false;
                if (geted.HasError)
                {
                    MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg());
                    geted.MarkErrorAsHandled();
                    return;
                }
                ComOpenURL.Open(_ID);
            }, null);
        }
Beispiel #2
0
        protected override void ExportList()
        {
            string _ID  = "";
            var    _Str = this.getExportWhereCondition(out _ID);

            ERP.Web.DomainService.Erp.DSErp _DS = new Web.DomainService.Erp.DSErp();

            var p = _DS.GetV_Sale_Order_LensListQuery(USysInfo.DBCode, _Str);

            _DS.Load(p, geted =>
            {
                ComOpenURL.Open(_ID + ".xls");
            }, null);
        }
Beispiel #3
0
        protected override void Export()
        {
            if (this._ExportModel == 2 && this._SelectedItemTree.Count == 0)
            {
                return;
            }
            //if (this._ExportModel == 2 && this._SelectedItemTree.Count > 30)
            //{
            //    MessageErp.ErrorMessage(ErpUIText.Get("Err_MoreThan30"));
            //    return;
            //}

            List <string> _ExportItems = new List <string>();
            string        _Str         = "";

            if (this._ExportModel == 2)
            {
                this._SelectedItemTree.ForEach(it =>
                {
                    _Str = it.WhCode + it.LensCode + it.F_LR;
                    _ExportItems.Add(_Str);
                });
            }
            else
            {
                _Str = "WhCode";
                _ExportItems.Add(_Str);

                _Str = this.WhCodeSelected;
                _ExportItems.Add(_Str);
            }

            DSErp _DS = new DSErp();

            this.IsBusy = true;
            var _ID = UReportID.ExcelFileName;
            var p   = _DS.GetV_Ware_Report_Stocks_Lens_XYListExportQuery(USysInfo.DBCode, USysInfo.LgIndex, _ID, _ExportItems);

            _DS.Load(p, geted =>
            {
                this.IsBusy = false;
                if (geted.HasError)
                {
                    MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg());
                    geted.MarkErrorAsHandled();
                    return;
                }
                ComOpenURL.Open(_ID);
            }, null);
        }
Beispiel #4
0
        protected override void Export2()
        {
            ERP.Web.DomainService.Common.DSExportToFactory _DS = new ERP.Web.DomainService.Common.DSExportToFactory();
            var _bID = UID.ID;

            Messenger.Default.Send <string>("", USysMessages.FunLoadBegin);
            _DS.Export(USysInfo.DBCode, USysInfo.LgIndex, USysInfo.UserCode, this.GridListSelectedCodes, geted =>
            {
                Messenger.Default.Send <string>("", USysMessages.FunLoadEnd);
                if (geted.HasError)
                {
                    MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg());
                    geted.MarkErrorAsHandled();
                    return;
                }
                var _file = geted.Value.ToString();
                this.Load();
                ComOpenURL.Open(_file);
            }, null);
        }
Beispiel #5
0
        protected override void Export()
        {
            DSErp _DS = new DSErp();

            this.IsBusy = true;
            //var _ID = UReportID.ExcelFileName;
            var _ID = this._DC.BCode + ".xls";
            var p   = _DS.GetV_Sale_Order_PDBillForExportQuery(USysInfo.DBCode, USysInfo.LgIndex, _ID, this.CurrentIDCode);

            _DS.Load(p, geted =>
            {
                this.IsBusy = false;
                if (geted.HasError)
                {
                    MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg());
                    geted.MarkErrorAsHandled();
                    return;
                }
                ComOpenURL.Open(_ID);
            }, null);
        }
Beispiel #6
0
        protected override void Export()
        {
            List <string> _ExportItems = new List <string>();

            _ExportItems.Add(this.CurrentIDCode);
            DSErp _DS = new DSErp();

            this.IsBusy = true;
            var _ID = UReportID.ExcelFileName;
            var p   = _DS.GetV_Ware_Stocks_Base_LensForExportQuery(USysInfo.DBCode, USysInfo.LgIndex, _ID, _ExportItems);

            _DS.Load(p, geted =>
            {
                this.IsBusy = false;
                if (geted.HasError)
                {
                    MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg());
                    geted.MarkErrorAsHandled();
                    return;
                }
                ComOpenURL.Open(_ID);
            }, null);
        }
Beispiel #7
0
 private void ExecuteCmdGetAttachment()
 {
     ComOpenURL.Open(USysInfo.DBCode + this.CurrentIDCode + "Attachment1.pdf", "Import/Attachment/Base/Lens");
 }