mirror of
https://github.com/ForgeFlow/stock-rma.git
synced 2025-01-21 12:57:49 +02:00
Merge pull request #136 from ForgeFlow/13.0-update-lints
[IMP] Update pre-commit lints according with OCA ones
This commit is contained in:
@@ -7,11 +7,11 @@ indent_style = space
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
[.eslintrc,*.{json,yml,yaml,rst,md}]
|
||||
[*.{json,yml,yaml,rst,md}]
|
||||
indent_size = 2
|
||||
|
||||
# Do not configure editor for libs and autogenerated content
|
||||
[*/static/{lib,src/lib}/**,*/static/description/index.html,*/readme/../README.rst]
|
||||
[{*/static/{lib,src/lib}/**,*/static/description/index.html,*/readme/../README.rst}]
|
||||
charset = unset
|
||||
end_of_line = unset
|
||||
indent_size = unset
|
||||
|
||||
291
.eslintrc
291
.eslintrc
@@ -1,291 +0,0 @@
|
||||
{
|
||||
"globals": {
|
||||
"$": false,
|
||||
"_": false,
|
||||
"fuzzy": false,
|
||||
"jQuery": false,
|
||||
"moment": false,
|
||||
"odoo": false,
|
||||
"openerp": false,
|
||||
"self": false
|
||||
},
|
||||
"env": {
|
||||
"browser": true
|
||||
},
|
||||
"rules": {
|
||||
"no-alert": "warn",
|
||||
"no-array-constructor": "warn",
|
||||
"no-bitwise": "off",
|
||||
"no-caller": "warn",
|
||||
"no-case-declarations": "warn",
|
||||
"no-catch-shadow": "warn",
|
||||
"no-class-assign": "warn",
|
||||
"no-cond-assign": "warn",
|
||||
"no-confusing-arrow": "warn",
|
||||
"no-console": "off",
|
||||
"no-const-assign": "warn",
|
||||
"no-constant-condition": "warn",
|
||||
"no-continue": "off",
|
||||
"no-control-regex": "warn",
|
||||
"no-debugger": "warn",
|
||||
"no-delete-var": "warn",
|
||||
"no-div-regex": "warn",
|
||||
"no-dupe-args": "warn",
|
||||
"no-dupe-class-members": "warn",
|
||||
"no-dupe-keys": "warn",
|
||||
"no-duplicate-case": "warn",
|
||||
"no-duplicate-imports": "warn",
|
||||
"no-else-return": "warn",
|
||||
"no-empty": "warn",
|
||||
"no-empty-character-class": "warn",
|
||||
"no-empty-function": "warn",
|
||||
"no-empty-pattern": "warn",
|
||||
"no-eq-null": "warn",
|
||||
"no-eval": "warn",
|
||||
"no-ex-assign": "warn",
|
||||
"no-extend-native": "warn",
|
||||
"no-extra-bind": "warn",
|
||||
"no-extra-boolean-cast": "warn",
|
||||
"no-extra-label": "warn",
|
||||
"no-extra-parens": "warn",
|
||||
"no-extra-semi": "warn",
|
||||
"no-fallthrough": "warn",
|
||||
"no-floating-decimal": "warn",
|
||||
"no-func-assign": "warn",
|
||||
"no-implicit-coercion": ["warn", {
|
||||
"allow": ["~"]
|
||||
}],
|
||||
"no-implicit-globals": "warn",
|
||||
"no-implied-eval": "warn",
|
||||
"no-inline-comments": "warn",
|
||||
"no-inner-declarations": "warn",
|
||||
"no-invalid-regexp": "warn",
|
||||
"no-invalid-this": "off",
|
||||
"no-irregular-whitespace": "warn",
|
||||
"no-iterator": "warn",
|
||||
"no-label-var": "warn",
|
||||
"no-labels": "warn",
|
||||
"no-lone-blocks": "warn",
|
||||
"no-lonely-if": "warn",
|
||||
"no-loop-func": "off",
|
||||
"no-magic-numbers": "off",
|
||||
"no-mixed-operators": "warn",
|
||||
"no-mixed-requires": "warn",
|
||||
"no-mixed-spaces-and-tabs": "warn",
|
||||
"no-multi-spaces": "warn",
|
||||
"no-multi-str": "warn",
|
||||
"no-multiple-empty-lines": "warn",
|
||||
"no-native-reassign": "warn",
|
||||
"no-negated-condition": "warn",
|
||||
"no-negated-in-lhs": "warn",
|
||||
"no-nested-ternary": "off",
|
||||
"no-new": "warn",
|
||||
"no-new-func": "warn",
|
||||
"no-new-object": "warn",
|
||||
"no-new-require": "warn",
|
||||
"no-new-symbol": "warn",
|
||||
"no-new-wrappers": "warn",
|
||||
"no-obj-calls": "warn",
|
||||
"no-octal": "warn",
|
||||
"no-octal-escape": "warn",
|
||||
"no-param-reassign": "warn",
|
||||
"no-path-concat": "warn",
|
||||
"no-plusplus": "off",
|
||||
"no-process-env": "warn",
|
||||
"no-process-exit": "warn",
|
||||
"no-proto": "warn",
|
||||
"no-prototype-builtins": "warn",
|
||||
"no-redeclare": "warn",
|
||||
"no-regex-spaces": "warn",
|
||||
"no-restricted-globals": "warn",
|
||||
"no-restricted-imports": "warn",
|
||||
"no-restricted-modules": "warn",
|
||||
"no-restricted-syntax": "warn",
|
||||
"no-return-assign": "warn",
|
||||
"no-script-url": "warn",
|
||||
"no-self-assign": "warn",
|
||||
"no-self-compare": "warn",
|
||||
"no-sequences": "warn",
|
||||
"no-shadow": "warn",
|
||||
"no-shadow-restricted-names": "warn",
|
||||
"no-whitespace-before-property": "warn",
|
||||
"no-spaced-func": "warn",
|
||||
"no-sparse-arrays": "warn",
|
||||
"no-sync": "warn",
|
||||
"no-tabs": "warn",
|
||||
"no-ternary": "off",
|
||||
"no-trailing-spaces": "warn",
|
||||
"no-this-before-super": "warn",
|
||||
"no-throw-literal": "warn",
|
||||
"no-undef": "warn",
|
||||
"no-undef-init": "warn",
|
||||
"no-undefined": "off",
|
||||
"no-unexpected-multiline": "warn",
|
||||
"no-underscore-dangle": "off",
|
||||
"no-unmodified-loop-condition": "warn",
|
||||
"no-unneeded-ternary": "warn",
|
||||
"no-unreachable": "warn",
|
||||
"no-unsafe-finally": "warn",
|
||||
"no-unused-expressions": "warn",
|
||||
"no-unused-labels": "warn",
|
||||
"no-unused-vars": "warn",
|
||||
"no-use-before-define": "warn",
|
||||
"no-useless-call": "warn",
|
||||
"no-useless-computed-key": "warn",
|
||||
"no-useless-concat": "warn",
|
||||
"no-useless-constructor": "warn",
|
||||
"no-useless-escape": "warn",
|
||||
"no-useless-rename": "warn",
|
||||
"no-void": "warn",
|
||||
"no-var": "off",
|
||||
"no-warning-comments": "off",
|
||||
"no-with": "warn",
|
||||
"array-bracket-spacing": "off",
|
||||
"array-callback-return": "warn",
|
||||
"arrow-body-style": "warn",
|
||||
"arrow-parens": "warn",
|
||||
"arrow-spacing": "off",
|
||||
"accessor-pairs": "warn",
|
||||
"block-scoped-var": "off",
|
||||
"block-spacing": ["warn", "always"],
|
||||
"brace-style": "warn",
|
||||
"callback-return": "warn",
|
||||
"camelcase": "off",
|
||||
"capitalized-comments": ["warn", "always", {
|
||||
"ignoreConsecutiveComments": true,
|
||||
"ignoreInlineComments": true
|
||||
}],
|
||||
"comma-dangle": ["warn", "always-multiline"],
|
||||
"comma-spacing": ["warn", {
|
||||
"before": false,
|
||||
"after": true
|
||||
}],
|
||||
"comma-style": "warn",
|
||||
"complexity": [
|
||||
"warn",
|
||||
15
|
||||
],
|
||||
"computed-property-spacing": "off",
|
||||
"consistent-return": "off",
|
||||
"consistent-this": "off",
|
||||
"constructor-super": "warn",
|
||||
"curly": "warn",
|
||||
"default-case": "off",
|
||||
"dot-location": ["warn", "property"],
|
||||
"dot-notation": "warn",
|
||||
"eol-last": "warn",
|
||||
"eqeqeq": "warn",
|
||||
"func-names": "off",
|
||||
"func-style": "off",
|
||||
"generator-star-spacing": "off",
|
||||
"global-require": "warn",
|
||||
"guard-for-in": "off",
|
||||
"handle-callback-err": "warn",
|
||||
"id-blacklist": "warn",
|
||||
"id-length": "off",
|
||||
"id-match": "warn",
|
||||
"indent": "warn",
|
||||
"init-declarations": "warn",
|
||||
"jsx-quotes": "warn",
|
||||
"key-spacing": "off",
|
||||
"keyword-spacing": "warn",
|
||||
"linebreak-style": [
|
||||
"warn",
|
||||
"unix"
|
||||
],
|
||||
"lines-around-comment": "warn",
|
||||
"max-depth": "warn",
|
||||
"max-len": ["warn", {
|
||||
"code": 88,
|
||||
"ignorePattern": "odoo\\.define\\(",
|
||||
"tabWidth": 4
|
||||
}],
|
||||
"max-lines": "off",
|
||||
"max-nested-callbacks": "warn",
|
||||
"max-params": "off",
|
||||
"max-statements": "off",
|
||||
"max-statements-per-line": "warn",
|
||||
"multiline-ternary": "off",
|
||||
"new-cap": "off",
|
||||
"new-parens": "warn",
|
||||
"newline-after-var": "off",
|
||||
"newline-before-return": "off",
|
||||
"newline-per-chained-call": "off",
|
||||
"object-curly-newline": ["warn", { "consistent": true }],
|
||||
"object-curly-spacing": ["warn", "never"],
|
||||
"object-property-newline": ["warn", {
|
||||
"allowAllPropertiesOnSameLine": true
|
||||
}],
|
||||
"object-shorthand": "off",
|
||||
"one-var": "off",
|
||||
"one-var-declaration-per-line": "off",
|
||||
"operator-assignment": "warn",
|
||||
"operator-linebreak": "warn",
|
||||
"padded-blocks": "off",
|
||||
"prefer-arrow-callback": "off",
|
||||
"prefer-const": "warn",
|
||||
"prefer-reflect": "off",
|
||||
"prefer-rest-params": "off",
|
||||
"prefer-spread": "off",
|
||||
"prefer-template": "off",
|
||||
"quote-props": "off",
|
||||
"quotes": "off",
|
||||
"radix": "warn",
|
||||
"require-yield": "warn",
|
||||
"rest-spread-spacing": "off",
|
||||
"semi": [
|
||||
"warn",
|
||||
"always"
|
||||
],
|
||||
"semi-spacing": "warn",
|
||||
"sort-imports": "warn",
|
||||
"sort-vars": "off",
|
||||
"space-before-blocks": "warn",
|
||||
"space-before-function-paren": "warn",
|
||||
"space-in-parens": "off",
|
||||
"space-infix-ops": "off",
|
||||
"space-unary-ops": "off",
|
||||
"spaced-comment": ["warn", "always"],
|
||||
"strict": ["warn", "function"],
|
||||
"template-curly-spacing": "off",
|
||||
"unicode-bom": "warn",
|
||||
"use-isnan": "warn",
|
||||
"valid-jsdoc": ["warn", {
|
||||
"prefer": {
|
||||
"arg": "param",
|
||||
"argument": "param",
|
||||
"augments": "extends",
|
||||
"constructor": "class",
|
||||
"exception": "throws",
|
||||
"func": "function",
|
||||
"method": "function",
|
||||
"prop": "property",
|
||||
"return": "returns",
|
||||
"virtual": "abstract",
|
||||
"yield": "yields"
|
||||
},
|
||||
"preferType": {
|
||||
"array": "Array",
|
||||
"bool": "Boolean",
|
||||
"boolean": "Boolean",
|
||||
"number": "Number",
|
||||
"object": "Object",
|
||||
"str": "String",
|
||||
"string": "String"
|
||||
},
|
||||
"requireParamDescription": false,
|
||||
"requireReturn": false,
|
||||
"requireReturnDescription": false,
|
||||
"requireReturnType": false
|
||||
}],
|
||||
"valid-typeof": "warn",
|
||||
"vars-on-top": "off",
|
||||
"wrap-iife": "warn",
|
||||
"wrap-regex": "warn",
|
||||
"yield-star-spacing": "off",
|
||||
"yoda": "warn"
|
||||
},
|
||||
"parserOptions": {
|
||||
"ecmaVersion": 2017
|
||||
}
|
||||
}
|
||||
282
.eslintrc.yml
Normal file
282
.eslintrc.yml
Normal file
@@ -0,0 +1,282 @@
|
||||
{
|
||||
"globals":
|
||||
{
|
||||
"$": false,
|
||||
"_": false,
|
||||
"fuzzy": false,
|
||||
"jQuery": false,
|
||||
"moment": false,
|
||||
"odoo": false,
|
||||
"openerp": false,
|
||||
"self": false,
|
||||
},
|
||||
"env": { "browser": true },
|
||||
"rules":
|
||||
{
|
||||
"no-alert": "warn",
|
||||
"no-array-constructor": "warn",
|
||||
"no-bitwise": "off",
|
||||
"no-caller": "warn",
|
||||
"no-case-declarations": "warn",
|
||||
"no-catch-shadow": "warn",
|
||||
"no-class-assign": "warn",
|
||||
"no-cond-assign": "warn",
|
||||
"no-confusing-arrow": "warn",
|
||||
"no-console": "off",
|
||||
"no-const-assign": "warn",
|
||||
"no-constant-condition": "warn",
|
||||
"no-continue": "off",
|
||||
"no-control-regex": "warn",
|
||||
"no-debugger": "warn",
|
||||
"no-delete-var": "warn",
|
||||
"no-div-regex": "warn",
|
||||
"no-dupe-args": "warn",
|
||||
"no-dupe-class-members": "warn",
|
||||
"no-dupe-keys": "warn",
|
||||
"no-duplicate-case": "warn",
|
||||
"no-duplicate-imports": "warn",
|
||||
"no-else-return": "warn",
|
||||
"no-empty": "warn",
|
||||
"no-empty-character-class": "warn",
|
||||
"no-empty-function": "warn",
|
||||
"no-empty-pattern": "warn",
|
||||
"no-eq-null": "warn",
|
||||
"no-eval": "warn",
|
||||
"no-ex-assign": "warn",
|
||||
"no-extend-native": "warn",
|
||||
"no-extra-bind": "warn",
|
||||
"no-extra-boolean-cast": "warn",
|
||||
"no-extra-label": "warn",
|
||||
"no-extra-parens": "warn",
|
||||
"no-extra-semi": "warn",
|
||||
"no-fallthrough": "warn",
|
||||
"no-floating-decimal": "warn",
|
||||
"no-func-assign": "warn",
|
||||
"no-implicit-coercion": ["warn", { "allow": ["~"] }],
|
||||
"no-implicit-globals": "warn",
|
||||
"no-implied-eval": "warn",
|
||||
"no-inline-comments": "warn",
|
||||
"no-inner-declarations": "warn",
|
||||
"no-invalid-regexp": "warn",
|
||||
"no-invalid-this": "off",
|
||||
"no-irregular-whitespace": "warn",
|
||||
"no-iterator": "warn",
|
||||
"no-label-var": "warn",
|
||||
"no-labels": "warn",
|
||||
"no-lone-blocks": "warn",
|
||||
"no-lonely-if": "warn",
|
||||
"no-loop-func": "off",
|
||||
"no-magic-numbers": "off",
|
||||
"no-mixed-operators": "warn",
|
||||
"no-mixed-requires": "warn",
|
||||
"no-mixed-spaces-and-tabs": "warn",
|
||||
"no-multi-spaces": "warn",
|
||||
"no-multi-str": "warn",
|
||||
"no-multiple-empty-lines": "warn",
|
||||
"no-native-reassign": "warn",
|
||||
"no-negated-condition": "warn",
|
||||
"no-negated-in-lhs": "warn",
|
||||
"no-nested-ternary": "off",
|
||||
"no-new": "warn",
|
||||
"no-new-func": "warn",
|
||||
"no-new-object": "warn",
|
||||
"no-new-require": "warn",
|
||||
"no-new-symbol": "warn",
|
||||
"no-new-wrappers": "warn",
|
||||
"no-obj-calls": "warn",
|
||||
"no-octal": "warn",
|
||||
"no-octal-escape": "warn",
|
||||
"no-param-reassign": "warn",
|
||||
"no-path-concat": "warn",
|
||||
"no-plusplus": "off",
|
||||
"no-process-env": "warn",
|
||||
"no-process-exit": "warn",
|
||||
"no-proto": "warn",
|
||||
"no-prototype-builtins": "warn",
|
||||
"no-redeclare": "warn",
|
||||
"no-regex-spaces": "warn",
|
||||
"no-restricted-globals": "warn",
|
||||
"no-restricted-imports": "warn",
|
||||
"no-restricted-modules": "warn",
|
||||
"no-restricted-syntax": "warn",
|
||||
"no-return-assign": "warn",
|
||||
"no-script-url": "warn",
|
||||
"no-self-assign": "warn",
|
||||
"no-self-compare": "warn",
|
||||
"no-sequences": "warn",
|
||||
"no-shadow": "warn",
|
||||
"no-shadow-restricted-names": "warn",
|
||||
"no-whitespace-before-property": "warn",
|
||||
"no-spaced-func": "warn",
|
||||
"no-sparse-arrays": "warn",
|
||||
"no-sync": "warn",
|
||||
"no-tabs": "warn",
|
||||
"no-ternary": "off",
|
||||
"no-trailing-spaces": "warn",
|
||||
"no-this-before-super": "warn",
|
||||
"no-throw-literal": "warn",
|
||||
"no-undef": "warn",
|
||||
"no-undef-init": "warn",
|
||||
"no-undefined": "off",
|
||||
"no-unexpected-multiline": "warn",
|
||||
"no-underscore-dangle": "off",
|
||||
"no-unmodified-loop-condition": "warn",
|
||||
"no-unneeded-ternary": "warn",
|
||||
"no-unreachable": "warn",
|
||||
"no-unsafe-finally": "warn",
|
||||
"no-unused-expressions": "warn",
|
||||
"no-unused-labels": "warn",
|
||||
"no-unused-vars": "warn",
|
||||
"no-use-before-define": "warn",
|
||||
"no-useless-call": "warn",
|
||||
"no-useless-computed-key": "warn",
|
||||
"no-useless-concat": "warn",
|
||||
"no-useless-constructor": "warn",
|
||||
"no-useless-escape": "warn",
|
||||
"no-useless-rename": "warn",
|
||||
"no-void": "warn",
|
||||
"no-var": "off",
|
||||
"no-warning-comments": "off",
|
||||
"no-with": "warn",
|
||||
"array-bracket-spacing": "off",
|
||||
"array-callback-return": "warn",
|
||||
"arrow-body-style": "warn",
|
||||
"arrow-parens": "warn",
|
||||
"arrow-spacing": "off",
|
||||
"accessor-pairs": "warn",
|
||||
"block-scoped-var": "off",
|
||||
"block-spacing": ["warn", "always"],
|
||||
"brace-style": "warn",
|
||||
"callback-return": "warn",
|
||||
"camelcase": "off",
|
||||
"capitalized-comments":
|
||||
[
|
||||
"warn",
|
||||
"always",
|
||||
{ "ignoreConsecutiveComments": true, "ignoreInlineComments": true },
|
||||
],
|
||||
"comma-dangle": ["warn", "always-multiline"],
|
||||
"comma-spacing": ["warn", { "before": false, "after": true }],
|
||||
"comma-style": "warn",
|
||||
"complexity": ["warn", 15],
|
||||
"computed-property-spacing": "off",
|
||||
"consistent-return": "off",
|
||||
"consistent-this": "off",
|
||||
"constructor-super": "warn",
|
||||
"curly": "warn",
|
||||
"default-case": "off",
|
||||
"dot-location": ["warn", "property"],
|
||||
"dot-notation": "warn",
|
||||
"eol-last": "warn",
|
||||
"eqeqeq": "warn",
|
||||
"func-names": "off",
|
||||
"func-style": "off",
|
||||
"generator-star-spacing": "off",
|
||||
"global-require": "warn",
|
||||
"guard-for-in": "off",
|
||||
"handle-callback-err": "warn",
|
||||
"id-blacklist": "warn",
|
||||
"id-length": "off",
|
||||
"id-match": "warn",
|
||||
"indent": "warn",
|
||||
"init-declarations": "warn",
|
||||
"jsx-quotes": "warn",
|
||||
"key-spacing": "off",
|
||||
"keyword-spacing": "warn",
|
||||
"linebreak-style": ["warn", "unix"],
|
||||
"lines-around-comment": "warn",
|
||||
"max-depth": "warn",
|
||||
"max-len":
|
||||
[
|
||||
"warn",
|
||||
{ "code": 88, "ignorePattern": "odoo\\.define\\(", "tabWidth": 4 },
|
||||
],
|
||||
"max-lines": "off",
|
||||
"max-nested-callbacks": "warn",
|
||||
"max-params": "off",
|
||||
"max-statements": "off",
|
||||
"max-statements-per-line": "warn",
|
||||
"multiline-ternary": "off",
|
||||
"new-cap": "off",
|
||||
"new-parens": "warn",
|
||||
"newline-after-var": "off",
|
||||
"newline-before-return": "off",
|
||||
"newline-per-chained-call": "off",
|
||||
"object-curly-newline": ["warn", { "consistent": true }],
|
||||
"object-curly-spacing": ["warn", "never"],
|
||||
"object-property-newline":
|
||||
["warn", { "allowAllPropertiesOnSameLine": true }],
|
||||
"object-shorthand": "off",
|
||||
"one-var": "off",
|
||||
"one-var-declaration-per-line": "off",
|
||||
"operator-assignment": "warn",
|
||||
"operator-linebreak": "warn",
|
||||
"padded-blocks": "off",
|
||||
"prefer-arrow-callback": "off",
|
||||
"prefer-const": "warn",
|
||||
"prefer-reflect": "off",
|
||||
"prefer-rest-params": "off",
|
||||
"prefer-spread": "off",
|
||||
"prefer-template": "off",
|
||||
"quote-props": "off",
|
||||
"quotes": "off",
|
||||
"radix": "warn",
|
||||
"require-yield": "warn",
|
||||
"rest-spread-spacing": "off",
|
||||
"semi": ["warn", "always"],
|
||||
"semi-spacing": "warn",
|
||||
"sort-imports": "warn",
|
||||
"sort-vars": "off",
|
||||
"space-before-blocks": "warn",
|
||||
"space-before-function-paren": "warn",
|
||||
"space-in-parens": "off",
|
||||
"space-infix-ops": "off",
|
||||
"space-unary-ops": "off",
|
||||
"spaced-comment": ["warn", "always"],
|
||||
"strict": ["warn", "function"],
|
||||
"template-curly-spacing": "off",
|
||||
"unicode-bom": "warn",
|
||||
"use-isnan": "warn",
|
||||
"valid-jsdoc":
|
||||
[
|
||||
"warn",
|
||||
{
|
||||
"prefer":
|
||||
{
|
||||
"arg": "param",
|
||||
"argument": "param",
|
||||
"augments": "extends",
|
||||
"constructor": "class",
|
||||
"exception": "throws",
|
||||
"func": "function",
|
||||
"method": "function",
|
||||
"prop": "property",
|
||||
"return": "returns",
|
||||
"virtual": "abstract",
|
||||
"yield": "yields",
|
||||
},
|
||||
"preferType":
|
||||
{
|
||||
"array": "Array",
|
||||
"bool": "Boolean",
|
||||
"boolean": "Boolean",
|
||||
"number": "Number",
|
||||
"object": "Object",
|
||||
"str": "String",
|
||||
"string": "String",
|
||||
},
|
||||
"requireParamDescription": false,
|
||||
"requireReturn": false,
|
||||
"requireReturnDescription": false,
|
||||
"requireReturnType": false,
|
||||
},
|
||||
],
|
||||
"valid-typeof": "warn",
|
||||
"vars-on-top": "off",
|
||||
"wrap-iife": "warn",
|
||||
"wrap-regex": "warn",
|
||||
"yield-star-spacing": "off",
|
||||
"yoda": "warn",
|
||||
},
|
||||
"parserOptions": { "ecmaVersion": 2017 },
|
||||
}
|
||||
@@ -9,4 +9,4 @@ line_length=88
|
||||
known_odoo=odoo
|
||||
known_odoo_addons=odoo.addons
|
||||
sections=FUTURE,STDLIB,THIRDPARTY,ODOO,ODOO_ADDONS,FIRSTPARTY,LOCALFOLDER
|
||||
known_third_party=
|
||||
default_section=THIRDPARTY
|
||||
|
||||
@@ -1,13 +1,47 @@
|
||||
exclude: "^setup/|/static/lib/|/static/src/lib/"
|
||||
exclude: |
|
||||
(?x)
|
||||
# Files and folders generated by bots, to avoid loops
|
||||
^setup/|/static/description/index\.html$|
|
||||
# Maybe reactivate this when all README files include prettier ignore tags?
|
||||
^README\.md$|
|
||||
# Library files can have extraneous formatting (even minimized)
|
||||
/static/(src/)?lib/|
|
||||
# Repos using Sphinx to generate docs don't need prettying
|
||||
^docs/_templates/.*\.html$|
|
||||
# You don't usually want a bot to modify your legal texts
|
||||
(LICENSE.*|COPYING.*)
|
||||
default_language_version:
|
||||
python: python3
|
||||
repos:
|
||||
- repo: https://github.com/psf/black
|
||||
rev: 19.3b0
|
||||
rev: 19.10b0
|
||||
hooks:
|
||||
- id: black
|
||||
- repo: https://github.com/prettier/prettier
|
||||
rev: "1.19.1"
|
||||
hooks:
|
||||
- id: prettier
|
||||
# TODO Avoid awebdeveloper/pre-commit-prettier if possible
|
||||
# HACK https://github.com/prettier/prettier/issues/7407
|
||||
- repo: https://github.com/awebdeveloper/pre-commit-prettier
|
||||
rev: v0.0.1
|
||||
hooks:
|
||||
- id: prettier
|
||||
name: prettier xml plugin
|
||||
additional_dependencies:
|
||||
- "prettier@1.19.1"
|
||||
- "@prettier/plugin-xml@0.7.2"
|
||||
files: \.xml$
|
||||
- repo: https://github.com/pre-commit/mirrors-eslint
|
||||
rev: v6.8.0
|
||||
hooks:
|
||||
- id: eslint
|
||||
verbose: true
|
||||
args:
|
||||
- --color
|
||||
- --fix
|
||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||
rev: v2.3.0
|
||||
rev: v2.4.0
|
||||
hooks:
|
||||
- id: trailing-whitespace
|
||||
# exclude autogenerated files
|
||||
@@ -16,6 +50,21 @@ repos:
|
||||
# exclude autogenerated files
|
||||
exclude: /README\.rst$|\.pot?$
|
||||
- id: debug-statements
|
||||
- id: fix-encoding-pragma
|
||||
args: ["--remove"]
|
||||
- id: check-case-conflict
|
||||
- id: check-docstring-first
|
||||
- id: check-executables-have-shebangs
|
||||
- id: check-merge-conflict
|
||||
# exclude files where underlines are not distinguishable from merge conflicts
|
||||
exclude: /README\.rst$|^docs/.*\.rst$
|
||||
- id: check-symlinks
|
||||
- id: check-xml
|
||||
- id: mixed-line-ending
|
||||
args: ["--fix=lf"]
|
||||
- repo: https://gitlab.com/pycqa/flake8
|
||||
rev: 3.7.9
|
||||
hooks:
|
||||
- id: flake8
|
||||
name: flake8 except __init__.py
|
||||
exclude: /__init__\.py$
|
||||
@@ -25,16 +74,6 @@ repos:
|
||||
args: ["--extend-ignore=F401"] # ignore unused imports in __init__.py
|
||||
files: /__init__\.py$
|
||||
additional_dependencies: ["flake8-bugbear==19.8.0"]
|
||||
- id: fix-encoding-pragma
|
||||
args: ["--remove"]
|
||||
- id: check-case-conflict
|
||||
- id: check-docstring-first
|
||||
- id: check-executables-have-shebangs
|
||||
- id: check-merge-conflict
|
||||
- id: check-symlinks
|
||||
- id: check-xml
|
||||
- id: mixed-line-ending
|
||||
args: ["--fix=lf"]
|
||||
- repo: https://github.com/pre-commit/mirrors-pylint
|
||||
rev: v2.3.1
|
||||
hooks:
|
||||
@@ -42,27 +81,22 @@ repos:
|
||||
name: pylint with optional checks
|
||||
args: ["--rcfile=.pylintrc", "--exit-zero"]
|
||||
verbose: true
|
||||
additional_dependencies: ["pylint-odoo==3.0.3"]
|
||||
additional_dependencies: ["pylint-odoo==3.1.0"]
|
||||
- id: pylint
|
||||
name: pylint with mandatory checks
|
||||
args: ["--rcfile=.pylintrc-mandatory"]
|
||||
additional_dependencies: ["pylint-odoo==3.0.3"]
|
||||
additional_dependencies: ["pylint-odoo==3.1.0"]
|
||||
- repo: https://github.com/asottile/pyupgrade
|
||||
rev: v1.24.0
|
||||
rev: v1.26.2
|
||||
hooks:
|
||||
- id: pyupgrade
|
||||
- repo: https://github.com/asottile/seed-isort-config
|
||||
rev: v1.9.3
|
||||
hooks:
|
||||
- id: seed-isort-config
|
||||
- repo: https://github.com/pre-commit/mirrors-isort
|
||||
rev: v4.3.21
|
||||
hooks:
|
||||
- id: isort
|
||||
name: isort except __init__.py
|
||||
exclude: /__init__\.py$
|
||||
- repo: https://github.com/pre-commit/mirrors-eslint
|
||||
rev: v6.5.1
|
||||
- repo: https://github.com/acsone/setuptools-odoo
|
||||
rev: 2.5.2
|
||||
hooks:
|
||||
- id: eslint
|
||||
verbose: true
|
||||
- id: setuptools-odoo-make-default
|
||||
|
||||
@@ -46,8 +46,10 @@
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_cust_out" />
|
||||
<field name="sequence_code">RMA → Customer</field>
|
||||
<field name="default_location_src_id" ref="rma.location_rma" />
|
||||
<field name="default_location_dest_id"
|
||||
ref="stock.stock_location_customers"/>
|
||||
<field
|
||||
name="default_location_dest_id"
|
||||
ref="stock.stock_location_customers"
|
||||
/>
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">outgoing</field>
|
||||
</record>
|
||||
@@ -56,9 +58,11 @@
|
||||
<field name="name">Customer → RMA</field>
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_cust_in" />
|
||||
<field name="sequence_code">Customer → RMA</field>
|
||||
<field name="default_location_src_id" ref="stock.stock_location_customers"/>
|
||||
<field name="default_location_dest_id"
|
||||
ref="rma.location_rma"/>
|
||||
<field
|
||||
name="default_location_src_id"
|
||||
ref="stock.stock_location_customers"
|
||||
/>
|
||||
<field name="default_location_dest_id" ref="rma.location_rma" />
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">incoming</field>
|
||||
</record>
|
||||
@@ -68,8 +72,10 @@
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_sup_out" />
|
||||
<field name="sequence_code">RMA -> Supplier</field>
|
||||
<field name="default_location_src_id" ref="rma.location_rma" />
|
||||
<field name="default_location_dest_id"
|
||||
ref="stock.stock_location_suppliers"/>
|
||||
<field
|
||||
name="default_location_dest_id"
|
||||
ref="stock.stock_location_suppliers"
|
||||
/>
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">outgoing</field>
|
||||
</record>
|
||||
@@ -78,9 +84,11 @@
|
||||
<field name="name">Supplier -> RMA</field>
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_sup_in" />
|
||||
<field name="sequence_code">Supplier -> RMA</field>
|
||||
<field name="default_location_src_id" ref="stock.stock_location_suppliers"/>
|
||||
<field name="default_location_dest_id"
|
||||
ref="rma.location_rma"/>
|
||||
<field
|
||||
name="default_location_src_id"
|
||||
ref="stock.stock_location_suppliers"
|
||||
/>
|
||||
<field name="default_location_dest_id" ref="rma.location_rma" />
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">incoming</field>
|
||||
</record>
|
||||
@@ -89,10 +97,14 @@
|
||||
<field name="name">Customer -> Supplier</field>
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_dropship" />
|
||||
<field name="sequence_code">Customer -> Supplier</field>
|
||||
<field name="default_location_src_id"
|
||||
ref="stock.stock_location_customers"/>
|
||||
<field name="default_location_dest_id"
|
||||
ref="stock.stock_location_suppliers"/>
|
||||
<field
|
||||
name="default_location_src_id"
|
||||
ref="stock.stock_location_customers"
|
||||
/>
|
||||
<field
|
||||
name="default_location_dest_id"
|
||||
ref="stock.stock_location_suppliers"
|
||||
/>
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">incoming</field>
|
||||
</record>
|
||||
@@ -101,10 +113,14 @@
|
||||
<field name="name">Supplier -> Customer</field>
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_dropship" />
|
||||
<field name="sequence_code">Supplier -> Customer</field>
|
||||
<field name="default_location_src_id"
|
||||
ref="stock.stock_location_suppliers"/>
|
||||
<field name="default_location_dest_id"
|
||||
ref="stock.stock_location_customers"/>
|
||||
<field
|
||||
name="default_location_src_id"
|
||||
ref="stock.stock_location_suppliers"
|
||||
/>
|
||||
<field
|
||||
name="default_location_dest_id"
|
||||
ref="stock.stock_location_customers"
|
||||
/>
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">incoming</field>
|
||||
</record>
|
||||
@@ -198,8 +214,10 @@
|
||||
<field name="location_src_id" ref="stock.stock_location_customers" />
|
||||
<field name="procure_method">make_to_stock</field>
|
||||
<field name="route_id" ref="rma.route_rma_dropship" />
|
||||
<field name="picking_type_id"
|
||||
ref="rma.picking_type_rma_dropship_return"/>
|
||||
<field
|
||||
name="picking_type_id"
|
||||
ref="rma.picking_type_rma_dropship_return"
|
||||
/>
|
||||
</record>
|
||||
|
||||
<record id="rule_rma_dropship" model="stock.rule">
|
||||
@@ -209,8 +227,7 @@
|
||||
<field name="location_src_id" ref="stock.stock_location_suppliers" />
|
||||
<field name="procure_method">make_to_stock</field>
|
||||
<field name="route_id" ref="rma.route_rma_dropship" />
|
||||
<field name="picking_type_id"
|
||||
ref="rma.picking_type_rma_dropship"/>
|
||||
<field name="picking_type_id" ref="rma.picking_type_rma_dropship" />
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -41,10 +41,14 @@
|
||||
<record id="picking_type_rma_dropship_return" model="stock.picking.type">
|
||||
<field name="name">Customer -> Supplier</field>
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_dropship" />
|
||||
<field name="default_location_src_id"
|
||||
ref="stock.stock_location_customers"/>
|
||||
<field name="default_location_dest_id"
|
||||
ref="stock.stock_location_suppliers"/>
|
||||
<field
|
||||
name="default_location_src_id"
|
||||
ref="stock.stock_location_customers"
|
||||
/>
|
||||
<field
|
||||
name="default_location_dest_id"
|
||||
ref="stock.stock_location_suppliers"
|
||||
/>
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">incoming</field>
|
||||
</record>
|
||||
@@ -52,10 +56,14 @@
|
||||
<record id="picking_type_rma_dropship" model="stock.picking.type">
|
||||
<field name="name">Supplier -> Customer</field>
|
||||
<field name="sequence_id" ref="seq_picking_type_rma_dropship" />
|
||||
<field name="default_location_src_id"
|
||||
ref="stock.stock_location_suppliers"/>
|
||||
<field name="default_location_dest_id"
|
||||
ref="stock.stock_location_customers"/>
|
||||
<field
|
||||
name="default_location_src_id"
|
||||
ref="stock.stock_location_suppliers"
|
||||
/>
|
||||
<field
|
||||
name="default_location_dest_id"
|
||||
ref="stock.stock_location_customers"
|
||||
/>
|
||||
<field name="warehouse_id" eval="False" />
|
||||
<field name="code">incoming</field>
|
||||
</record>
|
||||
@@ -97,8 +105,10 @@
|
||||
<field name="location_src_id" ref="stock.stock_location_customers" />
|
||||
<field name="procure_method">make_to_stock</field>
|
||||
<field name="route_id" ref="rma.route_rma_dropship" />
|
||||
<field name="picking_type_id"
|
||||
ref="rma.picking_type_rma_dropship_return"/>
|
||||
<field
|
||||
name="picking_type_id"
|
||||
ref="rma.picking_type_rma_dropship_return"
|
||||
/>
|
||||
</record>
|
||||
|
||||
<record id="rule_rma_dropship" model="stock.rule">
|
||||
@@ -109,8 +119,7 @@
|
||||
<field name="location_src_id" ref="stock.stock_location_suppliers" />
|
||||
<field name="procure_method">make_to_stock</field>
|
||||
<field name="route_id" ref="rma.route_rma_dropship" />
|
||||
<field name="picking_type_id"
|
||||
ref="rma.picking_type_rma_dropship"/>
|
||||
<field name="picking_type_id" ref="rma.picking_type_rma_dropship" />
|
||||
</record>
|
||||
|
||||
<!-- Enable the RMA in warehouse0 -->
|
||||
|
||||
@@ -2,37 +2,64 @@
|
||||
<odoo>
|
||||
<template id="report_rma_order_line_document">
|
||||
<t t-call="web.external_layout">
|
||||
<t t-set="doc" t-value="doc.with_context({'lang':doc.partner_id.lang})" />
|
||||
<t
|
||||
t-set="doc"
|
||||
t-value="doc.with_context({'lang':doc.partner_id.lang})"
|
||||
/>
|
||||
<div class="page">
|
||||
<div class="oe_structure" />
|
||||
<div class="row">
|
||||
<div class="col-6">
|
||||
<t t-if="(doc.customer_to_supplier==False and doc.type=='customer') or (doc.supplier_to_customer==False and doc.type=='supplier')">
|
||||
<t
|
||||
t-if="(doc.customer_to_supplier==False and doc.type=='customer') or (doc.supplier_to_customer==False and doc.type=='supplier')"
|
||||
>
|
||||
<strong>Shipping address:</strong>
|
||||
<div class="mt8">
|
||||
<div t-field="doc.in_warehouse_id.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'/>
|
||||
<p t-if="doc.in_warehouse_id.partner_id.vat">VAT: <span t-field="doc.in_warehouse_id.partner_id.vat"/></p>
|
||||
<div
|
||||
t-field="doc.in_warehouse_id.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'
|
||||
/>
|
||||
<p
|
||||
t-if="doc.in_warehouse_id.partner_id.vat"
|
||||
>VAT: <span
|
||||
t-field="doc.in_warehouse_id.partner_id.vat"
|
||||
/></p>
|
||||
</div>
|
||||
</t>
|
||||
<div t-if="doc.customer_to_supplier and doc.type=='customer'" class="mt8">
|
||||
<div
|
||||
t-if="doc.customer_to_supplier and doc.type=='customer'"
|
||||
class="mt8"
|
||||
>
|
||||
<strong>Shipping address:</strong>
|
||||
<div t-field="doc.supplier_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'/>
|
||||
<p t-if="doc.supplier_address_id.vat">VAT: <span t-field="doc.supplier_address_id.vat"/></p>
|
||||
<div
|
||||
t-field="doc.supplier_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'
|
||||
/>
|
||||
<p t-if="doc.supplier_address_id.vat">VAT: <span
|
||||
t-field="doc.supplier_address_id.vat"
|
||||
/></p>
|
||||
</div>
|
||||
<div t-if="doc.supplier_to_customer and doc.type=='supplier'" class="mt8">
|
||||
<div
|
||||
t-if="doc.supplier_to_customer and doc.type=='supplier'"
|
||||
class="mt8"
|
||||
>
|
||||
<strong>Shipping address:</strong>
|
||||
<div t-field="doc.customer_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'/>
|
||||
<p t-if="doc.customer_address_id.vat">VAT: <span t-field="doc.customer_address_id.vat"/></p>
|
||||
<div
|
||||
t-field="doc.customer_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'
|
||||
/>
|
||||
<p t-if="doc.customer_address_id.vat">VAT: <span
|
||||
t-field="doc.customer_address_id.vat"
|
||||
/></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-3 offset-1">
|
||||
<strong t-if="doc.type=='customer'">Customer:</strong>
|
||||
<strong t-if="doc.type=='supplier'">Supplier:</strong>
|
||||
<div t-field="doc.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name"], "no_marker": True}' />
|
||||
<div
|
||||
t-field="doc.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name"], "no_marker": True}'
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -53,7 +80,11 @@
|
||||
<strong>Contact Person:</strong>
|
||||
<p t-field="doc.requested_by.name" />
|
||||
</div>
|
||||
<div name="operation_id" t-if="doc.operation_id" class="col-3">
|
||||
<div
|
||||
name="operation_id"
|
||||
t-if="doc.operation_id"
|
||||
class="col-3"
|
||||
>
|
||||
<strong>Operation:</strong>
|
||||
<p t-field="doc.operation_id.name" />
|
||||
</div>
|
||||
@@ -72,21 +103,27 @@
|
||||
<td><span t-field="doc.product_id" /></td>
|
||||
<td class="text-right">
|
||||
<span t-field="doc.product_qty" />
|
||||
<span t-field="doc.uom_id" groups="uom.group_uom"/>
|
||||
<span
|
||||
t-field="doc.uom_id"
|
||||
groups="uom.group_uom"
|
||||
/>
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<span t-field="doc.price_unit" t-options='{"widget": "monetary", "display_currency": doc.currency_id}'/>
|
||||
<span
|
||||
t-field="doc.price_unit"
|
||||
t-options='{"widget": "monetary", "display_currency": doc.currency_id}'
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div t-if="doc.description">
|
||||
<strong><p>Description</p></strong>
|
||||
<span t-field="doc.description"></span>
|
||||
<span t-field="doc.description" />
|
||||
</div>
|
||||
<div t-if="doc.conditions">
|
||||
<strong><p>Term and conditions</p></strong>
|
||||
<span t-field="doc.conditions"></span>
|
||||
<span t-field="doc.conditions" />
|
||||
</div>
|
||||
</div>
|
||||
</t>
|
||||
@@ -96,7 +133,10 @@
|
||||
<template id="report_rma_order_line">
|
||||
<t t-call="web.html_container">
|
||||
<t t-foreach="docs" t-as="doc">
|
||||
<t t-call="rma.report_rma_order_line_document" t-lang="doc.partner_id.lang"/>
|
||||
<t
|
||||
t-call="rma.report_rma_order_line_document"
|
||||
t-lang="doc.partner_id.lang"
|
||||
/>
|
||||
</t>
|
||||
</t>
|
||||
</template>
|
||||
@@ -104,37 +144,64 @@
|
||||
|
||||
<template id="report_rma_order_document">
|
||||
<t t-call="web.external_layout">
|
||||
<t t-set="doc" t-value="doc.with_context({'lang':doc.partner_id.lang})" />
|
||||
<t
|
||||
t-set="doc"
|
||||
t-value="doc.with_context({'lang':doc.partner_id.lang})"
|
||||
/>
|
||||
<div class="page">
|
||||
<div class="oe_structure" />
|
||||
<div class="row">
|
||||
<div class="col-6">
|
||||
<t t-if="(doc.customer_to_supplier==False and doc.type=='customer') or (doc.supplier_to_customer==False and doc.type=='supplier')">
|
||||
<t
|
||||
t-if="(doc.customer_to_supplier==False and doc.type=='customer') or (doc.supplier_to_customer==False and doc.type=='supplier')"
|
||||
>
|
||||
<strong>Shipping address:</strong>
|
||||
<div class="mt8">
|
||||
<div t-field="doc.in_warehouse_id.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'/>
|
||||
<p t-if="doc.in_warehouse_id.partner_id.vat">VAT: <span t-field="doc.in_warehouse_id.partner_id.vat"/></p>
|
||||
<div
|
||||
t-field="doc.in_warehouse_id.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'
|
||||
/>
|
||||
<p
|
||||
t-if="doc.in_warehouse_id.partner_id.vat"
|
||||
>VAT: <span
|
||||
t-field="doc.in_warehouse_id.partner_id.vat"
|
||||
/></p>
|
||||
</div>
|
||||
</t>
|
||||
<div t-if="doc.customer_to_supplier and doc.type=='customer'" class="mt8">
|
||||
<div
|
||||
t-if="doc.customer_to_supplier and doc.type=='customer'"
|
||||
class="mt8"
|
||||
>
|
||||
<strong>Shipping address:</strong>
|
||||
<div t-field="doc.supplier_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'/>
|
||||
<p t-if="doc.supplier_address_id.vat">VAT: <span t-field="doc.supplier_address_id.vat"/></p>
|
||||
<div
|
||||
t-field="doc.supplier_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'
|
||||
/>
|
||||
<p t-if="doc.supplier_address_id.vat">VAT: <span
|
||||
t-field="doc.supplier_address_id.vat"
|
||||
/></p>
|
||||
</div>
|
||||
<div t-if="doc.supplier_to_customer and doc.type=='supplier'" class="mt8">
|
||||
<div
|
||||
t-if="doc.supplier_to_customer and doc.type=='supplier'"
|
||||
class="mt8"
|
||||
>
|
||||
<strong>Shipping address:</strong>
|
||||
<div t-field="doc.customer_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'/>
|
||||
<p t-if="doc.customer_address_id.vat">VAT: <span t-field="doc.customer_address_id.vat"/></p>
|
||||
<div
|
||||
t-field="doc.customer_address_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name", "phone", "fax"], "no_marker": True, "phone_icons": True}'
|
||||
/>
|
||||
<p t-if="doc.customer_address_id.vat">VAT: <span
|
||||
t-field="doc.customer_address_id.vat"
|
||||
/></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-3 offset-1">
|
||||
<strong t-if="doc.type=='customer'">Customer:</strong>
|
||||
<strong t-if="doc.type=='supplier'">Supplier:</strong>
|
||||
<div t-field="doc.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name"], "no_marker": True}' />
|
||||
<div
|
||||
t-field="doc.partner_id"
|
||||
t-options='{"widget": "contact", "fields": ["address", "name"], "no_marker": True}'
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -174,7 +241,10 @@
|
||||
<td><span t-field="l.product_id" /></td>
|
||||
<td class="text-right">
|
||||
<span t-field="l.product_qty" />
|
||||
<span t-field="l.uom_id" groups="uom.group_uom"/>
|
||||
<span
|
||||
t-field="l.uom_id"
|
||||
groups="uom.group_uom"
|
||||
/>
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<span t-field="l.price_unit" />
|
||||
@@ -184,7 +254,7 @@
|
||||
</table>
|
||||
<div t-if="doc.comment">
|
||||
<strong><p>Additional Information</p></strong>
|
||||
<span t-field="doc.comment"></span>
|
||||
<span t-field="doc.comment" />
|
||||
</div>
|
||||
</div>
|
||||
</t>
|
||||
@@ -193,7 +263,10 @@
|
||||
<template id="report_rma_order">
|
||||
<t t-call="web.html_container">
|
||||
<t t-foreach="docs" t-as="doc">
|
||||
<t t-call="rma.report_rma_order_document" t-lang="doc.partner_id.lang"/>
|
||||
<t
|
||||
t-call="rma.report_rma_order_document"
|
||||
t-lang="doc.partner_id.lang"
|
||||
/>
|
||||
</t>
|
||||
</t>
|
||||
</template>
|
||||
|
||||
@@ -10,21 +10,29 @@
|
||||
|
||||
<record id="group_rma_customer_user" model="res.groups">
|
||||
<field name="name">RMA Customer User</field>
|
||||
<field name="implied_ids" eval="[(4, ref('stock.group_stock_user'))]"/>
|
||||
<field
|
||||
name="implied_ids"
|
||||
eval="[(4, ref('stock.group_stock_user'))]"
|
||||
/>
|
||||
<field name="category_id" ref="module_category_rma" />
|
||||
</record>
|
||||
|
||||
<record id="group_rma_supplier_user" model="res.groups">
|
||||
<field name="name">RMA Supplier User</field>
|
||||
<field name="implied_ids" eval="[(4, ref('stock.group_stock_user'))]"/>
|
||||
<field
|
||||
name="implied_ids"
|
||||
eval="[(4, ref('stock.group_stock_user'))]"
|
||||
/>
|
||||
<field name="category_id" ref="module_category_rma" />
|
||||
</record>
|
||||
|
||||
<record id="group_rma_manager" model="res.groups">
|
||||
<field name="name">RMA Manager</field>
|
||||
<field name="implied_ids"
|
||||
<field
|
||||
name="implied_ids"
|
||||
eval="[(4, ref('rma.group_rma_customer_user')),
|
||||
(4, ref('rma.group_rma_supplier_user'))]"/>
|
||||
(4, ref('rma.group_rma_supplier_user'))]"
|
||||
/>
|
||||
<field name="users" eval="[(4, ref('base.user_root'))]" />
|
||||
<field name="category_id" ref="module_category_rma" />
|
||||
</record>
|
||||
@@ -45,28 +53,48 @@
|
||||
</record>
|
||||
|
||||
<record id="stock.group_stock_user" model="res.groups">
|
||||
<field name="implied_ids"
|
||||
<field
|
||||
name="implied_ids"
|
||||
eval="[(4, ref('group_rma_customer_user')),
|
||||
(4, ref('group_rma_supplier_user'))]"/>
|
||||
(4, ref('group_rma_supplier_user'))]"
|
||||
/>
|
||||
</record>
|
||||
|
||||
<record model="ir.rule" id="rma_order_rule">
|
||||
<field name="name">rma order multi-company</field>
|
||||
<field name="model_id" search="[('model','=','rma.order')]" model="ir.model"/>
|
||||
<field
|
||||
name="model_id"
|
||||
search="[('model','=','rma.order')]"
|
||||
model="ir.model"
|
||||
/>
|
||||
<field name="global" eval="True" />
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
<field
|
||||
name="domain_force"
|
||||
>['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
<record model="ir.rule" id="rma_order_line_rule">
|
||||
<field name="name">rma order line multi-company</field>
|
||||
<field name="model_id" search="[('model','=','rma.order.line')]" model="ir.model"/>
|
||||
<field
|
||||
name="model_id"
|
||||
search="[('model','=','rma.order.line')]"
|
||||
model="ir.model"
|
||||
/>
|
||||
<field name="global" eval="True" />
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
<field
|
||||
name="domain_force"
|
||||
>['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
<record model="ir.rule" id="rma_operation_rule">
|
||||
<field name="name">rma operation multi-company</field>
|
||||
<field name="model_id" search="[('model','=','rma.operation')]" model="ir.model"/>
|
||||
<field
|
||||
name="model_id"
|
||||
search="[('model','=','rma.operation')]"
|
||||
model="ir.model"
|
||||
/>
|
||||
<field name="global" eval="True" />
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
<field
|
||||
name="domain_force"
|
||||
>['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
|
||||
@@ -3,17 +3,27 @@
|
||||
<record id="product_category_form_view" model="ir.ui.view">
|
||||
<field name="name">product.category.form</field>
|
||||
<field name="model">product.category</field>
|
||||
<field name="inherit_id" ref="stock.product_category_form_view_inherit"/>
|
||||
<field
|
||||
name="inherit_id"
|
||||
ref="stock.product_category_form_view_inherit"
|
||||
/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="removal_strategy_id" position="after">
|
||||
<group name="rma">
|
||||
<field name="rma_approval_policy" groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"/>
|
||||
<field name="rma_customer_operation_id"
|
||||
<field
|
||||
name="rma_approval_policy"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
domain="[('type','=','customer')]"/>
|
||||
<field name="rma_supplier_operation_id"
|
||||
/>
|
||||
<field
|
||||
name="rma_customer_operation_id"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
domain="[('type','=','supplier')]"/>
|
||||
domain="[('type','=','customer')]"
|
||||
/>
|
||||
<field
|
||||
name="rma_supplier_operation_id"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
domain="[('type','=','supplier')]"
|
||||
/>
|
||||
</group>
|
||||
</field>
|
||||
</field>
|
||||
@@ -25,14 +35,21 @@
|
||||
<field name="inherit_id" ref="product.product_template_form_view" />
|
||||
<field name="arch" type="xml">
|
||||
<group name="inventory" position="inside">
|
||||
<group name="rma" groups="rma.group_rma_customer_user,rma.group_rma_supplier_user">
|
||||
<group
|
||||
name="rma"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
>
|
||||
<field name="rma_approval_policy" />
|
||||
<field name="rma_customer_operation_id"
|
||||
<field
|
||||
name="rma_customer_operation_id"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
domain="[('type','=','customer')]"/>
|
||||
<field name="rma_supplier_operation_id"
|
||||
domain="[('type','=','customer')]"
|
||||
/>
|
||||
<field
|
||||
name="rma_supplier_operation_id"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
domain="[('type','=','supplier')]"/>
|
||||
domain="[('type','=','supplier')]"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
</field>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
|
||||
<odoo>
|
||||
|
||||
<record id="res_config_settings_view_form" model="ir.ui.view">
|
||||
@@ -9,7 +8,13 @@
|
||||
<field name="inherit_id" ref="base.res_config_settings_view_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//div[hasclass('settings')]" position="inside">
|
||||
<div class="app_settings_block" data-string="RMA" string="RMA" data-key="rma" groups="rma.group_rma_manager">
|
||||
<div
|
||||
class="app_settings_block"
|
||||
data-string="RMA"
|
||||
string="RMA"
|
||||
data-key="rma"
|
||||
groups="rma.group_rma_manager"
|
||||
>
|
||||
<h2>Return Merchandise Authorization</h2>
|
||||
<div class="row mt16 o_settings_container">
|
||||
<div class="col-12 col-lg-6 o_setting_box">
|
||||
|
||||
@@ -7,14 +7,19 @@
|
||||
<field name="inherit_id" ref="base.view_partner_form" />
|
||||
<field name="arch" type="xml">
|
||||
<div name="button_box" position="inside">
|
||||
<button type="object"
|
||||
<button
|
||||
type="object"
|
||||
name="action_open_partner_rma"
|
||||
class="oe_stat_button"
|
||||
icon="fa-dropbox"
|
||||
context="{'res_partner_search_mode': 'customer'}"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user">
|
||||
<field name="rma_line_count" widget="statinfo"
|
||||
string="RMAs"/>
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
>
|
||||
<field
|
||||
name="rma_line_count"
|
||||
widget="statinfo"
|
||||
string="RMAs"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</field>
|
||||
|
||||
@@ -6,94 +6,143 @@
|
||||
name="RMA"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user,rma.group_rma_manager"
|
||||
web_icon="rma,static/description/icon.png"
|
||||
sequence="100"/>
|
||||
sequence="100"
|
||||
/>
|
||||
|
||||
<!-- Customer RMA -->
|
||||
<menuitem id="menu_customer_rma"
|
||||
<menuitem
|
||||
id="menu_customer_rma"
|
||||
name="Customer RMA"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
sequence="30"
|
||||
parent="menu_rma_root"/>
|
||||
parent="menu_rma_root"
|
||||
/>
|
||||
|
||||
<menuitem
|
||||
id="menu_rma_act_customer"
|
||||
sequence="50"
|
||||
parent="menu_customer_rma"
|
||||
groups="rma.group_rma_groups"
|
||||
action="action_rma_customer"/>
|
||||
action="action_rma_customer"
|
||||
/>
|
||||
|
||||
<menuitem
|
||||
id="menu_rma_line_customer"
|
||||
sequence="20"
|
||||
parent="menu_customer_rma"
|
||||
groups="rma.group_rma_customer_user"
|
||||
action="action_rma_customer_lines"/>
|
||||
action="action_rma_customer_lines"
|
||||
/>
|
||||
|
||||
<!-- Supplier RMA -->
|
||||
<menuitem id="menu_supplier_rma"
|
||||
<menuitem
|
||||
id="menu_supplier_rma"
|
||||
name="Supplier RMA"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
sequence="31"
|
||||
parent="menu_rma_root"/>
|
||||
parent="menu_rma_root"
|
||||
/>
|
||||
|
||||
<menuitem
|
||||
id="menu_rma_act_supplier"
|
||||
sequence="50"
|
||||
parent="menu_supplier_rma"
|
||||
groups="rma.group_rma_groups"
|
||||
action="action_rma_supplier"/>
|
||||
action="action_rma_supplier"
|
||||
/>
|
||||
|
||||
<menuitem
|
||||
id="menu_rma_line_supplier"
|
||||
sequence="20"
|
||||
parent="menu_supplier_rma"
|
||||
groups="rma.group_rma_supplier_user"
|
||||
action="action_rma_supplier_lines"/>
|
||||
action="action_rma_supplier_lines"
|
||||
/>
|
||||
|
||||
<!-- Settings-->
|
||||
<menuitem id="menu_rma_config"
|
||||
<menuitem
|
||||
id="menu_rma_config"
|
||||
name="Configuration"
|
||||
groups="rma.group_rma_manager"
|
||||
sequence="999"
|
||||
parent="menu_rma_root"/>
|
||||
parent="menu_rma_root"
|
||||
/>
|
||||
|
||||
<menuitem id="menu_rma_global_settings" name="Settings"
|
||||
<menuitem
|
||||
id="menu_rma_global_settings"
|
||||
name="Settings"
|
||||
parent="rma.menu_rma_config"
|
||||
sequence="1" action="action_rma_config_settings"
|
||||
groups="base.group_system"/>
|
||||
sequence="1"
|
||||
action="action_rma_config_settings"
|
||||
groups="base.group_system"
|
||||
/>
|
||||
|
||||
<menuitem id="menu_rma_operation_customer"
|
||||
<menuitem
|
||||
id="menu_rma_operation_customer"
|
||||
name="Customer Operations"
|
||||
groups="rma.group_rma_manager"
|
||||
sequence="35"
|
||||
parent="rma.menu_rma_config"
|
||||
action="action_rma_operation_customer"/>
|
||||
action="action_rma_operation_customer"
|
||||
/>
|
||||
|
||||
<menuitem id="menu_rma_operation_supplier"
|
||||
<menuitem
|
||||
id="menu_rma_operation_supplier"
|
||||
name="Supplier Operations"
|
||||
groups="rma.group_rma_manager"
|
||||
sequence="40"
|
||||
parent="rma.menu_rma_config"
|
||||
action="action_rma_operation_supplier"/>
|
||||
action="action_rma_operation_supplier"
|
||||
/>
|
||||
|
||||
<!-- Master data menus-->
|
||||
|
||||
<menuitem id="menu_rma_rma_control" name="Master Data" parent="menu_rma_root" sequence="50"/>
|
||||
<menuitem id="menu_rma_config_warehouse" name="Warehouse"
|
||||
parent="rma.menu_rma_rma_control" sequence="10"/>
|
||||
<menuitem id="menu_rma_config_stock" name="Products" action="stock.product_template_action_product"
|
||||
parent="rma.menu_rma_config_warehouse" sequence="10"/>
|
||||
<menuitem id="rma_product_product_menu" name="Product Variants" action="stock.stock_product_normal_action"
|
||||
parent="rma.menu_rma_config_warehouse" sequence="20" groups="product.group_product_variant"/>
|
||||
<menuitem
|
||||
id="menu_rma_rma_control"
|
||||
name="Master Data"
|
||||
parent="menu_rma_root"
|
||||
sequence="50"
|
||||
/>
|
||||
<menuitem
|
||||
id="menu_rma_config_warehouse"
|
||||
name="Warehouse"
|
||||
parent="rma.menu_rma_rma_control"
|
||||
sequence="10"
|
||||
/>
|
||||
<menuitem
|
||||
id="menu_rma_config_stock"
|
||||
name="Products"
|
||||
action="stock.product_template_action_product"
|
||||
parent="rma.menu_rma_config_warehouse"
|
||||
sequence="10"
|
||||
/>
|
||||
<menuitem
|
||||
id="rma_product_product_menu"
|
||||
name="Product Variants"
|
||||
action="stock.stock_product_normal_action"
|
||||
parent="rma.menu_rma_config_warehouse"
|
||||
sequence="20"
|
||||
groups="product.group_product_variant"
|
||||
/>
|
||||
|
||||
<menuitem id="menu_rma_config_partners" name="Partners"
|
||||
parent="rma.menu_rma_rma_control" sequence="20"/>
|
||||
<menuitem id="rma_res_partner_menu_customer"
|
||||
<menuitem
|
||||
id="menu_rma_config_partners"
|
||||
name="Partners"
|
||||
parent="rma.menu_rma_rma_control"
|
||||
sequence="20"
|
||||
/>
|
||||
<menuitem
|
||||
id="rma_res_partner_menu_customer"
|
||||
name="Customers"
|
||||
parent="rma.menu_rma_config_partners"
|
||||
action="base.action_partner_form"
|
||||
sequence="50"/>
|
||||
<menuitem id="rma_res_partner_menu_suppliers" name="Suppliers"
|
||||
sequence="50"
|
||||
/>
|
||||
<menuitem
|
||||
id="rma_res_partner_menu_suppliers"
|
||||
name="Suppliers"
|
||||
parent="rma.menu_rma_config_partners"
|
||||
action="account.res_partner_action_supplier" sequence="60"/>
|
||||
action="account.res_partner_action_supplier"
|
||||
sequence="60"
|
||||
/>
|
||||
</odoo>
|
||||
|
||||
@@ -21,38 +21,52 @@
|
||||
<form string="RMA Operations">
|
||||
<sheet>
|
||||
<div class="oe_button_box" name="button_box">
|
||||
<button name="toggle_active" type="object"
|
||||
class="oe_stat_button" icon="fa-archive">
|
||||
<field name="active" widget="boolean_button"
|
||||
options='{"terminology": "archive"}'/>
|
||||
<button
|
||||
name="toggle_active"
|
||||
type="object"
|
||||
class="oe_stat_button"
|
||||
icon="fa-archive"
|
||||
>
|
||||
<field
|
||||
name="active"
|
||||
widget="boolean_button"
|
||||
options='{"terminology": "archive"}'
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<group colspan="4" col="2">
|
||||
<group name="description"
|
||||
string="Description">
|
||||
<group name="description" string="Description">
|
||||
<field name="code" />
|
||||
<field name="name" />
|
||||
<field name="type" />
|
||||
<field name="company_id" groups="base.group_multi_company"/>
|
||||
<field
|
||||
name="company_id"
|
||||
groups="base.group_multi_company"
|
||||
/>
|
||||
</group>
|
||||
<group name="policies"
|
||||
string="Policies">
|
||||
<group name="policies" string="Policies">
|
||||
<field name="receipt_policy" />
|
||||
<field name="delivery_policy" />
|
||||
</group>
|
||||
<group name="inbound" string="Inbound">
|
||||
<field name="in_route_id" />
|
||||
<field name="in_warehouse_id" />
|
||||
<field name="location_id"
|
||||
domain="[('usage', '=', 'internal')]"/>
|
||||
<field name="customer_to_supplier"
|
||||
attrs="{'invisible':[('type', '=', 'supplier')]}"/>
|
||||
<field
|
||||
name="location_id"
|
||||
domain="[('usage', '=', 'internal')]"
|
||||
/>
|
||||
<field
|
||||
name="customer_to_supplier"
|
||||
attrs="{'invisible':[('type', '=', 'supplier')]}"
|
||||
/>
|
||||
</group>
|
||||
<group name="outbound" string="Outbound">
|
||||
<field name="out_route_id" />
|
||||
<field name="out_warehouse_id" />
|
||||
<field name="supplier_to_customer"
|
||||
attrs="{'invisible':[('type', '=', 'customer')]}"/>
|
||||
<field
|
||||
name="supplier_to_customer"
|
||||
attrs="{'invisible':[('type', '=', 'customer')]}"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
</sheet>
|
||||
|
||||
@@ -5,8 +5,10 @@
|
||||
<field name="name">rma.order.line.tree</field>
|
||||
<field name="model">rma.order.line</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="RMA Line"
|
||||
decoration-info="state in ('draft','to_approve')">
|
||||
<tree
|
||||
string="RMA Line"
|
||||
decoration-info="state in ('draft','to_approve')"
|
||||
>
|
||||
<field name="name" />
|
||||
<field name="partner_id" />
|
||||
<field name="product_id" />
|
||||
@@ -27,15 +29,20 @@
|
||||
<field name="name">rma.order.line.supplier.tree</field>
|
||||
<field name="model">rma.order.line</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="RMA Line"
|
||||
decoration-info="state in ('draft','to_approve')">
|
||||
<tree
|
||||
string="RMA Line"
|
||||
decoration-info="state in ('draft','to_approve')"
|
||||
>
|
||||
<field name="name" />
|
||||
<field name="partner_id" />
|
||||
<field name="product_id" />
|
||||
<field name="lot_id" groups="stock.group_production_lot" />
|
||||
<field name="rma_id" groups="rma.group_rma_groups" />
|
||||
<field name="origin" />
|
||||
<field name="operation_id" domain="[('type','=','supplier')]"/>
|
||||
<field
|
||||
name="operation_id"
|
||||
domain="[('type','=','supplier')]"
|
||||
/>
|
||||
<field name="uom_id" groups="uom.group_uom" />
|
||||
<field name="product_qty" />
|
||||
<field name="price_unit" />
|
||||
@@ -50,63 +57,104 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="RMA Line">
|
||||
<header>
|
||||
<button name="action_rma_to_approve" type="object"
|
||||
<button
|
||||
name="action_rma_to_approve"
|
||||
type="object"
|
||||
string="Request Approval"
|
||||
attrs="{'invisible':[('state', '!=', 'draft')]}"
|
||||
class="oe_highlight" groups="rma.group_rma_customer_user"/>
|
||||
<button name="action_rma_draft" type="object"
|
||||
class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user"
|
||||
/>
|
||||
<button
|
||||
name="action_rma_draft"
|
||||
type="object"
|
||||
string="Back to Draft"
|
||||
attrs="{'invisible':[('state', '=', 'draft')]}" class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"/>
|
||||
<button name="action_rma_approve" type="object"
|
||||
attrs="{'invisible':[('state', '=', 'draft')]}"
|
||||
class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
/>
|
||||
<button
|
||||
name="action_rma_approve"
|
||||
type="object"
|
||||
string="Approve"
|
||||
attrs="{'invisible':[('state', '!=', 'to_approve')]}" class="oe_highlight" groups="rma.group_rma_customer_user"/>
|
||||
<button name="action_rma_done" type="object"
|
||||
attrs="{'invisible':[('state', '!=', 'to_approve')]}"
|
||||
class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user"
|
||||
/>
|
||||
<button
|
||||
name="action_rma_done"
|
||||
type="object"
|
||||
string="Done"
|
||||
attrs="{'invisible':[('state', 'in', ('done', 'draft'))]}"
|
||||
groups="rma.group_rma_customer_user"/>
|
||||
groups="rma.group_rma_customer_user"
|
||||
/>
|
||||
<field name="state" widget="statusbar" nolabel="1" />
|
||||
</header>
|
||||
<sheet>
|
||||
<div name="button_box" class="oe_button_box">
|
||||
<button type="object" name="action_view_in_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_in_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="in_shipment_count" widget="statinfo"
|
||||
string="Shipments"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="in_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Shipments"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_out_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_out_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="out_shipment_count" widget="statinfo"
|
||||
string="Deliveries"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="out_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Deliveries"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_rma_lines"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_rma_lines"
|
||||
class="oe_stat_button"
|
||||
icon="fa-link"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="rma_line_count" widget="statinfo"
|
||||
string="Customer RMA"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="rma_line_count"
|
||||
widget="statinfo"
|
||||
string="Customer RMA"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<div class="oe_title" name="title">
|
||||
<h1>
|
||||
<field name="name" readonly="1"
|
||||
invisible="context.get('hide_title',False)"/>
|
||||
<field
|
||||
name="name"
|
||||
readonly="1"
|
||||
invisible="context.get('hide_title',False)"
|
||||
/>
|
||||
</h1>
|
||||
</div>
|
||||
<group>
|
||||
<group name="partner">
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
context="{'res_partner_search_mode': 'supplier'}"
|
||||
string="Supplier"/>
|
||||
<field name="delivery_address_id"
|
||||
string="Supplier"
|
||||
/>
|
||||
<field
|
||||
name="delivery_address_id"
|
||||
domain="['|', ('parent_id', '=', partner_id),('id', '=', partner_id)]"
|
||||
context="{'show_address': 1}"
|
||||
options="{'always_reload': 1}"
|
||||
groups='rma.group_rma_delivery_invoice_address'/>
|
||||
groups='rma.group_rma_delivery_invoice_address'
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
<group>
|
||||
@@ -114,10 +162,12 @@
|
||||
<field name="product_id" />
|
||||
<newline />
|
||||
<field name="product_tracking" invisible="1" />
|
||||
<field name="lot_id"
|
||||
<field
|
||||
name="lot_id"
|
||||
groups="stock.group_production_lot"
|
||||
attrs="{'required': [('product_tracking', 'in', ('serial', 'lot'))]}"
|
||||
domain="[('product_id', '=', product_id)]"/>
|
||||
domain="[('product_id', '=', product_id)]"
|
||||
/>
|
||||
</group>
|
||||
<group name="product_qty" string="Quantity">
|
||||
<field name="product_qty" />
|
||||
@@ -126,16 +176,20 @@
|
||||
</group>
|
||||
</group>
|
||||
<group name="main_info" string="Origin">
|
||||
<field name="reference_move_id"
|
||||
<field
|
||||
name="reference_move_id"
|
||||
options="{'no_create': True}"
|
||||
domain="[('picking_id.partner_id', '=', partner_id),
|
||||
('location_id.usage', '=', 'supplier'),
|
||||
('state', '=', 'done')]"/>
|
||||
('state', '=', 'done')]"
|
||||
/>
|
||||
</group>
|
||||
<group>
|
||||
<group name="operation" string="Operation">
|
||||
<field name="operation_id"
|
||||
domain="[('type','=','supplier')]"/>
|
||||
<field
|
||||
name="operation_id"
|
||||
domain="[('type','=','supplier')]"
|
||||
/>
|
||||
<field name="receipt_policy" />
|
||||
<field name="delivery_policy" />
|
||||
</group>
|
||||
@@ -152,28 +206,46 @@
|
||||
<group>
|
||||
<group name="inbound" string="Inbound">
|
||||
<field name="in_warehouse_id" />
|
||||
<field name="location_id"
|
||||
domain="[('usage', '=', 'internal')]"/>
|
||||
<field name="in_route_id" groups="stock.group_adv_location"/>
|
||||
<field
|
||||
name="location_id"
|
||||
domain="[('usage', '=', 'internal')]"
|
||||
/>
|
||||
<field
|
||||
name="in_route_id"
|
||||
groups="stock.group_adv_location"
|
||||
/>
|
||||
</group>
|
||||
<group name="outbound" string="Outbound">
|
||||
<field name="out_warehouse_id" />
|
||||
<field name="out_route_id" groups="stock.group_adv_location"/>
|
||||
<field
|
||||
name="out_route_id"
|
||||
groups="stock.group_adv_location"
|
||||
/>
|
||||
<field name="supplier_to_customer" />
|
||||
<field name="customer_address_id"
|
||||
<field
|
||||
name="customer_address_id"
|
||||
context="{'show_address': 1}"
|
||||
options="{'always_reload': 1}"
|
||||
attrs="{'required':[('supplier_to_customer', '=', True)],
|
||||
'invisible':[('supplier_to_customer', '=', False)]}"/>
|
||||
'invisible':[('supplier_to_customer', '=', False)]}"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
</page>
|
||||
<page name="stock" string="Stock Moves">
|
||||
<field name="move_ids" nolabel="1" readonly="1"/>
|
||||
<field
|
||||
name="move_ids"
|
||||
nolabel="1"
|
||||
readonly="1"
|
||||
/>
|
||||
</page>
|
||||
<page name="quantities" string="Quantities">
|
||||
<group>
|
||||
<group name="quantities" col="4" string="Quantities">
|
||||
<group
|
||||
name="quantities"
|
||||
col="4"
|
||||
string="Quantities"
|
||||
>
|
||||
<group name="receive">
|
||||
<field name="qty_to_receive" />
|
||||
<field name="qty_incoming" />
|
||||
@@ -190,19 +262,29 @@
|
||||
<page name="other" string="Other Info">
|
||||
<group name="general" string="General">
|
||||
<field name="conditions" />
|
||||
<field name="rma_id" groups="rma.group_rma_groups"/>
|
||||
<field
|
||||
name="rma_id"
|
||||
groups="rma.group_rma_groups"
|
||||
/>
|
||||
<field name="origin" />
|
||||
|
||||
</group>
|
||||
<group name="company" string="Company"
|
||||
groups="base.group_multi_company">
|
||||
<group
|
||||
name="company"
|
||||
string="Company"
|
||||
groups="base.group_multi_company"
|
||||
>
|
||||
<field name="company_id" />
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
</sheet>
|
||||
<div class="oe_chatter">
|
||||
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
|
||||
<field
|
||||
name="message_follower_ids"
|
||||
widget="mail_followers"
|
||||
groups="base.group_user"
|
||||
/>
|
||||
<field name="message_ids" widget="mail_thread" />
|
||||
</div>
|
||||
</form>
|
||||
@@ -215,38 +297,66 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="RMA Line">
|
||||
<header>
|
||||
<button name="action_rma_to_approve" type="object"
|
||||
<button
|
||||
name="action_rma_to_approve"
|
||||
type="object"
|
||||
string="Request Approval"
|
||||
attrs="{'invisible':[('state', '!=', 'draft')]}"
|
||||
class="oe_highlight" groups="rma.group_rma_customer_user"/>
|
||||
<button name="action_rma_draft" type="object"
|
||||
class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user"
|
||||
/>
|
||||
<button
|
||||
name="action_rma_draft"
|
||||
type="object"
|
||||
string="Back to Draft"
|
||||
attrs="{'invisible':[('state', '=', 'draft')]}" class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"/>
|
||||
<button name="action_rma_approve" type="object"
|
||||
attrs="{'invisible':[('state', '=', 'draft')]}"
|
||||
class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
/>
|
||||
<button
|
||||
name="action_rma_approve"
|
||||
type="object"
|
||||
string="Approve"
|
||||
attrs="{'invisible':[('state', '!=', 'to_approve')]}" class="oe_highlight" groups="rma.group_rma_customer_user"/>
|
||||
<button name="action_rma_done" type="object"
|
||||
attrs="{'invisible':[('state', '!=', 'to_approve')]}"
|
||||
class="oe_highlight"
|
||||
groups="rma.group_rma_customer_user"
|
||||
/>
|
||||
<button
|
||||
name="action_rma_done"
|
||||
type="object"
|
||||
string="Done"
|
||||
attrs="{'invisible':[('state', 'in', ('done', 'draft'))]}"
|
||||
groups="rma.group_rma_customer_user"/>
|
||||
groups="rma.group_rma_customer_user"
|
||||
/>
|
||||
<field name="state" widget="statusbar" nolabel="1" />
|
||||
</header>
|
||||
<sheet>
|
||||
<div name="button_box" class="oe_button_box">
|
||||
<button type="object" name="action_view_in_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_in_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="in_shipment_count" widget="statinfo"
|
||||
string="Shipments"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="in_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Shipments"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_out_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_out_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="out_shipment_count" widget="statinfo"
|
||||
string="Deliveries"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="out_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Deliveries"
|
||||
/>
|
||||
</button>
|
||||
<!--Move this button to rma_account-->
|
||||
<!--<button type="object" name="action_view_invoice"
|
||||
@@ -254,31 +364,44 @@
|
||||
icon="fa-pencil-square-o"
|
||||
string="Origin Inv">
|
||||
</button>-->
|
||||
<button type="object" name="action_view_rma_lines"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_rma_lines"
|
||||
class="oe_stat_button"
|
||||
icon="fa-link"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="rma_line_count" widget="statinfo"
|
||||
string="Supplier RMA"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="rma_line_count"
|
||||
widget="statinfo"
|
||||
string="Supplier RMA"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<div class="oe_title" name="title">
|
||||
<h1>
|
||||
<field name="name" readonly="1"
|
||||
invisible="context.get('hide_title',False)"/>
|
||||
<field
|
||||
name="name"
|
||||
readonly="1"
|
||||
invisible="context.get('hide_title',False)"
|
||||
/>
|
||||
</h1>
|
||||
</div>
|
||||
<group name="partner">
|
||||
<group name="partner">
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
context="{'res_partner_search_mode': 'customer'}"
|
||||
string="Customer"/>
|
||||
<field name="delivery_address_id"
|
||||
string="Customer"
|
||||
/>
|
||||
<field
|
||||
name="delivery_address_id"
|
||||
domain="['|', ('parent_id', '=', partner_id),
|
||||
('id', '=', partner_id)]"
|
||||
context="{'show_address': 1}"
|
||||
options="{'always_reload': 1}"
|
||||
groups='rma.group_rma_delivery_invoice_address'/>
|
||||
groups='rma.group_rma_delivery_invoice_address'
|
||||
/>
|
||||
<field name="under_warranty" />
|
||||
</group>
|
||||
</group>
|
||||
@@ -287,9 +410,11 @@
|
||||
<field name="product_id" />
|
||||
<newline />
|
||||
<field name="product_tracking" invisible="1" />
|
||||
<field name="lot_id"
|
||||
<field
|
||||
name="lot_id"
|
||||
groups="stock.group_production_lot"
|
||||
attrs="{'required': [('product_tracking', 'in', ('serial', 'lot'))]}"/>
|
||||
attrs="{'required': [('product_tracking', 'in', ('serial', 'lot'))]}"
|
||||
/>
|
||||
</group>
|
||||
<group name="product_qty" string="Quantity">
|
||||
<field name="product_qty" />
|
||||
@@ -298,15 +423,20 @@
|
||||
</group>
|
||||
</group>
|
||||
<group name="main_info" string="Origin">
|
||||
<field name="reference_move_id"
|
||||
<field
|
||||
name="reference_move_id"
|
||||
options="{'no_create': True}"
|
||||
domain="[('picking_id.partner_id', '=', partner_id),
|
||||
('location_dest_id.usage', '=', 'customer'),
|
||||
('state', '=', 'done')]"/>
|
||||
('state', '=', 'done')]"
|
||||
/>
|
||||
</group>
|
||||
<group>
|
||||
<group name="operation" string="Operation">
|
||||
<field name="operation_id" domain="[('type','=','customer')]"/>
|
||||
<field
|
||||
name="operation_id"
|
||||
domain="[('type','=','customer')]"
|
||||
/>
|
||||
<field name="receipt_policy" />
|
||||
<field name="delivery_policy" />
|
||||
</group>
|
||||
@@ -324,26 +454,44 @@
|
||||
<page name="route" string="Routes">
|
||||
<group name="inbound" string="Inbound">
|
||||
<field name="in_warehouse_id" />
|
||||
<field name="location_id"
|
||||
domain="[('usage', '=', 'internal')]"/>
|
||||
<field name="in_route_id" groups="stock.group_adv_location"/>
|
||||
<field
|
||||
name="location_id"
|
||||
domain="[('usage', '=', 'internal')]"
|
||||
/>
|
||||
<field
|
||||
name="in_route_id"
|
||||
groups="stock.group_adv_location"
|
||||
/>
|
||||
<field name="customer_to_supplier" />
|
||||
<field name="supplier_address_id"
|
||||
<field
|
||||
name="supplier_address_id"
|
||||
context="{'show_address': 1}"
|
||||
options="{'always_reload': 1}"
|
||||
attrs="{'required':[('customer_to_supplier', '=', True)],
|
||||
'invisible':[('customer_to_supplier', '=', False)]}"/>
|
||||
'invisible':[('customer_to_supplier', '=', False)]}"
|
||||
/>
|
||||
</group>
|
||||
<group name="outbound" string="Outbound">
|
||||
<field name="out_warehouse_id" />
|
||||
<field name="out_route_id" groups="stock.group_adv_location"/>
|
||||
<field
|
||||
name="out_route_id"
|
||||
groups="stock.group_adv_location"
|
||||
/>
|
||||
</group>
|
||||
</page>
|
||||
<page name="stock" string="Stock Moves">
|
||||
<field name="move_ids" nolabel="1" readonly="1"/>
|
||||
<field
|
||||
name="move_ids"
|
||||
nolabel="1"
|
||||
readonly="1"
|
||||
/>
|
||||
</page>
|
||||
<page name="quantities" string="Quantities">
|
||||
<group name="quantities" col="4" string="Quantities">
|
||||
<group
|
||||
name="quantities"
|
||||
col="4"
|
||||
string="Quantities"
|
||||
>
|
||||
<group name="receive">
|
||||
<field name="qty_to_receive" />
|
||||
<field name="qty_incoming" />
|
||||
@@ -354,8 +502,10 @@
|
||||
<field name="qty_outgoing" />
|
||||
<field name="qty_delivered" />
|
||||
</group>
|
||||
<group name="supplier_rma"
|
||||
attrs="{'invisible':[('customer_to_supplier','=',False)]}">
|
||||
<group
|
||||
name="supplier_rma"
|
||||
attrs="{'invisible':[('customer_to_supplier','=',False)]}"
|
||||
>
|
||||
<field name="qty_to_supplier_rma" />
|
||||
<field name="qty_in_supplier_rma" />
|
||||
</group>
|
||||
@@ -364,18 +514,28 @@
|
||||
<page name="other" string="Other Info">
|
||||
<group name="general" string="General">
|
||||
<field name="conditions" />
|
||||
<field name="rma_id" groups="rma.group_rma_groups"/>
|
||||
<field
|
||||
name="rma_id"
|
||||
groups="rma.group_rma_groups"
|
||||
/>
|
||||
<field name="origin" />
|
||||
</group>
|
||||
<group name="company" string="Company"
|
||||
groups="base.group_multi_company">
|
||||
<group
|
||||
name="company"
|
||||
string="Company"
|
||||
groups="base.group_multi_company"
|
||||
>
|
||||
<field name="company_id" />
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
</sheet>
|
||||
<div class="oe_chatter">
|
||||
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
|
||||
<field
|
||||
name="message_follower_ids"
|
||||
widget="mail_followers"
|
||||
groups="base.group_user"
|
||||
/>
|
||||
<field name="message_ids" widget="mail_thread" />
|
||||
</div>
|
||||
</form>
|
||||
@@ -395,28 +555,71 @@
|
||||
<field name="product_id" />
|
||||
<field name="lot_id" />
|
||||
<separator />
|
||||
<filter name="assigned_to" domain="[('assigned_to','=',uid)]" help="My RMAs"/>
|
||||
<filter
|
||||
name="assigned_to"
|
||||
domain="[('assigned_to','=',uid)]"
|
||||
help="My RMAs"
|
||||
/>
|
||||
<separator />
|
||||
<group name="stock_quantities" groups="stock.group_stock_user">
|
||||
<filter name="to_receive" domain="[('state','!=', 'done'),('qty_to_receive','>',0.0)]" help="To Receive"/>
|
||||
<filter name="to_deliver" domain="[('state','!=', 'done'),('qty_to_deliver','>',0.0)]" help="To Deliver"/>
|
||||
<group
|
||||
name="stock_quantities"
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<filter
|
||||
name="to_receive"
|
||||
domain="[('state','!=', 'done'),('qty_to_receive','>',0.0)]"
|
||||
help="To Receive"
|
||||
/>
|
||||
<filter
|
||||
name="to_deliver"
|
||||
domain="[('state','!=', 'done'),('qty_to_deliver','>',0.0)]"
|
||||
help="To Deliver"
|
||||
/>
|
||||
</group>
|
||||
<group name="rma_supplier_quantities">
|
||||
<filter name="to_send_to_supplier" domain="[('state','!=', 'done'),('qty_to_supplier_rma','>',0.0)]" help="To Send to Supplier RMA"/>
|
||||
<filter
|
||||
name="to_send_to_supplier"
|
||||
domain="[('state','!=', 'done'),('qty_to_supplier_rma','>',0.0)]"
|
||||
help="To Send to Supplier RMA"
|
||||
/>
|
||||
</group>
|
||||
<group expand="0" string="Group By">
|
||||
<filter name="status" string="State" domain="[]"
|
||||
context="{'group_by':'state'}"/>
|
||||
<filter name="partner" string="Partner" domain="[]"
|
||||
context="{'group_by':'partner_id'}"/>
|
||||
<filter name="operation" string="Operation" domain="[]"
|
||||
context="{'group_by':'operation_id'}"/>
|
||||
<filter name="product" string="Product" domain="[]"
|
||||
context="{'group_by':'product_id'}"/>
|
||||
<filter name="to_receive" string="To Receive" domain="[('qty_to_receive', '>', 0)]"
|
||||
context="{'group_by':'partner_id'}"/>
|
||||
<filter name="to_deliver" string="To Deliver" domain="[('qty_to_deliver', '>', 0)]"
|
||||
context="{'group_by':'partner_id'}"/>
|
||||
<filter
|
||||
name="status"
|
||||
string="State"
|
||||
domain="[]"
|
||||
context="{'group_by':'state'}"
|
||||
/>
|
||||
<filter
|
||||
name="partner"
|
||||
string="Partner"
|
||||
domain="[]"
|
||||
context="{'group_by':'partner_id'}"
|
||||
/>
|
||||
<filter
|
||||
name="operation"
|
||||
string="Operation"
|
||||
domain="[]"
|
||||
context="{'group_by':'operation_id'}"
|
||||
/>
|
||||
<filter
|
||||
name="product"
|
||||
string="Product"
|
||||
domain="[]"
|
||||
context="{'group_by':'product_id'}"
|
||||
/>
|
||||
<filter
|
||||
name="to_receive"
|
||||
string="To Receive"
|
||||
domain="[('qty_to_receive', '>', 0)]"
|
||||
context="{'group_by':'partner_id'}"
|
||||
/>
|
||||
<filter
|
||||
name="to_deliver"
|
||||
string="To Deliver"
|
||||
domain="[('qty_to_deliver', '>', 0)]"
|
||||
context="{'group_by':'partner_id'}"
|
||||
/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
@@ -435,20 +638,26 @@
|
||||
<field name="name">Supplier RMA</field>
|
||||
<field name="res_model">rma.order.line</field>
|
||||
<field name="domain">[('type','=', 'supplier')]</field>
|
||||
<field name="context">{"search_default_assigned_to":uid, "supplier":1}</field>
|
||||
<field
|
||||
name="context"
|
||||
>{"search_default_assigned_to":uid, "supplier":1}</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="view_rma_line_supplier_tree" />
|
||||
</record>
|
||||
|
||||
<record id="action_rma_line_supplier_tree"
|
||||
model="ir.actions.act_window.view">
|
||||
<record
|
||||
id="action_rma_line_supplier_tree"
|
||||
model="ir.actions.act_window.view"
|
||||
>
|
||||
<field eval="3" name="sequence" />
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="act_window_id" ref="action_rma_supplier_lines" />
|
||||
</record>
|
||||
|
||||
<record id="action_rma_line_supplier_form"
|
||||
model="ir.actions.act_window.view">
|
||||
<record
|
||||
id="action_rma_line_supplier_form"
|
||||
model="ir.actions.act_window.view"
|
||||
>
|
||||
<field eval="4" name="sequence" />
|
||||
<field name="view_mode">form</field>
|
||||
<field name="view_id" ref="view_rma_line_supplier_form" />
|
||||
|
||||
@@ -7,7 +7,11 @@
|
||||
<tree string="RMA">
|
||||
<field name="name" />
|
||||
<field name="reference" />
|
||||
<field name="partner_id" groups="base.group_user" string="Customer"/>
|
||||
<field
|
||||
name="partner_id"
|
||||
groups="base.group_user"
|
||||
string="Customer"
|
||||
/>
|
||||
<field name="date_rma" />
|
||||
</tree>
|
||||
</field>
|
||||
@@ -20,8 +24,11 @@
|
||||
<tree string="RMA">
|
||||
<field name="name" />
|
||||
<field name="reference" />
|
||||
<field name="partner_id" groups="base.group_user"
|
||||
string="Supplier"/>
|
||||
<field
|
||||
name="partner_id"
|
||||
groups="base.group_user"
|
||||
string="Supplier"
|
||||
/>
|
||||
<field name="date_rma" />
|
||||
</tree>
|
||||
</field>
|
||||
@@ -35,34 +42,58 @@
|
||||
<header />
|
||||
<sheet name='rma' string="RMA">
|
||||
<div class="oe_button_box" name="button_box">
|
||||
<button type="object" name="action_view_in_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_in_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="in_shipment_count" widget="statinfo"
|
||||
string="Shipments"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="in_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Shipments"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_out_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_out_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="out_shipment_count" widget="statinfo"
|
||||
string="Deliveries"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="out_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Deliveries"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_lines"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_lines"
|
||||
class="oe_stat_button"
|
||||
icon="fa-list"
|
||||
groups="rma.group_rma_customer_user">
|
||||
<field name="line_count" widget="statinfo"
|
||||
string="RMA Lines"/>
|
||||
groups="rma.group_rma_customer_user"
|
||||
>
|
||||
<field
|
||||
name="line_count"
|
||||
widget="statinfo"
|
||||
string="RMA Lines"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_supplier_lines"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_supplier_lines"
|
||||
class="oe_stat_button"
|
||||
attrs="{'invisible':[('supplier_line_count', '=', 0)]}"
|
||||
icon="fa-list"
|
||||
groups="rma.group_rma_supplier_user">
|
||||
<field name="supplier_line_count" widget="statinfo"
|
||||
string="Rel. RMA Lines"/>
|
||||
groups="rma.group_rma_supplier_user"
|
||||
>
|
||||
<field
|
||||
name="supplier_line_count"
|
||||
widget="statinfo"
|
||||
string="Rel. RMA Lines"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<div class="oe_title" name="title">
|
||||
@@ -72,12 +103,16 @@
|
||||
</div>
|
||||
<group>
|
||||
<group name="info">
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
context="{'res_partner_search_mode': 'customer'}"
|
||||
string="Customer"
|
||||
colspan="4"
|
||||
/>
|
||||
<field name="date_rma" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field
|
||||
name="date_rma"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
</group>
|
||||
<group name="comments">
|
||||
<field name="comment" />
|
||||
@@ -86,35 +121,54 @@
|
||||
</group>
|
||||
<group>
|
||||
<group name="inbound_route" string="Inbound">
|
||||
<field name="in_warehouse_id" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field name="customer_to_supplier" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field
|
||||
name="in_warehouse_id"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
<field
|
||||
name="customer_to_supplier"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
<field name="state" invisible="True" />
|
||||
<field name="supplier_address_id"
|
||||
<field
|
||||
name="supplier_address_id"
|
||||
context="{'show_address': 1}"
|
||||
options="{'always_reload': 1}"
|
||||
attrs="{'required':[('customer_to_supplier', '=', True)],
|
||||
'invisible':[('customer_to_supplier', '=', False)],
|
||||
'readonly':[('state', '!=', 'draft')]}"/>
|
||||
'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
<group>
|
||||
<group name="contact" string="Contact">
|
||||
<field name="requested_by" readonly="1" />
|
||||
<field name="assigned_to" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field name="company_id"
|
||||
groups="base.group_multi_company"/>
|
||||
<field
|
||||
name="assigned_to"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
<field
|
||||
name="company_id"
|
||||
groups="base.group_multi_company"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="RMA Lines" name="lines">
|
||||
<field name="rma_line_ids" context="{'default_rma_id': active_id,
|
||||
<field
|
||||
name="rma_line_ids"
|
||||
context="{'default_rma_id': active_id,
|
||||
'default_partner_id': partner_id,
|
||||
'hide_title': True}">
|
||||
'hide_title': True}"
|
||||
>
|
||||
<tree string="RMA Lines" name="lines">
|
||||
<field name="sequence" widget="handle" />
|
||||
<field name="state" invisible="True" />
|
||||
<field name="product_id" />
|
||||
<field name="lot_id" groups="stock.group_production_lot"/>
|
||||
<field
|
||||
name="lot_id"
|
||||
groups="stock.group_production_lot"
|
||||
/>
|
||||
<field name="name" />
|
||||
<field name="uom_id" groups="uom.group_uom" />
|
||||
<field name="operation_id" />
|
||||
@@ -126,7 +180,11 @@
|
||||
</notebook>
|
||||
</sheet>
|
||||
<div class="oe_chatter">
|
||||
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
|
||||
<field
|
||||
name="message_follower_ids"
|
||||
widget="mail_followers"
|
||||
groups="base.group_user"
|
||||
/>
|
||||
<field name="message_ids" widget="mail_thread" />
|
||||
</div>
|
||||
</form>
|
||||
@@ -141,26 +199,44 @@
|
||||
<header />
|
||||
<sheet string="RMA">
|
||||
<div class="oe_button_box" name="button_box">
|
||||
<button type="object" name="action_view_in_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_in_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="in_shipment_count" widget="statinfo"
|
||||
string="Shipments"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="in_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Shipments"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_out_shipments"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_out_shipments"
|
||||
class="oe_stat_button"
|
||||
icon="fa-truck"
|
||||
groups="stock.group_stock_user">
|
||||
<field name="out_shipment_count" widget="statinfo"
|
||||
string="Deliveries"/>
|
||||
groups="stock.group_stock_user"
|
||||
>
|
||||
<field
|
||||
name="out_shipment_count"
|
||||
widget="statinfo"
|
||||
string="Deliveries"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_lines"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_lines"
|
||||
class="oe_stat_button"
|
||||
icon="fa-list"
|
||||
groups="rma.group_rma_supplier_user">
|
||||
<field name="line_count" widget="statinfo"
|
||||
string="RMA Lines"/>
|
||||
groups="rma.group_rma_supplier_user"
|
||||
>
|
||||
<field
|
||||
name="line_count"
|
||||
widget="statinfo"
|
||||
string="RMA Lines"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<div class="oe_title" name="title">
|
||||
@@ -171,12 +247,17 @@
|
||||
<group>
|
||||
<group name="partner">
|
||||
<field name="state" invisible="1" />
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
context="{'res_partner_search_mode': 'supplier'}"
|
||||
string="Supplier"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
<field name="reference" />
|
||||
<field name="date_rma" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field
|
||||
name="date_rma"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="comment" />
|
||||
@@ -185,40 +266,58 @@
|
||||
</group>
|
||||
<group name="route">
|
||||
<group name="inbound_route" string="Inbound">
|
||||
<field name="in_warehouse_id" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field
|
||||
name="in_warehouse_id"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
</group>
|
||||
<group name="outbound_route" string="Outbound">
|
||||
<field name="supplier_to_customer" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field name="customer_address_id"
|
||||
<field
|
||||
name="supplier_to_customer"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
<field
|
||||
name="customer_address_id"
|
||||
context="{'show_address': 1}"
|
||||
options="{'always_reload': 1}"
|
||||
attrs="{'required':[('supplier_to_customer', '=', True)],
|
||||
'invisible':[('supplier_to_customer', '=', False)],
|
||||
'readonly':[('state', '!=', 'draft')]}"/>
|
||||
'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
<group>
|
||||
<group name="contact" string="Contact">
|
||||
<field name="requested_by" readonly="1" />
|
||||
<field name="assigned_to" attrs="{'readonly':[('state', '!=', 'draft')]}"/>
|
||||
<field name="company_id"
|
||||
groups="base.group_multi_company"/>
|
||||
<field
|
||||
name="assigned_to"
|
||||
attrs="{'readonly':[('state', '!=', 'draft')]}"
|
||||
/>
|
||||
<field
|
||||
name="company_id"
|
||||
groups="base.group_multi_company"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="RMA Lines" name="lines">
|
||||
<field name="rma_line_ids"
|
||||
<field
|
||||
name="rma_line_ids"
|
||||
context="{'form_view_ref':'rma.view_rma_line_supplier_form',
|
||||
'default_rma_id': active_id,
|
||||
'default_partner_id': partner_id,
|
||||
'supplier': 1,
|
||||
'hide_title': True}">
|
||||
'hide_title': True}"
|
||||
>
|
||||
<tree string="RMA Lines">
|
||||
<field name="sequence" widget="handle" />
|
||||
<field name="state" invisible="True" />
|
||||
<field name="name" />
|
||||
<field name="product_id" />
|
||||
<field name="lot_id" groups="stock.group_production_lot"/>
|
||||
<field
|
||||
name="lot_id"
|
||||
groups="stock.group_production_lot"
|
||||
/>
|
||||
<field name="name" />
|
||||
<field name="uom_id" groups="uom.group_uom" />
|
||||
<field name="operation_id" />
|
||||
@@ -230,7 +329,11 @@
|
||||
</notebook>
|
||||
</sheet>
|
||||
<div class="oe_chatter">
|
||||
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
|
||||
<field
|
||||
name="message_follower_ids"
|
||||
widget="mail_followers"
|
||||
groups="base.group_user"
|
||||
/>
|
||||
<field name="message_ids" widget="mail_thread" />
|
||||
</div>
|
||||
</form>
|
||||
@@ -247,10 +350,18 @@
|
||||
<field name="partner_id" />
|
||||
<separator />
|
||||
<group expand="0" string="Group By">
|
||||
<filter name="partner" string="Partner" domain="[]"
|
||||
context="{'group_by':'partner_id'}"/>
|
||||
<filter name="rma_date" string="RMA Date" domain="[]"
|
||||
context="{'group_by':'date_rma'}"/>
|
||||
<filter
|
||||
name="partner"
|
||||
string="Partner"
|
||||
domain="[]"
|
||||
context="{'group_by':'partner_id'}"
|
||||
/>
|
||||
<filter
|
||||
name="rma_date"
|
||||
string="RMA Date"
|
||||
domain="[]"
|
||||
context="{'group_by':'date_rma'}"
|
||||
/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
@@ -274,15 +385,13 @@
|
||||
<field name="view_id" ref="view_rma_supplier_tree" />
|
||||
</record>
|
||||
|
||||
<record id="action_rma_supplier_tree"
|
||||
model="ir.actions.act_window.view">
|
||||
<record id="action_rma_supplier_tree" model="ir.actions.act_window.view">
|
||||
<field eval="1" name="sequence" />
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="act_window_id" ref="action_rma_supplier" />
|
||||
</record>
|
||||
|
||||
<record id="action_rma_supplier_form"
|
||||
model="ir.actions.act_window.view">
|
||||
<record id="action_rma_supplier_form" model="ir.actions.act_window.view">
|
||||
<field eval="2" name="sequence" />
|
||||
<field name="view_mode">form</field>
|
||||
<field name="view_id" ref="view_rma_supplier_form" />
|
||||
|
||||
@@ -13,7 +13,10 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="stock_location_route_form_view_inherit_rma_stock" model="ir.ui.view">
|
||||
<record
|
||||
id="stock_location_route_form_view_inherit_rma_stock"
|
||||
model="ir.ui.view"
|
||||
>
|
||||
<field name="name">stock.location.route.form</field>
|
||||
<field name="inherit_id" ref="stock.stock_location_route_form_view" />
|
||||
<field name="model">stock.location.route</field>
|
||||
|
||||
@@ -5,7 +5,10 @@
|
||||
<field name="model">stock.warehouse</field>
|
||||
<field name="inherit_id" ref="stock.view_warehouse" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//field[@name='wh_output_stock_loc_id']" position="after">
|
||||
<xpath
|
||||
expr="//field[@name='wh_output_stock_loc_id']"
|
||||
position="after"
|
||||
>
|
||||
<field name="lot_rma_id" />
|
||||
</xpath>
|
||||
<field name="resupply_wh_ids" position="after">
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?xml version="1.0" ?>
|
||||
|
||||
<odoo>
|
||||
<record id="view_rma_add_stock_move_customer" model="ir.ui.view">
|
||||
<field name="name">rma.add.stock.move.customer</field>
|
||||
@@ -7,22 +6,40 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="Select Move">
|
||||
<group>
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
domain="[('customer','=',True)]"
|
||||
string="Customer"/>
|
||||
string="Customer"
|
||||
/>
|
||||
</group>
|
||||
<separator string="Select Stock Moves to add" />
|
||||
<field name="move_ids"
|
||||
domain="[('picking_id.partner_id', '=', partner_id), ('location_dest_id.usage', '=', 'customer')]">
|
||||
<field
|
||||
name="move_ids"
|
||||
domain="[('picking_id.partner_id', '=', partner_id), ('location_dest_id.usage', '=', 'customer')]"
|
||||
>
|
||||
<tree>
|
||||
<field name="product_id" />
|
||||
<field name="product_uom_qty" />
|
||||
<field name="product_uom" string="Unit of Measure" groups="uom.group_uom"/>
|
||||
<field
|
||||
name="product_uom"
|
||||
string="Unit of Measure"
|
||||
groups="uom.group_uom"
|
||||
/>
|
||||
<field name="picking_id" />
|
||||
<field name="location_id" groups="stock.group_stock_multi_locations"/>
|
||||
<field name="location_dest_id" groups="stock.group_stock_multi_locations"/>
|
||||
<field
|
||||
name="location_id"
|
||||
groups="stock.group_stock_multi_locations"
|
||||
/>
|
||||
<field
|
||||
name="location_dest_id"
|
||||
groups="stock.group_stock_multi_locations"
|
||||
/>
|
||||
<field name="create_date" groups="base.group_no_one" />
|
||||
<field name="date" string="Date" groups="base.group_no_one"/>
|
||||
<field
|
||||
name="date"
|
||||
string="Date"
|
||||
groups="base.group_no_one"
|
||||
/>
|
||||
<field name="date_expected" string="Date Expected" />
|
||||
<field name="state" />
|
||||
</tree>
|
||||
@@ -30,26 +47,36 @@
|
||||
<footer>
|
||||
<button
|
||||
string="Confirm"
|
||||
name="add_lines" type="object"
|
||||
class="oe_highlight"/>
|
||||
name="add_lines"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
or
|
||||
<button name="action_cancel"
|
||||
string="Cancel" class="oe_link" special="cancel"/>
|
||||
<button
|
||||
name="action_cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_rma_add_stock_move_customer"
|
||||
model="ir.actions.act_window">
|
||||
<record
|
||||
id="action_rma_add_stock_move_customer"
|
||||
model="ir.actions.act_window"
|
||||
>
|
||||
<field name="name">Add from Stock Move</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">rma_add_stock_move</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
<field name="view_id" ref="view_rma_add_stock_move_customer" />
|
||||
<field name="groups_id"
|
||||
eval="[(4, ref('rma.group_rma_customer_user'))]"/>
|
||||
<field
|
||||
name="groups_id"
|
||||
eval="[(4, ref('rma.group_rma_customer_user'))]"
|
||||
/>
|
||||
</record>
|
||||
|
||||
|
||||
@@ -59,9 +86,11 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="%(action_rma_add_stock_move_customer)d"
|
||||
<button
|
||||
name="%(action_rma_add_stock_move_customer)d"
|
||||
string="Add From Stock Move"
|
||||
type="action"/>
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
@@ -72,48 +101,66 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="Select Move">
|
||||
<group>
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
domain="[('supplier','=',True)]"
|
||||
string="Supplier"/>
|
||||
string="Supplier"
|
||||
/>
|
||||
</group>
|
||||
<separator string="Select Stock Moves to add" />
|
||||
<field name="move_ids"
|
||||
domain="[('picking_id.partner_id', '=', partner_id), ('location_id.usage', '=', 'supplier')]"/>
|
||||
<field
|
||||
name="move_ids"
|
||||
domain="[('picking_id.partner_id', '=', partner_id), ('location_id.usage', '=', 'supplier')]"
|
||||
/>
|
||||
<footer>
|
||||
<button
|
||||
string="Confirm"
|
||||
name="add_lines" type="object"
|
||||
class="oe_highlight"/>
|
||||
name="add_lines"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
or
|
||||
<button name="action_cancel"
|
||||
string="Cancel" class="oe_link" special="cancel"/>
|
||||
<button
|
||||
name="action_cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_rma_add_stock_move_supplier"
|
||||
model="ir.actions.act_window">
|
||||
<record
|
||||
id="action_rma_add_stock_move_supplier"
|
||||
model="ir.actions.act_window"
|
||||
>
|
||||
<field name="name">Add from Stock Move</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">rma_add_stock_move</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
<field name="view_id" ref="view_rma_add_stock_move_supplier" />
|
||||
<field name="groups_id"
|
||||
eval="[(4, ref('rma.group_rma_supplier_user'))]"/>
|
||||
<field
|
||||
name="groups_id"
|
||||
eval="[(4, ref('rma.group_rma_supplier_user'))]"
|
||||
/>
|
||||
</record>
|
||||
|
||||
<record id="view_rma_add_stock_move_button_supplier_form"
|
||||
model="ir.ui.view">
|
||||
<record
|
||||
id="view_rma_add_stock_move_button_supplier_form"
|
||||
model="ir.ui.view"
|
||||
>
|
||||
<field name="name">rma.order.supplier.form - stock.move wizard</field>
|
||||
<field name="model">rma.order</field>
|
||||
<field name="inherit_id" ref="rma.view_rma_supplier_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="%(action_rma_add_stock_move_supplier)d"
|
||||
<button
|
||||
name="%(action_rma_add_stock_move_supplier)d"
|
||||
string="Add From Stock Move"
|
||||
type="action"/>
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?xml version="1.0" ?>
|
||||
|
||||
<odoo>
|
||||
<record id="view_rma_picking" model="ir.ui.view">
|
||||
<field name="name">rma_picking</field>
|
||||
@@ -19,11 +18,17 @@
|
||||
<footer>
|
||||
<button
|
||||
string="Confirm"
|
||||
name="action_create_picking" type="object"
|
||||
class="oe_highlight"/>
|
||||
name="action_create_picking"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
or
|
||||
<button name="action_cancel"
|
||||
string="Cancel" class="oe_link" special="cancel"/>
|
||||
<button
|
||||
name="action_cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
@@ -47,11 +52,17 @@
|
||||
<footer>
|
||||
<button
|
||||
string="Confirm"
|
||||
name="action_create_picking" type="object"
|
||||
class="oe_highlight"/>
|
||||
name="action_create_picking"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
or
|
||||
<button name="action_cancel"
|
||||
string="Cancel" class="oe_link" special="cancel"/>
|
||||
<button
|
||||
name="action_cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
@@ -87,12 +98,20 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_form" />
|
||||
<field name="arch" type="xml">
|
||||
<header position="inside">
|
||||
<button name="%(action_rma_picking_in)d" states="approved"
|
||||
string="Create Incoming Shipment" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button name="%(action_rma_picking_out)d" states="approved"
|
||||
string="Create Delivery" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button
|
||||
name="%(action_rma_picking_in)d"
|
||||
states="approved"
|
||||
string="Create Incoming Shipment"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
<button
|
||||
name="%(action_rma_picking_out)d"
|
||||
states="approved"
|
||||
string="Create Delivery"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
</field>
|
||||
</record>
|
||||
@@ -103,12 +122,20 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_supplier_form" />
|
||||
<field name="arch" type="xml">
|
||||
<header position="inside">
|
||||
<button name="%(action_rma_picking_in)d" states="approved"
|
||||
string="Create Incoming Shipment" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button name="%(action_rma_picking_out)d" states="approved"
|
||||
string="Create Delivery" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button
|
||||
name="%(action_rma_picking_in)d"
|
||||
states="approved"
|
||||
string="Create Incoming Shipment"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
<button
|
||||
name="%(action_rma_picking_out)d"
|
||||
states="approved"
|
||||
string="Create Delivery"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
<!-- Copyright 2016 ForgeFlow
|
||||
License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl-3.0) -->
|
||||
<odoo>
|
||||
<record id="view_rma_order_line_make_supplier_rma"
|
||||
model="ir.ui.view">
|
||||
<record id="view_rma_order_line_make_supplier_rma" model="ir.ui.view">
|
||||
<field name="name">RMA Line Make Supplier RMA</field>
|
||||
<field name="model">rma.order.line.make.supplier.rma</field>
|
||||
<field name="type">form</field>
|
||||
@@ -12,11 +11,13 @@
|
||||
<separator string="Existing Supplier RMA to update:" />
|
||||
<newline />
|
||||
<group>
|
||||
<field name="supplier_rma_id" domain="[('partner_id', '=', partner_id)]"/>
|
||||
<field
|
||||
name="supplier_rma_id"
|
||||
domain="[('partner_id', '=', partner_id)]"
|
||||
/>
|
||||
</group>
|
||||
<newline />
|
||||
<separator
|
||||
string="New RMA details:"/>
|
||||
<separator string="New RMA details:" />
|
||||
<newline />
|
||||
<group>
|
||||
<field name="partner_id" />
|
||||
@@ -24,32 +25,41 @@
|
||||
<newline />
|
||||
<group>
|
||||
<field name="item_ids" nolabel="1" colspan="2">
|
||||
<tree string="Details" editable="bottom" create="false">
|
||||
<field name="line_id"
|
||||
options="{'no_open': true}"/>
|
||||
<tree
|
||||
string="Details"
|
||||
editable="bottom"
|
||||
create="false"
|
||||
>
|
||||
<field
|
||||
name="line_id"
|
||||
options="{'no_open': true}"
|
||||
/>
|
||||
<field name="product_id" />
|
||||
<field name="name" />
|
||||
<field name="operation_id" />
|
||||
<field name="product_qty" />
|
||||
<field name="uom_id"
|
||||
groups="uom.group_uom"/>
|
||||
<field name="uom_id" groups="uom.group_uom" />
|
||||
</tree>
|
||||
</field>
|
||||
</group>
|
||||
<newline />
|
||||
<footer colspan="2">
|
||||
<button name="make_supplier_rma"
|
||||
<button
|
||||
name="make_supplier_rma"
|
||||
string="Create/Update Supplier RMA"
|
||||
type="object"
|
||||
class="oe_highlight"/>
|
||||
class="oe_highlight"
|
||||
/>
|
||||
<button special="cancel" string="Cancel" class="oe_link" />
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_rma_order_line_make_supplier_rma"
|
||||
model="ir.actions.act_window">
|
||||
<record
|
||||
id="action_rma_order_line_make_supplier_rma"
|
||||
model="ir.actions.act_window"
|
||||
>
|
||||
<field name="name">Create Supplier RMA</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">rma.order.line.make.supplier.rma</field>
|
||||
@@ -65,10 +75,13 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_form" />
|
||||
<field name="arch" type="xml">
|
||||
<header position="inside">
|
||||
<button name="%(action_rma_order_line_make_supplier_rma)d"
|
||||
<button
|
||||
name="%(action_rma_order_line_make_supplier_rma)d"
|
||||
states="approved"
|
||||
string="Create Supplier RMA" class="oe_highlight"
|
||||
type="action"/>
|
||||
string="Create Supplier RMA"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -6,13 +6,22 @@
|
||||
<field name="inherit_id" ref="account.view_move_form" />
|
||||
<field name="arch" type="xml">
|
||||
<field name="name" position="before">
|
||||
<div class="oe_button_box" attrs="{'invisible': [('rma_count', '=', 0)]}">
|
||||
<button type="object" name="action_view_rma_customer"
|
||||
<div
|
||||
class="oe_button_box"
|
||||
attrs="{'invisible': [('rma_count', '=', 0)]}"
|
||||
>
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_rma_customer"
|
||||
class="oe_stat_button"
|
||||
icon="fa-eject"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user">
|
||||
<field name="rma_count" widget="statinfo"
|
||||
string="RMA"/>
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
>
|
||||
<field
|
||||
name="rma_count"
|
||||
widget="statinfo"
|
||||
string="RMA"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</field>
|
||||
@@ -29,9 +38,10 @@
|
||||
<data>
|
||||
<field name="name" position="after">
|
||||
<field name="rma_line_count" invisible="1" />
|
||||
<field name="rma_line_id"
|
||||
string="RMA line originated"/>
|
||||
<notebook attrs="{'invisible': [('rma_line_count', '=', 0)]}">
|
||||
<field name="rma_line_id" string="RMA line originated" />
|
||||
<notebook
|
||||
attrs="{'invisible': [('rma_line_count', '=', 0)]}"
|
||||
>
|
||||
<page string="RMA Lines">
|
||||
<field name="rma_line_ids" />
|
||||
</page>
|
||||
@@ -48,14 +58,17 @@
|
||||
<field name="inherit_id" ref="account.view_move_form" />
|
||||
<field name="arch" type="xml">
|
||||
<field name="invoice_vendor_bill_id" position="after">
|
||||
<field name="add_rma_line_id"
|
||||
<field
|
||||
name="add_rma_line_id"
|
||||
context="{'rma': True}"
|
||||
domain="[('type', '=', 'customer'),
|
||||
('partner_id', '=', partner_id)]"
|
||||
attrs="{'readonly': [('state','not in',['draft'])],
|
||||
'invisible': ['|', ('state', '=', 'paid'),
|
||||
('type', '=', 'in_invoice')]}" class="oe_edit_only"
|
||||
options="{'no_create': True}"/>
|
||||
('type', '=', 'in_invoice')]}"
|
||||
class="oe_edit_only"
|
||||
options="{'no_create': True}"
|
||||
/>
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -3,7 +3,10 @@
|
||||
License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl-3.0) -->
|
||||
<odoo>
|
||||
|
||||
<record id="action_rma_account_customer_lines" model="ir.actions.act_window">
|
||||
<record
|
||||
id="action_rma_account_customer_lines"
|
||||
model="ir.actions.act_window"
|
||||
>
|
||||
<field name="name">Customer RMA</field>
|
||||
<field name="res_model">rma.order.line</field>
|
||||
<field name="domain">[('type','=', 'customer')]</field>
|
||||
@@ -15,45 +18,57 @@
|
||||
<field name="name">Supplier RMA</field>
|
||||
<field name="res_model">rma.order.line</field>
|
||||
<field name="domain">[('type','=', 'supplier')]</field>
|
||||
<field name="context">{"search_default_to_refund":1, "supplier":1}</field>
|
||||
<field
|
||||
name="context"
|
||||
>{"search_default_to_refund":1, "supplier":1}</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="rma.view_rma_line_supplier_tree" />
|
||||
</record>
|
||||
|
||||
<!-- Accountants menu RMA -->
|
||||
<menuitem id="menu_rma_account"
|
||||
<menuitem
|
||||
id="menu_rma_account"
|
||||
name="Accounting"
|
||||
groups="account.group_account_user"
|
||||
sequence="32"
|
||||
parent="rma.menu_rma_root"/>
|
||||
parent="rma.menu_rma_root"
|
||||
/>
|
||||
|
||||
<menuitem id="menu_rma_customer_refunds"
|
||||
<menuitem
|
||||
id="menu_rma_customer_refunds"
|
||||
name="Customer RMA to Refund"
|
||||
sequence="20"
|
||||
parent="rma_account.menu_rma_account"
|
||||
groups="rma.group_rma_customer_user"
|
||||
action="action_rma_account_customer_lines"/>
|
||||
action="action_rma_account_customer_lines"
|
||||
/>
|
||||
|
||||
<menuitem id="menu_rma_line_supplier_refunds"
|
||||
<menuitem
|
||||
id="menu_rma_line_supplier_refunds"
|
||||
name="Supplier RMA to Refund"
|
||||
sequence="20"
|
||||
parent="rma_account.menu_rma_account"
|
||||
groups="rma.group_rma_customer_user"
|
||||
action="action_rma_supplier_lines"/>
|
||||
action="action_rma_supplier_lines"
|
||||
/>
|
||||
|
||||
|
||||
<menuitem id="menu_rma_line_account_customer"
|
||||
<menuitem
|
||||
id="menu_rma_line_account_customer"
|
||||
name="Customer RMA to Refund"
|
||||
sequence="20"
|
||||
parent="account.menu_finance_receivables"
|
||||
groups="rma.group_rma_customer_user"
|
||||
action="action_rma_account_customer_lines"/>
|
||||
action="action_rma_account_customer_lines"
|
||||
/>
|
||||
|
||||
<menuitem id="menu_rma_line_account_supplier"
|
||||
<menuitem
|
||||
id="menu_rma_line_account_supplier"
|
||||
name="Supplier RMA to Refund"
|
||||
sequence="20"
|
||||
parent="account.menu_finance_payables"
|
||||
groups="rma.group_rma_supplier_user"
|
||||
action="action_rma_supplier_lines"/>
|
||||
action="action_rma_supplier_lines"
|
||||
/>
|
||||
|
||||
</odoo>
|
||||
|
||||
@@ -6,26 +6,37 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_supplier_form" />
|
||||
<field name="arch" type="xml">
|
||||
<button name="action_view_out_shipments" position="after">
|
||||
<button type="object" name="action_view_invoice"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_invoice"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
string="Origin Inv">
|
||||
string="Origin Inv"
|
||||
>
|
||||
</button>
|
||||
<button type="object" name="action_view_refunds"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_refunds"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
groups="account.group_account_user">
|
||||
<field name="refund_count" widget="statinfo"
|
||||
string="Refunds"/>
|
||||
groups="account.group_account_user"
|
||||
>
|
||||
<field
|
||||
name="refund_count"
|
||||
widget="statinfo"
|
||||
string="Refunds"
|
||||
/>
|
||||
</button>
|
||||
</button>
|
||||
<group name="main_info" position="inside">
|
||||
<field name="account_move_line_id"
|
||||
<field
|
||||
name="account_move_line_id"
|
||||
options="{'no_create': True}"
|
||||
context="{'rma': True}"
|
||||
domain="['|',
|
||||
('move_id.partner_id', '=', partner_id),
|
||||
('move_id.partner_id', 'child_of', partner_id)]"/>
|
||||
('move_id.partner_id', 'child_of', partner_id)]"
|
||||
/>
|
||||
</group>
|
||||
<field name="operation_id" position="after">
|
||||
<field name="refund_policy" />
|
||||
@@ -36,8 +47,10 @@
|
||||
</page>
|
||||
</page>
|
||||
<field name="delivery_address_id" position="after">
|
||||
<field name="invoice_address_id"
|
||||
groups='rma.group_rma_delivery_invoice_address'/>
|
||||
<field
|
||||
name="invoice_address_id"
|
||||
groups='rma.group_rma_delivery_invoice_address'
|
||||
/>
|
||||
</field>
|
||||
<group name="deliver" position="after">
|
||||
<group name="refund">
|
||||
@@ -54,26 +67,37 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_form" />
|
||||
<field name="arch" type="xml">
|
||||
<button name="action_view_out_shipments" position="after">
|
||||
<button type="object" name="action_view_invoice"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_invoice"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
string="Origin Inv">
|
||||
string="Origin Inv"
|
||||
>
|
||||
</button>
|
||||
<button type="object" name="action_view_refunds"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_refunds"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
groups="account.group_account_user">
|
||||
<field name="refund_count" widget="statinfo"
|
||||
string="Refunds"/>
|
||||
groups="account.group_account_user"
|
||||
>
|
||||
<field
|
||||
name="refund_count"
|
||||
widget="statinfo"
|
||||
string="Refunds"
|
||||
/>
|
||||
</button>
|
||||
</button>
|
||||
<group name="main_info" position="inside">
|
||||
<field name="account_move_line_id"
|
||||
<field
|
||||
name="account_move_line_id"
|
||||
options="{'no_create': True}"
|
||||
context="{'rma': True}"
|
||||
domain="['|',
|
||||
('move_id.partner_id', '=', partner_id),
|
||||
('move_id.partner_id', 'child_of', partner_id)]"/>
|
||||
('move_id.partner_id', 'child_of', partner_id)]"
|
||||
/>
|
||||
</group>
|
||||
<field name="operation_id" position="after">
|
||||
<field name="refund_policy" />
|
||||
@@ -84,8 +108,10 @@
|
||||
</page>
|
||||
</page>
|
||||
<field name="delivery_address_id" position="after">
|
||||
<field name="invoice_address_id"
|
||||
groups='rma.group_rma_delivery_invoice_address'/>
|
||||
<field
|
||||
name="invoice_address_id"
|
||||
groups='rma.group_rma_delivery_invoice_address'
|
||||
/>
|
||||
</field>
|
||||
<group name="supplier_rma" position="after">
|
||||
<group name="refund">
|
||||
@@ -102,8 +128,12 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_rma_line_filter" />
|
||||
<field name="arch" type="xml">
|
||||
<field name="product_id" position="after">
|
||||
<filter name="to_refund" string="To Refund" domain="[('qty_to_refund', '>', 0)]"
|
||||
context="{'group_by':'partner_id'}"/>
|
||||
<filter
|
||||
name="to_refund"
|
||||
string="To Refund"
|
||||
domain="[('qty_to_refund', '>', 0)]"
|
||||
context="{'group_by':'partner_id'}"
|
||||
/>
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -5,21 +5,32 @@
|
||||
<field name="model">rma.order</field>
|
||||
<field name="inherit_id" ref="rma.view_rma_form" />
|
||||
<field name="arch" type="xml">
|
||||
<button name="action_view_out_shipments"
|
||||
position="after">
|
||||
<button type="object" name="action_view_invoice_refund"
|
||||
<button name="action_view_out_shipments" position="after">
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_invoice_refund"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
groups="account.group_account_user">
|
||||
<field name="invoice_refund_count" widget="statinfo"
|
||||
string="Refunds"/>
|
||||
groups="account.group_account_user"
|
||||
>
|
||||
<field
|
||||
name="invoice_refund_count"
|
||||
widget="statinfo"
|
||||
string="Refunds"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_invoice"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_invoice"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
groups="account.group_account_user">
|
||||
<field name="invoice_count" widget="statinfo"
|
||||
string="Origin Inv"/>
|
||||
groups="account.group_account_user"
|
||||
>
|
||||
<field
|
||||
name="invoice_count"
|
||||
widget="statinfo"
|
||||
string="Origin Inv"
|
||||
/>
|
||||
</button>
|
||||
</button>
|
||||
<!--
|
||||
@@ -36,21 +47,32 @@
|
||||
<field name="model">rma.order</field>
|
||||
<field name="inherit_id" ref="rma.view_rma_supplier_form" />
|
||||
<field name="arch" type="xml">
|
||||
<button name="action_view_out_shipments"
|
||||
position="after">
|
||||
<button type="object" name="action_view_invoice_refund"
|
||||
<button name="action_view_out_shipments" position="after">
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_invoice_refund"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
groups="account.group_account_user">
|
||||
<field name="invoice_refund_count" widget="statinfo"
|
||||
string="Refunds"/>
|
||||
groups="account.group_account_user"
|
||||
>
|
||||
<field
|
||||
name="invoice_refund_count"
|
||||
widget="statinfo"
|
||||
string="Refunds"
|
||||
/>
|
||||
</button>
|
||||
<button type="object" name="action_view_invoice"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_invoice"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
groups="account.group_account_user">
|
||||
<field name="invoice_count" widget="statinfo"
|
||||
string="Origin Inv"/>
|
||||
groups="account.group_account_user"
|
||||
>
|
||||
<field
|
||||
name="invoice_count"
|
||||
widget="statinfo"
|
||||
string="Origin Inv"
|
||||
/>
|
||||
</button>
|
||||
</button>
|
||||
<!--
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?xml version="1.0" ?>
|
||||
|
||||
<odoo>
|
||||
|
||||
<record id="view_rma_add_account_move" model="ir.ui.view">
|
||||
@@ -8,18 +7,25 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="Select Invoice from customer">
|
||||
<group>
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
domain="[('customer','=',True)]"
|
||||
string="Customer"/>
|
||||
string="Customer"
|
||||
/>
|
||||
</group>
|
||||
<separator string="Select Invoices lines to add" />
|
||||
<field name="line_ids"
|
||||
<field
|
||||
name="line_ids"
|
||||
domain="[('move_id.partner_id', '=', partner_id),
|
||||
('move_id.type', '=', 'out_invoice')]">
|
||||
('move_id.type', '=', 'out_invoice')]"
|
||||
>
|
||||
<tree string="Invoice Lines">
|
||||
<field name="move_id" />
|
||||
<field name="name" />
|
||||
<field name="account_id" groups="account.group_account_user"/>
|
||||
<field
|
||||
name="account_id"
|
||||
groups="account.group_account_user"
|
||||
/>
|
||||
<field name="quantity" />
|
||||
<field name="product_id" />
|
||||
<field name="product_uom_id" />
|
||||
@@ -32,11 +38,17 @@
|
||||
<footer>
|
||||
<button
|
||||
string="Confirm"
|
||||
name="add_lines" type="object"
|
||||
class="oe_highlight"/>
|
||||
name="add_lines"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
or
|
||||
<button name="action_cancel"
|
||||
string="Cancel" class="oe_link" special="cancel"/>
|
||||
<button
|
||||
name="action_cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
@@ -48,18 +60,25 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="Select Invoice from supplier">
|
||||
<group>
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
domain="[('supplier','=',True)]"
|
||||
string="Supplier"/>
|
||||
string="Supplier"
|
||||
/>
|
||||
</group>
|
||||
<separator string="Select Invoices lines to add" />
|
||||
<field name="line_ids"
|
||||
<field
|
||||
name="line_ids"
|
||||
domain="[('move_id.partner_id', '=', partner_id),
|
||||
('move_id.type', '=', 'in_invoice')]">
|
||||
('move_id.type', '=', 'in_invoice')]"
|
||||
>
|
||||
<tree string="Invoice Lines">
|
||||
<field name="move_id" />
|
||||
<field name="name" />
|
||||
<field name="account_id" groups="account.group_account_user"/>
|
||||
<field
|
||||
name="account_id"
|
||||
groups="account.group_account_user"
|
||||
/>
|
||||
<field name="quantity" />
|
||||
<field name="product_id" />
|
||||
<field name="product_uom_id" />
|
||||
@@ -72,11 +91,17 @@
|
||||
<footer>
|
||||
<button
|
||||
string="Confirm"
|
||||
name="add_lines" type="object"
|
||||
class="oe_highlight"/>
|
||||
name="add_lines"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
or
|
||||
<button name="action_cancel"
|
||||
string="Cancel" class="oe_link" special="cancel"/>
|
||||
<button
|
||||
name="action_cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
@@ -89,10 +114,16 @@
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
<field name="view_id" ref="view_rma_add_account_move" />
|
||||
<field name="groups_id" eval="[(4, ref('rma.group_rma_customer_user'))]"/>
|
||||
<field
|
||||
name="groups_id"
|
||||
eval="[(4, ref('rma.group_rma_customer_user'))]"
|
||||
/>
|
||||
</record>
|
||||
|
||||
<record id="action_rma_add_account_move_supplier" model="ir.actions.act_window">
|
||||
<record
|
||||
id="action_rma_add_account_move_supplier"
|
||||
model="ir.actions.act_window"
|
||||
>
|
||||
<field name="name">Add Invoice</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">rma_add_account_move</field>
|
||||
@@ -100,7 +131,10 @@
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
<field name="view_id" ref="view_rma_add_account_move_supplier" />
|
||||
<field name="groups_id" eval="[(4, ref('rma.group_rma_supplier_user'))]"/>
|
||||
<field
|
||||
name="groups_id"
|
||||
eval="[(4, ref('rma.group_rma_supplier_user'))]"
|
||||
/>
|
||||
</record>
|
||||
|
||||
<record id="view_rma_add_account_move_form" model="ir.ui.view">
|
||||
@@ -109,9 +143,11 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="%(action_rma_add_account_move)d"
|
||||
<button
|
||||
name="%(action_rma_add_account_move)d"
|
||||
string="Add From Invoice"
|
||||
type="action"/>
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
@@ -122,9 +158,11 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_supplier_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="%(action_rma_add_account_move_supplier)d"
|
||||
<button
|
||||
name="%(action_rma_add_account_move_supplier)d"
|
||||
string="Add From Invoice"
|
||||
type="action"/>
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -26,8 +26,17 @@
|
||||
</tree>
|
||||
</field>
|
||||
<footer>
|
||||
<button string='Create Refund' name="invoice_refund" type="object" class="btn-primary"/>
|
||||
<button string="Cancel" class="btn-default" special="cancel"/>
|
||||
<button
|
||||
string='Create Refund'
|
||||
name="invoice_refund"
|
||||
type="object"
|
||||
class="btn-primary"
|
||||
/>
|
||||
<button
|
||||
string="Cancel"
|
||||
class="btn-default"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
@@ -39,8 +48,10 @@
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="view_rma_refund" />
|
||||
<field name="binding_model_id" ref="rma.model_rma_order_line" />
|
||||
<field name="groups_id"
|
||||
eval="[(4, ref('account.group_account_invoice'))]"/>
|
||||
<field
|
||||
name="groups_id"
|
||||
eval="[(4, ref('account.group_account_invoice'))]"
|
||||
/>
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
@@ -50,9 +61,13 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="%(action_rma_refund)d" states="approved"
|
||||
string="Create Refund" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button
|
||||
name="%(action_rma_refund)d"
|
||||
states="approved"
|
||||
string="Create Refund"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
@@ -63,9 +78,13 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_supplier_button_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="%(action_rma_refund)d" states="approved"
|
||||
string="Create Refund" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button
|
||||
name="%(action_rma_refund)d"
|
||||
states="approved"
|
||||
string="Create Refund"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -7,18 +7,26 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_form" />
|
||||
<field name="arch" type="xml">
|
||||
<div name='button_box' position="inside">
|
||||
<button type="object" name="action_view_sale_order"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_sale_order"
|
||||
class="oe_stat_button"
|
||||
icon="fa-strikethrough"
|
||||
groups="sales_team.group_sale_salesman_all_leads">
|
||||
<field name="sales_count" widget="statinfo"
|
||||
string="Sales Orders"/>
|
||||
groups="sales_team.group_sale_salesman_all_leads"
|
||||
>
|
||||
<field
|
||||
name="sales_count"
|
||||
widget="statinfo"
|
||||
string="Sales Orders"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<group name="main_info" position="inside">
|
||||
<field name="sale_line_id"
|
||||
<field
|
||||
name="sale_line_id"
|
||||
context="{'rma': True}"
|
||||
options="{'no_create': True}"/>
|
||||
options="{'no_create': True}"
|
||||
/>
|
||||
</group>
|
||||
<group name="quantities" position="inside">
|
||||
<group>
|
||||
@@ -30,8 +38,10 @@
|
||||
<field name="sale_policy" />
|
||||
</field>
|
||||
<field name="origin" position="after">
|
||||
<field name="sale_id"
|
||||
attrs="{'invisible': [('sale_line_id', '=', False)]}"/>
|
||||
<field
|
||||
name="sale_id"
|
||||
attrs="{'invisible': [('sale_line_id', '=', False)]}"
|
||||
/>
|
||||
</field>
|
||||
<notebook position="inside">
|
||||
<page name="sale" string="Sale Lines">
|
||||
@@ -47,12 +57,18 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_supplier_form" />
|
||||
<field name="arch" type="xml">
|
||||
<div name='button_box' position="inside">
|
||||
<button type="object" name="action_view_sale_order"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_sale_order"
|
||||
class="oe_stat_button"
|
||||
icon="fa-strikethrough"
|
||||
groups="sales_team.group_sale_salesman_all_leads">
|
||||
<field name="sales_count" widget="statinfo"
|
||||
string="Sales Orders"/>
|
||||
groups="sales_team.group_sale_salesman_all_leads"
|
||||
>
|
||||
<field
|
||||
name="sales_count"
|
||||
widget="statinfo"
|
||||
string="Sales Orders"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<group name="quantities" position="inside">
|
||||
@@ -78,9 +94,13 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_button_form" />
|
||||
<field name="arch" type="xml">
|
||||
<header position="inside">
|
||||
<button name="%(action_rma_order_line_make_sale_order)d" states="approved"
|
||||
string="Create Sales Quotation" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button
|
||||
name="%(action_rma_order_line_make_sale_order)d"
|
||||
states="approved"
|
||||
string="Create Sales Quotation"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
</field>
|
||||
</record>
|
||||
@@ -90,9 +110,13 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_line_supplier_button_form" />
|
||||
<field name="arch" type="xml">
|
||||
<header position="inside">
|
||||
<button name="%(action_rma_order_line_make_sale_order)d" states="approved"
|
||||
string="Create Sales Quotation" class="oe_highlight"
|
||||
type="action"/>
|
||||
<button
|
||||
name="%(action_rma_order_line_make_sale_order)d"
|
||||
states="approved"
|
||||
string="Create Sales Quotation"
|
||||
class="oe_highlight"
|
||||
type="action"
|
||||
/>
|
||||
</header>
|
||||
</field>
|
||||
</record>
|
||||
@@ -103,8 +127,15 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_rma_line_filter" />
|
||||
<field name="arch" type="xml">
|
||||
<group name="stock_quantities" position="after">
|
||||
<group name="sale_quantities" groups="sales_team.group_sale_salesman">
|
||||
<filter domain="[('state','!=', 'done'),('qty_to_sell','>',0.0)]" help="To Sell" name="to_sell"/>
|
||||
<group
|
||||
name="sale_quantities"
|
||||
groups="sales_team.group_sale_salesman"
|
||||
>
|
||||
<filter
|
||||
domain="[('state','!=', 'done'),('qty_to_sell','>',0.0)]"
|
||||
help="To Sell"
|
||||
name="to_sell"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
</field>
|
||||
|
||||
@@ -6,12 +6,18 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_form" />
|
||||
<field name="arch" type="xml">
|
||||
<div name="button_box" position="inside">
|
||||
<button type="object" name="action_view_sale_order"
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_sale_order"
|
||||
class="oe_stat_button"
|
||||
icon="fa-pencil-square-o"
|
||||
groups="sales_team.group_sale_salesman">
|
||||
<field name="sale_count" widget="statinfo"
|
||||
string="Origin SO"/>
|
||||
groups="sales_team.group_sale_salesman"
|
||||
>
|
||||
<field
|
||||
name="sale_count"
|
||||
widget="statinfo"
|
||||
string="Origin SO"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</field>
|
||||
|
||||
@@ -7,10 +7,13 @@
|
||||
<field name="arch" type="xml">
|
||||
<xpath
|
||||
expr="//notebook/page/field[@name='order_line']/form/group/group/field[@name='price_unit']"
|
||||
position="after">
|
||||
<field name="rma_line_id"
|
||||
position="after"
|
||||
>
|
||||
<field
|
||||
name="rma_line_id"
|
||||
options="{'no_create': True}"
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"/>
|
||||
groups="rma.group_rma_customer_user,rma.group_rma_supplier_user"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
@@ -23,14 +26,23 @@
|
||||
<field name="inherit_id" ref="sale.view_order_form" />
|
||||
<field name="arch" type="xml">
|
||||
<data>
|
||||
<xpath expr="//button[@name='action_view_invoice']" position="before">
|
||||
<button type="object"
|
||||
<xpath
|
||||
expr="//button[@name='action_view_invoice']"
|
||||
position="before"
|
||||
>
|
||||
<button
|
||||
type="object"
|
||||
name="action_view_rma"
|
||||
class="oe_stat_button"
|
||||
icon="fa-dropbox"
|
||||
attrs="{'invisible': [('rma_count', '=', 0)]}"
|
||||
groups="rma.group_rma_customer_user">
|
||||
<field name="rma_count" widget="statinfo" string="RMA"/>
|
||||
groups="rma.group_rma_customer_user"
|
||||
>
|
||||
<field
|
||||
name="rma_count"
|
||||
widget="statinfo"
|
||||
string="RMA"
|
||||
/>
|
||||
</button>
|
||||
</xpath>
|
||||
</data>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
|
||||
<odoo>
|
||||
<record id="view_rma_add_sale" model="ir.ui.view">
|
||||
<field name="name">rma.add.sale</field>
|
||||
@@ -8,20 +7,26 @@
|
||||
<form string="Select Sale Order from customer">
|
||||
<separator string="Select Sale Order from customer" />
|
||||
<group>
|
||||
<field name="partner_id"
|
||||
<field
|
||||
name="partner_id"
|
||||
domain="[('customer','=',True)]"
|
||||
string="Customer"/>
|
||||
string="Customer"
|
||||
/>
|
||||
</group>
|
||||
<separator string="Select Sale Order Lines to Add" />
|
||||
<group>
|
||||
<field name="sale_id"
|
||||
<field
|
||||
name="sale_id"
|
||||
domain="[
|
||||
('partner_id','=',partner_id), (('state','not in',['draft','cancel']))]"
|
||||
context="{'partner_id': partner_id}"/>
|
||||
context="{'partner_id': partner_id}"
|
||||
/>
|
||||
</group>
|
||||
<field name="sale_line_ids"
|
||||
<field
|
||||
name="sale_line_ids"
|
||||
domain="[('order_id', '=', sale_id)]"
|
||||
string="Sale Order Lines">
|
||||
string="Sale Order Lines"
|
||||
>
|
||||
<tree>
|
||||
<field name="product_id" invisible="1" />
|
||||
<field name="order_id" />
|
||||
@@ -32,19 +37,33 @@
|
||||
<field name="qty_delivered" />
|
||||
<field name="qty_invoiced" />
|
||||
<field name="qty_to_invoice" />
|
||||
<field name="product_uom" string="Unit of Measure" groups="uom.group_uom"/>
|
||||
<field name="price_subtotal" sum="Total" widget="monetary"/>
|
||||
<field
|
||||
name="product_uom"
|
||||
string="Unit of Measure"
|
||||
groups="uom.group_uom"
|
||||
/>
|
||||
<field
|
||||
name="price_subtotal"
|
||||
sum="Total"
|
||||
widget="monetary"
|
||||
/>
|
||||
</tree>
|
||||
|
||||
</field>
|
||||
<footer>
|
||||
<button
|
||||
string="Confirm"
|
||||
name="add_lines" type="object"
|
||||
class="oe_highlight"/>
|
||||
name="add_lines"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
or
|
||||
<button name="action_cancel"
|
||||
string="Cancel" class="oe_link" special="cancel"/>
|
||||
<button
|
||||
name="action_cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
special="cancel"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
@@ -57,7 +76,10 @@
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
<field name="view_id" ref="view_rma_add_sale" />
|
||||
<field name="groups_id" eval="[(4, ref('rma.group_rma_customer_user')), (4, ref('rma.group_rma_customer_user'))]"/>
|
||||
<field
|
||||
name="groups_id"
|
||||
eval="[(4, ref('rma.group_rma_customer_user')), (4, ref('rma.group_rma_customer_user'))]"
|
||||
/>
|
||||
</record>
|
||||
|
||||
|
||||
@@ -67,9 +89,11 @@
|
||||
<field name="inherit_id" ref="rma.view_rma_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//header" position="inside">
|
||||
<button name="%(action_rma_add_sale)d"
|
||||
<button
|
||||
name="%(action_rma_add_sale)d"
|
||||
string="Add From Sale Order"
|
||||
type="action"/>
|
||||
type="action"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -12,13 +12,14 @@
|
||||
<separator string="Existing Quotation to update:" />
|
||||
<newline />
|
||||
<group>
|
||||
<field name="sale_order_id"
|
||||
<field
|
||||
name="sale_order_id"
|
||||
domain="[('partner_id','=', partner_id)]"
|
||||
context="{'partner_id': partner_id}"/>
|
||||
context="{'partner_id': partner_id}"
|
||||
/>
|
||||
</group>
|
||||
<newline />
|
||||
<separator
|
||||
string="New Sales Order details:"/>
|
||||
<separator string="New Sales Order details:" />
|
||||
<newline />
|
||||
<group>
|
||||
<field name="partner_id" />
|
||||
@@ -28,29 +29,39 @@
|
||||
<field name="item_ids" nolabel="1" colspan="2">
|
||||
<tree string="Details" editable="bottom">
|
||||
<field name="wiz_id" invisible="True" />
|
||||
<field name="line_id"
|
||||
invisible="True"/>
|
||||
<field name="line_id" invisible="True" />
|
||||
<field name="product_id" />
|
||||
<field name="name" />
|
||||
<field name="product_qty" />
|
||||
<field name="product_uom_id"
|
||||
groups="uom.group_uom"/>
|
||||
<field
|
||||
name="product_uom_id"
|
||||
groups="uom.group_uom"
|
||||
/>
|
||||
<field name="free_of_charge" />
|
||||
</tree>
|
||||
</field>
|
||||
</group>
|
||||
<footer colspan="2">
|
||||
<button name="make_sale_order"
|
||||
string="Create Sales Quotation" type="object"
|
||||
class="oe_highlight"/>
|
||||
<button special="cancel" string="Cancel" class="oe_link"/>
|
||||
<button
|
||||
name="make_sale_order"
|
||||
string="Create Sales Quotation"
|
||||
type="object"
|
||||
class="oe_highlight"
|
||||
/>
|
||||
<button
|
||||
special="cancel"
|
||||
string="Cancel"
|
||||
class="oe_link"
|
||||
/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_rma_order_line_make_sale_order"
|
||||
model="ir.actions.act_window">
|
||||
<record
|
||||
id="action_rma_order_line_make_sale_order"
|
||||
model="ir.actions.act_window"
|
||||
>
|
||||
<field name="name">Create Sales Quotation</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">rma.order.line.make.sale.order</field>
|
||||
|
||||
2
setup/.setuptools-odoo-make-default-ignore
Normal file
2
setup/.setuptools-odoo-make-default-ignore
Normal file
@@ -0,0 +1,2 @@
|
||||
# addons listed in this file are ignored by
|
||||
# setuptools-odoo-make-default (one addon per line)
|
||||
2
setup/README
Normal file
2
setup/README
Normal file
@@ -0,0 +1,2 @@
|
||||
To learn more about this directory, please visit
|
||||
https://pypi.python.org/pypi/setuptools-odoo
|
||||
1
setup/rma/odoo/addons/rma
Symbolic link
1
setup/rma/odoo/addons/rma
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../../rma
|
||||
6
setup/rma/setup.py
Normal file
6
setup/rma/setup.py
Normal file
@@ -0,0 +1,6 @@
|
||||
import setuptools
|
||||
|
||||
setuptools.setup(
|
||||
setup_requires=['setuptools-odoo'],
|
||||
odoo_addon=True,
|
||||
)
|
||||
1
setup/rma_account/odoo/addons/rma_account
Symbolic link
1
setup/rma_account/odoo/addons/rma_account
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../../rma_account
|
||||
6
setup/rma_account/setup.py
Normal file
6
setup/rma_account/setup.py
Normal file
@@ -0,0 +1,6 @@
|
||||
import setuptools
|
||||
|
||||
setuptools.setup(
|
||||
setup_requires=['setuptools-odoo'],
|
||||
odoo_addon=True,
|
||||
)
|
||||
1
setup/rma_sale/odoo/addons/rma_sale
Symbolic link
1
setup/rma_sale/odoo/addons/rma_sale
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../../rma_sale
|
||||
6
setup/rma_sale/setup.py
Normal file
6
setup/rma_sale/setup.py
Normal file
@@ -0,0 +1,6 @@
|
||||
import setuptools
|
||||
|
||||
setuptools.setup(
|
||||
setup_requires=['setuptools-odoo'],
|
||||
odoo_addon=True,
|
||||
)
|
||||
Reference in New Issue
Block a user