JSON API dynamic SQL generation method and system

A JSON and dynamic technology, applied in the field of software development, can solve the problems of duplication of code part and low development efficiency, and achieve the effect of improving development efficiency, reducing communication costs, and reducing code maintenance costs

Pending Publication Date: 2021-08-27
孔智科技(徐州)有限公司
View PDF0 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] (1) Adding, deleting, modifying and checking data, there is a lot of repetitive work in the code part, and different modules must write a new background API for processing, and the development efficiency is low

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • JSON API dynamic SQL generation method and system
  • JSON API dynamic SQL generation method and system
  • JSON API dynamic SQL generation method and system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0033] In order to make the technical means, creative features, goals and effects achieved by the present invention easy to understand, the present invention will be further elaborated below in conjunction with specific embodiments, but the following embodiments are only preferred embodiments of the present invention, not all. Based on the examples in the implementation manners, other examples obtained by those skilled in the art without making creative efforts all belong to the protection scope of the present invention. The experimental methods in the following examples, unless otherwise specified, are conventional methods, and the materials, reagents, etc. used in the following examples, unless otherwise specified, can be obtained from commercial sources.

[0034] The present invention provides a JSON API dynamic SQL generation method and system, specifically comprising the following steps:

[0035] (1) The front-end JSON data format convention, the background JSONAPI will p...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a JSON API dynamic SQL generation method and system, and the method comprises the following steps: (1) front-end JSON data format agreement: a background JSON API analyzes JSON data according to the JSON data format agreement; and (2) a front-end JS library packages a method for generating the JSON data, and when the front end triggers data persistence operation, such as newly adding, updating, querying and deleting, the data can be automatically generated according to the JSON agreement, and the data are sent to a background in an AJAX POST mode; (3) firstly, a unified API entry of the background analyzes the JSON data, verifies whether the token is legal or not, and correlates and queries a current user ID, a department ID, a role ID and the like; and (4) if the authentication is not passed, prompt information is returned and given. After the authentication is passed, the full path of the api method is analyzed, and if the full path of the api method is null, it is indicated that personalized logic processing does not exist, and only conventional operation is performed on the data.

Description

technical field [0001] The invention relates to the technical field of software development, in particular to a JSON API dynamic SQL generation method and system. Background technique [0002] With the development of Internet technology, JSON has gradually replaced XML as an efficient data exchange format. At present, the front end of many web applications will obtain the data of the HTML form, encapsulate it into JSON format, interact with the background API through AJAX, complete a series of data logic processing, and persist it into the database. [0003] At present, a software system usually involves multiple business modules. Generally speaking, the data of different business modules will be stored in different database tables. In addition to some personalized business logic preprocessing, data addition, deletion, modification The pattern is the same as that of querying these SQL operations, but the table name and field name are different, and the data is different. Ho...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G06F8/30G06F16/242G06F16/25
CPCG06F8/30G06F16/2433G06F16/252
Inventor 汪明陆永辉王广军张勇
Owner 孔智科技(徐州)有限公司
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products