User Tools

Site Tools


ra:oldfrontend

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
ra:oldfrontend [2018/10/16 12:42]
koubel [DevExpress MVC]
ra:oldfrontend [2018/12/04 15:03] (current)
koubel [React components]
Line 39: Line 39:
  
 Example: bug in fuel administration for more tabs with fuel types [[https://​protank.visualstudio.com/​_git/​PD/​pullrequest/​1492|PR]] Example: bug in fuel administration for more tabs with fuel types [[https://​protank.visualstudio.com/​_git/​PD/​pullrequest/​1492|PR]]
 +
 +Event when the controls are initialized - [[https://​protank.visualstudio.com/​_git/​PD?​path=%2FApplication%2FPSASWeb%2FPD.Master&​version=GBmaster&​line=247&​lineStyle=plain&​lineEnd=248&​lineStartColumn=1&​lineEndColumn=1|Webforms master page]]
  
 ====== DevExpress MVC ====== ====== DevExpress MVC ======
Line 50: Line 52:
  
 Event when the controls are initialized - [[https://​protank.visualstudio.com/​_git/​PD?​path=%2FApplication%2FPSASWeb%2FViews%2FShared%2F_PD.cshtml&​version=GBmaster&​line=336&​lineStyle=plain&​lineEnd=337&​lineStartColumn=1&​lineEndColumn=1|MVC master page]] Event when the controls are initialized - [[https://​protank.visualstudio.com/​_git/​PD?​path=%2FApplication%2FPSASWeb%2FViews%2FShared%2F_PD.cshtml&​version=GBmaster&​line=336&​lineStyle=plain&​lineEnd=337&​lineStartColumn=1&​lineEndColumn=1|MVC master page]]
 +
 +====== Resources, translations,​ language versions ======
 +
 +Webforms and MVC frontends uses series of //resx// files for languages strings and translations.
 +For Webforms, each control can have meta:​resoucekey attribute, which is key into resx file. 
 +
 +Be aware, that resx files can be transformed via xdt transformations. e.g. [[https://​protank.visualstudio.com/​PD/​_git/​PD?​path=%2FApplication%2FConfiguration%2Fpsas%2FResources%2FModules%2FL11%2FShifts%2FApp_LocalResources%2FCollectionsGridControl.ascx.cs-CZ.xdt&​version=GBmaster&​_a=contents|Application/​Configuration/​psas/​Resources/​Modules/​L11/​Shifts/​App_LocalResources/​CollectionsGridControl.ascx.cs-CZ.xdt]]. These are normally called only for build and deploy process on CI. Transformation isn't triggered for local development,​ so these messages aren't translated when application is developed locally.
 +
 +
 +https://​protank.visualstudio.com/​_git/​PD/​pullrequest/​1677?​_a=files
 ====== React in old PD1 application ====== ====== React in old PD1 application ======
  
Line 71: Line 83:
 See some react related tasks for more information and examples. See some react related tasks for more information and examples.
  
 +====== React components ======
 +Grid
 +
 +important props
 +  * rows - list of objects - rows. For columns, see later
 +  * updateHeightInModal - necessary for showing grid in modal
 +  * customRowSettings.customButtons - array for the settings for special row properties, mostly for popup menu
 +
 +<​code>​
 +<​DataGrid.Grid
 +            key={"​id"​}
 +            rows={this.workPlanStore.sewerCollections}
 +            showRowSelectionCheckbox={true}
 +            selectedRowKey={"​id"​}
 +            isLoading={false}
 +            showFilterRow={true}
 +            // list of rows necessary, without this, grid doesn'​t work either
 +            selectedRowValues={this.workPlanStore.selectedRowsIds.slice()}
 +            // necessary for show grid in modal
 +            updateHeightInModal={true}
 +            onRowsSelected={(x) => this.workPlanStore.setSelectedRows(x)}
 +            // settings for row popup menu which is available at the end of row on ... 
 +            customRowSettings={{
 +                visible: true,
 +                displayEdit:​ false,
 +                displayDelete:​ false,
 +                customButtons:​ [
 +                   { name: "​planning",​ title: localize("​sewerDrainGrid.planning"​),​ icon: ""​ },
 +                   { name: "​detail",​ title: localize("​sewerDrainGrid.workPlanDetail"​),​ icon: ""​ },
 +                ],
 +                handleButtonClick:​ this.handleRowButtonClick
 +            }}
 +            onRowsDeselected={(x) => this.workPlanStore.setDeselectedRows(x)}
 +        >
 +
 +        </​DataGrid.Grid>​
 +</​code>​
 +
 +Stores and observables
 ====== Internet Explorer Support ====== ====== Internet Explorer Support ======
  
ra/oldfrontend.1539686524.txt.gz ยท Last modified: 2018/10/16 12:42 by koubel