개정판 ea56e68c
issue #000: change database name to 'HYTOS.db'
Change-Id: I0f9fc109bfd4af155715938625cbb9c9451710d0
HYTOS/HYTOS/AppDocData.py | ||
---|---|---|
79 | 79 |
Error = 2 |
80 | 80 |
|
81 | 81 |
class AppDocData(SingletonInstane): |
82 |
DATABASE = 'ITI_PID.db' |
|
82 |
DATABASE = App.NAME + '.db' |
|
83 |
|
|
83 | 84 |
def __init__(self): |
84 | 85 |
from DisplayColors import DisplayColors |
85 | 86 |
|
... | ... | |
670 | 671 |
self.makeChildDir() |
671 | 672 |
try: |
672 | 673 |
# Creates or opens a file called mydb with a SQLite3 DB |
673 |
dbPath = os.path.join(self.getCurrentProject().getDbFilePath() , "ITI_PID.db")
|
|
674 |
dbPath = os.path.join(self.getCurrentProject().getDbFilePath() , App.NAME + '.db')
|
|
674 | 675 |
|
675 | 676 |
if not os.path.isfile(dbPath): |
676 | 677 |
templatePath = self.getTemplateDbPath() |
HYTOS/HYTOS/HMBTable.py | ||
---|---|---|
129 | 129 |
@date 2018.07.12 |
130 | 130 |
''' |
131 | 131 |
def loadData(self): |
132 |
from App import App |
|
132 | 133 |
from AppDocData import AppDocData |
133 | 134 |
|
134 | 135 |
try: |
... | ... | |
137 | 138 |
|
138 | 139 |
appDocData = AppDocData.instance() |
139 | 140 |
|
140 |
dbPath = os.path.join(appDocData.getCurrentProject().getDbFilePath() , 'ITI_PID.db')
|
|
141 |
dbPath = os.path.join(appDocData.getCurrentProject().getDbFilePath() , App.NAME + '.db')
|
|
141 | 142 |
|
142 | 143 |
conn = sqlite3.connect(dbPath) |
143 | 144 |
cursor = conn.cursor() |
... | ... | |
164 | 165 |
''' |
165 | 166 |
def saveData(self): |
166 | 167 |
import uuid |
168 |
from App import App |
|
167 | 169 |
from AppDocData import AppDocData |
168 | 170 |
|
169 | 171 |
try: |
170 | 172 |
if self._hmbs is not None: |
171 | 173 |
appDocData = AppDocData.instance() |
172 | 174 |
# Creates or opens a file called mydb with a SQLite3 DB |
173 |
dbPath = os.path.join(appDocData.getCurrentProject().getDbFilePath(), "ITI_PID.db")
|
|
175 |
dbPath = os.path.join(appDocData.getCurrentProject().getDbFilePath(), App.NAME + '.db')
|
|
174 | 176 |
conn = sqlite3.connect(dbPath) |
175 | 177 |
# Get a cursor object |
176 | 178 |
cursor = conn.cursor() |
내보내기 Unified diff