Skip to content

Instantly share code, notes, and snippets.

View tienhieuD's full-sized avatar
🦶
hmmm

DUONG TIEN HIEU tienhieuD

🦶
hmmm
View GitHub Profile
// js - model
// xml - view
// điịnh nghiĩa 1 caái model js
// taạo js
// gõ
odoo.define('omi_core.chat_client_action', function (require) {
"use strict";
from odoo import http
class SearchController(http.Controller):
@http.route('/fresh_crm/search_json/', type='json', auth='public')
def search_json(self, keyword, **kwargs):
"""
Search all data from list config model
:param keyword: the keyword to search
:param kwargs: optional (domain, order, limit, offset, model)

Add to Cart

<script>
$('.product-action-cart, .product__add-to-cart').on('click', function() {
	var product_id = $(this).data('product-id');
    fbq('track', 'AddToCart', {
		content_ids: [product_id.toString()],
        content_type: 'product',
      	// product_catalog_id: '1',
# -*- coding: utf-8 -*-
import functools
import json
import werkzeug
from odoo import http
from odoo.http import _logger, serialize_exception as _serialize_exception
from odoo.addons.web.controllers import main
1. Hiểu rõ các bước cài đặt và cấu hình các tham số cho odoo-bin
2. Biết cách cài module từ bên ngoài, và tự xây dựng một module của mình
3. Biết cách sử dụng các loại model trong odoo.
	a. Mixin model (res.config …. )
	b. Biết cách dùng các field cơ bản, hiểu rõ các field quan hệ, (compute)
	c. Hiểu rõ decorator api và cách dùng, dùng khi nào
4. extenal id, Menu và action
5. Các loại view cơ bản: form, tree, kanban, search, grapth, pivot, qweb
	a. Tạo dữ demo xml

b. Tạo dữ liệu với python

/*****************
* Author: Boris Dongarov (ideafixxxer)
*
* http://www.codeproject.com/Members/ideafixxxer
*
******************/
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
<link href="css/header_style.css" rel="stylesheet"/>
<link href="css/visa_style.css" rel="stylesheet"/>
<link href="css/paygate.css" rel="stylesheet"/>
<link href="css/slider.css" rel="stylesheet" type="text/css"/>
<link href="css/service_style.css" rel="stylesheet" type="text/css"/>
<button type="button" class="btn btn-primary em_btn_single" data-toggle="modal" data-target="#exampleModal">
Thanh toán
</button>
@tienhieuD
tienhieuD / bootstrap-masonry-plugin.js
Created September 29, 2018 04:37 — forked from alessandroraffa/bootstrap-masonry-plugin.js
Responsive Bootstrap 3 Masonry
$(document).ready(function () {
var masonryOptions = {
columnWidth: '.masonry-sizer',
itemSelector: '.masonry-item',
percentPosition: true
};
var $masonryContainer = $('.masonry-container');
var masonryBreakpoint = 767; // change this as you wish
var masonryActive = false;
var activateMasonry = function () {
<ul class="lv1">
<li><a href="#" style="
width: unset;
display: block;
">
<img class="icobred" src="https://dummyimage.com/20x20/999/fff&amp;text=ic">DANH MỤC
</a>
<ul class="lv2" style="
position: relative;
display: block;
@tienhieuD
tienhieuD / hot-item.less
Created September 3, 2018 10:16
hapu, gia thuoc hapu, gia thuoc hapu, entrustlab
a.hot-item {
position: relative;
overflow: hidden;
&::before {
content: 'Hot';
width: 112px;
height: auto;
color: white;
background: #0087ff;
position: absolute;