diff --git a/65734.83a38e50.async.js b/65734.6e7d71ed.async.js
similarity index 98%
rename from 65734.83a38e50.async.js
rename to 65734.6e7d71ed.async.js
index 05b0526d7d..01c5d5745d 100644
--- a/65734.83a38e50.async.js
+++ b/65734.6e7d71ed.async.js
@@ -644,9 +644,11 @@ var graduations = __webpack_require__(91154);
var Page = function Page(_ref) {
+ var _info$graduation_year;
var globalSetting = _ref.globalSetting,
dispatch = _ref.dispatch,
user = _ref.user,
+ info = _ref.info,
open = _ref.open,
_ref$onCancel = _ref.onCancel,
onCancel = _ref$onCancel === void 0 ? function () {} : _ref$onCancel;
@@ -695,32 +697,30 @@ var Page = function Page(_ref) {
return regeneratorRuntime_default()().wrap(function _callee$(_context) {
while (1) switch (_context.prev = _context.next) {
case 0:
- _context.next = 2;
- return getList(params);
- case 2:
- res = _context.sent;
+ // const res = await getList(params)
+ res = info;
if ((0,verifyLogin/* handleVerifyLogin */.o1)(dispatch)) {
- _context.next = 5;
+ _context.next = 3;
break;
}
return _context.abrupt("return");
- case 5:
+ case 3:
_ref3 = user.userInfo || {}, _ref3$user_school_id = _ref3.user_school_id, user_school_id = _ref3$user_school_id === void 0 ? '' : _ref3$user_school_id, _ref3$department_id = _ref3.department_id, department_id = _ref3$department_id === void 0 ? "" : _ref3$department_id, _ref3$school_name = _ref3.school_name, school_name = _ref3$school_name === void 0 ? '' : _ref3$school_name, _ref3$department_name = _ref3.department_name, department_name = _ref3$department_name === void 0 ? '' : _ref3$department_name;
year = res === null || res === void 0 || (_res$graduation_years = res.graduation_years) === null || _res$graduation_years === void 0 ? void 0 : _res$graduation_years.at(-1);
setSchools([{
id: user_school_id,
name: school_name
}]);
- _context.next = 10;
+ _context.next = 8;
return HandleGetDepartments(user_school_id);
- case 10:
+ case 8:
addForm.setFieldsValue({
year: year,
school_id: user_school_id,
department_id: Number(department_id),
name: "".concat(year).concat(school_name).concat(department_name, "\u6BD5\u4E1A\u8BBE\u8BA1")
});
- case 11:
+ case 9:
case "end":
return _context.stop();
}
@@ -894,7 +894,7 @@ var Page = function Page(_ref) {
width: 344
},
size: "large",
- options: years.map(function (item) {
+ options: info === null || info === void 0 || (_info$graduation_year = info.graduation_years) === null || _info$graduation_year === void 0 ? void 0 : _info$graduation_year.map(function (item) {
return {
value: item,
label: item
@@ -1157,6 +1157,8 @@ var JoinGraduationsModal_Page = function Page(_ref) {
+
+
var _excluded = ["homePage", "user", "globalSetting", "loading", "dispatch", "location"];
@@ -1170,6 +1172,7 @@ var _excluded = ["homePage", "user", "globalSetting", "loading", "dispatch", "lo
+
var VerifyType = /*#__PURE__*/function (VerifyType) {
VerifyType["Projects"] = "projects";
VerifyType["Shixuns"] = "shixuns";
@@ -1215,6 +1218,10 @@ var Join = function Join(_ref) {
_useState10 = slicedToArray_default()(_useState9, 2),
showdrop = _useState10[0],
setShowDrop = _useState10[1];
+ var _useState11 = (0,_react_17_0_2_react.useState)(),
+ _useState12 = slicedToArray_default()(_useState11, 2),
+ info = _useState12[0],
+ setInfo = _useState12[1];
function isLinkHidden(navbar, link) {
var _iterator = createForOfIteratorHelper_default()(navbar),
_step;
@@ -1308,10 +1315,51 @@ var Join = function Join(_ref) {
children: "\u65B0\u5EFA\u5F00\u53D1\u9879\u76EE"
})
})), (user === null || user === void 0 || (_user$userInfo10 = user.userInfo) === null || _user$userInfo10 === void 0 ? void 0 : _user$userInfo10.identity) !== 'student' && !isGraduationsHidden && /*#__PURE__*/(0,jsx_runtime.jsx)(menu/* default */.Z.Item, objectSpread2_default()(objectSpread2_default()({}, joinProps), {}, {
- onClick: function onClick() {
- if (!(0,verifyLogin/* handleVerifyLogin */.o1)(dispatch)) return;
- setIsNewGraduations(true);
- },
+ onClick: /*#__PURE__*/asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee() {
+ var res;
+ return regeneratorRuntime_default()().wrap(function _callee$(_context) {
+ while (1) switch (_context.prev = _context.next) {
+ case 0:
+ if ((0,verifyLogin/* handleVerifyLogin */.o1)(dispatch)) {
+ _context.next = 2;
+ break;
+ }
+ return _context.abrupt("return");
+ case 2:
+ _context.next = 4;
+ return (0,graduations/* getGraduations */.J3)({
+ keyword: '',
+ source: '',
+ status: '',
+ page: 1,
+ limit: 20,
+ tab_module_type: 'graduations'
+ });
+ case 4:
+ res = _context.sent;
+ if (!(res !== null && res !== void 0 && res.un_purchased)) {
+ _context.next = 8;
+ break;
+ }
+ dispatch({
+ type: 'globalSetting/setActionTabs',
+ payload: {
+ key: '采购提示'
+ }
+ });
+ return _context.abrupt("return");
+ case 8:
+ if (res.status === 0) {
+ setInfo(res);
+ setIsNewGraduations(true);
+ }
+ // setIsNewGraduations(true)
+ case 9:
+ case "end":
+ return _context.stop();
+ }
+ }, _callee);
+ })),
children: /*#__PURE__*/(0,jsx_runtime.jsx)("a", {
children: "\u65B0\u5EFA\u6BD5\u4E1A\u8BBE\u8BA1"
})
@@ -1398,6 +1446,7 @@ var Join = function Join(_ref) {
return setVisibleJoinProject(false);
}
}), /*#__PURE__*/(0,jsx_runtime.jsx)(NewGraduationsModal, {
+ info: info,
open: isNewGraduations,
onCancel: function onCancel() {
return setIsNewGraduations(false);
@@ -1410,11 +1459,11 @@ var Join = function Join(_ref) {
})]
});
};
-/* harmony default export */ var components_Join = ((0,_umi_production_exports.connect)(function (_ref2) {
- var homePage = _ref2.homePage,
- loading = _ref2.loading,
- user = _ref2.user,
- globalSetting = _ref2.globalSetting;
+/* harmony default export */ var components_Join = ((0,_umi_production_exports.connect)(function (_ref3) {
+ var homePage = _ref3.homePage,
+ loading = _ref3.loading,
+ user = _ref3.user,
+ globalSetting = _ref3.globalSetting;
return {
homePage: homePage,
user: user,
diff --git a/index.html b/index.html
index 2876a9f640..06a9139717 100644
--- a/index.html
+++ b/index.html
@@ -26,7 +26,7 @@
display: block !important;
}
-
+