Posts

angularjs - Popup Controller function call in angular.js -

I'm using it because it sounds popular, I'm calling the popup dialog as follows: $ scope.upload = function () {createDialogService ('simpleModal.html', {id: 'simpleDialog', title: 'India to upload video', background: true, controller: 'Trafficist Controller', success: {label: 'success', FN: function () {console.log ('simple mode off');}}}); }; And in my simpleModal.html only the following (a form) & lt; Div class = "row-fluid" & gt; it happens. & Lt; form ng-submit = "addNewVideo ()" & gt; & Lt; Input type = "text" ng-model = "newVid.videoURL" placeholder = "video url here" & gt; & Lt; Br / & gt; & Lt; Input type = "text" ng-model = "newVid.locality" placeholder = "locality" & gt; & Lt; Br / & gt; & Lt; Input type = "text" ng-model = "newVid.town" placeholder = "c...

ruby on rails - How to unit test a module (a resque scheduler job) in rspec -

मेरे पास एक (सरलीकृत) मॉड्यूल है: (/app/jobs/checkpulse.rb) मॉड्यूल चेकपल्स @ आकार =: दिल की धड़कन def self.perform () Machine.all.each do | मशीन | Machine.update_columns (active_alarm: true) # updated_at एंड एंड एंड को स्पर्श नहीं करना चाहता मैं इसे रेल कंसोल में उपयोग कर सकता हूं और यह सभी मशीनों को अपेक्षित रूप से बदलता है। मैं इसे परीक्षण करने के लिए एक युक्ति लिखने की कोशिश कर रहा हूं: (/spec/jobs/checkpulse_spec.rb) की आवश्यकता होती है "spec_helper" need_relative '../../app/jobs/checkpulse "कारखानेगर्ल.क्रेते (: मशीन, उपयोगकर्ता: उपयोगकर्ता, दिल की धड़कन: समय समाप्त: 5)}" यह मशीन को बदलना चाहिए " अलार्म मोड "चेकपल्स करते हैं। टेपरफ़ॉर्म (मशीन.एक्टिव_अलार्म) की उम्मीद है। be_true end end के लिए यह परीक्षण हर बार विफल रहता है मैंने चेकपल्स मॉड्यूल के अंदर डालकर इसे जांचने के लिए उपयोग किया है और इसमें मॉड्यूल के अंदर अपेक्षित व्यवहार है, लेकिन जब मॉड्यूल से लौटा जाता है, तो मशीन बदल नहीं जाती है। मैंने कोशिश की है, लेकिन यह या त...

postgresql - Postgres : No suitable Driver found for jdbc JAR File -

My eclipse program is working well. However, when I try to compile it in a JAR file, then I get this error: java.sql.SQLException: no suitable driver was found for jdbc: postgresql: //10.0.0.19: 5432 / Fussballverein I added the connector to my Java files and exported them to a jar file, is that correct? This is how my jar file looks: MyModel.class MyModel.java MyControll.class MyControll.java Mpanel mypanel.java Postgrescle-9.3-1101. jdbc3.jar Maryframe When I try to run it from my command prompt, it looks like this: Java -jar Gebauer_Laurenz.jar 10.0.0.19 User name password fussballverein I'm already getting the error here is my code; It would be great if someone could help. public throws auführen () SQLException, ClassNotFoundException {// Connection Objekt connection con = null; Println (server + "+ db +" "+ user +" + pw); Try {//Class.forName("org.postgresql.Driver "); // After death in DriverManager...

Format mySQL timestamp by changing date-month and remove seconds using PHP function? -

मैं mySQL से $ istoriko ['टाइमस्टैम्प'] को गूंजता हूं और मुझे 2014- 04-24 00:10:29 मैं इसे कैसे बदल सकता हूँ 24/04/14 (या 2014) 00:10 धन्यवाद इसे आज़माएं, इसका सरल आप किसी भी तारीख प्रारूप को अब दिनांक फ़ंक्शन में सेट कर सकते हैं प्रतिध्वनि तारीख ("d / m / y", strtotime ($ istoriko ['टाइमस्टैम्प']));

wordpress - activate plugins on custom theme -

I'm new to WordPress and just created my first template. In functions.php I've put the following code, the function I think is that the plugins should call the plugin directory: If (function_exists ('register_sidebar' '', 'Name' = & gt; 'Widgetized Area', 'id' => 'widgetized-area', 'description' => "',' before_widget '=> After_widget '= & gt;' ',' before_title '= & gt; ",' after_title '=>);); } I see all the plugins, and in the widget screen I also see the 'Widgets' screen and it allows me to drag the widget into the work area. The website displays the HTML of the plugin but neither JS and CSS is working. What am I missing? The code you added above in your functions.php is that To register any plugin, register the sidebar, there is no connection to its plugin You can follow the sidebar included in the template: If (...

java - Parallel HTTP requests with Retrofit -

I have an Android app that currently creates volley network requests and downloaded images With NetworkImageView is being used to show I would like to test the capabilities of Retrofit and since I have to run a lot of requests (thousands), I'm concerned about a little parallel execution volley RequestQueue which limits concurrent running requests to four, while others are waiting to execute the requests. In the Retrofit documentation, I have not found any way to handle the number of concurrent requests and I suspect that this information has been left to the developer in this library. Is that correct? If so, is there an Android-oriented implementation / library available? Otherwise, what are the best practices for handling parallel requests? Uses an digitizer for retrieiting queuing requests. Default Executor. NewcachedThreadPool uses which allows for unlimited threads. This usually fits more use cases than you usually have one or two requests at onc...

Go - Idiomatic way to return (potentially shadowed) variables which have been defined as part of a separate multiple variable return -

normal status While typing a function with the named return value, you typically use nude returns (Whether or not you have a different discussion). They can look like something: func add (x, y int) (z int) {z = x + y return} Return is the same problem as return z though with the compressed snippet below ... ( Module, ".md") {module, err: = readConvertMDFile (fileRoot + "htdocs / md /" +) func load module (module-name, fileRoot string) (module [] byte) {if String.HasSuffix (moduleName, ".md" module_name) If mistake! = Zero {log. Printerline (fault)} return module} and {module = [] byte {} return}} (this snippet runs fine, and this is my current solution to the problem) ... The compiler will complain that module is shaded if instead of return module bus Return . The reason for this is that the module was declared with err (second time), which has to be announced because it is still not present in this area. Possible...