CN109582347A - A kind of method and device obtaining front-end code - Google Patents

A kind of method and device obtaining front-end code Download PDF

Info

Publication number
CN109582347A
CN109582347A CN201811196769.XA CN201811196769A CN109582347A CN 109582347 A CN109582347 A CN 109582347A CN 201811196769 A CN201811196769 A CN 201811196769A CN 109582347 A CN109582347 A CN 109582347A
Authority
CN
China
Prior art keywords
business module
module
application program
version
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201811196769.XA
Other languages
Chinese (zh)
Other versions
CN109582347B (en
Inventor
崔航
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201811196769.XA priority Critical patent/CN109582347B/en
Publication of CN109582347A publication Critical patent/CN109582347A/en
Application granted granted Critical
Publication of CN109582347B publication Critical patent/CN109582347B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a kind of method and devices for obtaining front-end code, are related to a kind of field of computer technology, to solve the problems, such as that front-end code is difficult to safeguard in the prior art.This method is specifically included that according to system function, and the front-end code of application program is divided at least one business module;The corresponding service code of the business module is uploaded, and generates business module title, business module version number and the corresponding configuration information of the business module;The configuration file of target version application program is configured, the configuration file includes the target service module title and target service module release number of the target service module of the target version application program reference;According to the configuration file and the corresponding configuration information of the target service module, the front-end code of the target version application program is obtained, to safeguard the target version application program.The present invention is applied in application development and maintenance process.

Description

A kind of method and device obtaining front-end code
Technical field
The present invention relates to a kind of field of computer technology, more particularly to a kind of method and device for obtaining front-end code.
Background technique
In process of application development, it will usually develop the Component Gallery of oneself, the business function on upper layer is all based on group The exploitation of part library.Wherein business function can be divided into multiple modules, and the method for division is typically all independent as a business Closed loop, while not depending on other function module.
When an application program there are multiple versions to need to safeguard, the problem of code administration confusion will occur.Such as one A application program has 2 modules, modules A and module B, and they rely on infrastructure component library C to realize respective function.It is answering With 2.0 version of program, it is desirable that 1.0 versions of modules A, 2.0 versions of module B, 1.0 versions of infrastructure component library C;It is answering With 3.0 version of program, it is desirable that 2.0 versions of modules A, 3.0 versions of module B, 2.0 versions of infrastructure component library C.
If safeguarding the application program of multiple versions simultaneously, need in face of so complicated or even more complicated version combination, Very big puzzlement is then caused to developer.That is, all functional modules of same system all collect in code administration at this stage In in a project, when certain business modules are when particular version is unwanted, only pulled by whole system new Branch solves, when optional module becomes more, numbers of branches can exponentially growth, code is difficult to safeguard.
Summary of the invention
In view of this, the present invention provides a kind of method and device for obtaining front-end code, main purpose is to solve existing Front-end code is difficult to the problem of safeguarding in technology.
According to the present invention on one side, a kind of method for obtaining front-end code is provided, comprising:
According to system function, the front-end code of application program is divided at least one business module;
The corresponding service code of the business module is uploaded, and generates business module title, business module version number and institute State the corresponding configuration information of business module, the configuration information refer to when the business module realizes its corresponding system function according to Bad dependence business module title in addition to the business module and rely on business module version number;
The configuration file of target version application program is configured, the configuration file includes that the target version application program is drawn The target service module title and target service module release number of target service module;
According to the configuration file and the corresponding configuration information of the target service module, obtains the target version and answer With the front-end code of program, to safeguard the target version application program.
According to the present invention on one side, a kind of device for obtaining front-end code is provided, comprising:
Division unit, for according to system function, the front-end code of application program to be divided at least one business module;
Generation unit for uploading the corresponding service code of the business module, and generates business module title, business mould Block version number and the corresponding configuration information of the business module, the configuration information refer to that the business module realizes that its is corresponding The dependence business module title in addition to the business module that relies on when system function and rely on business module version number;
Configuration unit, for configuring the configuration file of target version application program, the configuration file includes the target The target service module title and target service module release number of the target service module of version application program reference;
Acquiring unit, for obtaining according to the configuration file and the corresponding configuration information of the target service module The front-end code of the target version application program, to safeguard the target version application program.
According to another aspect of the invention, a kind of storage medium is provided, at least one is stored in the storage medium can It executes instruction, the executable instruction makes processor execute the corresponding operation of method such as above-mentioned acquisition front-end code.
In accordance with a further aspect of the present invention, a kind of terminal is provided, comprising: processor, memory, communication interface and communication Bus, the processor, the memory and the communication interface complete mutual communication by the communication bus;
For the memory for storing an at least executable instruction, it is above-mentioned that the executable instruction executes the processor Obtain the corresponding operation of method of front-end code.
By above-mentioned technical proposal, technical solution provided in an embodiment of the present invention is at least had the advantage that
The present invention provides a kind of method and devices for obtaining front-end code, first, in accordance with system function, by application program Front-end code be divided at least one business module, then upload the corresponding service code of business module, and generate business mould Block title, business module version number and the corresponding configuration information of business module are reconfigured the configuration text of target version application program Part, it is last according to configuration file and the corresponding configuration information of target service module, obtain the front end of target version application program Code.Compared with prior art, the embodiment of the present invention is by the configuration information of business module, with the business module in configuration information Dependence business module title and rely on business module version number, reflect the incidence relation between business module, so as to unified pipe Reason and maintenance.Compared with prior art, the embodiment of the present invention passes through the configuration file of target version application program, acquisition and target The corresponding front-end code of version application program realizes management and maintenance to the front-end code of particular version application program.
The above description is only an overview of the technical scheme of the present invention, in order to better understand the technical means of the present invention, And it can be implemented in accordance with the contents of the specification, and in order to allow above and other objects of the present invention, feature and advantage can It is clearer and more comprehensible, the followings are specific embodiments of the present invention.
Detailed description of the invention
By reading the following detailed description of the preferred embodiment, various other advantages and benefits are common for this field Technical staff will become clear.The drawings are only for the purpose of illustrating a preferred embodiment, and is not considered as to the present invention Limitation.And throughout the drawings, the same reference numbers will be used to refer to the same parts.In the accompanying drawings:
Fig. 1 shows a kind of method flow diagram of acquisition front-end code of the offer of the embodiment of the present invention one;
Fig. 2 shows another method flow diagrams for obtaining front-end code provided by Embodiment 2 of the present invention;
Fig. 3 shows a kind of device block diagram of acquisition front-end code of the offer of the embodiment of the present invention three;
Fig. 4 shows another device block diagram for obtaining front-end code of the offer of the embodiment of the present invention four;
Fig. 5 shows a kind of structural schematic diagram of terminal of the offer of the embodiment of the present invention six.
Specific embodiment
Exemplary embodiments of the present disclosure are described in more detail below with reference to accompanying drawings.Although showing the disclosure in attached drawing Exemplary embodiment, it being understood, however, that may be realized in various forms the disclosure without should be by embodiments set forth here It is limited.On the contrary, these embodiments are provided to facilitate a more thoroughly understanding of the present invention, and can be by the scope of the present disclosure It is fully disclosed to those skilled in the art.
The front-end code write is transmitted to common terminal, preferably to safeguard front-end code, common terminal can To be computer or server.The embodiment of the invention provides a kind of methods for obtaining front-end code, as shown in Figure 1, the method Include:
101, according to system function, the front-end code of application program is divided at least one business module.
Application program refers to that it operates in user mode, can to complete the computer program of a certain or multinomial particular job To interact with user, there is visual user interface.Front-end code refers to that application program shows user interface and and user The required program code of interaction, is the subprogram of application program.System function refer to the function that application program can be shown or Person is able to respond the function of user's operation, for example, music playing process, is including show the displayings such as the lyrics, title of the song, singer System function also includes the system function for playing next, suspending the response user's operations such as broadcasting, increase broadcast sound volume.Foundation is answered With the difference of programming system function, the front-end code of application program is divided at least one business module.Business module be System function be it is one-to-one, in embodiments of the present invention, without limitation to the division mode of business module.
It further include technical foundation component in front-end code, technical foundation component is the necessary composition for realizing system function, In embodiments of the present invention, for easier description technique scheme, independent division is not done to technical foundation component, by technology base Plinth component regards a business module as.Technical foundation component include: infrastructure component module, user log in decision logic module and User exits decision logic module etc..Application program at least needs and technical foundation component constitutes basic system function, and two Regard technical foundation component as a business module in application, so front-end code includes at least a business module.
102, the corresponding service code of business module is uploaded, and generates business module title, business module version number and industry The corresponding configuration information of module of being engaged in.
Service code refers to the program code for realizing business module, when uploading service code, generates business module title With business module version number, business module version number increases with the increase for uploading service code number.Business module is matched Confidence breath refers to the dependence business module name in addition to business module relied on when business module realizes its corresponding system function Claim and rely on business module version number.Configuration information actual content is included in service code, passes through calling in service code The modes such as function or transmission function are identified.The configuration information mark in service code is searched, identification information is generated as matching Confidence breath.
103, the configuration file of target version application program is configured.
With the continuous operation of application program, the operation loophole of constantly repairing applications is needed, is needed constantly more The function of new application, therefore can be with the reparation or update of new colophon application program.In order to meet the difference of user Demand, the application program of each version require to safeguard, so target version application program, is in all versions of application program Particular version.Configuration file include target version application program reference target service module target service module title and Target service module release number.Wherein target service module belongs to business module, and quantity is at least 1, with target service mould Block title and target service module release number determine jointly.
104, according to configuration file and the corresponding configuration information of target service module, target version application program is obtained Front-end code, to safeguard target version application program.
Target service module needed for having write target version application program exactly in configuration file, and write in configuration information The dependence business module title of target service module is illustrated and relies on business module version number, hereby it is possible to find service code In target version application program front-end code.It modifies, compile, test and issues to front-end code, to safeguard target Version application program.
The present invention provides a kind of methods for obtaining front-end code, first, in accordance with system function, by the front end of application program Code is divided at least one business module, then uploads the corresponding service code of business module, and generate business module title, Business module version number and the corresponding configuration information of business module are reconfigured the configuration file of target version application program, finally According to configuration file and the corresponding configuration information of target service module, the front-end code of target version application program is obtained.With The prior art is compared, and the embodiment of the present invention is by the configuration information of business module, with the dependence of the business module in configuration information Business module title and dependence business module version number, reflect the incidence relation between business module, to be managed collectively and to tie up Shield.Compared with prior art, the embodiment of the present invention passes through the configuration file of target version application program, and acquisition is answered with target version With the corresponding front-end code of program, management and maintenance to the front-end code of particular version application program are realized.
The embodiment of the invention provides another methods for obtaining front-end code, as shown in Fig. 2, method includes:
201, according to system function, the front-end code of application program is divided at least one business module.
One application program can be realized multiple system functions, so could be divided into front-end code according to system function Multiple business modules.In the case where the function of application program is especially few, it is understood that there may be the situation of only one business module.? During actually writing application program, html, css, javascript, html5, css3, jQuery, ajax may be used, The language such as Bootstrap or Backbone write front-end code, and the language used in embodiments of the present invention to front-end code is not It limits.
202, the corresponding service code of business module is uploaded, and generates business module title, business module version number and industry The corresponding configuration information of module of being engaged in.
Service code is that partly or completely front-end code, service code are one-to-one with business module.Business The configuration information of module refers to the dependence industry in addition to business module relied on when business module realizes its corresponding system function Module title of being engaged in and dependence business module version number.Can not include Depending module in configuration information, also may include it is multiple according to Rely module.For example, front-end code is divided into business module A, business module B and business module C, wherein business module A is to rely on What business module B and business module C was realized, then business module B and business module C are in the configuration information of business module A Dependence business module title, the version number of business module B and business module C be all in the configuration information of business module A according to Rely business module version number.That is business module title is relied on, is one or more business module names in business module Claim, defines the effect of the business module with " dependence ".
203, the configuration file of target version application program is configured.
Configuration file includes the target service module title and mesh of the target service module of target version application program reference Mark business module version number.Configuration file is the basis for obtaining target version application code.Configuration file and application program Target version it is related, whether application program be also installed with client, and the version of installation application program is related.
Specifically, configuration target version application program configuration file, comprising: judge target version application program whether be Version is installed for the first time;If it is judged that be it is yes, then configure whole business module titles needed for target version application program and Corresponding version number is configuration file;If it is judged that be it is no, then according to application version has been installed, configure target version The configuration file of application program.It, can be by checking that client installed using journey when judging whether it is installation version for the first time Sequence judgement can be judged by checking the file of specific format that the application program can save, can also pass through and check client The log at end judges, installs the judgment method of version without limitation for the first time to judging whether it is in embodiments of the present invention.If Client is to install for the first time, then includes whole business module titles and corresponding version number in the application program of target version.Such as Fruit is not to install for the first time, and configuration file only includes the business module title for updating part and corresponding version number.Due to answering It is not necessarily identical as the version of its business module for being included with the target version of program, so in target version application program Business module requires logging modle title and corresponding version number.
Specifically, configuring the configuration file of target version application program according to application version has been installed, comprising: inspection Application version has been installed in survey, more new traffic module title and more new traffic module version compared with target version application program This number;By more new traffic module title and more new traffic module version number, it is configured to configuration file.
The module list for having installed business module in application version detected is obtained, the industry in obtaining target version The update module list for module of being engaged in.Based on update module list, business module in update module list and its right is judged Whether the version number answered is contained in module list, determines the business module and its corresponding version number if not including to update Business module and more new traffic module version number, if whether continuing next business module and its corresponding version number comprising if It is contained in module list, until business module all in update module list is all by judgement.After the completion of judging again, institute is obtained Some more new traffic module titles and more new traffic module version number.It will more new traffic module title and more new traffic module after people Version number is configured to configuration file.
204, according to pre-set sequence, the corresponding target service module of object module version number in configuration file is traversed, is looked into Look for the dependence business module of target service module.
Pre-set sequence can be the number order of business module, the service code upload sequence that can be business module, It can be putting in order for the title initial of business module, the arrangement mode of pre-set sequence do not done in embodiments of the present invention It limits.It traverses and searches according to pre-set sequence, the dependence business module in target service module.Target service module refers to target The business module for including in version application program.
The dependence business module for searching target service module, specifically includes: obtaining the corresponding target of target service module and matches Dependence business module title and dependence business module version number in confidence breath;It searches and relies on business module version number and dependence industry The corresponding dependence business module of module title of being engaged in;Obtain the secondary dependence business module name in the configuration information for relying on business module Title and secondary dependence business module version number, continue to search secondary dependence business module title and secondary dependence business module version Number corresponding secondary dependence business module, the configuration information until relying on business module are sky.
Obtain the secondary dependence business module title in the configuration information for relying on business module and secondary dependence business module After version number, method further include: if the secondary quantity for relying on business module title is greater than 1, according to depth-priority-searching method, Search the corresponding secondary dependence business module of secondary dependence business module title and secondary dependence business module version number.
Obtain the secondary dependence business module title in the configuration information for relying on business module and secondary dependence business module After version number, method further include: if the secondary quantity for relying on business module title is greater than 1, according to breadth first algorithm, Search the corresponding secondary dependence business module of secondary dependence business module title and secondary dependence business module version number.
Depth-priority-searching method and breadth first algorithm can calculate all dependence business modules of target service module, According to target service module and the relationship difference between business module is relied on, calculating speed is not also identical.
205, the corresponding industry of Depending module of the corresponding service code of set target service module and target service module Business code, generates the front-end code of target version application program.
In the service code of upload, the corresponding service code of target service module is searched, and search target service mould The corresponding service code of the Depending module of block, the service code that set search arrives generate the front end generation of target version application program Code.The modification to target version application program, compiling, test and publication may be implemented according to front-end code.
The present invention provides a kind of methods for obtaining front-end code, first, in accordance with system function, by the front end of application program Code is divided at least one business module, then uploads the corresponding service code of business module, and generate business module title, Business module version number and the corresponding configuration information of business module are reconfigured the configuration file of target version application program, finally According to configuration file and the corresponding configuration information of target service module, the front-end code of target version application program is obtained.With The prior art is compared, and the embodiment of the present invention is by the configuration information of business module, with the dependence of the business module in configuration information Business module title and dependence business module version number, reflect the incidence relation between business module, to be managed collectively and to tie up Shield.Compared with prior art, the embodiment of the present invention passes through the configuration file of target version application program, and acquisition is answered with target version With the corresponding front-end code of program, management and maintenance to the front-end code of particular version application program are realized.
Further, as the realization to method shown in above-mentioned Fig. 1, the embodiment of the present invention three provides a kind of acquisition front end The device of code, as shown in figure 3, the device includes:
Division unit 31, for according to system function, the front-end code of application program to be divided at least one business mould Block;
Generation unit 32 for uploading the corresponding service code of business module, and generates business module title, business module Version number and the corresponding configuration information of business module, configuration information refer to dependence when business module realizes its corresponding system function Dependence business module title in addition to business module and rely on business module version number;
Configuration unit 33, for configuring the configuration file of target version application program, configuration file includes that target version is answered With the target service module title and target service module release number of the target service module of program reference;
Acquiring unit 34, for obtaining target version according to configuration file and the corresponding configuration information of target service module The front-end code of application, to safeguard target version application program.
The present invention provides a kind of devices for obtaining front-end code, first, in accordance with system function, by the front end of application program Code is divided at least one business module, then uploads the corresponding service code of business module, and generate business module title, Business module version number and the corresponding configuration information of business module are reconfigured the configuration file of target version application program, finally According to configuration file and the corresponding configuration information of target service module, the front-end code of target version application program is obtained.With The prior art is compared, and the embodiment of the present invention is by the configuration information of business module, with the dependence of the business module in configuration information Business module title and dependence business module version number, reflect the incidence relation between business module, to be managed collectively and to tie up Shield.Compared with prior art, the embodiment of the present invention passes through the configuration file of target version application program, and acquisition is answered with target version With the corresponding front-end code of program, management and maintenance to the front-end code of particular version application program are realized.
Further, as the realization to method shown in above-mentioned Fig. 2, before the embodiment of the present invention four provides another acquisition The device for holding code, as shown in figure 4, the device includes:
The front-end code of application program is divided at least one business mould using according to system function by division unit 41 Block;
Generation unit 42 for uploading the corresponding service code of business module, and generates business module title, business module Version number and the corresponding configuration information of business module, configuration information refer to dependence when business module realizes its corresponding system function Dependence business module title in addition to business module and rely on business module version number;
Configuration unit 43, for configuring the configuration file of target version application program, configuration file includes that target version is answered With the target service module title and target service module release number of the target service module of program reference;
Acquiring unit 44, for obtaining target version according to configuration file and the corresponding configuration information of target service module The front-end code of application, to safeguard target version application program.
Further, configuration unit 43, comprising:
Judgment module 431, for judging whether target version application program is to install version for the first time;
Configuration module 432, for if it is judged that be it is yes, then configure whole business needed for target version application program Module title and corresponding version number are configuration file;
Configuration module 432, be also used to if it is judged that be it is no, then according to application version has been installed, configure target The configuration file of version application program.
Further, configuration module 432, comprising:
It checks submodule 4321, application version has been installed for detecting, compared with target version application program more New traffic module title and more new traffic module version number;
Configure submodule 4322, for will more new traffic module title and more new traffic module version number, be configured to configure File.
Further, acquiring unit 44, comprising:
Searching module 441, for traversing the corresponding target of object module version number in configuration file according to pre-set sequence Business module and the corresponding configuration information of target service module search the dependence business module of target service module;
Generation module 442, for gathering the dependence of the corresponding service code of target service module and target service module The corresponding service code of business module generates the front-end code of target version application program.
Further, searching module 441, comprising:
Acquisition submodule 4411, for obtaining the dependence business module title in target configuration information and relying on business module Version number;
Submodule 4412 is searched, relies on the dependence corresponding with business module title is relied on of business module version number for searching Business module;
Acquisition submodule 4411 is also used to obtain the secondary dependence business module name in the configuration information for relying on business module Title and secondary dependence business module version number, continue to search secondary dependence business module title and secondary dependence business module version Number corresponding secondary dependence business module, the configuration information until relying on business module are sky.
Further, method further include:
Submodule 4412 is searched, is also used to obtain the secondary dependence business module name in the configuration information for relying on business module After title and secondary dependence business module version number, if the secondary quantity for relying on business module title is greater than 1, according to depth Priority algorithm searches secondary dependence business module title and the corresponding secondary dependence business mould of secondary dependence business module version number Block.
Further, method further include:
Submodule 4412 is searched, is also used to obtain the secondary dependence business module name in the configuration information for relying on business module After title and secondary dependence business module version number, if the secondary quantity for relying on business module title is greater than 1, according to range Priority algorithm searches secondary dependence business module title and the corresponding secondary dependence business mould of secondary dependence business module version number Block.
The present invention provides a kind of devices for obtaining front-end code, first, in accordance with system function, by the front end of application program Code is divided at least one business module, then uploads the corresponding service code of business module, and generate business module title, Business module version number and the corresponding configuration information of business module are reconfigured the configuration file of target version application program, finally According to configuration file and the corresponding configuration information of target service module, the front-end code of target version application program is obtained.With The prior art is compared, and the embodiment of the present invention is by the configuration information of business module, with the dependence of the business module in configuration information Business module title and dependence business module version number, reflect the incidence relation between business module, to be managed collectively and to tie up Shield.Compared with prior art, the embodiment of the present invention passes through the configuration file of target version application program, and acquisition is answered with target version With the corresponding front-end code of program, management and maintenance to the front-end code of particular version application program are realized.
According to embodiments of the present invention five provide a kind of storage medium, and the storage medium is stored at least one executable finger It enables, the method which can be performed the acquisition front-end code in above-mentioned any means embodiment.
Fig. 5 shows a kind of structural schematic diagram for terminal that according to embodiments of the present invention six provide, present invention specific implementation Example does not limit the specific implementation of terminal.
As shown in figure 5, the terminal may include: processor (processor) 502, communication interface (Communications Interface) 504, memory (memory) 506 and communication bus 508.
Wherein: processor 502, communication interface 504 and memory 506 complete mutual lead to by communication bus 508 Letter.
Communication interface 504, for being communicated with the network element of other equipment such as client or other servers etc..
Processor 502 can specifically execute the correlation in above-mentioned data query embodiment of the method for executing program 510 Step.
Specifically, program 510 may include program code, which includes computer operation instruction.
Processor 502 may be central processor CPU or specific integrated circuit ASIC (Application Specific Integrated Circuit), or be arranged to implement the integrated electricity of one or more of the embodiment of the present invention Road.The one or more processors that terminal includes can be same type of processor, such as one or more CPU;It is also possible to Different types of processor, such as one or more CPU and one or more ASIC.
Memory 506, for storing program 510.Memory 506 may include high speed RAM memory, it is also possible to further include Nonvolatile memory (non-volatile memory), for example, at least a magnetic disk storage.
Program 510 specifically can be used for so that processor 502 executes following operation:
According to system function, the front-end code of application program is divided at least one business module;
The corresponding service code of the business module is uploaded, and generates business module title, business module version number and institute State the corresponding configuration information of business module, the configuration information refer to when the business module realizes its corresponding system function according to Bad dependence business module title in addition to the business module and rely on business module version number;
The configuration file of target version application program is configured, the configuration file includes that the target version application program is drawn The target service module title and target service module release number of target service module;
According to the configuration file and the corresponding configuration information of the target service module, obtains the target version and answer With the front-end code of program, to safeguard the target version application program.
Obviously, those skilled in the art should be understood that each module of the above invention or each step can be with general Computing device realize that they can be concentrated on a single computing device, or be distributed in multiple computing devices and formed Network on, optionally, they can be realized with the program code that computing device can perform, it is thus possible to which they are stored It is performed by computing device in the storage device, and in some cases, it can be to be different from shown in sequence execution herein Out or description the step of, perhaps they are fabricated to each integrated circuit modules or by them multiple modules or Step is fabricated to single integrated circuit module to realize.In this way, the present invention is not limited to any specific hardware and softwares to combine.
The foregoing is only a preferred embodiment of the present invention, is not intended to restrict the invention, for the skill of this field For art personnel, the invention may be variously modified and varied.All within the spirits and principles of the present invention, made any to repair Change, equivalent replacement, improvement etc., should all include within protection scope of the present invention.

Claims (10)

1. a kind of method for obtaining front-end code characterized by comprising
According to system function, the front-end code of application program is divided at least one business module;
The corresponding service code of the business module is uploaded, and generates business module title, business module version number and the industry Module of being engaged in corresponding configuration information, the configuration information refers to be relied on when the business module realizes its corresponding system function Dependence business module title and dependence business module version number in addition to the business module;
The configuration file of target version application program is configured, the configuration file includes that the target version application program is quoted The target service module title and target service module release number of target service module;
According to the configuration file and the corresponding configuration information of the target service module, the target version application journey is obtained The front-end code of sequence, to safeguard the target version application program.
2. the method as described in claim 1, which is characterized in that the configuration file of the configuration target version application program, packet It includes:
Judge whether the target version application program is to install version for the first time;
If it is judged that be it is yes, then configure whole business module titles needed for the target version application program and corresponding Version number is the configuration file;
If it is judged that be it is no, then according to having installed application version, configure the described of the target version application program Configuration file.
3. method according to claim 2, which is characterized in that the basis has installed application version, configures the mesh Mark the configuration file of version application program, comprising:
Detection is described to have installed application version, the more new traffic module title compared with the target version application program and More new traffic module version number;
By the more new traffic module title and the more new traffic module version number, it is configured to the configuration file.
4. the method as described in claim 1, which is characterized in that described according to the configuration file and the target service mould The corresponding configuration information of block obtains the front-end code of the target version application program, comprising:
According to pre-set sequence, the corresponding target service module of object module version number in the configuration file and described is traversed The corresponding configuration information of target service module searches the dependence business module of target service module;
The dependence business module for gathering the corresponding service code of the target service module and the target service module is corresponding Service code, generate the front-end code of the target version application program.
5. method as claimed in claim 4, which is characterized in that the dependence business module for searching target service module, packet It includes:
Obtain the dependence business module title and the dependence business in the corresponding configuration information of the target service module Module release number;
Search the dependence business module version number and the corresponding dependence business module of the dependence business module title;
Obtain the secondary dependence business module title in the configuration information for relying on business module and secondary dependence business module Version number, continues to search the secondary dependence business module title and the secondary dependence business module version number is corresponding secondary Business module is relied on, until the configuration information for relying on business module is sky.
6. method as claimed in claim 4, which is characterized in that described to obtain in the configuration information for relying on business module After secondary dependence business module title and secondary dependence business module version number, the method also includes:
If the secondary quantity for relying on business module title is greater than 1, according to depth-priority-searching method, search it is described it is secondary according to Rely business module title and the corresponding secondary dependence business module of the secondary dependence business module version number.
7. method as claimed in claim 4, which is characterized in that described to obtain in the configuration information for relying on business module After secondary dependence business module title and secondary dependence business module version number, the method also includes:
If the secondary quantity for relying on business module title is greater than 1, according to breadth first algorithm, search it is described it is secondary according to Rely business module title and the corresponding secondary dependence business module of the secondary dependence business module version number.
8. a kind of device for obtaining front-end code characterized by comprising
Division unit, for according to system function, the front-end code of application program to be divided at least one business module;
Generation unit for uploading the corresponding service code of the business module, and generates business module title, business module version This number configuration information corresponding with the business module, the configuration information refer to that the business module realizes its corresponding system The dependence business module title in addition to the business module that relies on when function and rely on business module version number;
Configuration unit, for configuring the configuration file of target version application program, the configuration file includes the target version The target service module title and target service module release number of the target service module of application program reference;
Acquiring unit, for according to the configuration file and the corresponding configuration information of the target service module, described in acquisition The front-end code of target version application program, to safeguard the target version application program.
9. a kind of storage medium, it is stored with an at least executable instruction in the storage medium, the executable instruction makes to handle Device is executed such as the method corresponding operation of any of claims 1-7 for obtaining front-end code.
10. a kind of terminal, comprising: processor, memory, communication interface and communication bus, the processor, the memory and The communication interface completes mutual communication by the communication bus;
The memory executes the processor as right is wanted for storing an at least executable instruction, the executable instruction Ask the corresponding operation of the method for acquisition front-end code described in any one of 1-7.
CN201811196769.XA 2018-10-15 2018-10-15 Method and device for acquiring front-end codes Active CN109582347B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811196769.XA CN109582347B (en) 2018-10-15 2018-10-15 Method and device for acquiring front-end codes

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811196769.XA CN109582347B (en) 2018-10-15 2018-10-15 Method and device for acquiring front-end codes

Publications (2)

Publication Number Publication Date
CN109582347A true CN109582347A (en) 2019-04-05
CN109582347B CN109582347B (en) 2024-04-02

Family

ID=65920075

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811196769.XA Active CN109582347B (en) 2018-10-15 2018-10-15 Method and device for acquiring front-end codes

Country Status (1)

Country Link
CN (1) CN109582347B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113098961A (en) * 2021-03-31 2021-07-09 北京自如信息科技有限公司 Component uploading method, device and system, computer equipment and readable storage medium
CN115454391A (en) * 2022-11-11 2022-12-09 零氪科技(北京)有限公司 Client, client construction method and device, electronic equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020124242A1 (en) * 2000-10-27 2002-09-05 Mcgoogan Sean Bi-endian libraries
CN102023983A (en) * 2009-09-11 2011-04-20 首都师范大学 Statistical space-time database and managing method thereof
CN102541851A (en) * 2010-12-10 2012-07-04 金蝶软件(中国)有限公司 Page modularity generation method and page modularity generation system
CN106843820A (en) * 2015-12-04 2017-06-13 阿里巴巴集团控股有限公司 Code process method and apparatus
US20170286077A1 (en) * 2016-03-31 2017-10-05 Ca, Inc. Interface definition language compiler with version reconciliation
CN108334334A (en) * 2018-03-07 2018-07-27 政采云有限公司 A kind of management relies on the method and system of packet version

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020124242A1 (en) * 2000-10-27 2002-09-05 Mcgoogan Sean Bi-endian libraries
CN102023983A (en) * 2009-09-11 2011-04-20 首都师范大学 Statistical space-time database and managing method thereof
CN102541851A (en) * 2010-12-10 2012-07-04 金蝶软件(中国)有限公司 Page modularity generation method and page modularity generation system
CN106843820A (en) * 2015-12-04 2017-06-13 阿里巴巴集团控股有限公司 Code process method and apparatus
US20170286077A1 (en) * 2016-03-31 2017-10-05 Ca, Inc. Interface definition language compiler with version reconciliation
CN108334334A (en) * 2018-03-07 2018-07-27 政采云有限公司 A kind of management relies on the method and system of packet version

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
蔡完锡;李叠;刘昊;褥震;董渊;: "Android系统非应用层软件的管理和优化", 计算机工程与设计, no. 05, 16 May 2016 (2016-05-16), pages 264 - 272 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113098961A (en) * 2021-03-31 2021-07-09 北京自如信息科技有限公司 Component uploading method, device and system, computer equipment and readable storage medium
CN113098961B (en) * 2021-03-31 2023-04-07 北京自如信息科技有限公司 Component uploading method, device and system, computer equipment and readable storage medium
CN115454391A (en) * 2022-11-11 2022-12-09 零氪科技(北京)有限公司 Client, client construction method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN109582347B (en) 2024-04-02

Similar Documents

Publication Publication Date Title
CN109086071A (en) A kind of method and server of management software version information
US10740093B2 (en) Advanced packaging techniques for improving work flows
US10540624B2 (en) System and method to automate provenance-aware application execution
KR101841751B1 (en) Callpath finder
US9811554B2 (en) Assisting query and querying
Scanniello et al. Clustering support for static concept location in source code
US10275240B2 (en) Dependency rank based on commit history
US8972936B2 (en) Version labeling in a version control system
US10169005B2 (en) Consolidating and reusing portal information
CN104423961B (en) A kind of method and system for generating test script
CN107038519B (en) Method and system for bidirectional data synchronization between systems
Dincturk et al. A model-based approach for crawling rich internet applications
CN106062751A (en) Managing data profiling operations related to data type
CN107122295B (en) Test case script generation method and device
US20130311517A1 (en) Representing Incomplete and Uncertain Information in Graph Data
US10558445B2 (en) Constructing and enhancing a deployment pattern
US10031936B2 (en) Database table data fabrication
CN106033388A (en) A test use case library management method and system
CN105279089A (en) Method and device for obtaining page element
CN109582347A (en) A kind of method and device obtaining front-end code
US9300522B2 (en) Information technology asset management
CN107608672A (en) A kind of UI module managements, UI module management methods and system
CN112000343B (en) Method and system for deploying multi-version services in Kubernetes by using Devops
CN109101242B (en) Data base automatic dispositions method and device
CN100507908C (en) Method and system for graph analysis and synchronization

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant