back soft

مطالب مرتبط با «with dynamic» در back soft | نویسنده: استخدام کار

Dynamically create object with properties based on inputted List C#

امروزدخترم رابردم دندانپزشکی .یکی ازهمکاران قدیمی به اسم خانم شریفی رادیدم خوشحال شدم ،راستش برای من فرقی نمی کنه که خاطره خوب ازهمکارام داشته باشم یانه وقتی بعدازمدتهااونهارامی بینم خوشحال میشم،بعدرف...

ادامه مطلب

How to getConstructor with dynamic parameter in java

امروزدخترم رابردم دندانپزشکی .یکی ازهمکاران قدیمی به اسم خانم شریفی رادیدم خوشحال شدم ،راستش برای من فرقی نمی کنه که خاطره خوب ازهمکارام داشته باشم یانه وقتی بعدازمدتهااونهارامی بینم خوشحال میشم،بعدرف...

ادامه مطلب

Dynamic URL doesn't work with HTML5 angularjs

I'm creating an app in AngularJS and ExpressJS and when I try to use dynamic url, with the angular state, it doesn't work properly. It's working when I access directly the URL but only static URLs. server.js var express = require('express'), server = express(), path = require('path'), port = process.env.PORT || 8081; server.use(express.static(__diame)); server.all("/*", function(req, res, next) { res.sendFile(path.join(__diame, 'index.html')); }); server.listen(port); console.l...

ادامه مطلب

Create nested JSON with dynamic keys with PHP

