Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions codbex-countries/codbex-countries.edm
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
<model>
<entities>
<entity name="Country" dataName="COUNTRY" dataCount="SELECT COUNT(*) AS COUNT FROM &quot;${tablePrefix}_COUNTRY&quot;" dataQuery="" type="SETTING" title="Country" caption="Manage entity Country" description="Manage entity Country" tooltip="Country" icon="globe" menuKey="country" menuLabel="Country" menuIndex="100" layoutType="MANAGE" perspectiveName="Settings" perspectiveLabel="Entities" perspectiveHeader="" perspectiveIcon="globe" perspectiveOrder="990" perspectiveNavId="" perspectiveRole="" generateReport="false" multilingual="true" generateDefaultRoles="true" roleRead="codbex-countries.Countries.CountryReadOnly" roleWrite="codbex-countries.Countries.CountryFullAccess">
<property name="Id" description="" tooltip="" dataName="COUNTRY_ID" dataType="INTEGER" dataNullable="true" dataPrimaryKey="true" dataAutoIncrement="true" widgetType="TEXTBOX" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Name" description="" tooltip="" dataName="COUNTRY_NAME" dataType="VARCHAR" dataLength="255" dataNullable="false" dataUnique="true" widgetType="TEXTBOX" widgetSize="fd-col-md--4 fd-col--6" widgetLength="20" widgetIsMajor="true"></property>
<property name="Code2" description="" tooltip="" dataName="COUNTRY_CODE2" dataType="CHAR" dataLength="2" dataNullable="false" dataUnique="true" widgetType="TEXTBOX" widgetSize="fd-col-md--2 fd-col--3" widgetLength="20" widgetIsMajor="true"></property>
<property name="Code3" description="" tooltip="" dataName="COUNTRY_CODE3" dataType="CHAR" dataLength="3" dataNullable="false" dataUnique="true" widgetType="TEXTBOX" widgetSize="fd-col-md--2 fd-col--3" widgetLength="20" widgetIsMajor="true"></property>
<property name="Numeric" description="" tooltip="" dataName="COUNTRY_NUMERIC" dataType="CHAR" dataLength="3" dataNullable="false" dataUnique="true" widgetType="TEXTBOX" widgetSize="fd-col-md--2 fd-col--3" widgetLength="20" widgetIsMajor="true"></property>
<entity name="Country" dataName="COUNTRY" dataCount="SELECT COUNT(*) AS COUNT FROM &quot;${tablePrefix}_COUNTRY&quot;" dataQuery="" type="SETTING" title="Country" caption="Manage entity Country" description="Manage entity Country" tooltip="Country" icon="globe" menuKey="country" menuLabel="Country" menuIndex="100" layoutType="MANAGE" perspectiveName="Settings" perspectiveLabel="Settings" perspectiveHeader="" perspectiveIcon="globe" perspectiveOrder="990" perspectiveNavId="" perspectiveRole="" generateReport="false" multilingual="true" generateDefaultRoles="true" roleRead="codbex-countries.Countries.CountryReadOnly" roleWrite="codbex-countries.Countries.CountryFullAccess">
<property name="Id" description="" tooltip="" dataName="COUNTRY_ID" dataType="INTEGER" dataNullable="true" dataPrimaryKey="true" dataAutoIncrement="true" auditType="NONE" widgetType="TEXTBOX" widgetSize="" widgetLength="20" widgetIsMajor="true"></property>
<property name="Name" description="" tooltip="" dataName="COUNTRY_NAME" dataType="VARCHAR" dataLength="255" dataNullable="false" dataUnique="true" auditType="NONE" widgetType="TEXTBOX" widgetSize="fd-col-md--4 fd-col--6" widgetLength="20" widgetIsMajor="true"></property>
<property name="Code2" description="" tooltip="" dataName="COUNTRY_CODE2" dataType="CHAR" dataLength="2" dataNullable="false" dataUnique="true" auditType="NONE" widgetType="TEXTBOX" widgetSize="fd-col-md--2 fd-col--3" widgetLength="20" widgetIsMajor="true"></property>
<property name="Code3" description="" tooltip="" dataName="COUNTRY_CODE3" dataType="CHAR" dataLength="3" dataNullable="false" dataUnique="true" auditType="NONE" widgetType="TEXTBOX" widgetSize="fd-col-md--2 fd-col--3" widgetLength="20" widgetIsMajor="true"></property>
<property name="Numeric" description="" tooltip="" dataName="COUNTRY_NUMERIC" dataType="CHAR" dataLength="3" dataNullable="false" dataUnique="true" auditType="NONE" widgetType="TEXTBOX" widgetSize="fd-col-md--2 fd-col--3" widgetLength="20" widgetIsMajor="true"></property>
</entity>
</entities>
<perspectives>
</perspectives>
<navigations>
</navigations>
<mxGraphModel><root><mxCell id="0"/><mxCell id="1" parent="0"/><mxCell id="2" style="entity" parent="1" vertex="1"><Entity name="Country" dataName="COUNTRY" dataCount="SELECT COUNT(*) AS COUNT FROM &quot;${tablePrefix}_COUNTRY&quot;" title="Country" tooltip="Country" icon="globe" menuLabel="Country" perspectiveIcon="globe" perspectiveOrder="990" type="Entity" menuKey="country" perspectiveName="Settings" caption="Manage entity Country" disableGeneration="false" entityType="SETTING" description="Manage entity Country" generateDefaultRoles="true" roleRead="codbex-countries.Countries.CountryReadOnly" roleWrite="codbex-countries.Countries.CountryFullAccess" multilingual="true" as="value"/><mxGeometry x="240" y="80" width="200" height="158" as="geometry"><mxRectangle width="200" height="28" as="alternateBounds"/></mxGeometry></mxCell><mxCell id="3" parent="2" vertex="1" connectable="0"><Property name="Id" dataName="COUNTRY_ID" dataType="INTEGER" dataLength="0" dataPrimaryKey="true" dataAutoIncrement="true" as="value"/><mxGeometry y="28" width="200" height="26" as="geometry"/></mxCell><mxCell id="6" parent="2" vertex="1" connectable="0"><Property name="Name" dataName="COUNTRY_NAME" dataLength="255" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--4 fd-col--6" as="value"/><mxGeometry y="54" width="200" height="26" as="geometry"/></mxCell><mxCell id="7" parent="2" vertex="1" connectable="0"><Property name="Code2" dataName="COUNTRY_CODE2" dataType="CHAR" dataLength="2" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--2 fd-col--3" as="value"/><mxGeometry y="80" width="200" height="26" as="geometry"/></mxCell><mxCell id="8" parent="2" vertex="1" connectable="0"><Property name="Code3" dataName="COUNTRY_CODE3" dataType="CHAR" dataLength="3" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--2 fd-col--3" as="value"/><mxGeometry y="106" width="200" height="26" as="geometry"/></mxCell><mxCell id="9" parent="2" vertex="1" connectable="0"><Property name="Numeric" dataName="COUNTRY_NUMERIC" dataType="CHAR" dataLength="3" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--2 fd-col--3" as="value"/><mxGeometry y="132" width="200" height="26" as="geometry"/></mxCell></root></mxGraphModel>
<mxGraphModel><root><mxCell id="0"/><mxCell id="1" parent="0"/><mxCell id="2" style="entity" parent="1" vertex="1"><Entity name="Country" dataName="COUNTRY" dataCount="SELECT COUNT(*) AS COUNT FROM &quot;${tablePrefix}_COUNTRY&quot;" title="Country" tooltip="Country" icon="globe" menuLabel="Country" perspectiveIcon="globe" perspectiveOrder="990" type="Entity" menuKey="country" perspectiveName="Settings" caption="Manage entity Country" disableGeneration="false" entityType="SETTING" description="Manage entity Country" generateDefaultRoles="true" roleRead="codbex-countries.Countries.CountryReadOnly" roleWrite="codbex-countries.Countries.CountryFullAccess" multilingual="true" perspectiveLabel="Settings" as="value"/><mxGeometry x="240" y="80" width="200" height="158" as="geometry"><mxRectangle width="200" height="28" as="alternateBounds"/></mxGeometry></mxCell><mxCell id="3" parent="2" vertex="1" connectable="0"><Property name="Id" dataName="COUNTRY_ID" dataType="INTEGER" dataLength="0" dataPrimaryKey="true" dataAutoIncrement="true" as="value"/><mxGeometry y="28" width="200" height="26" as="geometry"/></mxCell><mxCell id="6" parent="2" vertex="1" connectable="0"><Property name="Name" dataName="COUNTRY_NAME" dataLength="255" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--4 fd-col--6" as="value"/><mxGeometry y="54" width="200" height="26" as="geometry"/></mxCell><mxCell id="7" parent="2" vertex="1" connectable="0"><Property name="Code2" dataName="COUNTRY_CODE2" dataType="CHAR" dataLength="2" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--2 fd-col--3" as="value"/><mxGeometry y="80" width="200" height="26" as="geometry"/></mxCell><mxCell id="8" parent="2" vertex="1" connectable="0"><Property name="Code3" dataName="COUNTRY_CODE3" dataType="CHAR" dataLength="3" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--2 fd-col--3" as="value"/><mxGeometry y="106" width="200" height="26" as="geometry"/></mxCell><mxCell id="9" parent="2" vertex="1" connectable="0"><Property name="Numeric" dataName="COUNTRY_NUMERIC" dataType="CHAR" dataLength="3" dataNotNull="true" dataUnique="true" dataPrecision="NaN" dataScale="NaN" widgetSize="fd-col-md--2 fd-col--3" as="value"/><mxGeometry y="132" width="200" height="26" as="geometry"/></mxCell></root></mxGraphModel>
</model>
27 changes: 16 additions & 11 deletions codbex-countries/codbex-countries.gen
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,21 @@
"brandUrl": "https://www.codbex.com/",
"title": "Countries Management Module",
"description": "Managing Countries Data",
"fileName": "codbex-countries",
"genFolderName": "codbex-countries",
"dataSource": "DefaultDB",
"roles": [
{
"entityName": "Country",
"roleRead": "codbex-countries.Countries.CountryReadOnly",
"roleWrite": "codbex-countries.Countries.CountryFullAccess"
}
],
"tprefix": "codbex-countries-model",
"projectName": "codbex-countries",
"workspaceName": "workspace",
"filePath": "codbex-countries.model",
"templateId": "template-application-angular-v2/template/template.js",
"fileName": "codbex-countries",
"genFolderName": "codbex-countries",
"dataSource": "DefaultDB",
"perspectives": {
"Settings": {
"views": [
Expand All @@ -25,18 +33,11 @@
"role": ""
}
},
"roles": [
{
"entityName": "Country",
"roleRead": "codbex-countries.Countries.CountryReadOnly",
"roleWrite": "codbex-countries.Countries.CountryFullAccess"
}
],
"tprefix": "codbex-countries-model",
"models": [
{
"properties": [
{
"auditType": "NONE",
"dataAutoIncrement": true,
"dataName": "COUNTRY_ID",
"dataNullable": true,
Expand All @@ -62,6 +63,7 @@
"inputRule": ""
},
{
"auditType": "NONE",
"dataLength": "255",
"dataName": "COUNTRY_NAME",
"dataNullable": false,
Expand Down Expand Up @@ -90,6 +92,7 @@
"inputRule": ""
},
{
"auditType": "NONE",
"dataLength": "2",
"dataName": "COUNTRY_CODE2",
"dataNullable": false,
Expand Down Expand Up @@ -118,6 +121,7 @@
"inputRule": ""
},
{
"auditType": "NONE",
"dataLength": "3",
"dataName": "COUNTRY_CODE3",
"dataNullable": false,
Expand Down Expand Up @@ -146,6 +150,7 @@
"inputRule": ""
},
{
"auditType": "NONE",
"dataLength": "3",
"dataName": "COUNTRY_NUMERIC",
"dataNullable": false,
Expand Down
7 changes: 6 additions & 1 deletion codbex-countries/codbex-countries.model
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
{
"properties": [
{
"auditType": "NONE",
"dataAutoIncrement": "true",
"dataName": "COUNTRY_ID",
"dataNullable": "true",
Expand All @@ -18,6 +19,7 @@
"widgetType": "TEXTBOX"
},
{
"auditType": "NONE",
"dataLength": "255",
"dataName": "COUNTRY_NAME",
"dataNullable": "false",
Expand All @@ -32,6 +34,7 @@
"widgetType": "TEXTBOX"
},
{
"auditType": "NONE",
"dataLength": "2",
"dataName": "COUNTRY_CODE2",
"dataNullable": "false",
Expand All @@ -46,6 +49,7 @@
"widgetType": "TEXTBOX"
},
{
"auditType": "NONE",
"dataLength": "3",
"dataName": "COUNTRY_CODE3",
"dataNullable": "false",
Expand All @@ -60,6 +64,7 @@
"widgetType": "TEXTBOX"
},
{
"auditType": "NONE",
"dataLength": "3",
"dataName": "COUNTRY_NUMERIC",
"dataNullable": "false",
Expand Down Expand Up @@ -90,7 +95,7 @@
"name": "Country",
"perspectiveHeader": "",
"perspectiveIcon": "globe",
"perspectiveLabel": "Entities",
"perspectiveLabel": "Settings",
"perspectiveName": "Settings",
"perspectiveNavId": "",
"perspectiveOrder": "990",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class CountryController {
this.checkPermissions('write');
this.validateEntity(entity);
entity.Id = this.repository.create(entity) as any;
response.setHeader('Content-Location', '/services/ts/codbex-countries/gen/codbex-countries/api/Settings/CountryService.ts/' + entity.Id);
response.setHeader('Content-Location', '/services/ts/codbex-countries/gen/codbex-countries/api/Settings/CountryController.ts/' + entity.Id);
response.setStatus(response.CREATED);
return entity;
} catch (error: any) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
state="{{ forms.details['Name'].$valid ? '' : 'error' }}"
ng-required="false"
ng-model="entity.Name"
ng-readonly="true"
ng-readonly="action === 'select'"
ng-maxlength="20.0"
type="text"
placeholder="{{ 'codbex-countries:codbex-countries-model.messages.inputEnter' | t:{'name':'$t(codbex-countries:codbex-countries-model.t.COUNTRY_NAME)'} }}">
Expand All @@ -52,7 +52,7 @@
state="{{ forms.details['Code2'].$valid ? '' : 'error' }}"
ng-required="false"
ng-model="entity.Code2"
ng-readonly="true"
ng-readonly="action === 'select'"
ng-maxlength="2.0"
type="text"
placeholder="{{ 'codbex-countries:codbex-countries-model.messages.inputEnter' | t:{'name':'$t(codbex-countries:codbex-countries-model.t.COUNTRY_CODE2)'} }}">
Expand All @@ -73,7 +73,7 @@
state="{{ forms.details['Code3'].$valid ? '' : 'error' }}"
ng-required="false"
ng-model="entity.Code3"
ng-readonly="true"
ng-readonly="action === 'select'"
ng-maxlength="3.0"
type="text"
placeholder="{{ 'codbex-countries:codbex-countries-model.messages.inputEnter' | t:{'name':'$t(codbex-countries:codbex-countries-model.t.COUNTRY_CODE3)'} }}">
Expand All @@ -94,7 +94,7 @@
state="{{ forms.details['Numeric'].$valid ? '' : 'error' }}"
ng-required="false"
ng-model="entity.Numeric"
ng-readonly="true"
ng-readonly="action === 'select'"
ng-maxlength="3.0"
type="text"
placeholder="{{ 'codbex-countries:codbex-countries-model.messages.inputEnter' | t:{'name':'$t(codbex-countries:codbex-countries-model.t.COUNTRY_NUMERIC)'} }}">
Expand Down
21 changes: 2 additions & 19 deletions codbex-countries/project.json
Original file line number Diff line number Diff line change
@@ -1,20 +1,3 @@
{
"guid": "codbex-countries",
"dependencies": [],
"actions": [
{
"name": "Build TypeScript",
"commands": [
{
"os": "unix",
"command": "tsc"
},
{
"os": "windows",
"command": "cmd /c tsc"
}
],
"registry": "true"
}
]
}
"guid": "codbex-countries"
}
23 changes: 0 additions & 23 deletions codbex-countries/tsconfig.json

This file was deleted.

Loading