onNodeClick(row, evt)}
onDblclick={() => onNodeDbClick(row)}
onContextmenu={evt => onNodeContextmenu(row, evt)}
@@ -636,6 +652,21 @@ export const GanttControl = defineComponent({
return [..._columns, slider];
};
+ /**
+ * 绘制设置
+ */
+ const renderSetting = (): JSX.Element => {
+ return (
+
onSettingClick()}>
+
+
+ );
+ };
+
return {
c,
ns,
@@ -652,6 +683,7 @@ export const GanttControl = defineComponent({
onNodeExpand,
onNodeCollapse,
renderContent,
+ renderSetting,
onSliderMove,
renderNoData,
allowDrop,
@@ -694,6 +726,13 @@ export const GanttControl = defineComponent({
onMoveSlider={this.onSliderMove}
primaryColor={this.ganttStyle.primaryColor}
headerStyle={{ textColor: this.ganttStyle.textColor }}
+ borderColor={this.ganttStyle.borderColor}
+ bodyStyle={{
+ todayColor: this.ganttStyle.todayColor,
+ weekendColor: this.ganttStyle.weekendColor,
+ bgColor: this.ganttStyle.bgColor,
+ selectColor: this.ganttStyle.weekendColor,
+ }}
>
{{
default: () => {
@@ -702,6 +741,9 @@ export const GanttControl = defineComponent({
empty: () => {
return this.renderNoData();
},
+ setting: () => {
+ return this.renderSetting();
+ },
}}
diff --git a/src/locale/en/index.ts b/src/locale/en/index.ts
index 97083943aa97692060ecc63256569b0f1691c616..c29da447a9646894b9f55db9b5b536beb05bcbb7 100644
--- a/src/locale/en/index.ts
+++ b/src/locale/en/index.ts
@@ -536,6 +536,12 @@ export default {
gridSetting: {
hideControl: 'Column selection',
},
+ ganttSetting: {
+ resultDefault: 'Restore defaults',
+ headerCaption: 'Header display attributes',
+ optionalAttribute: 'Optional attributes',
+ selectedAttribute: 'Selected attributes',
+ },
actionToolbar: {
more: 'More',
},
diff --git a/src/locale/zh-CN/index.ts b/src/locale/zh-CN/index.ts
index 67aab238ccc3a12abccd984d0289d7f019da4e56..c267eec4f63c3ccc0f3f0f00f8514d0d1e12b55f 100644
--- a/src/locale/zh-CN/index.ts
+++ b/src/locale/zh-CN/index.ts
@@ -498,6 +498,12 @@ export default {
gridSetting: {
hideControl: '列选择',
},
+ ganttSetting: {
+ resultDefault: '恢复默认值',
+ headerCaption: '表头显示属性',
+ optionalAttribute: '可选属性',
+ selectedAttribute: '已选择属性',
+ },
actionToolbar: {
more: '更多',
},