Vote count:
 0I get some data from an API call and I try to construct a JSON to send it back to another API.The final JSON must look like this:{ "jobs": { "MP_OFFER_ID_1": { "job_id": "jobboard_reference_1", "url": "url_1", "status": 0 }, "MP_OFFER_ID_2": { "job_id": "job_id_2", "url": "url_2",...

ادامه مطلب

Deserializing JSON with dynamic property

Vote count:
 0I have to deserialize a JSON response(from a wep API) . The problem is that this API retus JSON with dynamic property. Had it been like { "employees": [{ "employeeCode": "ABC", "cityId": 123 },{ "employeeCode": "DEF", "cityId": 234 }] } it would have been perfect but the...

ادامه مطلب

Dynamic CSS with jQuery?

Vote count: 0 I've created a custom dropdown element. The number of options it can have is based on a Database Table (I haven't created the Table yet). Like the number of options can be 4 or even 5 or anything for that matter. I'll use PHP to give the number of options for the dropdown. Each of the options are in an li tag. The li siblings are inside the ul tag. I have a CSS file which animates the li items. But instead of animating them all at once (in which case I would just animate the ul and would get the same effect), what I want to do is to animate them one by one. Each li will have a delay which is progressive. For example if the first li has a 0s delay and a duration of 300ms then th...

ادامه مطلب

class with dynamic this.variables

Vote count: 0 im creating a class where i would be able to have in my constructor dynamic variables, but im not sure if im doing the right way or if it is valid. Example static: my class: class MyClass{ constructor(options){ this.propertyname = options.value; this.propertyname = options.value; this.propertyname = options.value; } } Does this example would be the same of the above? My only issue would be that the example i have wasnt making the options value assign to "this." my class: class MyClass{ constructor(options){ for (var property in options) { if (options.hasOwnProperty(property)) { this[property] = options[property]; } } } } Calling: var example = new MyClass({ property1: "Somethin...

ادامه مطلب

Why does dynamically created element with Dragstart event returns undefined?

Vote count: 0 The following code creates new elements and ascribes an dragstart event to it. However it results in an "undefined". What am I doing wrong? for (var S = 0; S < arrInbound[i][3].length; S++){ var namesDiv = document.createElement('div'); namesDiv.id = S; namesDiv.draggable = 'true'; namesDiv.contenteditable = 'true'; namesDiv.className = "crewNames"; namesDiv.ondragstart = function(){dragStart(event) if(event.target.type=="range")event.preventDefault(); event.dataTransfer.setData("Text", event.target.id); console.log("Dragging..."); }; namesDiv.onclick = function(){alert("ytry");}; namesDiv.ierHTML = arrInbound[i][3][S]; tagElRight.appendChild(namesDiv) } asked 26 secs agoEthan ...

ادامه مطلب

ld fails to link a static library to a dynamic library even when all files are compiled with fPIC

Vote count: 0 Summary: On a CentOS 7 x64 system, I've build the latest Boost 1.61.0 with -fPIC enabled. I'm trying to link libboost_log.a to the dynamic library I'm building so that the user of my library doesn't have to have Boost installed. That succeeded using the stock GCC 4.8.5 shipped with CentOS 7, but failed when I'm using GCC 5.2.1 from devtoolset-4. Error: /opt/rh/devtoolset-4/root/usr/libexec/gcc/x86_64-redhat-linux/5.2.1/ld: /opt/boost/lib/libboost_log.a(attribute_name.o): relocation R_X86_64_32 against `_ZZN5boost3log12v2s_mt_posix3aux14lazy_singletonINS1_14attribute_name10repositoryENS_10shared_ptrIS5_EEE3getEvE29_boost_log_once_block_flag_43' can not be used when making a shar...

ادامه مطلب

Express JS Dynamic Routing with Typescript

Vote count: 0 I want to migrate my routing logic from plain javascript to typescript. In javascript I would use below logic. How can I achieve the same the below in typescript to implement a route by implementing the IRoute interface.The idea is to use a class which handles routing. route.ts: var express = require('express'); var myRouter = express.Router(); myRouter.route('/') .all(function(req,res,next) { res.writeHead(200, { 'Content-Type': 'text/plain' }); next(); }) .get(function(req,res,next){ res.end('Will send all the promotions to you!'); }) .post(function(req, res, next){ res.end('Will add the promotions: ' + req.body.name + ' with details: ' + req.body.description); }) .delete(fun...

ادامه مطلب

ElasticSearch create an index with dynamic properties

Vote count: 0 Is it possible to create an index, restricting indexing a parent property? For example, $ curl -XPOST 'http://localhost:9200/actions/action/' -d '{ "user": "kimchy", "message": "trying out Elasticsearch", "actionHistory": [ { "timestamp": 123456789, "action": "foo" }, { "timestamp": 123456790, "action": "bar" }, { "timestamp": 123456791, "action": "buz" }, ... ] }' I don't want actionHistory to be indexed at all. How can this be done? For the above document, I believe the index would be created as $ curl -XPOST localhost:9200/actions -d '{ "settings": { "number_of_shards": 1 }, "mappings": { "action": { "properties" : { "user": { "type": "string", "index" : "analyzed" }, "messa...

ادامه مطلب

Object assign with dynamic variable in Javascript

Vote count: 0 I have this initialState in my Redux store const initialState = { isFetching : false, active : {} } Where active is an object. Now I have an action that should append or add a property to active's data property like so: [DASHBOARD_TEMPLATE_DATA_RECEIVE]: (state, action) => { retu Object.assign({}, state, { isFetching : false, active : Object.assign({}, active, {data[action.key]: action.data}) }) } As you can see data[action.key] is not permitted, how do I do it? asked 35 secs agoJoey Hipolito This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publ...

ادامه مطلب

How to execute dynamic query with sql""select c from T""".as[T] interpolation in slick

Vote count: 0 I am trying to implement a function with Slick3 to retu a tuple. def executeQueryConfig2[T](sql: String, f : Option[T] => Unit): Future[T] = { val action2 = sql"""$sql""".as[T].headOption getDatabase(config).run(action2).mapTo[T].map(f(_)).recover{ case e: SQLException => println(e.getMessage) } ....... } The compiler shows the error: Error:(66, 35) could not find implicit value for parameter rconv: slick.jdbc.GetResult[T] val action2 = sql"""$sql""".as[T].headOption ^ If T is the type in types which have been implemented by the slick 3, how I implement such function? Thanks. asked 1 min agoBirdflying1005 This entry passed through the Full-Text RSS service - if this is your con...

ادامه مطلب

How to make line chart using asp.net mvc4 with dynamic data without javascript?

Vote count: 0 I would like to make line chart in my project. i was already make pie chart using datavisulazation dll but now want to make line chart with dynamic data so how can i make it? asked 1 min agoUrvish Patel Let's block ads! بخوانید...

ادامه مطلب

Parameterized dynamic sql query with multiple parameters

Vote count: 0 I had a Program in c# which would run queries using a dynamically created string which would be used as a query. Now due to possibility of SQL injection, I want to use parameterized queries to generate the same. Was looking at Parameterized dynamic sql query and that is mostly what I want, but then I want multiple parameters in the same sequence and not in different sequences. i.e I want something like (Where value in ({0}, {1}, {2}), param0 , param1, param2 ) The answer in that thread is SqlCommand cmd = new SqlCommand(); StringBuilder sqlBuilder = new StringBuilder(); sqlBuilder.Append("SELECT name, memberid FROM members "); var i = 1; foreach (string item in keywords) { sqlB...

ادامه مطلب

Applying toLocaleString to all dynamic textboxes with a certain class

Vote count: 0 Working on an ASP.NET website. I have a page where there are alot of dynamically created textboxes. In addition to these textboxes I link dynamic javascript calculations to certain textboxes as well. This is all database driven. For example.... (pseudo-code) textbox1 = "10" textbox2 = "4" textbox3 = textbox 1 + textbox 2 (displays "14") All of the textboxes are working great, dynamically calculating correctly, etc.... BUT, I need to format them with commas, if applicable. All of these dynamic textboxes have a css class of 'dynamic_control'. Question: I would like to autoformat numbers > 999 with commas. (AFTER any calculations are finalized.) So, what I did was this... $(docume...

ادامه مطلب

Best Scope in Dagger2 for Okhttp3 with dynamic Interceptors

Vote count: 0 How would the scope work with Auth Tokens? I caot create my Retrofit instance until I can add an interceptor that signs it with my auth token. Therefore, I would like to create Retrofit when the auth tokens are available (after sign-in). How do I get scope working correctly in this situation? Thanks a lot! asked 2 mins agoChema Let's block ads! بخوانید...

ادامه مطلب

Javascript for loops with dynamic variable

Vote count: 0 I am writing a Google form using a script so that I can pull the data from a Google spreadsheet and generate a page for each event based on a list of events which are of unknown length. I have worked out that I can create the pages I need using this loop, with my list of events, eventvalues : for (var i = 2; i < eventvalues.length; i+=1){ var page = form.addPageBreakItem().setTitle(eventvalues[i][0]);} I would like to end up with variables Page1 Page2 Page3 Etc all the way to eventvalues.length Currently the variable page is used by the last page only and all others are not assigned to a variable because of being re assigned. Thanks in advance edited 1 min agofge asked 2 mins a...

ادامه مطلب

How to create a dynamic page/view with MVC?

Vote count: 0 I have Controllers that have are associated with a view, such as HomeController's public ActionResult Index() Is it possible to dynamically create/display a view without having it rendered in any CSHTML markup? asked 1 min agoAlvinfromDiaspar Let's block ads! بخوانید...

ادامه مطلب

UICollectionView within UIScrollView dynamic height

Vote count: 0 I currently have a UICollectionView within a UIScrollView, scrolling is disabled on the collectionView. The current issue is the collectionview cells are cut off, the collectionView doesn't dynamically set its height to fit within the scrollView. How can I change the collection to dynamically fit within the scrollview? Below is what I've tired let newHeight = collectionView.sizeThatFits(CGSizeMake(collectionView.bounds.width, CGFloat(MAXFLOAT))) collectionViewHeight.constant = newHeight.height asked 1 min agokye Let's block ads! بخوانید...

ادامه مطلب