start writing page

This commit is contained in:
2018-10-18 17:35:01 +08:00
parent 9f71819b06
commit 5199d4e44e
6 changed files with 149 additions and 48 deletions

View File

@@ -1,11 +1,29 @@
// 控制面板类
class ControlPanel {
instanceOfCell: HTMLElement;
cellId: string;
constructor(cell) {
this.instanceOfCell = cell;
constructor(cellId) {
this.cellId = cellId;
}
render() {}
update(instanceOfCells) {
const cellInfoObject = {};
const cellInfoElements = document
.getElementById("cell-info")
.getElementsByTagName("input");
for (let x = 0; x < cellInfoElements.length; x++) {
cellInfoObject[cellInfoElements[x].name] = cellInfoElements[x].value;
}
for (const instance of instanceOfCells) {
if (instance.cellId === "A1") {
for (const key in cellInfoObject) {
instance[key] = cellInfoObject[key];
}
console.log(instance);
}
}
}
setFont() {}
setFontSize() {}
setFontColor() {}
@@ -35,7 +53,6 @@ class DataResource {
class DataResourceItem {
displayName: string;
dataField: string;
constructor(name, field) {
this.displayName = name;
this.dataField = field;
@@ -121,3 +138,4 @@ interface OrderDetailsFormat {
}>;
}>;
}
export { ControlPanel };