Compare commits
No commits in common. "b1b81a777fdf30a48a5c56dfaba1f854097e0b9e" and "fcd014bad3de8c281258b126d7eebbd21a7b33da" have entirely different histories.
b1b81a777f
...
fcd014bad3
52
README.md
52
README.md
|
@ -1,52 +0,0 @@
|
||||||
# CellarioScheduler Database Switcher
|
|
||||||
|
|
||||||
## Usage
|
|
||||||
|
|
||||||
To run the switcher, execute the `.bat` file as an administrator.
|
|
||||||
To preserve compatability with older verisons of CellarioScheduler and their default install locations,
|
|
||||||
you must run with write access to `C:\Program Files\HighRes Biosolutions`.
|
|
||||||
|
|
||||||
When running the tool for the first time, a config file (extension `.toml`) will be generated.
|
|
||||||
Edit this file to add additional databases.
|
|
||||||
The format of this file is outlined below.
|
|
||||||
|
|
||||||
After you have added your databases to the config file, restart the tool and they should appear as buttons.
|
|
||||||
Clicking a button will:
|
|
||||||
|
|
||||||
1. Either alter the registry entry for the connection string (<=4.2) or alter `appsettings.Production.json` (>=4.3)
|
|
||||||
to reflect your database settings.
|
|
||||||
2. Create a symlink from the specified CellarioScheduler directory to `C:\Program Files\HighRes Biosolutions\Cellario`
|
|
||||||
- If a real install of CellarioScheduler already exists here, it is automatically renamed with a random suffix so it
|
|
||||||
will not be clobbered.
|
|
||||||
3. Launches CellarioScheduler
|
|
||||||
|
|
||||||
## Configuration
|
|
||||||
|
|
||||||
A database entry has the following sections:
|
|
||||||
|
|
||||||
### Entry Name
|
|
||||||
This is the part in the square brackets.
|
|
||||||
Whatever is entered here will appear in the UI.
|
|
||||||
Spaces are not permitted, underscores and hyphens are permitted.
|
|
||||||
|
|
||||||
### DatabaseUser
|
|
||||||
This is the user login for the database.
|
|
||||||
It should be verbatim what you would use to log in to your database.
|
|
||||||
|
|
||||||
### DatabasePassword
|
|
||||||
This is the password for the database.
|
|
||||||
It is likely either `postgres` or `oracle`.
|
|
||||||
|
|
||||||
### DatabaseType
|
|
||||||
Either `postgres` or `oracle`
|
|
||||||
|
|
||||||
### CellarioDirectory
|
|
||||||
This is the absolute path to your installation directory for CellarioScheduler.
|
|
||||||
This allows you to associate a particular database with a given installation of CS.
|
|
||||||
The backslash characters `\` must be escaped with another backslash character `\`;
|
|
||||||
see the example database if this is unclear.
|
|
||||||
|
|
||||||
### Version
|
|
||||||
This is the version of CellarioScheduler installed in `CellarioDirectory`.
|
|
||||||
You do not need to enter the full version, only the major and minor version numbers (i.e. `4.1` is sufficient).
|
|
||||||
This is only used to determine if the registry should be altered or if appsettings should be altered.
|
|
|
@ -1,4 +1,4 @@
|
||||||
from tkinter import Tk, Canvas, Scrollbar VERTICAL, LEFT, RIGHT, Y, BOTH
|
from tkinter import Tk, VERTICAL, LEFT, RIGHT, Y, BOTH
|
||||||
from tkinter import ttk
|
from tkinter import ttk
|
||||||
|
|
||||||
from instance import Instance, gen_function_for_instance
|
from instance import Instance, gen_function_for_instance
|
||||||
|
@ -12,8 +12,8 @@ def start_ui(instances: [Instance], settings):
|
||||||
if MainSettings.Sort == SortType.ALPHA:
|
if MainSettings.Sort == SortType.ALPHA:
|
||||||
instances = list(sorted(instances))
|
instances = list(sorted(instances))
|
||||||
|
|
||||||
canvas = Canvas(root)
|
canvas = ttk.Canvas(root)
|
||||||
scrollbar = Scrollbar(root, orient=VERTICAL, command=canvas.yview)
|
scrollbar = ttk.Scrollbar(root, orient=VERTICAL, command=canvas.yview)
|
||||||
frame = ttk.Frame(canvas)
|
frame = ttk.Frame(canvas)
|
||||||
|
|
||||||
frame.bind(
|
frame.bind(
|
||||||
|
|
Loading…
Reference in New Issue