CN108803894A - A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates - Google Patents

A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates Download PDF

Info

Publication number
CN108803894A
CN108803894A CN201810589282.1A CN201810589282A CN108803894A CN 108803894 A CN108803894 A CN 108803894A CN 201810589282 A CN201810589282 A CN 201810589282A CN 108803894 A CN108803894 A CN 108803894A
Authority
CN
China
Prior art keywords
phonetic
pinying
trade name
chinese character
simplified form
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.)
Pending
Application number
CN201810589282.1A
Other languages
Chinese (zh)
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.)
Zhuhai Guangyuan Pharmaceutical Co Ltd
Original Assignee
Zhuhai Guangyuan Pharmaceutical 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 Zhuhai Guangyuan Pharmaceutical Co Ltd filed Critical Zhuhai Guangyuan Pharmaceutical Co Ltd
Priority to CN201810589282.1A priority Critical patent/CN108803894A/en
Publication of CN108803894A publication Critical patent/CN108803894A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/02Input arrangements using manually operated switches, e.g. using keyboards or dials
    • G06F3/023Arrangements for converting discrete items of information into a coded form, e.g. arrangements for interpreting keyboard generated codes as alphanumeric codes, operand codes or instruction codes
    • G06F3/0233Character input methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/31Programming languages or programming paradigms
    • G06F8/315Object-oriented languages

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Human Computer Interaction (AREA)
  • Document Processing Apparatus (AREA)

Abstract

The present invention relates to JavaScript technical fields, more particularly to realize that the phonetic of trade name writes a Chinese character in simplified form the method automatically generated based on pinying.js.The method of the present invention step is:1, pinying.js is introduced to the page.2, a Text Entry, combobox are defined.3, query functions are defined, the trade name inputted according to text box obtains first phonetic letter automatically.4, the value that will be indexed, traverses combobox, is selected for user.The present invention solves the problems such as traditional commodities name first letter of pinyin need to be manually entered, is cumbersome, accuracy is low, efficiency is low.

Description

A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates
Technical field
The present invention relates to JavaScript technical fields, more particularly to the phonetic letter of trade name is realized based on pinying.js Write the method automatically generated.
Background technology
JavaScript, a kind of high-level programming language are executed by explaining, are a regime type, object-oriented(It is based on Prototype)Literal translation language.It has realized the standardization of language via European computermaker association by ECMAScript.Its quilt Most websites in the world are used, also by world browser(Chrome, IE, FireFox etc.)It supports.
It is the language of normal form more than one based on the leading language of prototype, function that JavaScript, which is one, it support towards Object programs, imperative programming and functional expression programming.It provides grammer to manipulate text, array, date and regular expressions Formula etc. does not support I/O, such as network, storage and figure etc., but these can provide support by its host environment.
Invention content
Realize that the phonetic of trade name writes a Chinese character in simplified form automatic life based on pinying.js present invention solves the technical problem that being to provide At method, solve the problems such as traditional commodities name first letter of pinyin need to be manually entered, is cumbersome, accuracy is low, efficiency is low.
The present invention solve above-mentioned technical problem technical solution be:
The method includes following steps:
Step 1: introducing pinying.js to the page;
Step 2: defining a Text Entry, combobox;
Step 3: defining query functions, the trade name inputted according to text box obtains first phonetic letter automatically;
Step 4: the value that will be indexed, traverses combobox, selected for user;
Beneficial effects of the present invention:The phonetic that trade name is realized the present invention is based on pinying.js is write a Chinese character in simplified form and is automatically generated, and operates Convenient, at low cost, efficient method.
Description of the drawings
The following further describes the present invention with reference to the drawings:
Fig. 1 is flow chart of the method for the present invention.
Specific implementation mode
It is safeguarded as shown in Figure 1, the unified of page title may be implemented using following steps in the present invention
Step 1: introducing pinying.js to the page;
<script type="text/javascript" src="${ctx }/statics/js/pinying.js" charset="GBK"></script>
Step 2: defining a Text Entry, combobox;
<input onKeyUp="query()" id="productName" class="col-xs-12 form-control pinput" type="text" name="productName" value="${model.productName}" Placeholder=" trade name " isvalid=" yes " checkexpession=" NotNull ">
<select id="mnemonicName" class="col-xs-12 form-control pinput" name=" mnemonicName">
<option value="${model.mnemonicName}">${model.mnemonicName}</option>
</select>
Step 3: defining query functions, the trade name inputted according to text box obtains first phonetic letter automatically;
function query(){
var str = document.getElementById("productName").value.trim();
var arrRslt = makePy(str);
}
Step 4: the value that will be indexed, traverses combobox, selected for user;
var option = null;
document.getElementById("mnemonicName").innerHTML="";// empty combobox
var first = document.getElementById("mnemonicName");
for(var j=0;j<arrRslt.length;j++){
var obj = document.getElementById("mnemonicName");
obj.add(new Option(arrRslt[j],arrRslt[j]));
}。

Claims (5)

