Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 26c0f1da8e | |||
| 1d46d78c35 | |||
| 920c746444 |
+8
-1
@@ -1,4 +1,5 @@
|
|||||||
import random
|
import random
|
||||||
|
from datetime import datetime
|
||||||
|
|
||||||
vfyd_tags = [
|
vfyd_tags = [
|
||||||
"vfyd accounting",
|
"vfyd accounting",
|
||||||
@@ -21,7 +22,6 @@ vfyd_tags = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
team = [
|
team = [
|
||||||
"nle",
|
|
||||||
"abz",
|
"abz",
|
||||||
"hael",
|
"hael",
|
||||||
"roen",
|
"roen",
|
||||||
@@ -30,6 +30,13 @@ team = [
|
|||||||
"huvw",
|
"huvw",
|
||||||
"artn",
|
"artn",
|
||||||
"gvar",
|
"gvar",
|
||||||
|
"sben",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
is_friday = datetime.now().weekday() == 4
|
||||||
|
|
||||||
|
if not is_friday:
|
||||||
|
team.append("nle")
|
||||||
|
|
||||||
|
|
||||||
random.shuffle(team)
|
random.shuffle(team)
|
||||||
|
|||||||
@@ -22,6 +22,10 @@ def cli() -> None:
|
|||||||
def dispatch():
|
def dispatch():
|
||||||
"""Randomly distribute unassigned tasks among team members."""
|
"""Randomly distribute unassigned tasks among team members."""
|
||||||
|
|
||||||
|
if DispatchStorage.load():
|
||||||
|
print("[red]Tickets were already dispatched.[/red]")
|
||||||
|
return
|
||||||
|
|
||||||
client = odoo_client.OdooClient()
|
client = odoo_client.OdooClient()
|
||||||
today = datetime.now().strftime("%Y-%m-%d")
|
today = datetime.now().strftime("%Y-%m-%d")
|
||||||
domain = [
|
domain = [
|
||||||
|
|||||||
Reference in New Issue
Block a user