Implementation of Atitit. List page and condition query best practices (1) ------ set query conditions and submit query and return json data, atititjson

Source: Internet
Author: User
Tags microsoft frontpage

Implementation of Atitit. List page and condition query best practices (1) ------ set query conditions and submit query and return json data, atititjson

Implementation of Atitit. List page and condition query best practices (1) ------ set query conditions and submit query and return json data

 

1. Configure condition field @ Conditional 1

2. 2. the display type of the condition field in condition configuration is range ---- @ Conditional (displayType condition = condition displayType. rang, specified rangStart frequency = Specified rang. start, specify rangEnd tables = Specified rang. end, op = op. range) 1

3. # ---- show condition page list 1

4. Submit the conditional Query Form by dwr 1

5. @ filter: set filter condition use or not use... or save form... 2

6. @ converter 2

7. # ---- save each condition map 4 debugging 2

8. # = start 2

9. Sigle, range >>> wehere cause 2

10. Hb pageing 2

11. Ret page map 2

12. # ---- code 3

13. Refer to 5

 

1. 1. condition configuration condition field @ Conditional 12. 2. the display type of the condition field in condition configuration is range ---- @ Conditional (displayType condition = condition displayType. rang, specified rangStart frequency = Specified rang. start, specify rangEnd tables = Specified rang. end, op = op. range)

Or dispayType. single ..

 

Author: old wow's paw Attilax iron, EMAIL: 1466519819@qq.com

Reprinted please indicate Source: http://blog.csdn.net/attilax

 

 

3. # ---- show condition page list4. submit the condition Query Form by dwr

// QueryBtn_click

Query (1)

Function query (isResetPage1)

{

If (isResetPage1 = 1)

ResetPageTo1 ();

Var mp = dwr. util. getFormValues ("formx ");

ElmtC. findByPropertyss_page (mp, function (data ){

// Alert ("saved successfully ");

BindTableData (data. rows );

SetPageInfo ({"total": data. total, "pageSize": 10 });

});

}

 

5. @ filter: set filter condition use or not use... or save form... 6. @ converter7. # ---- save each condition map 4 for debugging

Filex. save_safe (core. toJsonStr (QueryPropertyssMap), "c: \ json2.txt ");

 

8. # = start

