Jqueryeasyuicombobox value judgment and processing. I tried it for a while and posted it to record it.

Source: Internet
Author: User
// If an agent returns the goods, the returned agent and the brand if ($ {type2}) {varbid0 $ (& amp; #39; # orderReturnForm & amp; #39 ;). find (& amp; #39; input [namebid] & amp ;#... syntaxHighlighter. al
// If an agent returns the goods, the returned agent and the brand if ($ {type = 2}) {var bid0 = $ ('# orderReturnForm') are displayed '). find ('input [name = bid] '); var agencyid = $ (' # orderReturnForm '). find ('input [name = agencyid] '); var agencyidCombobox = agencyid. combobox ({url: '$ {pageContext. request. contextPath}/dls/agencyAction! NoAuth_MyAgencyJson.html ', valueField: 'id', textField: 'username', multiple: false, editable: false, panelHeight: 'auto', onSelect: function () {var agencyvalue = agencyid. combobox ("getValue"); var bid0Combobox = bid0.combobox ({url: '$ {pageContext. request. contextPath}/spgl/brandAction! NoAuth_comboboxAgencyBrand.html? Agencyid = '+ agencyvalue, valueField: 'id', textField: 'name', multiple: true, editable: true, onLoadSuccess: function () {parent. $. messager. progress ('close') ;}}); $ ("# bid "). combobox ('showpanel ') ;}}) ;}// if an agent returns the product, the returned agent and brand if ($ {type = 2}) are displayed }) {var bid0 = $ ('# orderReturnForm '). find ('input [name = bid] '); var agencyid = $ (' # orderReturnForm '). find ('input [name = agencyid] '); var agencyidCombobox = Gencyid. combobox ({url: '$ {pageContext. request. contextPath}/dls/agencyAction! NoAuth_MyAgencyJson.html ', valueField: 'id', textField: 'username', multiple: false, editable: false, panelHeight: 'auto', onSelect: function () {var agencyvalue = agencyid. combobox ("getValue"); var bid0Combobox = bid0.combobox ({url: '$ {pageContext. request. contextPath}/spgl/brandAction! NoAuth_comboboxAgencyBrand.html? Agencyid = '+ agencyvalue, valueField: 'id', textField: 'name', multiple: true, editable: true, onLoadSuccess: function () {parent. $. messager. progress ('close') ;}}); $ ("# bid "). combobox ('showpanel ');}});}

 

 

 

 


 

// Determine whether the Warehouse is empty. if it is empty, the warehouse drop-down box is displayed. if it is not empty, the warehouse is given to the hidden domain if ($ ("# rid ")! = Null & $ ("# rid"). combobox ("getValues ")! = Null & $ ("# rid"). combobox ("getValues ")! = "") {Var rid = $ ("# rid "). combobox ("getValues"); $ (". rid "). attr ("name", "rid"); $ (". rid "). attr ("value", rid);} else {// parent. sy. messagerConfirm ('Return warehouse not selected ', 'select the warehouse to be returned! '); $ ("# Rid "). combobox ('showpanel '); return;} // if there is a return from the agent, if ($ {type = 2}) {// determines whether the agent is empty, if it is not empty, the brand is processed. if ($ ("# agencyid") in the agent drop-down box is displayed if ($ ("# agencyid ")! = Null & $ ("# agencyid"). combobox ("getValues ")! = Null & $ ("# agencyid"). combobox ("getValues ")! = "") {If ($ ("# bid ")! = Null & $ ("# bid"). combobox ("getValues ")! = Null & $ ("# bid"). combobox ("getValues ")! = "") {Var bid0 = $ ('# bid '). combobox ("getValues"); $ (". bids "). attr ("name", "bids"); $ (". bids "). attr ("value", bid0);} else {$ ("# bid "). combobox ('showpanel '); return ;}} else {$ ("# agencyid "). combobox ('showpanel '); return ;}// determines whether the Warehouse is empty. If it is empty, the warehouse drop-down box is displayed; if it is not empty, the repository is given to the hidden domain if ($ ("# rid ")! = Null & $ ("# rid"). combobox ("getValues ")! = Null & $ ("# rid"). combobox ("getValues ")! = "") {Var rid = $ ("# rid "). combobox ("getValues"); $ (". rid "). attr ("name", "rid"); $ (". rid "). attr ("value", rid);} else {// parent. sy. messagerConfirm ('Return warehouse not selected ', 'select the warehouse to be returned! '); $ ("# Rid "). combobox ('showpanel '); return;} // if there is a return from the agent, if ($ {type = 2}) {// determines whether the agent is empty, if it is not empty, the brand is processed. if ($ ("# agencyid") in the agent drop-down box is displayed if ($ ("# agencyid ")! = Null & $ ("# agencyid"). combobox ("getValues ")! = Null & $ ("# agencyid"). combobox ("getValues ")! = "") {If ($ ("# bid ")! = Null & $ ("# bid"). combobox ("getValues ")! = Null & $ ("# bid"). combobox ("getValues ")! = "") {Var bid0 = $ ('# bid '). combobox ("getValues"); $ (". bids "). attr ("name", "bids"); $ (". bids "). attr ("value", bid0);} else {$ ("# bid "). combobox ('showpanel '); return ;}} else {$ ("# agencyid "). combobox ('showpanel '); return ;}}

 

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.