update web
This commit is contained in:
parent
9a73bc2a18
commit
42a56df4a5
6 changed files with 30 additions and 18 deletions
|
@ -1,6 +1,7 @@
|
|||
package v1
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"net/http"
|
||||
"reflect"
|
||||
"strconv"
|
||||
|
@ -309,12 +310,12 @@ func AddPartition(c *gin.Context) {
|
|||
formatBool := true
|
||||
for formatBool {
|
||||
currentDisk = service.MyService.Disk().GetDiskInfo(path)
|
||||
if len(currentDisk.Children) != 1 {
|
||||
fmt.Println(currentDisk.Children)
|
||||
if len(currentDisk.Children) > 0 {
|
||||
formatBool = false
|
||||
break
|
||||
}
|
||||
time.Sleep(time.Second)
|
||||
|
||||
}
|
||||
currentDisk = service.MyService.Disk().GetDiskInfo(path)
|
||||
if len(currentDisk.Children) != 1 {
|
||||
|
|
BIN
web/img/USB.3ba78dec.png
Normal file
BIN
web/img/USB.3ba78dec.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 12 KiB |
19
web/js/2.js
19
web/js/2.js
File diff suppressed because one or more lines are too long
|
@ -8,7 +8,7 @@
|
|||
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||||
|
||||
"use strict";
|
||||
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vee_validate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vee-validate */ \"./node_modules/vee-validate/dist/vee-validate.esm.js\");\n/* harmony import */ var _plugins_vee_validate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @/plugins/vee-validate */ \"./src/plugins/vee-validate.js\");\n/* harmony import */ var lottie_web_vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! lottie-web-vue */ \"./node_modules/lottie-web-vue/dist/lottie-web-vue.esm.js\");\n/* harmony import */ var vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vue-smooth-reflow */ \"./node_modules/vue-smooth-reflow/dist/vue-smooth-reflow.min.js\");\n/* harmony import */ var vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3__);\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"Welcome\",\n mixins: [vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3___default.a],\n data: function data() {\n return {\n step: 1,\n username: '',\n password: '',\n confirmation: \"\",\n isLoading: true,\n message: \"\",\n notificationShow: false,\n initAni: {\n classes: 'zoomIn',\n delay: 1000,\n duration: 700\n },\n s1Ani: {\n classes: 'fadeInUp',\n delay: 1300,\n duration: 700\n },\n s2Ani: {\n classes: 'fadeInUp',\n delay: 1700,\n duration: 700\n },\n s3Ani: {\n classes: 'fadeInUp',\n delay: 1900,\n duration: 700\n },\n s4Ani: {\n classes: 'fadeIn',\n delay: 2500,\n duration: 700\n }\n };\n },\n components: {\n ValidationObserver: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationObserver\"],\n ValidationProvider: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationProvider\"],\n LottieAnimation: lottie_web_vue__WEBPACK_IMPORTED_MODULE_2__[\"default\"]\n },\n created: function created() {\n var lang = navigator.language || navigator.userLanguage;\n console.log(lang);\n },\n mounted: function mounted() {\n this.$smoothReflow({\n el: '.login-panel',\n property: ['height', 'width']\n });\n this.isLoading = false;\n },\n methods: {\n reg: function reg() {\n var _this = this;\n\n this.$api.user.createUsernameAndPaword({\n username: this.username,\n pwd: this.password\n }).then(function (res) {\n if (res.data.success == 200) {\n _this.goToStep(3);\n }\n });\n },\n login: function login() {\n var _this2 = this;\n\n this.$api.user.login({\n username: this.username,\n pwd: this.password\n }).then(function (res) {\n if (res.data.success == 200) {\n localStorage.setItem(\"user_token\", res.data.data.token);\n localStorage.setItem(\"version\", res.data.data.version);\n\n _this2.$store.commit('setToken', res.data.data.token);\n\n _this2.$api.user.getUserInfo().then(function (res) {\n if (res.data.success == 200) {\n _this2.$store.commit('changeUserInfo', res.data.data);\n\n _this2.$router.push('/');\n }\n });\n } else {\n _this2.notificationShow = true;\n _this2.message = _this2.$t(\"Username or Password error!\");\n }\n });\n },\n goToStep: function goToStep(step) {\n this.step = step;\n },\n complete: function complete() {\n this.login();\n }\n }\n});\n\n//# sourceURL=webpack:///./src/views/Welcome.vue?./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options");
|
||||
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vee_validate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vee-validate */ \"./node_modules/vee-validate/dist/vee-validate.esm.js\");\n/* harmony import */ var _plugins_vee_validate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @/plugins/vee-validate */ \"./src/plugins/vee-validate.js\");\n/* harmony import */ var lottie_web_vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! lottie-web-vue */ \"./node_modules/lottie-web-vue/dist/lottie-web-vue.esm.js\");\n/* harmony import */ var vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vue-smooth-reflow */ \"./node_modules/vue-smooth-reflow/dist/vue-smooth-reflow.min.js\");\n/* harmony import */ var vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3__);\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"Welcome\",\n mixins: [vue_smooth_reflow__WEBPACK_IMPORTED_MODULE_3___default.a],\n data: function data() {\n return {\n step: 1,\n username: '',\n password: '',\n confirmation: \"\",\n isLoading: true,\n message: \"\",\n notificationShow: false,\n isInit: false,\n initAni: {\n classes: 'zoomIn',\n delay: 1000,\n duration: 700\n },\n s1Ani: {\n classes: 'fadeInUp',\n delay: 1300,\n duration: 700\n },\n s2Ani: {\n classes: 'fadeInUp',\n delay: 1700,\n duration: 700\n },\n s3Ani: {\n classes: 'fadeInUp',\n delay: 1900,\n duration: 700\n },\n s4Ani: {\n classes: 'fadeIn',\n delay: 2500,\n duration: 700\n }\n };\n },\n components: {\n ValidationObserver: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationObserver\"],\n ValidationProvider: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationProvider\"],\n LottieAnimation: lottie_web_vue__WEBPACK_IMPORTED_MODULE_2__[\"default\"]\n },\n created: function created() {\n // var lang = navigator.language || navigator.userLanguage;\n this.isInit = !this.$store.state.needInitialization;\n\n if (this.isInit) {\n this.$router.push(\"/login\");\n }\n },\n mounted: function mounted() {\n this.$smoothReflow({\n el: '.login-panel',\n property: ['height', 'width']\n });\n this.isLoading = false;\n },\n watch: {\n // Watch System Initialization\n '$store.state.needInitialization': {\n handler: function handler(data) {\n this.isInit = !data;\n\n if (this.isInit) {\n this.$router.push(\"/login\");\n }\n },\n deep: true\n }\n },\n methods: {\n reg: function reg() {\n var _this = this;\n\n this.$api.user.createUsernameAndPaword({\n username: this.username,\n pwd: this.password\n }).then(function (res) {\n if (res.data.success == 200) {\n _this.goToStep(3);\n }\n });\n },\n login: function login() {\n var _this2 = this;\n\n this.$api.user.login({\n username: this.username,\n pwd: this.password\n }).then(function (res) {\n if (res.data.success == 200) {\n localStorage.setItem(\"user_token\", res.data.data.token);\n localStorage.setItem(\"version\", res.data.data.version);\n\n _this2.$store.commit('setToken', res.data.data.token);\n\n _this2.$api.user.getUserInfo().then(function (res) {\n if (res.data.success == 200) {\n _this2.$store.commit('changeUserInfo', res.data.data);\n\n _this2.$router.push('/');\n }\n });\n } else {\n _this2.notificationShow = true;\n _this2.message = _this2.$t(\"Username or Password error!\");\n }\n });\n },\n goToStep: function goToStep(step) {\n this.step = step;\n },\n complete: function complete() {\n this.login();\n }\n }\n});\n\n//# sourceURL=webpack:///./src/views/Welcome.vue?./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options");
|
||||
|
||||
/***/ }),
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||||
|
||||
"use strict";
|
||||
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vee_validate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vee-validate */ \"./node_modules/vee-validate/dist/vee-validate.esm.js\");\n/* harmony import */ var _plugins_vee_validate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @/plugins/vee-validate */ \"./src/plugins/vee-validate.js\");\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"Login\",\n data: function data() {\n return {\n username: '',\n password: '',\n isLoading: true,\n message: \"\",\n notificationShow: false,\n isInit: false\n };\n },\n components: {\n ValidationObserver: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationObserver\"],\n ValidationProvider: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationProvider\"]\n },\n mounted: function mounted() {\n var _this = this;\n\n this.$api.info.guideCheck().then(function (res) {\n if (res.data.success == 200 && res.data.data.need_init_user) {\n _this.isLoading = false;\n } else {\n _this.isLoading = true;\n }\n });\n this.$api.user.getUserInfo().then(function (user) {\n _this.username = user.data.data.user_name;\n });\n },\n methods: {\n login: function login() {\n var _this2 = this;\n\n this.$api.user.login({\n username: this.username,\n pwd: this.password\n }).then(function (res) {\n if (res.data.success == 200) {\n localStorage.setItem(\"user_token\", res.data.data.token);\n localStorage.setItem(\"version\", res.data.data.version);\n\n _this2.$store.commit('setToken', res.data.data.token);\n\n _this2.$api.user.getUserInfo().then(function (res) {\n if (res.data.success == 200) {\n _this2.$store.commit('changeUserInfo', res.data.data);\n\n _this2.$router.push('/');\n }\n });\n } else {\n _this2.notificationShow = true;\n _this2.message = _this2.$t(\"Password error!\");\n }\n });\n }\n }\n});\n\n//# sourceURL=webpack:///./src/views/Login.vue?./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options");
|
||||
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vee_validate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! vee-validate */ \"./node_modules/vee-validate/dist/vee-validate.esm.js\");\n/* harmony import */ var _plugins_vee_validate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @/plugins/vee-validate */ \"./src/plugins/vee-validate.js\");\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"Login\",\n data: function data() {\n return {\n username: '',\n password: '',\n isLoading: false,\n message: \"\",\n notificationShow: false,\n isInit: false\n };\n },\n components: {\n ValidationObserver: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationObserver\"],\n ValidationProvider: vee_validate__WEBPACK_IMPORTED_MODULE_0__[\"ValidationProvider\"]\n },\n created: function created() {\n this.isInit = !this.$store.state.needInitialization;\n\n if (!this.isInit) {\n this.$router.push(\"/welcome\");\n }\n },\n mounted: function mounted() {\n var _this = this;\n\n this.$api.user.getUserInfo().then(function (user) {\n _this.username = user.data.data.user_name;\n });\n },\n watch: {\n // Watch System Initialization\n '$store.state.needInitialization': {\n handler: function handler(data) {\n this.isInit = !data;\n\n if (!this.isInit) {\n this.$router.push(\"/welcome\");\n }\n },\n deep: true\n }\n },\n methods: {\n login: function login() {\n var _this2 = this;\n\n this.$api.user.login({\n username: this.username,\n pwd: this.password\n }).then(function (res) {\n if (res.data.success == 200) {\n localStorage.setItem(\"user_token\", res.data.data.token);\n localStorage.setItem(\"version\", res.data.data.version);\n\n _this2.$store.commit('setToken', res.data.data.token);\n\n _this2.$api.user.getUserInfo().then(function (res) {\n if (res.data.success == 200) {\n _this2.$store.commit('changeUserInfo', res.data.data);\n\n _this2.$router.push('/');\n }\n });\n } else {\n _this2.notificationShow = true;\n _this2.message = _this2.$t(\"Password error!\");\n }\n });\n }\n }\n});\n\n//# sourceURL=webpack:///./src/views/Login.vue?./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options");
|
||||
|
||||
/***/ }),
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue