Control data configuration method and computer readable storage medium
A technology of data configuration and storage medium, applied in the field of data processing, can solve the problems of low efficiency and a lot of labor costs, and achieve the effect of convenient reuse, improve development efficiency, and reduce repeated development.
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0051] Please refer to figure 2 , Embodiment 1 of the present invention is: a control data configuration method, comprising the following steps:
[0052] S1: define a view data model (ViewModel) of the control, and the view data model includes fields for displaying data of the control.
[0053] S2: preset the field mapping relationship of the data source, the field mapping relationship is the mapping relationship between the fields in the view data model and the data fields in the data source.
[0054] S3: Build a data source model of the network data source, the data source model includes the network address of the network data source and the field mapping relationship of the network data source, further, the network address may be a URL address with access parameters.
[0055] S4: Judging whether the data in the data source of the control is directly given static data, that is, judging whether the data source of the control is a static data source, if yes, go to step S5, i...
Embodiment 2
[0069] This embodiment is a specific application scenario of Embodiment 1.
[0070] Suppose you want to develop a carousel control, which can be used to display the carousel of the news or the carousel of the advertising system, then define the view data model (ViewModel) of the control as:
[0071] {
[0072] id: "Data ID",
[0073] url: "image URL",
[0074] title: "title text",
[0075] click_url: "The jump address after clicking"
[0076]}
[0077] The view data model contains four fields.
[0078] Assuming that the data in the data source of the advertising system includes the advertising ID, the URL of the advertising banner, the advertising slogan and the product URL, the field mapping relationship of the data source is:
[0079] Data ID → Advertising ID
[0080] Image URL→Ad Banner URL
[0081] Title Text → Advertising Slogan
[0082] After clicking, jump to the address → product URL
[0083] Assuming that the data of the advertising system is dynamic data acc...
Embodiment 3
[0102] This embodiment is a computer-readable storage medium corresponding to the above-mentioned embodiments, on which a computer program is stored, and when the program is executed by a processor, the following steps are implemented:
[0103] Defining a view data model of the control, the view data model including fields for displaying data of the control;
[0104] Preset the field mapping relationship of the data source, the field mapping relationship is the mapping relationship between the fields in the view data model and the data fields in the data source;
[0105] According to the field mapping relationship of a data source, the data of the data field corresponding to the field in the view data model in the data source is obtained, and returned to the control.
[0106] Further, the "acquire the data of the data field corresponding to the field in the view data model in the data source according to the field mapping relationship of a data source, and return it to the con...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com