1. realizing that the phonetic of trade name writes a Chinese character in simplified form the method automatically generated based on pinying.js, it is characterised in that:The method Including following steps:
Step 1: introducing pinying.js to the page;
Step 2: defining a Text Entry, combobox;
Step 3: defining query functions, the trade name inputted according to text box obtains first phonetic letter automatically;
Step 4: the value that will be indexed, traverses combobox, selected for user.
2. phonetic according to claim 1 writes a Chinese character in simplified form automatic generation method, it is characterised in that:In the step one, introduce Pinying.js is to the page.
3. phonetic according to claim 1 writes a Chinese character in simplified form automatic generation method, it is characterised in that:In the step two, definition One Text Entry, combobox.
4. phonetic according to claim 1 writes a Chinese character in simplified form automatic generation method, it is characterised in that:In the step three, definition Query functions, the trade name inputted according to text box obtain first phonetic letter automatically, support polyphone.
5. phonetic according to claim 1 writes a Chinese character in simplified form automatic generation method, it is characterised in that:In the step four, by rope The value guided to, traverses combobox, and user is facilitated to select.
CN201810589282.1A 2018-06-08 2018-06-08 A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates Pending CN108803894A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810589282.1A CN108803894A (en) 2018-06-08 2018-06-08 A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810589282.1A CN108803894A (en) 2018-06-08 2018-06-08 A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates

Publications (1)

Publication Number Publication Date
CN108803894A true CN108803894A (en) 2018-11-13

Family

ID=64088986

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810589282.1A Pending CN108803894A (en) 2018-06-08 2018-06-08 A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates

Country Status (1)

Country Link
CN (1) CN108803894A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109828973A (en) * 2019-01-31 2019-05-31 泰康保险集团股份有限公司 Information processing method and equipment
CN111026459A (en) * 2019-12-05 2020-04-17 杭州有赞科技有限公司 Character string to pinyin method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102819606A (en) * 2012-08-20 2012-12-12 中国农业银行股份有限公司 Spelling-based information inquiry method and system and server
CN103092846A (en) * 2011-10-27 2013-05-08 镇江雅迅软件有限责任公司 Realization of commodity retrieval method based on phonetic initial letters
CN105574118A (en) * 2015-12-14 2016-05-11 广州华多网络科技有限公司 Input information determining method and client end
CN108037837A (en) * 2017-11-07 2018-05-15 朗坤智慧科技股份有限公司 A kind of intelligent prompt method of search term

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103092846A (en) * 2011-10-27 2013-05-08 镇江雅迅软件有限责任公司 Realization of commodity retrieval method based on phonetic initial letters
CN102819606A (en) * 2012-08-20 2012-12-12 中国农业银行股份有限公司 Spelling-based information inquiry method and system and server
CN105574118A (en) * 2015-12-14 2016-05-11 广州华多网络科技有限公司 Input information determining method and client end
CN108037837A (en) * 2017-11-07 2018-05-15 朗坤智慧科技股份有限公司 A kind of intelligent prompt method of search term

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109828973A (en) * 2019-01-31 2019-05-31 泰康保险集团股份有限公司 Information processing method and equipment
CN111026459A (en) * 2019-12-05 2020-04-17 杭州有赞科技有限公司 Character string to pinyin method

Similar Documents

Publication Publication Date Title
US7761787B2 (en) Document generation system and user interface for producing a user desired document
US8065685B2 (en) Method, system and apparatus for a transformation engine for use in the processing of structured documents
CN105824787B (en) A kind of control method and system of html template dynamic configuration
US20060048096A1 (en) RTF template and XSL/FO conversion: a new way to create computer reports
US20080288239A1 (en) Localization and internationalization of document resources
US20040230900A1 (en) Declarative mechanism for defining a hierarchy of objects
Müller et al. Multi-level annotation in MMAX
US7707496B1 (en) Method, system, and apparatus for converting dates between calendars and languages based upon semantically labeled strings
CN104267949A (en) Form designer and form design method
US20190057074A1 (en) Patent automation system
Faulkner et al. HTML 5.2
CN108803894A (en) A method of it realizing that the phonetic of trade name is write a Chinese character in simplified form based on pinying.js and automatically generates
CN110187886A (en) A kind of documentation website generation method and terminal
US20040205612A1 (en) Programmatically generating a presentation style for legacy host data
Pohja COMPARISON OF COMMON XML-BASED WEB USER INTERFACE LANGUAGESCOMPARISON OF COMMON XML-BASED WEB USER INTERFACE LANGUAGES
US20050177788A1 (en) Text to XML transformer and method
CN115328455A (en) Information display method, device, equipment and medium for flutter application
KR20060061733A (en) Declarative mechanism for defining a hierarchy of objects
de Krieger Modernizing the WebDSL front-end: A case study in SDF3 and Statix
US11210454B2 (en) Method for preparing documents written in markup languages while implementing a user interface for dealing with data of an information system
CN111597205B (en) Template configuration method, information extraction device, electronic equipment and medium
KR20120139955A (en) System for web data extraction for mobile platform
Browning et al. Working with Text
Sutherland et al. Chapter 3: Working with Text
US20140304227A1 (en) Systems, Computer Program Products, and Methods Using Data Set Objects

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
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20181113