This event will be fired when the element loses focus. Mostly it is used with the form validation code(e.g. with the input field in a form). onfocus event is the opposite to the onblur attribute.
Syntax :
<element onload="script">
...
This event is fired when an object has been loaded. This event is used mostly with the body element to execute a script, after the page loaded all content (including images, script files, CSS files, etc.), this event will be fired. It also help u...
To check a function exist or not in PHP we use a built-in function function_exists(). This function check that the function exists or not.
Syntax:
function_exists(function_name);
It includes one parameter i.e., the name of the function...
Hello Reader's if you want to use top in your MySql query then this blog is very helfull to you.
Lets see how to use top clause in MySql in different different location.
Suppose if you want to get only first 5 records of the table, Then you c...
Methods for Usability Testing
There are two Methods accessible to do Usability testing-
Laboratory Usability Testing
Remote Usability Testing
Laboratory Usability Testing:- This testing is directed in a different lab room in vici...
Usability Testing Approach/Techniques
Planning/Arranging:- During this stage the objectives of usability test are resolved. Having volunteers sit before your application and recording their activities is not an objective. You have to decide ...
Hello friends,
Most of time we need to create Object of contents in jQuery and use it according to requirement , So in this block you will see how to merge two or more object in first object .
When two or more object arguments are supplied t...
Objectives of Usability Testing:-
Objective of this testing is to fulfill/satisfy clients and it for the most part focuses on the accompanying parameters of a framework:-
Adequacy/Effectiveness of the framework
Is the framework is an...
after upgrading from magento 1.8 to 1.9 I have faced the Integrity constraint error in checkout process with the following statement -
Integrity constraint violation: 1062 Duplicate entry 'order_id' for key 'UNQ_SALES_FLAT_ORDER_INCREMENT_ID'' ...
Frame
Frames are HTML tag which divides the browser's window into multiple parts where each part can load a separate HTML document.
<frame> tag specifies each frame within a frameset tag.
A collection of frames in the browser window...
Usability Testing:-
In Usability Testing, a little arrangement of target end-users of a Software framework "use" it to uncover ease of use defect. This testing for the most part spotlights on the user's-straight forwardness to utilize the app...
In javascript we use different functions to display outputs, like to display into an alert box, HTML output, HTML element,browser console we use different functions.
1. window.alert():- Used when we want to display data into an alert box.
E...
Cheat-Sheet for Comparison between Bootstrap and Foundation Classes and Elements
Introduction of Bootstrap and Foundation
Bootstrap and foundation frameworks are very well known font-end framework for Respons...
This article defines a function substr_count() which can be used for count the occurrences of a character or substring in a string. In general way, substr_count() takes two arguments, first argument is a string and second argument is a character ...
Onchange is the most important function for Odoo. similar to a negative number of seats, or more participants than seats. For example you can see below code.
r.taken_seats = 0.0
else:
r.taken_sea...
Onchange is the most important function for Odoo. The "onchange" mechanism provides a method for the client interface to update a form at the time when the user filled a value in a field, without saving anything to the database.
For example you ...
DESCRIBE Statement:
It is used to view the structure of a table means it shows name and data type of columns.
Syntax 1:
DESC tablename;
Syntax 2:
DESCRIBE tablename;
Example:
DESC Employee;
Column
Datatype
...
As we know that there are also some built in directives provided by angular js. Apart from these we can also create our own custom directives by using .directive function.
When we are naming a directive we must ensure that it should be in camel ...
If you want to create a report for the Session mode follow the below code in your Odoo module. And for each session, it should display session's name, its start and end, and list the session's attendees.
openacademy/__openerp__.py
...
If you want to register attendees to multiple sessions follow the below code in your Odoo module.
<group>
<field name="session_ids">
<field name="attendee_ids...
$state.go(to [, toParams] [, options])
It returns Promise which represents the state of transition.
It is the convenience method for transitioning to a new state. $state.go calls $state.transitionTo internally but automatically sets options to ...
View for wizard is used to show the value in current database, add buttons to the wizard and implement the corresponding method for adding the attendees to the given session.
For example you can see below code.
...
Jquery filter( selector) method:-
It is one of the most important method which we can use to filter out elements from a list of DOM elements.
It removes all elements from the set of matched elements that do not match the specified selector(s)...
While using pop-up in your code you need to use update panel for that.
So if you have server side controls inside that pop-up sometimes these events are not triggered as usual because of update panel.
What you need to do...
In python search function searches for first occurrence of RE pattern within string with optional flags.
The search function is used to re.search function and returns a match object on success.
use the below syntax for search function in .py ...
Launching wizards is use to show the view of any project in Odoo and using an ir.actions.act_window record like above, but with an extra field src_model which specifies that in the context of which model the the action is available. The wizard wi...
In python your extension module is the initialization function and This function is called by the Python interpreter when the module is loaded. the function is named initModule.
use the below function in your own module in .py file,
PyMODINIT...
Wizards is used to show the view of any project in Odoo and the interactive sessions with user (or dialog boxes) through dynamic forms is also described by Wizards. A wizard is simply a model that extends the class TransientModel instead of Model...
Hello Everyone, today I will guide you "To pass JSON in AJAX ".
In the below code information is a variable that store JSON. We can pass this variable into AJAX data and get user records, and show it into a userDetail <div>.
You can us...
While using sessions user must have to be cautious while invoking and destroying it
When user login into the page session gets created from the database details
Ex : session["userid"]=obj.getsessionid();
While logout we mus...
In python method mapping table is an array of PyMethodDef structures which creates this (PyMethodDef) structure through a function and the table needs to be terminated with a sentinel that consists of NULL and 0 values for the appropriate members...
The Tooltip plugin is used to show the details of an element when the user will hover on that element. It will show a small pop-up in the specified position to the element.
You have to use data-toggle="tooltip" attribute and a title in the ele...
Hi Guys,
Here i am posting that how you can use image with color in background.
<div>
block {
background: #1e7f00 url("http://api.ning.com/files/rBZCY6X2uOlTJ8P9qLiTaHrX71x-bhRd9qAkTQBwNkSJPHtbC0Md09jy7l2JFbAGIWeexn8YrPUqqxKklZ5...
Hello Readers,
Most of the JavaScript libraries use $ sign as a function or other variable name, just as jQuery does. In jQuery's case, $ sign is used just an alias for jQuery, so here all functionality is available without using $ sign.
...
Hello Reader if you wan to make range selector UI using jquery this blog will be helpfull to you.
Lets start making this UI. First you have to create html file and it's code will go like this:-
<!doctype html>
<html lang="en"> ...
Hello Readers,
Jquery .index() method generally used to search for a define element within the jQuery object which it is called on. Jquery .index() method has 4 different signatures with different semantics which can be confusing. In this ...
Generic view declaration is most important part of Odoo module. Here a view is declared as a record of the model ir.ui.view. The view type is implied by the root element of the arch field.
For example code is below.
<record ...
Hello Reader if you are making the content based website where you want to show div in bounce or blink effect. Here this code is driven by Jquery.
First create html file with name bounce.html and its code will go like this:-
<!DOCTYPE h...
As in my previous blog display content in OpenERP/Odoo the same process will we followed for odoo9, and they are:-
Widgets have a number of methods and features, but the basics are simple:
1. set up a widget
2. format the widget's data
3. d...
Widgets are most powerful workstation and the Odoo web client bundles jQuery for easy DOM manipulation. It is useful and provides a better API then standard W3C DOM2, but it is insufficient to structure complex applications which l...
Hello Readers if you are designing the html UI and you want to make div resizable by mouse then you can use the code as below:-
<!doctype html>
<html lang="en">
<head>
<link href="http://code.jquery.com...
Delegation is most important for odoo module, it is the third inheritance mechanism which provides more flexibility (it can be altered at runtime) but less power: using the _inherits a model delegates the lookup of any field n...
Inheritance and extension in odoo9 is used to set one page to another page and Odoo provides three different mechanisms to extend models in a modular way.
1. creating a new model from an existing one, adding new information to the copy but leavi...
Hello Reader if you want to hide or disappear a div then you can do it by exlpode effect. This will driven by Jquery.
First create a blank html file name is exlodeeffect.html and its code will go like this:-
<html lang="en">
&...
Hello Readers if you want to make a switch button that will increase your font size of webpage then you can learn to code it here.
first you have to create html page name it click.html, It's code will go like this:-
<!doctype html>
...
Automatic fileds used to set onchange function and operation is given below
id
Identifier field
_log_access
Whether log access fields (create_date, write_uid, ...) should be generated (default: True)
create_date
Date at wh...
Hello Reader's if you want to make a UI where your div can drag and movable all over the screen. Then the followin example is helful to you.
<!DOCTYPE html>
<head>
<link href="http://code.jquery.com/ui/1.10.4/themes/ui-...
Environment swapping is most important for odoo module and with_context([context][, **overrides]) records[source]
It Returns a new version of this recordset attached to an extended context.
The extended context is either the provided cont...
Recordset operations is used to make ids and function in Odoo module. The operation are given below.
ids
List of actual record ids in this recordset (ignores placeholder ids for records to create)
ensure_one()
Verifies that the current recors...
Hello Reader's if want to generate the date selector then you can use the Javascript. By choosing JS you don't have to write every month, day or date hard core in the code.
Lets start to generate the code for it.
Step 1: Create head section ...