2022110305
This commit is contained in:
1 parent
5513061137
commit
c781d24ab0
1 file changed
+8
-10
+8
-10
@@ -238,13 +238,12 @@
|
|||||||
"import os,sys,shutil\n",
|
"import os,sys,shutil\n",
|
||||||
"import json\n",
|
"import json\n",
|
||||||
"import math\n",
|
"import math\n",
|
||||||
"\n",
|
"import glob\n",
|
||||||
"\n",
|
"\n",
|
||||||
"fi_path = os.getcwd()+'/file/137'\n",
|
"fi_path = os.getcwd()+'/file/137'\n",
|
||||||
"old = []\n",
|
"old = []\n",
|
||||||
"new = []\n",
|
|
||||||
"dict2 = {}\n",
|
"dict2 = {}\n",
|
||||||
"depart = []\n",
|
"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"filename = 'data/巴陵石化人员.json'\n",
|
"filename = 'data/巴陵石化人员.json'\n",
|
||||||
"with open(filename,'r') as fl:\n",
|
"with open(filename,'r') as fl:\n",
|
||||||
@@ -257,14 +256,13 @@
|
|||||||
" dict2[int(k)] = [m_name,m_depart]\n",
|
" dict2[int(k)] = [m_name,m_depart]\n",
|
||||||
"\n",
|
"\n",
|
||||||
"\n",
|
"\n",
|
||||||
"fl=os.listdir(fi_path)\n",
|
"m_path = os.getcwd()+'/file/137'\n",
|
||||||
"for fn in fl:\n",
|
"fls = glob.glob(f'file/137/*.pdf')\n",
|
||||||
" if os.path.isfile(fi_path + '/' + fn):\n",
|
"\n",
|
||||||
" ofn = int(fn.split('.')[0])\n",
|
"for fn in fls:\n",
|
||||||
" old.append(ofn)\n",
|
" old.append(os.path.basename(fn).split('.')[0])\n",
|
||||||
" #print(fn)\n",
|
" #print(fn)\n",
|
||||||
"old.sort()\n",
|
"\n",
|
||||||
" #print(str(nfn)+'.pdf')\n",
|
|
||||||
"\n",
|
"\n",
|
||||||
"for n in old: \n",
|
"for n in old: \n",
|
||||||
" o_name = f'{fi_path}/{n}.pdf'\n",
|
" o_name = f'{fi_path}/{n}.pdf'\n",
|
||||||
|
|||||||
Reference in new issue
Block a user