Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
@@ -82,8 +82,8 @@ class SoongWorkflowRecord(models.Model):
|
||||
|
||||
is_company = fields.Boolean(string="本公司", default=True, compute='_compute_is_company',search='_search_part_of_company')
|
||||
|
||||
# 节点更新时间(上一节点的结束时间)
|
||||
node_update_time = fields.Datetime(string="节点更新时间")
|
||||
# 办结时间(上一节点的结束时间)
|
||||
node_update_time = fields.Datetime(string="办结时间")
|
||||
|
||||
@api.depends_context('uid', 'company')
|
||||
@api.depends('company_id')
|
||||
|
||||
@@ -8,10 +8,18 @@
|
||||
<field name="name">User</field>
|
||||
<field name="category_id" ref="module_category_soong_workflow"/>
|
||||
</record>
|
||||
|
||||
<record id="group_soong_workflow_hr" model="res.groups">
|
||||
<field name="name">工作流--人事分组</field>
|
||||
<field name="category_id" ref="module_category_soong_workflow"/>
|
||||
<field name="implied_ids" eval="[(4, ref('group_soong_workflow_user'))]"/>
|
||||
<field name="users" eval="[(4, ref('base.user_admin'))]"/>
|
||||
</record>
|
||||
|
||||
<record id="group_soong_workflow_manager" model="res.groups">
|
||||
<field name="name">Manager</field>
|
||||
<field name="category_id" ref="module_category_soong_workflow"/>
|
||||
<field name="implied_ids" eval="[(4, ref('group_soong_workflow_user'))]"/>
|
||||
<field name="implied_ids" eval="[(4, ref('group_soong_workflow_user')),(4, ref('group_soong_workflow_hr'))]"/>
|
||||
<field name="users" eval="[(4, ref('base.user_admin'))]"/>
|
||||
</record>
|
||||
|
||||
@@ -38,17 +46,5 @@
|
||||
<field name="perm_unlink" eval="True"/>
|
||||
</record>
|
||||
|
||||
<!-- 当前用户可以访问当前部门以及下属部门的数据-->
|
||||
<!-- <record id="rule_soong_workflow_record_user_department_read" model="ir.rule">-->
|
||||
<!-- <field name="name">当前用户可以访问当前部门以及下属部门的数据</field>-->
|
||||
<!-- <field name="model_id" ref="model_soong_workflow_record"/>-->
|
||||
<!-- <field name="groups" eval="[(4, ref('group_soong_workflow_user'))]"/>-->
|
||||
<!-- <field name="domain_force">[('is_department_record', '=', True)]</field>-->
|
||||
<!-- <field name="perm_read" eval="True"/>-->
|
||||
<!-- <field name="perm_write" eval="True"/>-->
|
||||
<!-- <field name="perm_create" eval="True"/>-->
|
||||
<!-- <field name="perm_unlink" eval="True"/>-->
|
||||
<!-- </record>-->
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
@@ -243,7 +243,7 @@
|
||||
decoration-danger="approve_state == 'end'" decoration-success="approve_state == 'pending'"/>
|
||||
<field name="create_uid"/>
|
||||
<field name="employee_ids" widget="many2many_tags" string="当前经办人" class="list_ids_width"/>
|
||||
<field name="soong_state"/><field name="node_update_time" string="节点更新时间" optional="show"/>
|
||||
<field name="soong_state"/><field name="node_update_time" string="办结时间" optional="show"/>
|
||||
<field name="is_manager" column_invisible="1"/>
|
||||
<field name="is_unlink" column_invisible="1"/>
|
||||
<field name="is_log2" column_invisible="1"/>
|
||||
@@ -252,7 +252,42 @@
|
||||
invisible="not is_unlink"/>
|
||||
<button name="greater_record" type="object" string="更多" class="btn-primary" invisible="not is_log2"/>
|
||||
<button name="reminders_record" type="object" string="催办" class="btn-primary"
|
||||
invisible="soong_state != 'done' or create_uid != uid or approve_state == 'end'"/>
|
||||
invisible="create_uid != uid or approve_state == 'end'"/>
|
||||
<button name="revoke_record" type="object" string="撤销" class="btn-primary"
|
||||
groups="soong_workflow.group_soong_workflow_manager"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<!-- 已办流程视图 -->
|
||||
<record id="soong_workflow_record_done_tree" model="ir.ui.view">
|
||||
<field name="name">soong.workflow.done.record.tree</field>
|
||||
<field name="model">soong.workflow.record</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="已办流程" action="open_record" type="object"
|
||||
decoration-muted="approve_state == 'end'" decoration-warning="approve_state != 'end'"
|
||||
delete="false"
|
||||
create="false" default_order="write_date2 desc, id desc" expand="1" limit="10">
|
||||
<header>
|
||||
<button name="admin_end" type="object" string="管理员强制结束" class="oe_highlight"
|
||||
groups="soong_workflow.group_soong_workflow_manager"/>
|
||||
<button name="delete_record" type="object" string="删除" class="oe_highlight"
|
||||
groups="soong_workflow.group_soong_workflow_manager"/>
|
||||
</header>
|
||||
<field name="priority" optional="show" widget="priority" nolabel="1"/>
|
||||
<field name="code"/>
|
||||
<field name="workflow_id" string="审批类型"/>
|
||||
<field name="name"/>
|
||||
<field name="approve_state" string="审批状态" widget="badge"
|
||||
decoration-danger="approve_state == 'end'" decoration-success="approve_state == 'pending'"/>
|
||||
<field name="create_uid"/>
|
||||
<field name="node_update_time" string="办结时间" optional="show"/>
|
||||
<field name="is_manager" column_invisible="1"/>
|
||||
<field name="is_unlink" column_invisible="1"/>
|
||||
<field name="is_log2" column_invisible="1"/>
|
||||
<button name="delete_record" type="object" string="删除" class="btn-primary"
|
||||
confirm="你确定要删除吗?"
|
||||
invisible="not is_unlink"/>
|
||||
<button name="greater_record" type="object" string="更多" class="btn-primary" invisible="not is_log2"/>
|
||||
<button name="revoke_record" type="object" string="撤销" class="btn-primary"
|
||||
groups="soong_workflow.group_soong_workflow_manager"/>
|
||||
</tree>
|
||||
@@ -294,6 +329,7 @@
|
||||
<button name="delete_record" type="object" string="删除" class="oe_highlight"
|
||||
groups="soong_workflow.group_soong_workflow_manager"/>
|
||||
</header>
|
||||
<field name="priority" optional="show" widget="priority" nolabel="1"/>
|
||||
<field name="code"/>
|
||||
<field name="workflow_id" string="审批类型"/>
|
||||
<field name="name"/>
|
||||
@@ -301,7 +337,7 @@
|
||||
decoration-danger="approve_state == 'end'" decoration-success="approve_state == 'pending'"/>
|
||||
<field name="create_uid"/>
|
||||
<field name="employee_ids" widget="many2many_tags" string="当前经办人" class="list_ids_width"/>
|
||||
<field name="soong_state"/>
|
||||
<field name="soong_state"/><field name="node_update_time" string="办结时间" optional="show"/>
|
||||
<field name="is_manager" column_invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
@@ -393,7 +429,7 @@
|
||||
['done', 'active']), ('is_company', '=', True)]
|
||||
</field>
|
||||
<field name="search_view_id" ref="soong_workflow_record_search1"/>
|
||||
<field name="view_id" ref="soong_workflow_record_my_tree"/>
|
||||
<field name="view_id" ref="soong_workflow_record_done_tree"/>
|
||||
</record>
|
||||
<record id="soong_workflow_department_record_action" model="ir.actions.act_window">
|
||||
<field name="name">流程查询</field>
|
||||
|
||||
@@ -63,13 +63,7 @@ class CurrentReceivableRentReport(models.Model):
|
||||
|
||||
for idx, rec in enumerate(receivables, start=1):
|
||||
amt = rec.original_amount or 0.0
|
||||
# 从property.rent.list中获取税率
|
||||
rent_list = self.env['property.rent.list'].search([
|
||||
('lessee_id', '=', rec.lessee_id.id if rec.lessee_id else False),
|
||||
('property_id', 'in', rec.property_ids.ids if rec.property_ids else []),
|
||||
('due_date', '=', rec.due_date),
|
||||
], limit=1)
|
||||
tax_rate = rent_list.tax if rent_list else (rec.tax or 0.0)
|
||||
tax_rate = rec.tax or 0.0
|
||||
amt_nt = amt / (1 + tax_rate / 100) if tax_rate else amt
|
||||
total_amount += amt
|
||||
total_amount_nt += amt_nt
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** @odoo-module1 **/
|
||||
/** @odoo-module **/
|
||||
|
||||
|
||||
import {registry} from "@web/core/registry";
|
||||
@@ -158,6 +158,14 @@ class ReceivableReport extends Component {
|
||||
|
||||
async onUpdateCompany(v) {
|
||||
console.log(v)
|
||||
// 检查v是否为空或v[0]不存在
|
||||
if (!v || !v[0]) {
|
||||
this.state.selectCompany = {};
|
||||
this.state.selectPartner = {};
|
||||
this.state.domainUsers = [];
|
||||
await this.onSearch();
|
||||
return;
|
||||
}
|
||||
// 执行一次 查询
|
||||
// 通过 read 重新查询一次, 更多只返回了 id
|
||||
let values = await this.serviceOrm.call(
|
||||
|
||||
@@ -51,9 +51,11 @@
|
||||
</div>
|
||||
<div class="col">
|
||||
<select id="formview_default_conditions" class="o_input" t-model="state.condition" t-on-change="onChangeCondition">
|
||||
<option value="">权属类型</option>
|
||||
<option t-foreach="state.conditions" t-as="cond"
|
||||
t-att-value="cond.value"
|
||||
t-key="cond.name">
|
||||
t-key="cond.name"
|
||||
t-if="cond.value">
|
||||
<t t-esc="cond.name"/>
|
||||
</option>
|
||||
</select>
|
||||
|
||||
@@ -23,4 +23,9 @@
|
||||
}
|
||||
.stat-change {
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
/* 下拉框placeholder样式 */
|
||||
#formview_default_conditions option[value=""] {
|
||||
color: #6c757d;
|
||||
}
|
||||
@@ -66,16 +66,16 @@ class YuthonWillTask(http.Controller):
|
||||
users_id = int(kw.get('users_id'))
|
||||
user = request.env['res.users'].sudo().browse(int(users_id))
|
||||
employee_id = user.with_company(user.company_id.id).employee_id.id
|
||||
records = request.env['hr.payslip'].sudo().search([('employee_id', '=', employee_id)])
|
||||
records = request.env['yuthon.salary.active'].sudo().search([('employee_id', '=', employee_id)])
|
||||
data = {}
|
||||
for record in records:
|
||||
year = record.date_from.year
|
||||
month = record.date_from.month
|
||||
year = int(record.select_year)
|
||||
month = int(record.select_time)
|
||||
if year not in data.keys():
|
||||
data[year] = {'total': 0}
|
||||
if month not in data[year].keys():
|
||||
data[year][month] = {'total': record.actual_salary}
|
||||
data[year]['total'] += record.actual_salary
|
||||
data[year][month] = {'total': record.actual_paid_salary}
|
||||
data[year]['total'] += record.actual_paid_salary
|
||||
return json.dumps({'data': data, 'code': 200, 'message': ''})
|
||||
|
||||
@http.route('/phone/salary/self/detail', type='http', auth="none", csrf=False, cors='*')
|
||||
|
||||
@@ -752,7 +752,7 @@
|
||||
<menuitem id="menu_soong_workflow_department_record" name="流程查询" action="soong_workflow.soong_workflow_department_record_action" sequence="15"/>
|
||||
<menuitem id="menu_soong_workflow_done_record" name="已办流程" action="soong_workflow.soong_workflow_record_done_action" sequence="20"/>
|
||||
<menuitem id="menu_workflow_approval_request_admin" name="流程监控" action="soong_workflow.soong_workflow_record_action_admin" sequence="25"/>
|
||||
<menuitem id="menu_soong_workflow_hr_employee" name="人力资源流程" action="soong_workflow.soong_workflow_hr_employee_action" sequence="30"/>
|
||||
<menuitem id="menu_soong_workflow_hr_employee" name="人力资源流程" action="soong_workflow.soong_workflow_hr_employee_action" sequence="30" groups="soong_workflow.group_soong_workflow_hr"/>
|
||||
<menuitem id="yuthon_file_processing_menu" name="文件处理" action="yuthon_official.yuthon_file_processing_action" sequence="35"/>
|
||||
<menuitem id="yuthon_sub_enterprises" name="文件处理(子企业)" action="yuthon_official.view_yuthon_sub_enterprises_action" sequence="40"/>
|
||||
<menuitem id="yuthon_notice_menu1_board" name="通知公告" action="yuthon_notice.approval_notice_action" sequence="45"/>
|
||||
@@ -762,7 +762,7 @@
|
||||
<menuitem id="menu_hr_attendance_my_record_board" name="我的考勤" action="yuthon_hr_attendance.hr_attendance_action1" sequence="65"/>
|
||||
<menuitem id="menu_hr_attendance_my_abnormal_board" name="我的异常" action="yuthon_hr_attendance.hr_attendance_my_abnormal" sequence="70"/>
|
||||
<menuitem id="yuthon_vacation_reports_my" name="考勤确认单" action="yuthon_hr_attendance.action_server_open_my_vacation_form1" sequence="75"/>
|
||||
<menuitem id="yuthon_salary_active_my1" name="工资条" action="yuthon_salary.yuthon_salary_active_my_action" sequence="80"/>
|
||||
<menuitem id="yuthon_salary_active_my2" name="工资条" action="yuthon_salary.yuthon_salary_active_my_action" sequence="80"/>
|
||||
<menuitem id="yuthon_meal_expenses_my_board" name="餐费" action="yuthon_salary.view_my_yuthon_meal_expenses_action" sequence="85"/>
|
||||
<menuitem id="property_device_repair_action_brand" name="报事报修" action="yuthon_maintain.property_device_repair_action" sequence="90"/>
|
||||
<menuitem id="property_device_repair_action_brand_all" name="报事报修(管理员)" action="yuthon_maintain.property_device_repair_all_action" groups="base.group_system" sequence="95"/>
|
||||
|
||||
Reference in New Issue
Block a user