Skip to content

Commit

Permalink
Release 2024-11-04
Browse files Browse the repository at this point in the history
  • Loading branch information
alexkurasoff committed Nov 4, 2024
1 parent 1cb5c92 commit 21c862f
Show file tree
Hide file tree
Showing 77 changed files with 3,734 additions and 2,345 deletions.
Binary file added Releases/OpenRIMS20241104RN.docx
Binary file not shown.
663 changes: 573 additions & 90 deletions client/package-lock.json

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
"font-awesome": "^4.7.0",
"is-integer": "^1.0.7",
"moment": "^2.29.1",
"node-sass": "^5.0.0",
"number.isinteger": "^0.1.1",
"object-assign": "^4.1.1",
"pad-end": "^1.0.2",
Expand Down
2 changes: 2 additions & 0 deletions client/src/components/ActivityManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -510,6 +510,7 @@ class ActivityManager extends Component{
Alerts.warning(this.state.labels.backDlg_war,()=>{
this.state.send=true
this.state.reassign=true
this.state.reject=false
this.setState(this.state)
}, ()=>{})
}}
Expand All @@ -521,6 +522,7 @@ class ActivityManager extends Component{
onClick={()=>{
this.state.send=true
this.state.reject=true
this.state.reassign=false
Navigator.message(this.state.identifier,"*","saveChecklistSilent",{})
}}
//action return to applicant
Expand Down
26 changes: 7 additions & 19 deletions client/src/components/Administrate.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import Actions from './Actions'
import ATCCodes from './ATCCodes'
import Excipients from './Excipients'
import Inns from './Inns'
import ReportConfigurator from './reports/ReportConfigurator'
import DataSources from './datasources/DataSources'
import Import_A from './Import_A'
import Import_B from './Import_B'
import ImportWorkflow from './ImportWorkflow'
Expand Down Expand Up @@ -53,7 +53,7 @@ class Administrate extends Component{
language:'',
global_exit:'',
dataconfigurator:'',
reports:'',
datasourcesconfigurator:'',
messages:'',
resources:'',
processes:'',
Expand Down Expand Up @@ -129,8 +129,8 @@ class Administrate extends Component{
}
}
return <DataConfigurator nodeId={params.nodeId} vars={params.nodeId!=0}/>
case "reportconfigurator":
return <ReportConfigurator/>
case "datasourcesconfigurator":
return <DataSources/>
case "messages":
return <Messages/>
case "dataformpreview":
Expand Down Expand Up @@ -284,18 +284,6 @@ class Administrate extends Component{
</NavItem>
</div>
</DropdownItem>
{/* <DropdownItem>
<div>
<NavItem active={this.state.menu=='actions'}>
<NavLink href="/admin#administrate/actions">
<div>
<i className="fas fa-xs fa-check-double mr-1"></i>
{this.state.labels.label_actions}
</div>
</NavLink>
</NavItem>
</div>
</DropdownItem> */}
</DropdownMenu>
</UncontrolledDropdown>

Expand Down Expand Up @@ -372,11 +360,11 @@ class Administrate extends Component{
</DropdownItem>
<DropdownItem>
<NavItem>
<NavLink active={this.state.menu=='reports' || this.state.menu=='reportconfig'}
href="/admin#administrate/reportconfigurator">
<NavLink active={this.state.menu=='datasourcesconfigurator' || this.state.menu=='reportconfig'}
href="/admin#administrate/datasourcesconfigurator">
<div>
<i className="fas fa-xs fa-table mr-1"></i>
{this.state.labels.reports}
{this.state.labels.datasourcesconfigurator}
</div>
</NavLink>
</NavItem>
Expand Down
15 changes: 0 additions & 15 deletions client/src/components/ApplicationStart.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ class ApplicationStart extends Component{
global_submit:'',
return_action:'',
route_action:'',
global_showPrint:"",
notes:'',
},
history:{}, //histroy table
Expand Down Expand Up @@ -184,20 +183,6 @@ class ApplicationStart extends Component{
Navigator.message(this.state.identifier, "*", "nextButtonPressed", {btnname:this.state.btnname})
}}
>{this.state.nextlabel}</Button>{' '}
<Button size="sm" hidden={this.state.history.historyId == 0}
className="mr-1" color="info"
onClick={()=>{
let data={
url:this.props.data.url,
applDictNodeId:this.props.data.applDictNodeId,
historyId:this.props.data.historyId,
}
let param = JSON.stringify(data)
var url = "/" + Navigator.tabSetName() + "#printprev" + "/" + encodeURIComponent(param)
let w = window.open(url, "_blank")
}}>
{this.state.labels.global_showPrint}
</Button>{' '}
<Button size="sm"
className="mr-1" color="success"
onClick={()=>{
Expand Down
15 changes: 6 additions & 9 deletions client/src/components/Content.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,12 @@ import Administrate from './Administrate'
import Applications from './Applications'
import ToDoList from './ToDoList'
import Monitoring from './Monitoring'
import Reports from './Reports'
import PrintPreview from './PrintPreview'
import Spinner from './utils/Spinner'
import SpinnerMain from './utils/SpinnerMain'
import PublicPermitData from './PublicPermitData'
import URLAssistant from './URLAssistant'
import VariableAssistant from './dataconfig/VariableAssistant'
import DataSourceTest from './datasources/DataSourceTest'

/**
* Uniform content component
Expand Down Expand Up @@ -136,8 +135,6 @@ class Content extends Component{
return <ToDoList />
case "monitor":
return <Monitoring />
case "reports":
return <Reports />
case "urlassistant":
{
let parStr = Navigator.parameterValue()
Expand All @@ -148,7 +145,11 @@ class Content extends Component{
{
let parStr = Navigator.parameterValue()
let params=JSON.parse(parStr)
return <VariableAssistant value={params.value} recipient={params.recipient}/>
return <VariableAssistant currentName={params.value} recipient={params.recipient}/>
}
case "datasourcetest":
{
return <DataSourceTest />
}
default:
return this.paintRows()
Expand All @@ -169,10 +170,6 @@ class Content extends Component{
return <Monitoring />
case "reports":
return <Reports />
case "printprev":
parStr = Navigator.parameterValue();
data = JSON.parse(parStr)
return <PrintPreview data={data} narrow/>
default:
return this.paintRows()
}
Expand Down
44 changes: 20 additions & 24 deletions client/src/components/Dictionary.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,26 @@ class Dictionary extends Component{
</Row>
)
}
/**
* is this dictionary loaded
* @param {DictionaryDTO} dictionaryDTO
*/
static isLoaded(dictionaryDTO){
if(dictionaryDTO==undefined){
return false
}
if(dictionaryDTO.table==undefined){
return false
}
if(dictionaryDTO.table.headers==undefined){
return false
}
if(dictionaryDTO.table.headers.headers==undefined){
return false
}
return dictionaryDTO.table.headers.headers.length>0
}

/**
* listen for incoming messages from the parent component
*/
Expand Down Expand Up @@ -291,7 +311,6 @@ class Dictionary extends Component{
this.comparator = new FieldsComparator(this)
this.state.sendMess=true
this.setState(this.state)
//Navigator.message(this.props.identifier,this.props.recipient,"onSelectionChange",this.state.data)
})
}}>
{field.code}
Expand Down Expand Up @@ -321,29 +340,6 @@ class Dictionary extends Component{
return accum
}
},0)
/*let hasnext = this.state.hasnext//(this.props.display && sumSelected==1) || (!this.props.display && sumSelected>0)
if(hasnext && !this.state.data.readOnly && !this.state.data.mult){
ret.push(
<BreadcrumbItem hidden={this.state.edit} key='next'>
<div className={className} style={{fontSize:'0.8rem'}}
onClick={()=>{
if(this.state.data.readOnly){
return
}
let varName=this.state.data.varName
Fetchers.postJSONNoSpinner("/api/common/dictionary/load/next", this.state.data, (query,result)=>{
this.state.data=result
this.state.hasnext=false
this.state.data.varName=varName
this.comparator = new FieldsComparator(this)
this.setState(this.state)
})
}}>
<b>{this.state.labels.next}</b>
</div>
</BreadcrumbItem>
)
}*/
return ret
}
/**
Expand Down
15 changes: 6 additions & 9 deletions client/src/components/EmptyFunc.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ function EmptyFunc({recipient}){
const[data, setData] = useState({}); //data from the server and/or properties

function handleMessages(event){
let data=event.data
if(data.from==recipient){
//TODO handle messages
let eventData=event.data
if(eventData.to==identifier.current){
//TODO handle messages from next level
}
}

Expand All @@ -27,7 +27,7 @@ function EmptyFunc({recipient}){
*/
function loadData(){
Fetchers.postJSON("/api/unknown", data, (query,result)=>{
let newLabels=Locales.createLabelsFunctional()
let newLabels=Locales.createLabelsFunctional(result,labels)
Locales.resolveLabelsFunctional(newLabels,setLabels)
if(result.valid){
setData(result)
Expand All @@ -38,17 +38,14 @@ function EmptyFunc({recipient}){
}

/**
* Load or initialize data after component did mount
* Reset event processor after each render to avoid usage of the previous data
*/
useEffect(()=>{
//setup the messages listener
window.addEventListener("message",handleMessages)

loadData()

//cleanup the messages listener
return ()=>window.removeEventListener("message",handleMessages)
},[])
})

if(labels.locale== undefined){
return Pharmadex.wait()
Expand Down
Loading

0 comments on commit 21c862f

Please sign in to comment.