Server IP : 127.0.0.2 / Your IP : 3.147.72.3 Web Server : Apache/2.4.18 (Ubuntu) System : User : www-data ( ) PHP Version : 7.0.33-0ubuntu0.16.04.16 Disable Function : disk_free_space,disk_total_space,diskfreespace,dl,exec,fpaththru,getmyuid,getmypid,highlight_file,ignore_user_abord,leak,listen,link,opcache_get_configuration,opcache_get_status,passthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,php_uname,phpinfo,posix_ctermid,posix_getcwd,posix_getegid,posix_geteuid,posix_getgid,posix_getgrgid,posix_getgrnam,posix_getgroups,posix_getlogin,posix_getpgid,posix_getpgrp,posix_getpid,posix,_getppid,posix_getpwnam,posix_getpwuid,posix_getrlimit,posix_getsid,posix_getuid,posix_isatty,posix_kill,posix_mkfifo,posix_setegid,posix_seteuid,posix_setgid,posix_setpgid,posix_setsid,posix_setuid,posix_times,posix_ttyname,posix_uname,pclose,popen,proc_open,proc_close,proc_get_status,proc_nice,proc_terminate,shell_exec,source,show_source,system,virtual MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /opt/odoo/addons/stock_dropshipping/test/ |
Upload File : |
- Create a supplier. - !record {model: res.partner, id: supplier_crossdock}: name: Crossdocking supplier - Use the warehouse created in cancellation_propagated.yml. - !python {model: stock.warehouse, id: wh_pps}: | assert self.crossdock_route_id.active, 'Crossdock route is not active' - Create new product without any routes. - !record {model: product.product, id: cross_shop_product, view: False}: name: PCE type: product categ_id: product.product_category_1 list_price: 100.0 standard_price: 70.0 seller_ids: - delay: 1 name: supplier_crossdock min_qty: 2.0 type: product uom_id: product.product_uom_unit uom_po_id: product.product_uom_unit - Create a sales order with a line of 100 PCE incoming shipment, with route_id crossdock shipping. - !record {model: sale.order, id: sale_order_crossdock_shpng}: partner_id: base.res_partner_4 warehouse_id: wh_pps note: Create Sales order order_line: - product_id: cross_shop_product product_uom_qty: 100.00 - !python {model: sale.order.line, id: False}: | route_wh_pps_crossdock = self.env['stock.warehouse'].browse(ref('stock_dropshipping.wh_pps')).crossdock_route_id.id order = self.env['sale.order'].browse(ref('sale_order_crossdock_shpng')) order.order_line.write({'route_id': route_wh_pps_crossdock}) - Confirm sales order. - !python {model: sale.order, id: sale_order_crossdock_shpng}: | self.action_confirm() - Run the scheduler. - !python {model: procurement.order, id: False}: | self.run_scheduler() - Check a quotation was created for the created supplier and confirm it. - !python {model: purchase.order, id: False}: | po = self.search([('partner_id', '=', ref('supplier_crossdock')), ('state','=','draft')]) po.button_confirm()