For (Field failed: flds ){

Conditional cdt = response. getAnnotation (Conditional. class );

If (cdt = null)

Continue;

.......

 

9. Sigle, range >>>> wehere cause10. Hb pageing11. Ret page map

Map mp = new HashMap ();

Mp. put ("total", SafeVal. val (threadLocal_rowsCount.get (), list_sub.size ()));

Mp. put ("rows", list_sub );

 

12. # ---- code

 

Public List findByPropertyss (Map QueryPropertyssMap ){

// Log. debug ("finding GvMaterial instance with property:" +

// PropertyName + ", value:" + value );

Core. log ("--- o720 --");

Core. logMap (QueryPropertyssMap );

Filex. save_safe (core. toJsonStr (QueryPropertyssMap), "c: \ json2.txt ");

String propertyName;

Object value;

Criteria c = getSession (). createCriteria (GvMaterial. class );

Field [] flds = GvMaterial. class. getDeclaredFields ();

For (Field failed: flds ){

Try {

 

String fldName = response. getName ();

If (fldName. startsWith ("playtime ")){

String s = "";

}

If (! IncludeFldInfoPostMap (QueryPropertyssMap, fldName ))

Continue;

Conditional cdt = response. getAnnotation (Conditional. class );

If (cdt = null)

Continue;

 

If (cdt. adptr ()! = None. class) // cstm mode

//

{

List li = adptrMOde (QueryPropertyssMap, c, struct, fldName,

Cdt );

AddExpresss (c, li );

} Else if (cdt. displayType (). equals (displayType. single )){

 

// If

// (Response. getType (). getName (). equals (String. class. getName ()))

//{

 

List <Criterion> exprsLi = getExprs (fldName, cdt. op (),

QueryPropertyssMap );

Core. log (String. format ("-- o7f1: dbg fldinfo: % s --- % s ",

FldName, QueryPropertyssMap. get (fldName )));

AddExpresss (c, exprsLi );

// Restrictions. like (fldName, "%" ++ "% ")

} Else if (cdt. displayType (). equals (displayType. rang )){

 

List <Criterion> exprsLi = getExprs (fldName, cdt. op (),

QueryPropertyssMap );

Core. log (String. format ("-- o7f1: dbg fldinfo: % s --- % s ",

FldName, QueryPropertyssMap. get (fldName )));

AddExpresss (c, exprsLi );

}

//

 

} Catch (Exception e ){

Core. log (e );

}

 

// C. add (Restrictions. eq ("aname", name); // eq is equal to, gt is greater than, lt is less than, or is or

}

C. addOrder (Order. desc ("materialId "));

 

List <GvMaterial> list = c. list ();

ThreadLocal_rowsCount.set (list. size ());

Object page = QueryPropertyssMap. get ("page_page ");

List <GvMaterial> list_sub = PagingUtil. getList (list,

QueryPropertyssMap. get ("pagesize"), page );

 

Return list_sub;

 

}

13. Reference

Atitit. Improved development efficiency --- revolution of the MDA software development mode (5) ---- list query modeling-attilax column-blog channel-CSDN.NET.htm


Webpage help me

Requirement 1: Determine the website subject

To create a website, you must first solve the website content problem, that is, determine the website subject. PC Magazine in the United States rated ten subjects of the top 100 national famous websites in 99 years: 1st categories: online job hunting; 2nd categories: online Chat/instant information/ICQ; 3rd categories: online community/discussion/email list; 4th categories: computer technology; 5th categories: webpage/website development; 6th categories: entertainment websites; 7th categories: travel; 8th categories: Reference/information; 9th categories: Family/education; 10th categories: Life/fashion. We can refer to the classification above to continue the subdivision. If you are interested in some aspects or have a large amount of information, you can also create something that you are interested in. If you are an individual, you can have your own opinions and make your own characteristics; they do not feel bored or powerless when creating websites. Interest is the driving force behind website creation. It is difficult to design and produce excellent works without enthusiasm.

The selection of content themes should be small and refined, the positioning of themes should be small, and the content should be refined. Do not try to create an all-encompassing website. This will often lead to the loss of website features, high labor intensity, and difficulties in timely website updates. Remember: there is only first, no second on the Internet!

Method 2: select a domain name

A domain name is the name of a website on the Internet. All the construction value of a non-product-sold pure information service website depends on its website domain name. If this domain name is lost, all the preliminary work will be? Ke Qi? Br>
Currently, many personal websites rely on free personal space, and their domain names also rely on free domain names, such as Netease's virtual Domain Name Service, in fact, this is not conducive to the promotion and development of personal websites. It is not only because the window opened in a timely manner hinders the viewer's sight and goodwill, so that one can know at a glance that it is a personal website, it also hinders the transmission speed of webpages. Therefore, in my personal opinion, the first thing I need to do is to spend some money to register a domain name. An independent domain name is the first fortune of my website. It is easy to remember the domain name.

Essentials 3: master the network creation tools

The development of network technology has led to the development of the software industry. Therefore, tools and software used to create web pages are becoming more and more abundant. From the most basic HTML editor to the popular Flash interactive Web page creation tools and various Web page creation tools, the following are representative Web page Producers:

(1) HTML editor. Although HTML code is complex and it takes a lot of time to edit and debug it, it is still favored by senior website creators because of the stability, wide support, and the ability to create complex pages. Currently, there are many editors to choose from. These editors support complex page creation and advanced HTML specifications. Professional HTML editors such as Hotdog are commonly used.

(2) WYSIWYG Web Editor. Microsoft Frontpage is represented by Microsoft Frontpage. It has the same operation interface as Word and is familiar with Word functions. It can easily compile webpages with a little training. In addition, Frontpage can parse the HTML source code of the webpage and provide preview support. However, some special display functions of Frontpage cannot be implemented in other non-ie browsers. Therefore, Frontpage is a tool software suitable for beginners and intermediate website developers.

(3) The Flash interactive web page creation tool developed by Macromedia. This is a powerful interactive vector multimedia webpage creation tool. It can easily output a variety of animated webpages. It does not require any complicated operations, but is also more compact than JAVA! However, its animation effect, interaction effect, and multimedia effect are outstanding. In addition, Mp3 music can be encapsulated in Flash animation, and forms can be filled in. In addition, because the webpage files compiled by Flash are much smaller than normal webpage files, browsing speed is greatly accelerated. This is a very suitable tool for dynamic Web production.

In addition, individual website creators also need to understand the W3C HTML4.0 standard, the basic knowledge of CSS Cascading Style Sheets, and the basic knowledge of javascript and VBScript. For some of the frequently-used... the remaining full text>

Let's look at a fly, and see where it ___ 1 ___ First, it flies out of the wind

1. () D flies
2. () B second
3. () A some
4, () A food
5, B feet
6. () A in
7 () C leaves
8D learn from
9 C our house
10D get
Also: When can you _ 8 ___ suspected to be the mistake of what can you _ 8 ___
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.