|
@@ -14,7 +14,7 @@ let calcBaseView = {
|
|
|
setting:{
|
|
|
header: [
|
|
|
{name: '计算基础名称', dataCode: 'base', width: 280, vAlign: 'center', hAlign: 'left'},
|
|
|
- {name: '金额', dataCode: 'price', width: 120, vAlign: 'center', hAlign: 'left'}
|
|
|
+ {name: '金额', dataCode: 'price', width: 120, vAlign: 'center', hAlign: 'right'}
|
|
|
],
|
|
|
options: {
|
|
|
tabStripVisible: false,
|
|
@@ -84,7 +84,7 @@ let calcBaseView = {
|
|
|
sheet.setFormatter(-1, 1, '@');
|
|
|
for(let col = 0, cLen = cols.length; col < cLen; col++){
|
|
|
sheet.getRange(-1, col, -1, 1).hAlign(GC.Spread.Sheets.HorizontalAlign[cols[col]['hAlign']]);
|
|
|
- sheet.getRange(-1, col, -1, 1).hAlign(GC.Spread.Sheets.VerticalAlign[cols[col]['vAlign']]);
|
|
|
+ sheet.getRange(-1, col, -1, 1).vAlign(GC.Spread.Sheets.VerticalAlign[cols[col]['vAlign']]);
|
|
|
for(let row = 0, rLen = datas.length; row < rLen; row++){
|
|
|
sheet.setValue(row, col, datas[row][cols[col]['dataCode']]);
|
|
|
}
|
|
@@ -210,8 +210,9 @@ let calcBaseView = {
|
|
|
CalcBaseCellType.prototype = new ns.CellTypes.Text();
|
|
|
CalcBaseCellType.prototype.paint = function (ctx, value, x, y, w, h, style, options) {
|
|
|
if(value!=null){
|
|
|
- // ctx.fillText(value,x+3+ctx.measureText(value).width,y+h-3);
|
|
|
- ctx.fillText(value,x+w,y+h-3);
|
|
|
+ // ctx.fillText(value,x+3+ctx.measureText(value).width,y+h-3);
|
|
|
+ // ctx.fillText(value,x+w-3,y+h-3);
|
|
|
+ GC.Spread.Sheets.CellTypes.Text.prototype.paint.apply(this, arguments);
|
|
|
}
|
|
|
if(calcBaseView.editingCell){
|
|
|
if(calcBaseView.editingCell.row==options.row&&calcBaseView.editingCell.col==options.col){
|