Method for realizing different product release modes through rich text editing

文档序号:1113334 发布日期:2020-09-29 浏览:7次 中文

阅读说明:本技术 一种通过富文本编辑实现不同产品发布方式的方法 (Method for realizing different product release modes through rich text editing ) 是由 聂浩锋 崔乐乐 姚民伟 单震 宋设 于 2020-06-28 设计创作,主要内容包括:本发明提供一种通过富文本编辑实现不同产品发布方式的方法,属于前后端交互技术领域,本发明主要分为两个部分,在传统运营页面通过设计按钮为按钮复制方法选择传统发布模式或者新版发布模式,新版发布模式内嵌富文本编辑器;对不同的产品或者类型针对个性化进行不同的编辑解决.通过在开发页面选择单一模式和丰富模式来转变传统模式与富文本编辑模式,通过内嵌的富文本编辑可以随意修改字体,颜色,插入图片等功能性个性化要求。(The invention provides a method for realizing different product release modes through rich text editing, which belongs to the technical field of front-end and back-end interaction, and is mainly divided into two parts, wherein a traditional release mode or a new release mode is selected for a button copying method on a traditional operation page through designing buttons, and a rich text editor is embedded in the new release mode; the traditional mode and the rich text editing mode are changed by selecting a single mode and a rich mode on a development page, and the font, the color, the inserted picture and other functional personalized requirements can be modified at will by the embedded rich text editing.)

1. A method for realizing different product release modes through rich text editing is characterized in that,

the method mainly comprises two parts, namely 1) selecting a traditional release mode or a new release mode for a button copying method through designing buttons on a traditional operation page, and 2) embedding a rich text editor in the new release mode.

2. The method of claim 1,

a traditional release mode or a new release mode is selected for a button copying method by designing a button, and the method comprises the following steps:

and endowing a unique ID on a style for displaying the user access amount on a jsp page, filling a preloading configuration in a corresponding js file, and directly displaying the access amount data in the database when loading the webpage by applying the ajax technology.

3. The method of claim 2,

by using a distributed method, a mapper mapping file and a corresponding interface are established in a supporting project, and corresponding fields of a corresponding database are updated in the mapper file through an sql language.

4. The method of claim 3,

creating a functional interface file in an intermediate dubbo project, packaging the functional interface file, respectively deploying the functional interface file in a support project and a local project, realizing the interface in the support project to obtain the ID of a corresponding page, updating the access amount +1 of the page, and storing the page in a database to finish updating.

5. The method of claim 4,

add consumer-provider configurations to service-contexturContext. xml and dubbo-provider. xml files at the same time as the local item and the support item.

6. The method of claim 5,

and adding the call of the new interface in the DataUtils tool class, calling the interface at a controller layer, realizing the interface, obtaining the data of the access amount in the database and +1 the data, and automatically updating the database content by the background because the interface is called so that the access amount is increased and the front-end display is consistent with the database data.

7. The method of claim 1,

the embedded rich text editor in the new release mode comprises the following steps:

(1) firstly, compiling two operation modes through codes on a jsp page, classifying the operation modes through a Div module Id, and separating a traditional mode and a new edition rich text editing mode;

(2) the selection mode button is subjected to ID arrangement, when an old edition is selected for release, the content of the rich text editor in the new edition mode is hidden, and when the new edition is selected for release, the rich text editor is displayed, and the traditional mode of the old edition is hidden;

(3) and when the requirement is written in a mode which is not in accordance with the requirement of the old edition, selecting a new edition release mode and writing the new edition release mode by using rich text editing.

8. The method of claim 7,

the rich text editor can select a common text mode or an HTML tag code format, and can also select fonts, word sizes, colors, inserted pictures and other language codes.

Technical Field

The invention relates to a front-end and back-end interaction technology, in particular to a method for realizing different product release modes through rich text editing.

Background

A Rich Text Editor, called RTE for short, is a Text Editor that can be embedded in a browser and is what you see is what you get. Unlike text editors, programmers can go to the web to download free text editors embedded in their own web sites or programs.

The rich text editor is widely applied to online publishing of the Internet, and is used for information entry and display of daily mails, articles, blogs, news, diaries and the like. With the popularization of the internet, the network editor is used for inputting text information to realize information editing, displaying, publishing and browsing, and the text information becomes an indispensable important component in daily life of people.

Sometimes, the mode of the back-end operation mode is single, the front-end page needs to have rich styles and patterns, different modes are displayed in different modes, the content of a specific project is difficult to search, the working efficiency is low, and the problem cannot be solved at present.

Disclosure of Invention

In order to solve the technical problems, the invention provides a method for realizing different product release modes through rich text editing, a rich text editor is used for enabling a page to have multiple choices during display, different contents are written in the rich text editor to make different displays on the page, the page is more rich and diversified, and the identification and the search are convenient.

The technical scheme of the invention is as follows:

a method for realizing different product release modes through rich text editing mainly comprises two parts, namely 1) selecting a traditional release mode or a new release mode for a button copying method through a design button on a traditional operation page, and 2) embedding a rich text editor in the new release mode.

Further, in the above-mentioned case,

a traditional release mode or a new release mode is selected for a button copying method on a traditional operation page by designing buttons, and the method comprises the following steps:

