Social status history

This commit is contained in:
Natsumi
2021-05-29 21:01:56 +12:00
parent 8198d2a4fc
commit 657ae20cd0
2 changed files with 34 additions and 1 deletions

View File

@@ -7127,6 +7127,14 @@ speechSynthesis.getVoices();
},
layout: 'table'
};
$app.data.socialStatusHistoryTable = {
data: [],
tableProps: {
stripe: true,
size: 'mini'
},
layout: 'table'
};
$app.data.visits = 0;
$app.data.openVR = configRepository.getBool('openVR');
$app.data.openVRAlways = configRepository.getBool('openVRAlways');
@@ -9380,11 +9388,29 @@ speechSynthesis.getVoices();
$app.methods.showSocialStatusDialog = function () {
this.$nextTick(() => adjustDialogZ(this.$refs.socialStatusDialog.$el));
var D = this.socialStatusDialog;
var { statusHistory } = API.currentUser;
var statusHistoryArray = [];
for (var i = 0; i < statusHistory.length; ++i) {
var addStatus = {
no: i + 1,
status: statusHistory[i]
}
statusHistoryArray.push(addStatus);
}
this.socialStatusHistoryTable.data = statusHistoryArray;
D.status = API.currentUser.status;
D.statusDescription = API.currentUser.statusDescription;
D.visible = true;
};
$app.methods.setSocialStatusFromHistory = function (val) {
if (val === null) {
return;
}
var D = this.socialStatusDialog;
D.statusDescription = val.status;
};
// App: Language Dialog
$app.data.languageDialog = {