瀏覽代碼

add ignore

maguohua 7 年之前
父節點
當前提交
b276e000cb
共有 7 個文件被更改,包括 6 次插入4 次删除
  1. 二進制
      .DS_Store
  2. 3 1
      .gitignore
  3. 1 1
      models/shopping/shop.js
  4. 1 1
      mongodb/db.js
  5. 二進制
      prototype/16018a6492334.jpeg
  6. 1 1
      prototype/addressComponent.js
  7. 二進制
      public/.DS_Store

二進制
.DS_Store


+ 3 - 1
.gitignore

@@ -1,3 +1,5 @@
 npm-debug.log
 node_modules
-coverage
+coverage
+package-lock.json
+public/img/

+ 1 - 1
models/shopping/shop.js

@@ -72,7 +72,7 @@ const shopSchema = new mongoose.Schema({
 	}],
 });
 
-shopSchema.index({ id: 1 });
+shopSchema.index({ id: 1 }); //primary_key 主键
 
 const Shop = mongoose.model('Shop', shopSchema);
 

+ 1 - 1
mongodb/db.js

@@ -8,7 +8,7 @@ mongoose.Promise = global.Promise;
 const db = mongoose.connection;
 
 db.once('open' ,() => {
-	console.log('连接数据库成功')
+	console.log('连接数据库成功');
 })
 
 db.on('error', function(error) {

二進制
prototype/16018a6492334.jpeg


+ 1 - 1
prototype/addressComponent.js

@@ -23,7 +23,7 @@ class AddressComponent extends BaseComponent {
 	 		const ipArr = ip.split(':');
 	 		ip = ipArr[ipArr.length -1];
 	 		if (process.env.NODE_ENV == 'development') {
-	 			ip = '116.226.184.83';
+	 			ip = '220.249.123.162';
 	 		}
 	 		try{
 	 			let result;

二進制
public/.DS_Store