Posts

java - Parameterization entity with JPA -

I am trying to create a unit to parameter the values ​​of business rules, I have name, type and value Value: Value: Type: value (double) Value: 20 Usage will be done in a rule to add 20% of the value of the imported product. But I have many situations in the form of string, boolean or multi-valuable I thought of something like this: @NotEmpty private string name; // Enum @Enumerated (EnumType.STRING) @Enumeration (enumClass = ParameterType.class) with possible type (text, value, boolean, etc.) Private parameter type type; @OneToMany (mapped = "value") private list & lt; Parameter Value & gt; Values; ParameterValue unit, how can I implement it, because the value can be of different types (double, string, boolean, etc.)? This does not work: public class parameter value {Private object value; } Reason: org.hibernate.MappingException: Number of columns in property mapping is incorrect: br.entity.admin.ParameterValue.value Type: Object "}} ...

ios - Printing value of a optional variable includes the word "Optional" in Swift -

इस सवाल का पहले से ही एक उत्तर है: 6 उत्तर 3 जवाब .मैं आईओएस और स्विफ्ट के लिए नया हूँ। अपने आवेदन में मैं एक वैकल्पिक मूल्य को मुद्रित करने की कोशिश कर रहा हूं और यह प्रिंट करता है "वैकल्पिक वेरिएबल) "मैं यह शब्द कैसे वैकल्पिक var bDay = StringUtils.convertDateToString (जन्मदिन, प्रारूप: Constants.BIRTHDAY_FORMAT) को हटा सकता हूँ उम्र = self.clientDetail? .getAge () println ("उम्र ..... \ (उम्र)") bDay + = "\ (उम्र)" कंसोल में आउटपुट आयु ..... वैकल्पिक (2 9) मैं एक यूआईएलबल को इस वैरिएबल को आवंटित करने की कोशिश कर रहा हूं लेकिन स्क्रीन पर यह दिखाई देता है कि 17 सितंबर, 1986 वैकल्पिक (29) मेरा उद्देश्य इस वैकल्पिक को दूर करना है शब्द और इसे सितंबर 17, 1986 (2 9) पहले से धन्यवाद वैकल्पिक चेनिंग का यहां प्रयोग किया जाता है: उम्र दें = self.clientDetail। .getAge () तो वापसी getAge () वैकल्पिक मान है वैकल्पिक बाध्यकारी प्रयास करें: यदि उम्र = उम्र {println ("उम्र ..... \ (उम्र)")} या बस खोलना...

html5 - Wrong controller action in rails form with link -

मेरे पास एक फ़ॉर्म है ... = form_for_for_form_, url = & gt ; Update_path,: method = & gt; : क्या करें | फॉर्म | = Form.input_field: name = link_to image_tag asset_path ("icon.png"), {: नियंत्रक = & gt; 'नियंत्रक / नाम',: एक्शन = & gt; 'हटाएं',: id = & gt; Some.id} = form.submit ऊपर के रूप में मेरे पास एक लिंक / इमेज / आइकन है, जो क्लिक पर कार्रवाई नियंत्रक को हटाना चाहिए, लेकिन किसी कारण से यह सूचकांक नियंत्रक को जाता है कार्रवाई। क्या कोई बात कर सकता है कि यहां क्या गलत है? जब आप एक संसाधन मार्गों को परिभाषित करते हैं, तो हटाए जाने की क्रिया को उसी url के रूप में परिभाषित किया जाएगा जैसा कि अपडेट करें कार्रवाई (जो कि PUT या Patch HTTP क्रियाओं का उपयोग करके एक्सेस की जाती है), लेकिन इसे DELETE HTTP क्रिया का उपयोग करके एक्सेस किया जाता है आपको बस अपने ऑब्जेक्ट के अपडेट पथ के लिंक को सेट करना है और इसके बजाय DELETE क्रिया का उपयोग करें: = link_to image_tag ( "Icon.png"), update_path (id: some.id), विध...

qa - Apache JMeter - how to enter a web page and save a parameter? -

I have never used Jmter before and I have to write a script which will usually do the following: Use this parameter to enter another page Enter a web page Save a parameter from the page's resume Use this parameter to enter another page If you can guide me step by step then actually evaluate it. Thanks! See the link below: The recording scenario Correlation (find out the findings between pages and pass) Hope This will help.

javascript - responsive html content carousel plugin or without -

Image
I'm trying to create a responsive HTML content carousel. As shown on the image below. This is trying to use jQuery Cycle2, but I could not find the effect I was looking for. Finding such plug-ins will be able to do that I thought maybe the simple solution would be to try plain javascript / jQuery. Found this topic, I am still struggling to achieve this with the responsible elements. Any help would be greatly appreciated - I am not saying that it should be without a plugin which is not difficult to implement and probably without much more land. Use "bootstrap": You simply type the desired style . & lt; Div class = "container" & gt; & Lt; Div class = "row" & gt; & Lt; Div class = "col-xs-12 col-sm-12 col-md-4 col-lg-4> your first box here your third box here & lt; / Div>

r - Filter rows below a given row element within a group -

I have a datafile with one set of events dated in each row linked from one place to another Index is a series of events and different matches that could have been done after the first and / or index events. Every place needs to reduce all the events occurring before the index event. I data structure looks like this. Localized match date score iid 1 index 4/11/2013 15 1 1 Milan 1/09/2013 23 2 1 Milan 14/04/2013 1 3 1 Milan 7/1/2014 21 4 2 Index 2/4/2013 12 1 2 Milan 1/2/2013 10 2 3 Index 1/5/2013 23 1 3 Milan 2/5/2013 10 2 4 Index 3/3/2013 9 1 4 Milan 10 / 2/2013 32 2 4 Match 1/10/2012 15 3 4 Match 4/3/2013 12 4 4 Milan 10/3/2013 10 5 And to reduce dataframe Is required so that each location needs to end with the rows below the date of the index event. localized match date score iid 1 matched 1/09/2013 2013 23 2 1 match 14 / 04/2013 1 3 2 Milan 1/2/2013 10 2 4 Milan 10/2/2013 32 2 4 Milan 1/10/2012 15 3 I ask here for the first time, so I hope that I am not doing it wrong. ...

java - convert iso 4217 numeric currency code to currency name -

I have ISO 4217 numeric currency code: 840 I want to get the currency name: USD I am trying to: currency curr1 = currency .get instances ("840"); But how do I fix java.lang.IllegalArgumentException ? Any ideas? java.util.Currency.getInstance only supports ISO 4217 Currency Code No, currency numbers, however, you can retrieve all the currencies by using the getAvailableCurrencies method, and then the result of the getNumericCode method By comparison, you can search for code 840. Like it: Public Stable Currency Matchinance (Int Numericcode) {Set