endowing a unique ID on a style for displaying the user access amount on a jsp page, filling in a preloading configuration in a corresponding js file, and directly displaying the access amount data in a database when a webpage is loaded by applying an ajax technology;

by using a distributed method, a mapper mapping file and a corresponding interface are established in a supporting project, and corresponding fields of a corresponding database are updated in the mapper file through an sql language;

creating a functional interface file in an intermediate dubbo project, packaging the functional interface file, respectively deploying the functional interface file in a support project and a local project, realizing the interface in the support project to obtain the ID of a corresponding page, updating the access amount +1 of the page, and storing the page in a database to finish updating;

adding consumer provider configurations to service-provider context.xml and dubbo-provider.xml files simultaneously in the local project and the support project;

and adding the call of the new interface in the DataUtils tool class, calling the interface at a controller layer, realizing the interface, obtaining the data of the access amount in the database and +1 the data, and automatically updating the database content by the background because the interface is called so that the access amount is increased and the front-end display is consistent with the database data.

Further, in the above-mentioned case,

the embedded rich text editor in the new release mode comprises the following steps:

(1) firstly, compiling two operation modes through codes on a jsp page, classifying the operation modes through a Div module Id, and separating a traditional mode and a new edition rich text editing mode;

(2) the selection mode button is subjected to ID arrangement, when an old edition is selected for release, the content of the rich text editor in the new edition mode is hidden, and when the new edition is selected for release, the rich text editor is displayed, and the traditional mode of the old edition is hidden;

(3) and when the requirement is written in a mode which is not in accordance with the requirement of the old edition, selecting a new edition release mode, and performing personalized writing on the new edition release mode by using rich text editing.

The rich text editor can select a common text mode or an HTML tag code format, and can also select fonts, word sizes, colors, even pictures and other language codes.

The invention has the advantages that

(1) The invention adopts the reference of the rich text editor, so that the webpage is not single any more, and the content is more rich.

(2) The invention develops different modes of the same page by selecting different modes, so that the page has higher usability and better compatibility.

(3) The invention uses rich functions of the rich text editor, so that the edited content is rich and diversified and can be modified easily.

Detailed Description

In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer and more complete, the technical solutions in the embodiments of the present invention are described below, it is obvious that the described embodiments are a part of the embodiments of the present invention, but not all embodiments, and all other embodiments obtained by a person of ordinary skill in the art without creative efforts based on the embodiments of the present invention belong to the protection scope of the present invention.

The invention relates to front-end page and rich text editing, which interacts with a database through a back-end SpringMVC and provides high-efficiency brief introduction when a page is accessed.

The method is mainly divided into two parts, a traditional release mode or a new release mode is selected by a method of designing buttons as buttons on a traditional operation page, and a rich text editor is embedded in the new release mode.

The first part is a part of the first part,

(1) firstly, endowing a unique ID on a style for displaying user access amount on a jsp page, then filling in preloading configuration in a corresponding js file, and at the moment, applying ajax technology, the method can update part of the web pages and realize asynchronous update on the web pages under the condition of not reloading the whole web pages. The access data in the database is intended to be displayed directly when the web page is loaded.

(2) By using a distributed method, a mapper mapping file and a corresponding interface are established in a supporting project, and corresponding fields of a corresponding database are updated in the mapper file through an sql language.

(3) Creating a functional interface file in an intermediate dubbo project, packaging the functional interface file, respectively deploying the functional interface file in a support project and a local project, realizing the interface in the support project to obtain the ID of a corresponding page, updating the access amount +1 of the page, and storing the page in a database to finish updating.

(4) Consumer provider configurations are added to service-consumercontext.xml and dubbo-provider.xml files at the same time as the local item and the support item to ensure the integrity and operability of the item.

(5) And adding the call of the new interface in the DataUtils tool class, calling the interface at a controller layer, realizing the interface, obtaining the data of the access amount in the database and +1 the data, and automatically updating the database content by the background because the interface is called so that the access amount is increased and the front-end display is consistent with the database data.

In the second part of the first part of the second part,

(1) firstly, two operation modes are written in a jsp page through codes, and are classified by a Div module Id, so that a traditional mode and a new edition rich text editing mode are separated.

(2) And performing ID arrangement on the selection mode button, hiding the content of the rich text editor in the new version mode when the old version is selected for release, and revealing the rich text editor to hide the traditional mode of the old version when the new version is selected for release.

(3) When the requirements of people do not conform to the writing mode required by the old edition and some personalized requirements are difficult to realize, a new edition publishing mode can be selected and personalized writing can be carried out by rich text editing.

(4) The rich text editor can select a common text mode or an HTML tag code format, and can also select fonts, word sizes, colors, even insert pictures and other language codes and the like to meet different personalized requirements.

The invention can realize the development of different products through the rich text editor, and reduce the repeated redundancy of codes. Different rich text editors with rich citation are adopted, and different personalized requirements can be realized according to different requirements.

The above description is only a preferred embodiment of the present invention, and is only used to illustrate the technical solutions of the present invention, and not to limit the protection scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

5页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:基于AI的语段编辑方法、装置、设备以及存储介质

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!