Document UI Code Development

Source: Internet
Author: User

1. After the UI project is constructed, open the generated UI project code, such as initializing the values of some fields


2. Line number setup for order detail lines, Order Basic action button prompt
Ufida. U9. Base.BaseBP.Agent.dll (Agent)
Ufida. U9. Base.BaseBP.Deploy.dll (Implementing weak types)
The DLL is in the Portal\applicationserver\libs directory, because the UI is called through the proxy and can only be implemented with a weak type




         Public voidafteronload () {stringParamwhere =NULL; //EnquiryPdformmessage.showconfirmdialog ( This. Page,"abc8b212-990a-40a6-81b3-28c50b0127d3","580","408", Title, Wpfindid.clientid, This.                        Btnfind, Paramwhere); Flexfieldhelper.setdescflexfield (NewDescflexfieldparameter[] {NewDescflexfieldparameter ( This. FlexFieldPicker0, This.            Model.homagiftdoc)}); Flexfieldhelper.setdescflexfield (NewDescflexfieldparameter[] {NewDescflexfieldparameter ( This. DataGrid8, This. DataGrid8.Columns.Count-1,"Descflexfield") }); //Turn on personalization//Ufida. U9. Ui.            PDHelper.PersonalizationHelper.SetPersonalizationEnable ((Basewebform) this, true); //Get prompt resource: whether to delete the current record            stringMessage =Pdresource.getdeleteconfirminfo (); //Bind Registration Popup dialog box to delete buttonPdformmessage.showconfirmdialog ( This. Page, message,"", This.            Btndelete); Pdformmessage.showconfirmdialog ( This. Page,"confirm Discard current record? ","", This.            Btncancel); //introduce a namespace://Ufida. U9. Base.BaseBP.Agent.dll//Ufida. U9. Base.BaseBP.Deploy.dll//Set the default line numberGetprofilevalueproxy bpobj =NewGetprofilevalueproxy (); Bpobj.profilecode="Syslineno"; Pvdtodata Pvtdodata=bpobj.do (); //Row Grid((Iautorowno) This. datagrid8.columns["RowNo"]). Sequence =true; ((Iautorowno) This. datagrid8.columns["RowNo"]). Sequencestep =Int32.Parse (Pvtdodata.profilevalue); ((Iautorowno) This. datagrid8.columns["RowNo"]). Sequencestart =Int32.Parse (Pvtdodata.profilevalue); }
Afteronload
         Public voidafteruimodelbinding () {//Set Document Status read-only((UFSoft.UBF.UI.ControlModel.IUIFieldBindingDataBindControl) This. GiftDocStatus150). ReadOnly =true; //setting line numbers is not editable             This. datagrid8.columns["RowNo"]. Enabled =false;        DISABLEBTN (); }        /// <summary>        ///control button Display/// </summary>        Private voiddisablebtn () {if(Ufida. U9. Ui. PDHelper.NavigateManager.IsModelPopup ( This) || Ufida. U9. Ui. PDHelper.NavigateManager.IsTitleLink ( This))            {                //This .                 Btnok.visible = true; //This . Btnclose.visible = true;                 This. btnlist.enabled =false; }            Else            {                //This .                Btnok.visible = false; //This . Btnclose.visible = false;                 This. btnlist.enabled =true; }            //when there is no data            if( This. Model.HomaGiftDoc.FocusedRecord.ID <0L)            {                 This. btnapprove.enabled =false;  This. btnundoapprove.enabled =false;  This. btnsubmit.enabled =false;  This. btndelete.enabled =false;  This. btncopy.enabled =false; }            Else            {                //according to the Document Status control button                Switch( This. Model.HomaGiftDoc.FocusedRecord.GiftDocStatus) { Case 0://Open                         This. btnapprove.enabled =false;  This. btnundoapprove.enabled =false;  This. btnsubmit.enabled =false;  This. btndelete.enabled =false;  Break;  Case 1://approved in                         This. btnapprove.enabled =true;  This. btnundoapprove.enabled =true;  This. btnsubmit.enabled =false;  This. btndelete.enabled =true;  Break;  Case 2://has been approved                         This. btnapprove.enabled =false;  This. btnundoapprove.enabled =false;  This. btnsubmit.enabled =false;  This. btndelete.enabled =false;  Break; }            }        }
Afteruimodelbinding Method

The basic function of the document has been developed.

Document UI Code Development

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.