Skip to content

Commit 2fc0712

Browse files
committed
setup data and fiscal year
1 parent ec33294 commit 2fc0712

6 files changed

Lines changed: 52 additions & 46 deletions

File tree

src/AccountGoWeb/Views/Financials/Accounts.cshtml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,16 @@
77
</div>
88
<script>
99
var columnDefs = [
10-
{headerName: "Group", cellRenderer: 'group'},
10+
{ headerName: "Group", cellRenderer: 'agGroupCellRenderer'},
1111
{headerName: "Code", width: 100, cellRenderer: function(val){
1212
return "<a href='account/" + val.data.id + "'>" + val.data.accountCode + "</a>";
1313
}},
1414
{headerName: "Name", field: "accountName", width: 350, cellRenderer: function(val){
1515
if(val.data.childAccounts.length > 0)
1616
return "";
1717
return val.data.accountName;
18-
}},
18+
}
19+
},
1920
{headerName: "Description", field: "description", width: 250},
2021
{headerName: "Cash", width: 100, cellRenderer: function(val) {
2122
if(val.data.isCash)
@@ -56,7 +57,7 @@
5657
icons: {
5758
groupExpanded: '<i class="fa fa-minus-square-o"/>',
5859
groupContracted: '<i class="fa fa-plus-square-o"/>'
59-
},
60+
},
6061
// PROPERTIES
6162
rowSelection: 'single',
6263
enableFilter: true,

src/AccountGoWeb/Views/Financials/GeneralLedger.cshtml

Lines changed: 34 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -6,34 +6,40 @@
66
<div id="masterGL" class="ag-blue"></div>
77
</div>
88
<script>
9-
10-
119
var columnDefs = [
12-
{headerName: "Group", cellRenderer: 'group'},
13-
//{headerName: "GL", field: "id", width: 100, callRenderer : function (val) {
14-
// return val.data.id == 0 || val.data.id ? '' : val.data.GL;
15-
//}},
16-
{headerName: "Account", field: "accountName", width: 350, cellRenderer: function(val){
17-
18-
if(val.data.length > 0)
19-
return "";
20-
return val.data.accountName;
21-
}},
22-
{headerName: "Date", field: "date", width: 250, cellRenderer: function(val){
23-
if(val.data.length > 0)
24-
return val.data.date;
25-
return val.data.date;
26-
}},
27-
{headerName: "Debit", field: "debit", width: 100, cellRenderer: function(val){
28-
if(val.data.length > 0)
29-
return val.data.debit;
30-
return val.data.debit;
31-
}},
32-
{headerName: "Credit", field: "credit", width: 100, cellRenderer: function(val){
33-
if(val.data.length > 0)
34-
return val.data.credit == 'undefined' ? '' : val.data.credit;
35-
return val.data.credit;
36-
}}
10+
{ headerName: "Group", cellRenderer: 'agGroupCellRenderer' },
11+
//{headerName: "GL", field: "id", width: 100, callRenderer : function (val) {
12+
// return val.data.id == 0 || val.data.id ? '' : val.data.GL;
13+
//}},
14+
{
15+
headerName: "Account", field: "accountName", width: 350, cellRenderer: function (val) {
16+
17+
if (val.data.length > 0)
18+
return "";
19+
return val.data.accountName;
20+
}
21+
},
22+
{
23+
headerName: "Date", field: "date", width: 250, cellRenderer: function (val) {
24+
if (val.data.length > 0)
25+
return val.data.date;
26+
return val.data.date;
27+
}
28+
},
29+
{
30+
headerName: "Debit", field: "debit", width: 100, cellRenderer: function (val) {
31+
if (val.data.length > 0)
32+
return val.data.debit;
33+
return val.data.debit;
34+
}
35+
},
36+
{
37+
headerName: "Credit", field: "credit", width: 100, cellRenderer: function (val) {
38+
if (val.data.length > 0)
39+
return val.data.credit == 'undefined' ? '' : val.data.credit;
40+
return val.data.credit;
41+
}
42+
}
3743
];
3844
var xx;
3945
var gridOptions = {
@@ -62,7 +68,7 @@
6268
enableColResize: true,
6369
};
6470
65-
71+
6672
6773
function autoSizeAll() {
6874
var allColumnIds = [];

src/AccountGoWeb/appsettings.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
{
22
"ApiUrl": "https://accountgoapi.azurewebsites.net/api/"
3+
//"ApiUrl": "http://localhost:5000/api/"
34
}

src/AccountGoWeb/webpack.config.js

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@ var path = require('path');
44

55
var buildDir = path.resolve(__dirname, './wwwroot/scripts');
66
var scriptsDir = path.resolve(__dirname, './wwwroot/libs/tsxbuild');
7-
//var scriptsDir = path.resolve(__dirname, './Scripts');
87

98
var config = {
109
entry: {
11-
home: scriptsDir + '/home' + '/home',
10+
index: scriptsDir + '/home' + '/index',
1211
"sales/salesorder": scriptsDir + '/sales/salesorder',
1312
"quotations/salesquotation": scriptsDir + '/quotations/salesquotation',
1413
"sales/salesinvoice": scriptsDir + '/sales/salesinvoice',
@@ -25,27 +24,26 @@ var config = {
2524
extensions: ['.js', '.jsx', '.tsx']
2625
},
2726
devtool: 'source-map',
28-
//module: {
29-
// loaders: [
30-
// {
31-
// test: /\.tsx$/,
32-
// loader: 'ts-loader',
33-
// exclude: /(node_modules)/
34-
// }
35-
// ]
36-
//},
3727
plugins: [
3828
new webpack.optimize.CommonsChunkPlugin({
3929
name: "vendor"
30+
}),
31+
new webpack.ProvidePlugin({
32+
$: 'jquery',
33+
jQuery: 'jquery',
34+
'window.jQuery': 'jquery',
35+
Popper: ['popper.js', 'default']
4036
})
4137
],
4238
externals: {
4339
'Config': JSON.stringify(process.env.ENV === 'production' ?
4440
{
4541
apiUrl: "https://accountgoapi.azurewebsites.net/"
42+
//apiUrl: "http://localhost:5000/"
4643
} :
4744
{
4845
apiUrl: "https://accountgoapi.azurewebsites.net/"
46+
//apiUrl: "http://localhost:5000/"
4947
})
5048
}
5149
};

src/Api/Controllers/AdministrationController.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -458,10 +458,10 @@ private void InitializeFinancialYear()
458458
if (_adminService.GetFinancialYears().Count >= 1) return;
459459
var financialYear = new Core.Domain.Financials.FinancialYear
460460
{
461-
FiscalYearCode = "FY1516",
462-
FiscalYearName = "FY 2016/2017",
463-
StartDate = new DateTime(2016, 01, 01),
464-
EndDate = new DateTime(2016, 12, 31),
461+
FiscalYearCode = "FY1819",
462+
FiscalYearName = "FY 2018/2019",
463+
StartDate = new DateTime(2018, 01, 01),
464+
EndDate = new DateTime(2018, 12, 31),
465465
IsActive = true
466466
};
467467
_financialService.SaveFinancialYear(financialYear);

0 commit comments

Comments
 (0)